Re: [google-appengine] Re: Plans for Node.js on App Engine Standard?

2017-03-27 Thread Attila-Mihaly Balazs
Note that there is an (undocumented AFAIK) restriction that you can't 
transactionally enqueue *named* tasks :-(

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/d0ef8dcb-917e-4a31-9725-725293267c13%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Production SDK stuck at 1.9.48?

2017-03-27 Thread Attila-Mihaly Balazs
Sorry y'all, but getting back to the original topic: both of my 
applications (I have a "staging" and a "production" one) are stuck on 
1.9.48, even though 1.9.51 is out!

Relevant logs:

- Staging:

 - - [27/Mar/2017:10:49:55 +0300] "POST  HTTP/1.1" 200 137 
- "" "" ms=12 cpu_ms=6 cpm_usd=1.531e-8 loading_request=0 
instance=00c61b117c3d531f29ab70f01f432a316cff3c620255897cf3b3016d31b95d3cff0023c4189f0e
 
*app_engine_release=1.9.48* trace_id=-

- Production:

 - - [27/Mar/2017:10:49:21 +0300] "GET  HTTP/1.1" 302 - - "
" "" ms=661 cpu_ms=0 cpm_usd=0 loading_request=0 instance=- 
*app_engine_release=1.9.48* trace_id=5da331cbc41493ef21734a0d6b83c920


I used the latest python SDK (1.9.51) to do the deploy. I will also try it 
with gcloud, however it takes a little while to update the deployment 
script (and I also want to use this opportunity to parralelize the 
deployment of our different modules/services to reduce the deploy time).

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/ee9c3a14-e73f-4569-9c01-ceabd78c7826%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Start page not shown

2017-03-27 Thread Fabio Gonçalves
Hi, I published all my *.html and *.jpg, etc. via Google App Engine. 
These files are reachable. When I enter 
https://fogo-guide.appspot.com/index.html the page is shown. 
But when I try https://fogo-guide.appspot.com/ I get an error message:

Traceback (most recent call last):
  File 
"/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/runtime/wsgi.py",
 line 240, in Handle
handler = _config_handle.add_wsgi_middleware(self._LoadHandler())
  File 
"/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/runtime/wsgi.py",
 line 302, in _LoadHandler
raise err
ImportError:  has no 
attribute php

What' wrong? Deployment ends without any error message. 

The app.yaml I added. 

The main.php has only one dummy line:

https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/9fe0f6bb-2150-4314-a733-8f97814fd333%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


app.yaml
Description: Binary data


Re: [google-appengine] Make appspot URL unsearchable

2017-03-27 Thread himanshu kapoor
I am using the browser to access the URL but it does not redirect me to 
google login page. Mostly I am already logged In with user ID of the 
project owner.

On Monday, March 27, 2017 at 11:00:43 AM UTC+5:30, Attila-Mihaly Balazs 
wrote:
>
> Yes, "login: admin" is independent of the runtime you use. Are you using a 
> browser to access the URL or some kind of tool (like cURL?). In the browser 
> it should redirect you to the google login page to ensure that you're 
> logged in with a google user that has "owner" level permissions on the 
> project.
>
> Attila
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/a7d786f0-996e-4a25-8da1-804b9558f5cb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Production SDK stuck at 1.9.48?

2017-03-27 Thread pdknsk
I'm on 1.9.48 and use gcloud. Might be a display bug.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/54569bd9-e57b-4e78-a035-abf2df2d686b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Flexible Environment deployments are not supported in the apps region 'europe-west'.

2017-03-27 Thread pdknsk
It's a different reason that Google won't tell you.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/03452f26-247e-4036-957b-bbb6c70527ca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Production SDK stuck at 1.9.48?

2017-03-27 Thread Attila-Mihaly Balazs
I'm pretty sure it isn't a display bug since I used to also see "1.9.48" 
listed next to each instance on the "Instances" page (I no longer see it - 
perhaps they changed something and no longer display that column?)

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/53636d7f-dadc-4a8b-ab89-0eedd1fe5d76%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Production SDK stuck at 1.9.48?

2017-03-27 Thread pdknsk
gcloud prints the same.

$ gcloud app instances describe  --service default --version 

appEngineRelease: 1.9.48
...

I doubt it makes a differences as there have been no significant updates in 
months, if not years.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/c51b49e7-1bf3-44b7-91a4-ef0347eba0da%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Problems with deploying App Engine application

2017-03-27 Thread 'Nick (Cloud Platform Support)' via Google App Engine
Hey Augusto,

Which account is signed in with the gcloud tool? Are you sure that account 
has EDITOR privileges on the project? 

Keep in mind that this forum isn't meant for technical support, and ideally 
you should post a question like this to stackoverflow.com, including enough 
details about your situation that someone else could begin to look into the 
issue.  

Cheers,

Nick
Cloud Platform Community Support

On Sunday, March 26, 2017 at 6:09:35 PM UTC-4, Augusto Cadini wrote:
>
> Hi, I have the same error! and I follow your tip but not works! No exists 
> "Cloud Container Build"
>
> Em domingo, 20 de novembro de 2016 22:29:11 UTC-2, Jacquelin Hansel 
> escreveu:
>>
>> Hi everyone,
>>
>> My team and I are working on the Trendy Lights Tutorial 
>>  
>> (connecting App Engine with Earth Engine).
>>
>> We have set up all the files and also have converted the .p12 key to .pem 
>> key but failed to run the app on the Google Cloud Platform and constantly 
>> got the error message saying "You do not have permission to access project 
>> [...] and service "cloudbuilt.googleapis.com" is not for consumer..." 
>> (see attached picture).
>>
>> We have already whitelisted our service account for the use of Earth 
>> Engine. Does anyone know what the problem might be? 
>>
>> Thank you so much!
>>
>> Jacquelin
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/9e6c34e3-4d66-4556-8152-287fe15a1b4f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Mapping Custom Domain to Specific URL

2017-03-27 Thread Francis Mwangi
I am able to map custom domain to my appengine app. What i want is to map 
to a specific url within the app eg

www.zappos.com to map to https://amazon.appspot.com/shoes
www.yoyo.com to map to https://amazon.appspot.com/toys
www.diapers.com to map to https://amazon.appspot.com/diapers

is it possible to map custom domain to point to a specific appengine url?

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/a5f67991-ce93-4667-8c2a-fc2b71dbc5f9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Google App Engine flexible runtime(custom runtime) and web font not working(ttf, woff, woff2)

2017-03-27 Thread 임형주
I've got some problem where google app engine flexible custom runtime with 
web font(ttf, woff, woff2).
I'vs got 404 error for web font resource.

app.yaml
runtime: custom
env: flex


Docker file
# The standard nginx container just runs nginx. The configuration file added
# below will be used by nginx.
FROM nginx

# Copy the nginx configuration file. This sets up the behavior of nginx, 
most
# importantly, it ensure nginx listens on port 8080. Google App Engine 
expects
# the runtime to respond to HTTP requests at port 8080.
COPY nginx.conf /etc/nginx/nginx.conf
COPY extra-mime.types /etc/nginx/extra-mime.types

# create log dir configured in nginx.conf
RUN mkdir -p /var/log/app_engine

# Create a simple file to handle heath checks. Health checking can be 
disabled
# in app.yaml, but is highly recommended. Google App Engine will send an 
HTTP
# request to /_ah/health and any 2xx or 404 response is considered healthy.
# Because 404 responses are considered healthy, this could actually be left
# out as nginx will return 404 if the file isn't found. However, it is 
better
# to be explicit.
RUN mkdir -p /usr/share/nginx/www/_ah && \
echo "healthy" > /usr/share/nginx/www/_ah/health

# Finally, all static assets.
ADD www/ /usr/share/nginx/www/
RUN chmod -R a+r /usr/share/nginx/www

nginx.conf
events {
worker_connections 1024;
}

http {
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
include /etc/nginx/extra-mime.types;
default_type application/octet-stream;

# Logs will appear on the Google Developer's Console when logged to this
# directory.
access_log /var/log/app_engine/app.log;
error_log /var/log/app_engine/app.log;

gzip on;
gzip_disable "msie6";
gzip_vary on;
gzip_proxied any;
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_min_length 256;
gzip_types text/plain text/css application/json 
application/x-javascript application/javascript text/xml application/xml 
application/xml+rss text/javascript;

server {
# Google App Engine expects the runtime to serve HTTP traffic from
# port 8080.
listen 8080;
root /usr/share/nginx/www;
index index.html index.htm;


extra-mime.types
types {
   font/truetype ttf;
   application/x-font-woff2  woff2;
   font/opentype otf;
}

When I run docker on my local computer, there is no problem and all mime 
type has no problem and font rendering is working.

But, when I deploy to app engine(flexible environment custom runtime), I've 
got 404 error.(content-type is text/html for woff/woff2)

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/a8841f68-85ca-40ff-ae73-a00fab5ac7fb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Production SDK stuck at 1.9.48?

2017-03-27 Thread Attila-Mihaly Balazs
AFAIK they update it every two months or so. The latest SDK version 
downloadable from the site is 1.9.51, so I'm guessing there are at least 
some bugfixes / improvements which could help my applications.

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/9f54a22f-3476-4431-b3a8-e04cd4f2d6ec%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Problems getting started with App Engine free trial

2017-03-27 Thread Carl Caulkett
Hello, I am trying to get started with the App Engine free trial but I 
cannot get the page (Labelled confusingly Google Cloud Platform) to accept 
either my Debit card or my bank details. The card details do not show any 
errant items and the bank details show no errors when the verify button is 
pressed. Yet when I press "Start my Free Trial" I am told to Verify. And if 
I have chosen the Debit card method, I am informed that the "Transaction 
was declined due to an Invalid Payment" method. Frankly this is appalling 
and doesn't fill one with confidence to build "Financial Apps of the 
Future" if it cannot get a freaking Debit card payment mechanism sorted. 
How do I start my App Engine Free Trial?

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/acb3f7d6-6f10-4acb-9dd1-8c8d8fcc48d5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Error when using google.cloud.logging with logging.v1.RequestLog?

2017-03-27 Thread Julian Bunn
Right now we cannot use the request_logs feature for downloading our GAE 
logs (see my other thread on that problem!), so I thought I would try the 
newer google.cloud features, and get modern :-)

Here is the simple test I tried:

from google.cloud import logging
from google.cloud.logging import DESCENDING
def main():
client = logging.Client() 
for entry in client.list_entries(order_by=DESCENDING):
print entry
if __name__ == '__main__':
main()

When executing this (after setting up the gcloud credentials), there seems 
to be a problem parsing the log entries:

python GetLogsCloud.py
Traceback (most recent call last):
  File "GetLogsCloud.py", line 25, in 
main()
  File "GetLogsCloud.py", line 18, in main
for entry in client.list_entries(order_by=DESCENDING):
  File "c:\python27\lib\site-packages\google\cloud\iterator.py", line 219, 
in _items_iter
for item in page:
  File "c:\python27\lib\site-packages\google\cloud\iterator.py", line 163, 
in next
result = self._item_to_value(self._parent, item)
  File "c:\python27\lib\site-packages\google\cloud\logging\_gax.py", line 
488, in _item_to_entry
resource = MessageToDict(entry_pb)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
133, in MessageToDict
return printer._MessageToJsonObject(message)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
164, in _MessageToJsonObject
return self._RegularMessageToJsonObject(message, js)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
196, in _RegularMessageToJsonObject
js[name] = self._FieldToJsonObject(field, value)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
230, in _FieldToJsonObject
return self._MessageToJsonObject(value)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
162, in _MessageToJsonObject
return methodcaller(_WKTJSONMETHODS[full_name][0], message)(self)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
266, in _AnyMessageToJsonObject
sub_message = _CreateMessageFromTypeUrl(type_url)
  File "c:\python27\lib\site-packages\google\protobuf\json_format.py", line 
341, in _CreateMessageFromTypeUrl
'Can not find message descriptor by type_url: {0}.'.format(type_url))
TypeError: Can not find message descriptor by type_url: 
type.googleapis.com/google.appengine.logging.v1.RequestLog.

I'm wondering what the issue is here ... is it because of the type of 
logging we use on GAE?

Thanks!

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/67b5422c-6e56-48e5-84d5-545df3341849%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Upload files to appspot.com

2017-03-27 Thread 'Josh Moore' via Google App Engine
Also note that each AppEngine app has a free quota of 5 GB for Cloud
Storage via its "Default Bucket," as documented here
.
You won't have to worry about a charge, unless you're storing over 5
gigabytes of JPEGs.

On Thu, Mar 23, 2017 at 6:25 AM, 'Nicholas (Google Cloud Support)' via
Google App Engine  wrote:

> Files uploaded with an App Engine application cannot be downloaded,
> uploaded or modified via FTP.  One of the reasons for this is that they may
> not all reside in one place given App Engine's scalable design.  To perform
> some tasks like deleting static resources, adding them or modifying them,
> here are your choices:
>
> Deleting static resources
>
>- Download the the completing application service/module to your local
>machine using the *download_app* command Alex described above
>- Delete the resources locally, making sure to update all references
>to them in your *app.yaml* and HTML files
>- Deploy your application service/module again, now without the
>resources you deleted
>
> Adding static resources
>
>- Download service as above
>- Add new static resources, adding references to them in *app.yaml*
>and HTML files
>- Deploy again as above
>
> Modifying static resources
>
>- Download service as above
>- Modify resources, updating references to them in *app.yaml* and HTML
>files
>- Deploy again as above
>
> I have this information is helpful.
>
> On Wednesday, March 22, 2017 at 5:01:30 PM UTC-4, Fabio Gonçalves wrote:
>>
>> Hi,
>> thanks for helping.
>> I only have to change pure html and JPEG's. The JPEG's are stored in a
>> separate folder.
>> The Cloud Storage is not a possibility for me, because it will be on
>> charge and I have less money.
>>
>> Is there no way via ftp or something like that to put and get files?
>>
>> Am Dienstag, 21. März 2017 17:38:30 UTC+1 schrieb Alex (Cloud Platform
>> Support):
>>>
>>> Hi Fabio,
>>>
>>> In order to help you further, I will need you to provide a additional
>>> details concerning which types of files are you looking to upload?
>>>
>>> In case you are looking to upload pictures (jpeg file format), you would
>>> need to first download the source code of your app using this download_app
>>> command
>>> .
>>> Then you will be able to update these images inside the source code and
>>> re-upload the app to your App Engine instance. In fact, it does seem that
>>> your images are stored along your application code when looking at their
>>> “Request URLs”, however let me know if you are expecting to upload your
>>> files elsewhere.
>>>
>>> Alternatively, you may be interested modifying the underlying
>>> infrastructure of your app and storing different types of files directly on 
>>> Cloud
>>> Storage . Then, serve them via your
>>> App Engine instance as described on this Reading and Writing to Google
>>> Cloud Storage guide
>>> 
>>> .
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Google App Engine" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-appengine+unsubscr...@googlegroups.com.
> To post to this group, send email to google-appengine@googlegroups.com.
> Visit this group at https://groups.google.com/group/google-appengine.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-appengine/fc2263ab-b490-4e40-b16c-
> b2fcba431ef6%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 

Josh Moore |  Cloud Solutions Engineer |  joshu...@google.com |

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAOvpJmWfSFOVEFyMjPyd-1o2NXZGz2fu2P9uVZC9Jh%2BcVfDBLQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Extract only log lines from stackdriver using gcloud?

2017-03-27 Thread Adrien Delessert
I've been using the grep-for-textPayload approach for a while which works 
for most things, but if you ever wind up needing to incorporate multiple 
keys from each log message I stumbled on a decent approach via jq, which 
gives you access to all of the keys and a format string syntax.

For example to add back a timestamp to each log line:
gcloud beta logging read '' --format=json | jq -rnc --stream 
'fromstream(1|truncate_stream(inputs)) 
| @text "\(.timestamp) \(.textPayload)"'

Or just extracting the textPayload in what feels like a more predictable 
manner than grep/cut if the formatting ever changes:
gcloud beta logging read '' --format=json | jq -rnc --stream 
'fromstream(1|truncate_stream(inputs)) 
| .textPayload'

Very much agreed re 'nothing beats having a CLI that easily facilitates 
ad-hoc exploration using "grep, perl, custom scripts etc"'.

My apologies for digging up an old discussion, but I hope this is helpful 
to anyone who finds this thread in the future!


Wednesday, June 22, 2016 at 5:15:47 AM UTC-4, Jonas Tingeborn wrote:
>
> *Is there a way to get the gcloud command to output just the textPayload 
> attribute values?*
>
> I haven't managed to figure out a good way of how to extract only the *log 
> lines* that an app submitts to stackdriver, without all the metadata 
> associated with the log entry, of which the actual log line is just one of 
> many attributes.
>
> Currently I've had to resort to some shell-fu in order to get the log 
> output in a form akin to what logging locally to file would have yielded.
> To get logs from a given docker container in container engine I presently 
> do something like the following:
>
> gcloud beta logging read '**' --format list | grep ' 
> textPayload: ' | cut -c17- > relevant_log_lines
>
> *PS. thanks for providing a CLI for stackdriver, very handy indeed.*
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/4df90aa1-085b-4352-9d9f-a9124646fc5c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Problems getting started with App Engine free trial

2017-03-27 Thread 'Adam (Cloud Platform Support)' via Google App Engine
The page is labeled "Google Cloud Platform" because the free trial is for 
Google Cloud Platform , of which App Engine 
is just one part. Free trial verification requires either a credit card or 
bank account details 
 for 
verification. If you have further issues or questions you may open a billing 
support ticket 
, or use 
the Free Trial Troubleshooter 
.

On Monday, March 27, 2017 at 12:02:43 PM UTC-4, Carl Caulkett wrote:
>
> Hello, I am trying to get started with the App Engine free trial but I 
> cannot get the page (Labelled confusingly Google Cloud Platform) to accept 
> either my Debit card or my bank details. The card details do not show any 
> errant items and the bank details show no errors when the verify button is 
> pressed. Yet when I press "Start my Free Trial" I am told to Verify. And if 
> I have chosen the Debit card method, I am informed that the "Transaction 
> was declined due to an Invalid Payment" method. Frankly this is appalling 
> and doesn't fill one with confidence to build "Financial Apps of the 
> Future" if it cannot get a freaking Debit card payment mechanism sorted. 
> How do I start my App Engine Free Trial?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/36f1e3bc-87d8-4a4a-8aa4-6dbdfdc1f881%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: How to access Google Cloud SQL Proxy from App Engine from DotNet App

2017-03-27 Thread George West
Hi

I need more info about when MySQL and the App are running under the same 
project

Can I simply make a direct call to MySQL from the App engine without proxy, 
or white-listed IPs, or SSL
Just an internal ip address and user name and password?


On Friday, 24 March 2017 11:44:26 UTC-4, Jordan (Cloud Platform Support) 
wrote:
>
> As noted in the documentation 
> , 
> connections that are made using the Cloud SQL Proxy or from App Engine are 
> already encrypted by default whether you configure SSL for the instance or 
> not. So you do not require an SSL cert in these cases. 
>
> If your Cloud SQL instance is in the same project as the App Engine app 
> that is making the connection, your App Engine application is already 
> authorized to access the SQL instance. Therefore you do not need to 
> authorize any additional networks or IPs. If you are connecting to a Cloud 
> SQL instance located in a different project, you will need to authorize 
> the App Engine app 
> 
> . 
>
> Alternatively, you can force Only SSL connections to your instance 
> (regardless of IP address), by following the SSL guide 
> .
>  
> Just make sure you supply the location of your SSL cert and key 
> 
>  
> in your Dockerfile similar to how it is done again in Kubernetes 
> 
>  so 
> that the proxy starts with the SSL configuration. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/29a2191e-e57c-4516-b818-926dd5cd991f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Plans for Node.js on App Engine Standard?

2017-03-27 Thread 'Jordan (Cloud Platform Support)' via Google App Engine
Transactional Tasks are coming to the new Cloud Tasks API which will be 
accessible via App Engine Flex and other Google Cloud products. You can sign 
up for the Alpha release 
of
 
Cloud Tasks to try it out. Note there is currently no ETA for the 
Transactional Task integration. 

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/b8a9d702-442c-4cda-b52c-0f0718a21b28%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Error 403 with Android restricted Cloud Platform API key and Cloud Endpoints

2017-03-27 Thread Cristina De Rito
I have a problem restricting a Google Cloud Platform API key usage to an 
Android app: I have added its package name and certificate SHA-1 
fingerprint (the debug one to get started) but it doesn't work.




The error I get when calling any API is

403 Requests from this Android client application  are blocked.

I'm calling the APIs by using a Cloud Endpoints generated client lib, and 
I've not been able to find any method that I can use at initialisation time 
to set the app credentials, nor does it do it by itself (as I can guess 
from the "" in the error). I can't find any useful info in any 
documentation as well, as far as I've red it seems like it should do it by 
itself.

This is my init code:

MyApi.Builder builder = new MyApi.Builder(new NetHttpTransport(), new 
AndroidJsonFactory(), null)
.setApplicationName("")
.setRootUrl()
.setGoogleClientRequestInitializer(new 
MyApiRequestInitializer());

I've also tried what suggested in this answer 
 but nothing changed.

Is there any passage I'm missing? How should it be done?

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/85451cbf-dd9f-4acc-952f-f1da4e430d11%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Plans for Node.js on App Engine Standard?

2017-03-27 Thread Attila-Mihaly Balazs
Thank you.

Also, to give task queues their due: they DO support transactional adding 
of tasks, just NOT for named tasks.

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/4f6f5842-8725-4ab5-baed-b4ffc2503535%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Problems getting started with App Engine free trial

2017-03-27 Thread Carl Caulkett
I have supplied both bank account details and debit card details, and 
despite not being alerted to any specific problem, both applications were 
rejected. I do not have the necessary account credentials for a billing 
support ticket, and the items described in the Free Trial Troubleshooter 
rather suggest that they are intended for those lucky soles who have got 
past the bank verification mechanism. I repeat my details are perfectly 
valid - would it be heretical to suggest that the verification mechanism is 
broken. 

On Monday, March 27, 2017 at 6:20:00 PM UTC+1, Adam (Cloud Platform 
Support) wrote:
>
> The page is labeled "Google Cloud Platform" because the free trial is for 
> Google Cloud Platform , of which App 
> Engine is just one part. Free trial verification requires either a credit 
> card or bank account details 
>  for 
> verification. If you have further issues or questions you may open a billing 
> support ticket 
> , or use 
> the Free Trial Troubleshooter 
> .
>
> On Monday, March 27, 2017 at 12:02:43 PM UTC-4, Carl Caulkett wrote:
>>
>> Hello, I am trying to get started with the App Engine free trial but I 
>> cannot get the page (Labelled confusingly Google Cloud Platform) to accept 
>> either my Debit card or my bank details. The card details do not show any 
>> errant items and the bank details show no errors when the verify button is 
>> pressed. Yet when I press "Start my Free Trial" I am told to Verify. And if 
>> I have chosen the Debit card method, I am informed that the "Transaction 
>> was declined due to an Invalid Payment" method. Frankly this is appalling 
>> and doesn't fill one with confidence to build "Financial Apps of the 
>> Future" if it cannot get a freaking Debit card payment mechanism sorted. 
>> How do I start my App Engine Free Trial?
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/6a55fab3-7916-437e--13c17f6a770a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Problems getting started with App Engine free trial

2017-03-27 Thread Carl Caulkett
Please read my initial description of the problem. The main problem was NOT 
the description of the page at the top.

On Monday, March 27, 2017 at 7:27:30 PM UTC+1, Carl Caulkett wrote:
>
> I have supplied both bank account details and debit card details, and 
> despite not being alerted to any specific problem, both applications were 
> rejected. I do not have the necessary account credentials for a billing 
> support ticket, and the items described in the Free Trial Troubleshooter 
> rather suggest that they are intended for those lucky soles who have got 
> past the bank verification mechanism. I repeat my details are perfectly 
> valid - would it be heretical to suggest that the verification mechanism is 
> broken. 
>
> On Monday, March 27, 2017 at 6:20:00 PM UTC+1, Adam (Cloud Platform 
> Support) wrote:
>>
>> The page is labeled "Google Cloud Platform" because the free trial is for 
>> Google Cloud Platform , of which App 
>> Engine is just one part. Free trial verification requires either a credit 
>> card or bank account details 
>>  for 
>> verification. If you have further issues or questions you may open a billing 
>> support ticket 
>> , or 
>> use the Free Trial Troubleshooter 
>> .
>>
>> On Monday, March 27, 2017 at 12:02:43 PM UTC-4, Carl Caulkett wrote:
>>>
>>> Hello, I am trying to get started with the App Engine free trial but I 
>>> cannot get the page (Labelled confusingly Google Cloud Platform) to accept 
>>> either my Debit card or my bank details. The card details do not show any 
>>> errant items and the bank details show no errors when the verify button is 
>>> pressed. Yet when I press "Start my Free Trial" I am told to Verify. And if 
>>> I have chosen the Debit card method, I am informed that the "Transaction 
>>> was declined due to an Invalid Payment" method. Frankly this is appalling 
>>> and doesn't fill one with confidence to build "Financial Apps of the 
>>> Future" if it cannot get a freaking Debit card payment mechanism sorted. 
>>> How do I start my App Engine Free Trial?
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/234c2d66-9472-4224-a6d4-b8e0a206dad0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Understanding write costs documentation

2017-03-27 Thread 'Nicholas (Google Cloud Support)' via Google App Engine
To the best of my knowledge, the older model for quantifying entity writes 
is no longer being used anywhere.  Thus, I believe the documentation page 
you provided is in need of some updating.  I've forwarded this request to 
the documentation team.  Thanks for bringing this to our attention.

In the future, you can also use the *Send feedback* link at the bottom of 
most documentation pages to report such findings directly to the 
documentation team.

On Tuesday, March 21, 2017 at 6:10:56 AM UTC-4, Ashley Finney wrote:
>
> Does this doc need updating?
>
> https://cloud.google.com/appengine/docs/standard/go/datastore/entities#Go_Understanding_write_costs
>
> Due to the change in write costs.
>
> https://cloudplatform.googleblog.com/2016/03/Google-Cloud-Datastore-simplifies-pricing-cuts-cost-dramatically-for-most-use-cases.html
>
> Thanks,
> Ash.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/d8b0730d-2bea-4a4f-a040-91bfcd2db7ca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Error when using google.cloud.logging with logging.v1.RequestLog?

2017-03-27 Thread 'Nick (Cloud Platform Support)' via Google App Engine
Hey Julian,

I've been able just now to run the same code fine. What might you mean by 
"the type of logging we use on GAE"? Are you doing anything particularly 
odd there?

It's worth mentioning here that this forum isn't meant for technical 
support but rather for general discussion of the platform, services, design 
patterns, etc. This question should have been posted to stackoverflow.com 
on a relevant Cloud Platform / App Engine tag. We monitor Stack Overflow 
regularly, so we'll be able to answer there, although we can perhaps help 
debug this a little here before you move to post there.

Cheers,

Nick
Cloud Platform Community Support

On Monday, March 27, 2017 at 12:25:45 PM UTC-4, Julian Bunn wrote:
>
> Right now we cannot use the request_logs feature for downloading our GAE 
> logs (see my other thread on that problem!), so I thought I would try the 
> newer google.cloud features, and get modern :-)
>
> Here is the simple test I tried:
>
> from google.cloud import logging
> from google.cloud.logging import DESCENDING
> def main():
> client = logging.Client() 
> for entry in client.list_entries(order_by=DESCENDING):
> print entry
> if __name__ == '__main__':
> main()
>
> When executing this (after setting up the gcloud credentials), there seems 
> to be a problem parsing the log entries:
>
> python GetLogsCloud.py
> Traceback (most recent call last):
>   File "GetLogsCloud.py", line 25, in 
> main()
>   File "GetLogsCloud.py", line 18, in main
> for entry in client.list_entries(order_by=DESCENDING):
>   File "c:\python27\lib\site-packages\google\cloud\iterator.py", line 219, 
> in _items_iter
> for item in page:
>   File "c:\python27\lib\site-packages\google\cloud\iterator.py", line 163, 
> in next
> result = self._item_to_value(self._parent, item)
>   File "c:\python27\lib\site-packages\google\cloud\logging\_gax.py", line 
> 488, in _item_to_entry
> resource = MessageToDict(entry_pb)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 133, in MessageToDict
> return printer._MessageToJsonObject(message)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 164, in _MessageToJsonObject
> return self._RegularMessageToJsonObject(message, js)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 196, in _RegularMessageToJsonObject
> js[name] = self._FieldToJsonObject(field, value)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 230, in _FieldToJsonObject
> return self._MessageToJsonObject(value)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 162, in _MessageToJsonObject
> return methodcaller(_WKTJSONMETHODS[full_name][0], message)(self)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 266, in _AnyMessageToJsonObject
> sub_message = _CreateMessageFromTypeUrl(type_url)
>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py", 
> line 341, in _CreateMessageFromTypeUrl
> 'Can not find message descriptor by type_url: {0}.'.format(type_url))
> TypeError: Can not find message descriptor by type_url: 
> type.googleapis.com/google.appengine.logging.v1.RequestLog.
>
> I'm wondering what the issue is here ... is it because of the type of 
> logging we use on GAE?
>
> Thanks!
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/cd373f85-74d3-4dab-97d7-2693bf1dc6e2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Error when using google.cloud.logging with logging.v1.RequestLog?

2017-03-27 Thread Julian Bunn
Hi Nick,

Thanks ... I do try StackOverflow from time to time for these sorts of
technical issues, but have very limited success. Perhaps I'm using bad
tags. See for example a logging related question I posted there on Friday
about JSON credentials for logging
https://stackoverflow.com/questions/43004904/accessing-gae-log-files-using-google-cloud-logging-python

Regarding the v1.RequestLog error that's the topic of this thread: we do
not use StackDriver logging in our GAE deployment, so I wonder whether
cloud.logging only supports StackDriver logs?

Otherwise, I am at a loss as to why google.cloud.logging can't understand
the log format it fetches from our GAE deployment?

We've now been without access to our log data for almost a week, so I'm
getting quite desperate to find a solution either with request_logs or
cloud.logging :-)

Thanks for your help.

Julian




On Mon, Mar 27, 2017 at 11:58 AM, 'Nick (Cloud Platform Support)' via
Google App Engine  wrote:

> Hey Julian,
>
> I've been able just now to run the same code fine. What might you mean by
> "the type of logging we use on GAE"? Are you doing anything particularly
> odd there?
>
> It's worth mentioning here that this forum isn't meant for technical
> support but rather for general discussion of the platform, services, design
> patterns, etc. This question should have been posted to stackoverflow.com
> on a relevant Cloud Platform / App Engine tag. We monitor Stack Overflow
> regularly, so we'll be able to answer there, although we can perhaps help
> debug this a little here before you move to post there.
>
> Cheers,
>
> Nick
> Cloud Platform Community Support
>
>
> On Monday, March 27, 2017 at 12:25:45 PM UTC-4, Julian Bunn wrote:
>>
>> Right now we cannot use the request_logs feature for downloading our GAE
>> logs (see my other thread on that problem!), so I thought I would try the
>> newer google.cloud features, and get modern :-)
>>
>> Here is the simple test I tried:
>>
>> from google.cloud import logging
>> from google.cloud.logging import DESCENDING
>> def main():
>> client = logging.Client()
>> for entry in client.list_entries(order_by=DESCENDING):
>> print entry
>> if __name__ == '__main__':
>> main()
>>
>> When executing this (after setting up the gcloud credentials), there
>> seems to be a problem parsing the log entries:
>>
>> python GetLogsCloud.py
>> Traceback (most recent call last):
>>   File "GetLogsCloud.py", line 25, in 
>> main()
>>   File "GetLogsCloud.py", line 18, in main
>> for entry in client.list_entries(order_by=DESCENDING):
>>   File "c:\python27\lib\site-packages\google\cloud\iterator.py", line
>> 219, in _items_iter
>> for item in page:
>>   File "c:\python27\lib\site-packages\google\cloud\iterator.py", line
>> 163, in next
>> result = self._item_to_value(self._parent, item)
>>   File "c:\python27\lib\site-packages\google\cloud\logging\_gax.py",
>> line 488, in _item_to_entry
>> resource = MessageToDict(entry_pb)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 133, in MessageToDict
>> return printer._MessageToJsonObject(message)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 164, in _MessageToJsonObject
>> return self._RegularMessageToJsonObject(message, js)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 196, in _RegularMessageToJsonObject
>> js[name] = self._FieldToJsonObject(field, value)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 230, in _FieldToJsonObject
>> return self._MessageToJsonObject(value)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 162, in _MessageToJsonObject
>> return methodcaller(_WKTJSONMETHODS[full_name][0], message)(self)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 266, in _AnyMessageToJsonObject
>> sub_message = _CreateMessageFromTypeUrl(type_url)
>>   File "c:\python27\lib\site-packages\google\protobuf\json_format.py",
>> line 341, in _CreateMessageFromTypeUrl
>> 'Can not find message descriptor by type_url: {0}.'.format(type_url))
>> TypeError: Can not find message descriptor by type_url:
>> type.googleapis.com/google.appengine.logging.v1.RequestLog.
>>
>> I'm wondering what the issue is here ... is it because of the type of
>> logging we use on GAE?
>>
>> Thanks!
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google App Engine" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/google-appengine/M01jjjNc1dQ/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> google-appengine+unsubscr...@googlegroups.com.
> To post to this group, send email to google-appengine@googlegroups.com.
> Visit this group at https://groups.google.com/group/google-appengine.
> To view this discussion on the web visit https://g

Re: [google-appengine] Re: Plans for Node.js on App Engine Standard?

2017-03-27 Thread Jeff Schnitzer
You can only transactionally enqueue tasks from GAE standard using the
ApiProxy-based interface. You cannot yet transactionally enqueue tasks
(named or otherwise) with the new REST-based APIs for the datastore and
task queue. Flex only supports the REST APIs.

It’s great to hear that this is on the roadmap! Thanks Jordan.

Jeff

On Mon, Mar 27, 2017 at 11:27 AM, Attila-Mihaly Balazs 
wrote:

> Thank you.
>
> Also, to give task queues their due: they DO support transactional adding
> of tasks, just NOT for named tasks.
>
> Attila
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CADK-0uiZtfSD4fSrZvxNP69FH6RypX1bBUdWL2vbK7dyuUEGww%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Error 403 with Android restricted Cloud Platform API key and Cloud Endpoints

2017-03-27 Thread 'Adam (Cloud Platform Support)' via Google App Engine
Provided that you are using the Endpoints client library that you generated 
for Android 
,
 
it's not necessary to manually add the headers yourself. You need to 
configure the client library to authenticate, and the full instructions for 
this are provided in the documentation Calling Backend APIs from an Android 
Client 

.

On Monday, March 27, 2017 at 2:20:46 PM UTC-4, Cristina De Rito wrote:
>
> I have a problem restricting a Google Cloud Platform API key usage to an 
> Android app: I have added its package name and certificate SHA-1 
> fingerprint (the debug one to get started) but it doesn't work.
>
> 
>
>
> The error I get when calling any API is
>
> 403 Requests from this Android client application  are blocked.
>
> I'm calling the APIs by using a Cloud Endpoints generated client lib, and 
> I've not been able to find any method that I can use at initialisation time 
> to set the app credentials, nor does it do it by itself (as I can guess 
> from the "" in the error). I can't find any useful info in any 
> documentation as well, as far as I've red it seems like it should do it by 
> itself.
>
> This is my init code:
>
> MyApi.Builder builder = new MyApi.Builder(new NetHttpTransport(), new 
> AndroidJsonFactory(), null)
> .setApplicationName("")
> .setRootUrl()
> .setGoogleClientRequestInitializer(new 
> MyApiRequestInitializer());
>
> I've also tried what suggested in this answer 
>  but nothing changed.
>
> Is there any passage I'm missing? How should it be done?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/5ffe2acf-1437-48b2-832a-2c278ed37ed7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Google App Engine flexible runtime(custom runtime) and web font not working(ttf, woff, woff2)

2017-03-27 Thread 'Nicholas (Google Cloud Support)' via Google App Engine
*404*s are normally served when a resource cannot be found given a specific 
URL.  In general, an effective way to identify where this is happening is 
by starting from the where logs are available to you and working inwards 
until you get to the docker container.

   - Are there other static assets in the same directory being served 
   correctly?
   - Is there a request log entry for the font resource?  If not, it would 
   suggest that the request is not making it to the application at all.
   - If the request log is present, does the request make it to the 
   application container?  If it does not, there may be *app.yaml* static 
   file/folder handlers intercepting the request before it is sent to the 
   application container.
   - If so, does the request make it to your container's nginx process? 
You should be able to check your container's nginx logs by connecting 
   to the instance 
   
,
 
   entering the application docker container and inspecting nginx logs.
   
The above is a general guide for troubleshooting errors in the flexible 
environment.  Given the specific error, I'd suggest asking a question on Stack 
Overflow  with the 
*[google-app-engine]* tag.  If you believe this to be an issue with the 
platform not behaving as documented or intended, I'd suggest filing a new 
issue on Issue Tracker .  This 
Google Group is intended for general best practice, how-to and architecture 
type discussions.

On Monday, March 27, 2017 at 9:15:22 AM UTC-4, 임형주 wrote:
>
> I've got some problem where google app engine flexible custom runtime with 
> web font(ttf, woff, woff2).
> I'vs got 404 error for web font resource.
>
> app.yaml
> runtime: custom
> env: flex
>
>
> Docker file
> # The standard nginx container just runs nginx. The configuration file 
> added
> # below will be used by nginx.
> FROM nginx
>
> # Copy the nginx configuration file. This sets up the behavior of nginx, 
> most
> # importantly, it ensure nginx listens on port 8080. Google App Engine 
> expects
> # the runtime to respond to HTTP requests at port 8080.
> COPY nginx.conf /etc/nginx/nginx.conf
> COPY extra-mime.types /etc/nginx/extra-mime.types
>
> # create log dir configured in nginx.conf
> RUN mkdir -p /var/log/app_engine
>
> # Create a simple file to handle heath checks. Health checking can be 
> disabled
> # in app.yaml, but is highly recommended. Google App Engine will send an 
> HTTP
> # request to /_ah/health and any 2xx or 404 response is considered healthy.
> # Because 404 responses are considered healthy, this could actually be left
> # out as nginx will return 404 if the file isn't found. However, it is 
> better
> # to be explicit.
> RUN mkdir -p /usr/share/nginx/www/_ah && \
> echo "healthy" > /usr/share/nginx/www/_ah/health
>
> # Finally, all static assets.
> ADD www/ /usr/share/nginx/www/
> RUN chmod -R a+r /usr/share/nginx/www
>
> nginx.conf
> events {
> worker_connections 1024;
> }
>
> http {
> sendfile on;
> tcp_nopush on;
> tcp_nodelay on;
> keepalive_timeout 65;
> types_hash_max_size 2048;
> include /etc/nginx/mime.types;
> include /etc/nginx/extra-mime.types;
> default_type application/octet-stream;
>
> # Logs will appear on the Google Developer's Console when logged to 
> this
> # directory.
> access_log /var/log/app_engine/app.log;
> error_log /var/log/app_engine/app.log;
>
> gzip on;
> gzip_disable "msie6";
> gzip_vary on;
> gzip_proxied any;
> gzip_comp_level 6;
> gzip_buffers 16 8k;
> gzip_http_version 1.1;
> gzip_min_length 256;
> gzip_types text/plain text/css application/json 
> application/x-javascript application/javascript text/xml application/xml 
> application/xml+rss text/javascript;
>
> server {
> # Google App Engine expects the runtime to serve HTTP traffic from
> # port 8080.
> listen 8080;
> root /usr/share/nginx/www;
> index index.html index.htm;
>
>
> extra-mime.types
> types {
>font/truetype ttf;
>application/x-font-woff2  woff2;
>font/opentype otf;
> }
>
> When I run docker on my local computer, there is no problem and all mime 
> type has no problem and font rendering is working.
>
> But, when I deploy to app engine(flexible environment custom runtime), 
> I've got 404 error.(content-type is text/html for woff/woff2)
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group

[google-appengine] Re: Mapping Custom Domain to Specific URL

2017-03-27 Thread 'Jordan (Cloud Platform Support)' via Google App Engine
I would recommended moving your URL handler code into separate Services 

 
(e.g 'shoes.amazon.appspot.com'). Then you can upload a Dispatch 
configuration
 
file which allows you to specify up to 20 specific routing rules 

. 

Alternatively, you can detect the ORIGIN Header of the incoming request and 
serve different content (e.g shoes,toys,etc.) depending on the Custom 
Domain that was requested. This method would not use individual '/shoes' 
URL handlers and would route all of your Custom Domains to the main 
' https://amazon.appspot.com/' default handler (which would be the one 
performing the content serving logic). 

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/a472d0dd-6889-45da-94af-62b0239f5c18%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Start page not shown

2017-03-27 Thread 'Alex (Cloud Platform Support)' via Google App Engine


Hi Fabio,

This appears to be a request for 1-on-1 assistance with a technical issue 
specific to your development. This isn't the right forum to look for help 
on such a question, which is perfectly suited to stackoverflow.com. This 
forum, on the other hand, is meant for more general high-level discussions 
of the platform and services, design patterns, etc.

As for how to assist with the issue itself, looking at your provide 
app.yaml file it seems that you are attempting to run a PHP application in 
a Python environment. Therefore, changing the “runtime: python27” parameter 
to “runtime: php55” as specified in this app.yaml Reference example 
 may 
solve your issue.

Regards,
Alex

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/b3004b87-ea9a-425b-9630-838ba43d34d7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Issue with a new SSL Cert (You must verify ownership of this certificate's domain(s)in order to upload it)

2017-03-27 Thread Arun Shanker Prasad
Hi Attila,

Thanks for the response.

Yes, I ended up doing that, but the issue is that it does not let me adding 
the root domain as the www domain is already there, so we had to remove and 
add it again. The new interface automatically adds both the root domain and 
the www subdomain.

Also an important note, it looks like Google may have changed something 
recently, so we are not able to manage a domain even if you are an 
administrator of the application, we need to be the "verified" owner in 
webmaster tools.

Thanks,
Arun

On Friday, 24 March 2017 20:33:48 UTC+5:30, Attila-Mihaly Balazs wrote:
>
> I had similar issues. Try verifying your root domain (ie. "example.com") 
> even if you're not planning on using it with GAE. That should solve the 
> issue (although it's not at all intuitive).
>
> Attila
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/ce90dcee-e3a2-4f05-82b1-a5fc4a5d8721%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Issue with a new SSL Cert (You must verify ownership of this certificate's domain(s)in order to upload it)

2017-03-27 Thread Attila-Mihaly Balazs
Yep, the SSL interface is confusing (like, why do you have to verify the 
subdomain when you already verified the root domain? In what universe do 
you have control of the root domain but don't control the subdomain?).

Anyway, when adding the domain to appengine, at the second step you *can* 
remove the www one (I've done this Monday actually). So the workflow is 
something like:

- go to the setup page 
https://console.cloud.google.com/appengine/settings/domains?project=
- click "Add custom domain"
- select "Verify new domain" from the dropdown
- after completing verification in the webmaster tools, click the refresh 
button
- now it will display two text boxes (as you've said) one with 
"www.foo.com" and one with "foo.com" but you can use the X on "www.foo.com" 
(on the right end) to remove it and leave only "foo.com" (or the other way 
around).

Ie. you don't have to add both domains suggested by Google.

And a good point about having to be the verified of the domain in Webmaster 
tools.

Cheers,
Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/ebf18a57-971a-4a83-ae2f-811a425a15cc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Plans for Node.js on App Engine Standard?

2017-03-27 Thread Attila-Mihaly Balazs
Yes, that's exactly right Jeff. Thank you for formulating it clearly!

Attila

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/2a69e1c8-ccb6-4658-b516-57831c12afa6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Understanding java.util.ConcurrentModificationException: too much contention on these datastore entities. please try again.

2017-03-27 Thread Louise Elmose Hedegaard
Hi Jeff,

What do you mean by "linear order of operations"?
I do not get any timeouts.

I begin the transaction before the pseudo code above, and attempt to commit 
the transaction after the pseudo code - it is the commit that causes the 
ConcurrentModification operation.
I am quite sure I do not start any nested transactions, as my logic only 
begins/commits/rollback transactions when a servlet is invoked.
I did try starting a nested transaction for the part of the pseudo code 
that sends mail to the external system and updates statusses accordingly, 
but that did not work either, so I went back to the original code with only 
one transaction.

Thanks,
-Louise

Den lørdag den 25. marts 2017 kl. 19.14.22 UTC+1 skrev Jeff Schnitzer:
>
> That does not sound correct.
>
> If you have a linear order of operations in the same transaction (or 
> entirely without transactions), you should never see concurrent 
> modification exception. Timeouts are a different matter.
>
> To the OP: Where are you transaction boundaries? Are you accidentally 
> starting a new transaction “inside” an outer transaction and modifying the 
> same entity as the outer transaction? That will guarantee CME every time.
>
> Jeff
>
> On Fri, Mar 24, 2017 at 4:02 PM, 'Adam (Cloud Platform Support)' via 
> Google App Engine > wrote:
>
>> A great article that explains this is 'Timeouts due to write contention 
>> 
>> ': 
>>
>> *Writes to a single entity group are serialized by the App Engine 
>>> datastore, and thus there's a limit on how quickly you can update one 
>>> entity group. In general, this works out to somewhere between 1 and 5 
>>> updates per second.*
>>
>>
>> Writing to the same entity twice successively is enough to cause a 
>> ConcurrentModificationException. Strategies to avoid this are discussed in 
>> 'Avoiding 
>> datastore contention 
>> '.  
>>
>> On Friday, March 24, 2017 at 3:18:28 AM UTC-4, Louise Elmose Hedegaard 
>> wrote:
>>>
>>> Hi,
>>>
>>> In my app I have the following logic (pseudoCode):
>>>
>>> List nonSentMails= getNonSentMails();//1) datastore read
>>>
>>> List sendNow = new ArrayList(); 
>>> for each nonSentMail in nonSentMails
>>>if (sendNow(nonSentMail)){
>>>sendNow.add(nonSentMail);
>>>}
>>>
>>> for each nonSentMail in sendNow
>>> SentStatus sentStatus = sendMailViaRestApi();
>>> create maillog in datastore with sent status//2) datastore write - 
>>> new entry
>>> nonSentMail.setSentStatus(sentStatus);
>>>
>>> update(sendNow) //3) datastore write
>>>
>>>
>>> When comitting the above I get:
>>> java.util.ConcurrentModificationException: too much contention on these 
>>> datastore entities. please try again.
>>>
>>> This is a problem, as the operation is not idempotent - when I send a 
>>> mail via a REST API the mail is sent immediately, and I want the status of 
>>> my maillog and NonSentMail objects to reflect this.
>>>
>>> I do not understand why this error occurs. 
>>> There are only three operations on the datastore:
>>> 1) The initial read of non sent mails
>>> 2) The creation of new mail log entries
>>> 3) The update of the status of non sent mails
>>>
>>> 2) should never lead to ConcurrentModificationException as far as I 
>>> understand it. 1) and 3) operates on the same entities, but 1) only reads, 
>>> so I cannot see any problem here either.
>>> Furthermore there is currently only one user of my app, so there should 
>>> be no other threads accessing the data.
>>> Note that the elements in sendNow might have the same parents, but again 
>>> I do not believe this should be a problem?
>>>
>>> Can you please help me understand why the above code can lead to a 
>>> ConcurrentModificationException?
>>>
>>> Thanks,
>>> -Lull
>>>
>>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Google App Engine" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to google-appengi...@googlegroups.com .
>> To post to this group, send email to google-a...@googlegroups.com 
>> .
>> Visit this group at https://groups.google.com/group/google-appengine.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/google-appengine/aec47937-549f-4de2-899d-b59da5163ad8%40googlegroups.com
>>  
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group

[google-appengine] Re: Understanding java.util.ConcurrentModificationException: too much contention on these datastore entities. please try again.

2017-03-27 Thread Louise Elmose Hedegaard
Hi Adam,

Why do you mention timeout - ConcurrentModificationException is not related 
to timeouts is it?

Thanks,
-Louise

Den lørdag den 25. marts 2017 kl. 00.02.05 UTC+1 skrev Adam (Cloud Platform 
Support):
>
> A great article that explains this is 'Timeouts due to write contention 
> 
> ': 
>
> *Writes to a single entity group are serialized by the App Engine 
>> datastore, and thus there's a limit on how quickly you can update one 
>> entity group. In general, this works out to somewhere between 1 and 5 
>> updates per second.*
>
>
> Writing to the same entity twice successively is enough to cause a 
> ConcurrentModificationException. Strategies to avoid this are discussed in 
> 'Avoiding 
> datastore contention 
> '.  
>
> On Friday, March 24, 2017 at 3:18:28 AM UTC-4, Louise Elmose Hedegaard 
> wrote:
>>
>> Hi,
>>
>> In my app I have the following logic (pseudoCode):
>>
>> List nonSentMails= getNonSentMails();//1) datastore read
>>
>> List sendNow = new ArrayList(); 
>> for each nonSentMail in nonSentMails
>>if (sendNow(nonSentMail)){
>>sendNow.add(nonSentMail);
>>}
>>
>> for each nonSentMail in sendNow
>> SentStatus sentStatus = sendMailViaRestApi();
>> create maillog in datastore with sent status//2) datastore write - 
>> new entry
>> nonSentMail.setSentStatus(sentStatus);
>>
>> update(sendNow) //3) datastore write
>>
>>
>> When comitting the above I get:
>> java.util.ConcurrentModificationException: too much contention on these 
>> datastore entities. please try again.
>>
>> This is a problem, as the operation is not idempotent - when I send a 
>> mail via a REST API the mail is sent immediately, and I want the status of 
>> my maillog and NonSentMail objects to reflect this.
>>
>> I do not understand why this error occurs. 
>> There are only three operations on the datastore:
>> 1) The initial read of non sent mails
>> 2) The creation of new mail log entries
>> 3) The update of the status of non sent mails
>>
>> 2) should never lead to ConcurrentModificationException as far as I 
>> understand it. 1) and 3) operates on the same entities, but 1) only reads, 
>> so I cannot see any problem here either.
>> Furthermore there is currently only one user of my app, so there should 
>> be no other threads accessing the data.
>> Note that the elements in sendNow might have the same parents, but again 
>> I do not believe this should be a problem?
>>
>> Can you please help me understand why the above code can lead to a 
>> ConcurrentModificationException?
>>
>> Thanks,
>> -Lull
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/c4cbe174-7d53-4242-ab8b-051b5456a388%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.