[google-appengine] Re: Cloud Build for Google App Engine - Flexible is failing with a generic 'exit status 1' - debug output shows issue in python files

2019-06-18 Thread 'Yasser Karout' via Google App Engine
Hello,

I recommend posting this on Stackoverflow as it is better suited for 
development questions since the post will have more visibility. Groups is 
more geared towards high level discussions about Google Cloud products. But 
if you suspect the issue is on the Google side, feel free to open a new 
issue here [1] to potentially have the Cloud Build Team look into it.

Thanks,

[1] https://issuetracker.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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/2f68fadf-71b1-493c-b219-2d593598%40googlegroups.com.


[google-appengine] Re: Memcache Error in Google App Engine

2019-06-18 Thread 'Yasser Karout' via Google App Engine
I found an internal issue that could be relevant to this. To confirm this, 
can you provide the error you are getting and which runtime you are using? 
Is it a custom runtime?

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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/6fd91309-6793-42e0-93b5-73710980ba13%40googlegroups.com.


[google-appengine] Re: Are datastore Ids unique across all namespaces?

2019-06-18 Thread 'Nicolas (Google Cloud Platform Support)' via Google App Engine


Iā€™m glad to know we were able to help you,

 

Have a great day!


On Monday, June 17, 2019 at 11:05:39 PM UTC-4, NP wrote:
>
> Thanks.
>
> That link answered my question with the answer being - No, the Ids are not 
> unique across all namespaces. The link also provided a solution for me if I 
> need them to be unique.
>
>
> On Monday, June 17, 2019 at 12:55:36 PM UTC-7, Nicolas (Google Cloud 
> Platform Support) wrote:
>>
>> Hi,
>>
>>  
>>
>> I understand your use case and I think the best way to accomplish that 
>> would be something like suggested in this StackOverflow 
>> 
>>  
>> post and set up your own  GUIDs.
>>
>>  
>>
>> I hope that helps!
>>
>>
>>
>> On Friday, June 14, 2019 at 10:53:30 PM UTC-4, NP wrote:
>>>
>>> Thanks for your response. And yes, I was referring to the numeric id.
>>>
>>> In case it wasn't clear from my post, I actually want the ids to be 
>>> unique. I was just trying to confirm that it is.
>>>
>>> The reason I would prefer the ids are unique is because I have seeded 
>>> data which all my users can use. The users can then in turn create entities 
>>> for their application which are saved with a namespace for the user. Since 
>>> each user basically has access to 2 namespaces (the default or blank 
>>> namespace which contains my seeded data and the namespace for their app), I 
>>> would like to search for entities by just their numeric ids. If I find the 
>>> record, I then check the namespace associated with the corresponding key. 
>>> For this to work, the ids need to be unique across all namespaces.
>>>
>>>
>>>
>>> On Friday, June 14, 2019 at 7:06:48 PM UTC-7, Harmit Rishi (Cloud 
>>> Platform Support) wrote:

 In order to effectively address your question, I would like to take a 
 moment and explain the characteristics of a Entity 
 . Each 
 entity within Datastore has a key that uniquely identifies it. The key (as 
 you provided) consists of the following components: 

 1. Namespace of the entity
 2. The kind 
 
  
 of entity (categorized for queries)
 3. An Identifier 
 
  
 for the individual entity (can be a key name string or a integer numeric 
 id.)

 I will be assuming that you are referring to the integer numeric id for 
 your question. 

 As far as having two of the same numeric ID's goes, indeed it is 
 possible and this can be done by having your application assign their own 
 numeric IDs manually to the entitles being created. However, as indicated 
 in the documentation here 
 ,
  
 "there is nothing to prevent a Datastore mode database from assigning one 
 of your manual numeric IDs to another entity". You will have to implement 
 the *allocateids() 
 *method
  
 within your application which will allow you to obtain a block of IDs in 
 order to avoid the conflict mentioned above.

 Also, since you mentioned that "Datastore is the one automatically 
 generating the ids", the documentation found here 
 
  states 
 that the "automatic ID generator will keep track of IDs that have been 
 allocated" and that Datastore "will avoid reusing them for another entity".

 Therefore to sum it all up. Yes, you can achieve the goal you want. 
 However, it would be a good idea to implement the best practices for it as 
 well such as: manually assigning Ids with implementing *allocateids() 
 *
 . 

 I hope this helps!



-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/3e4f6c57-1521-483c-9f70-2a161941a75a%40googlegroups.com.


Re: [google-appengine] Re: Task queue not executing tasks / backlogged

2019-06-18 Thread Javier Martin
I'm experiencing the same problem. 
Every 30-45 minutes, about 10-20 tasks in queue are just ignored for some 
minutes. It takes about 7-9 minutes for the queue to dispatch them. All the 
rest of tasks are dispatched normally : (
I already filed an issue on the 
tracker https://issuetracker.google.com/issues/135471809
Did you find any solution?

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/a1ba3588-48c4-40b8-876c-f17818b061e1%40googlegroups.com.


[google-appengine] Cloud Build for Google App Engine - Flexible is failing with a generic 'exit status 1' - debug output shows issue in python files

2019-06-18 Thread Claudio Vallesi

I'm testing how to build a pipeline on GCP and after successfully deploying 
an Angular 6 application I wanted to add a websocket (socket.io) backend 
that will serve real time updates.

First of all the error itself, which is results of this command:

gcloud builds submit --verbosity=debug --config stage.cloudbuild.yaml .

[...]

Step #1: ERROR: (gcloud.app.deploy) INTERNAL: Internal error encountered.
Finished Step #1
ERROR
ERROR: build step 1 "gcr.io/cloud-builders/gcloud" failed: exit status 1
--


DEBUG: (gcloud.builds.submit) build 29412e5a-cd7f-4af8-9b83-71fb17414dc2 
completed with status "FAILURE"
Traceback (most recent call last):
  File "C:\Users\[UsernameRedacted]\AppData\Local\Google\Cloud 
SDK\google-cloud-sdk\lib\googlecloudsdk\calliope\cli.py", line 985, in 
Execute
resources = calliope_command.Run(cli=self, args=args)
  File "C:\Users\[UsernameRedacted]\AppData\Local\Google\Cloud 
SDK\google-cloud-sdk\lib\googlecloudsdk\calliope\backend.py", line 795, in 
Run
resources = command_instance.Run(args)
  File "C:\Users\[UsernameRedacted]\AppData\Local\Google\Cloud 
SDK\google-cloud-sdk\lib\surface\builds\submit.py", line 497, in Run
raise FailedBuildException(build)
FailedBuildException: build 29412e5a-cd7f-4af8-9b83-71fb17414dc2 completed 
with status "FAILURE"
ERROR: (gcloud.builds.submit) build 29412e5a-cd7f-4af8-9b83-71fb17414dc2 
completed with status "FAILURE"
[...]
[ ... NPM saying it's not its fault yada yada ... ]

My local environment is:

   - Node: 10.9.0
   - NPM: 6.2.0
   - OS: Windows 10

Seems like something is wrong in some python script in my local machine but 
honestly I don't know how I should fix this. Any help is appreciated.

The following is the app.yaml file (specifically stage.app.yaml):

service: mercury

runtime: nodejs
env: flex

instance_class: B1
manual_scaling:
  instances: 1

env_variables:
  MERCURY_PORT: 5001
  MERCURY_SECRET: [REDACTED]

network:
  session_affinity: true

The cloudbuild.yaml (specifically stage.cloudbuild.yaml):

steps:

- name: 'gcr.io/cloud-builders/npm'
  args: [ 'install' ]

- name: 'gcr.io/cloud-builders/gcloud'
  args: [ 'app', 'deploy', 'stage.app.yaml', '-v=stage' ]

And finally, this is the package.json:

{

  "name": "mercury",
  "version": "1.0.0",
  "description": "socket.io event manager",
  "main": "index.js",
  "scripts": {
"start": "node index.js",
"deploy-stage": "gcloud builds submit --config stage.cloudbuild.yaml .",
"deploy-prod": "gcloud builds submit --config prod.cloudbuild.yaml ."
  },
  "dependencies": {
"async": "^2.4.0",
"body-parser": "^1.17.1",
"dotenv": "^4.0.0",
"express": "^4.15.2",
"express-validator": "^3.2.0",
"http": "0.0.0",
"jsonwebtoken": "^7.4.0",
"moment": "^2.18.1",
"request": "^2.81.0",
"request-promise": "^4.2.2",
"socket.io": "^2.0.1"
  },
  "devDependencies": {
"eslint": "^4.18.1",
"eslint-plugin-node": "^6.0.0",
"log-timestamp": "^0.1.2"
  },
  "engines": {
"node": "10.9.0"
  }
}

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/9a79ef09-d6e1-4fcc-898d-9bf13a90fb0f%40googlegroups.com.


[google-appengine] Re: Can't open different version of appengine in flexible environment

2019-06-18 Thread Peter Chen
Do I have to change dispatch.yaml each time I deploy? By the way, I am 
deploying a react app.

On Thursday, June 13, 2019 at 9:07:36 PM UTC+2, Amit Sinha wrote:
>
> Hello Peter, 
>
> As Nicolas mentioned, this error usually related to app.yaml file 
> configuration issue. However, I would recommend to check any other 
> configuration file if you have, such as dispatch.yaml [1] 
>
> By looking at the errors, it seems like request reached to the 
> application. If this is the case, you can investigate the logs from 
> Stackdriver Logging. I would say check the Stackdriver Logging to find any 
> request with ā€˜404ā€™ status in your particular App Engine version which might 
> help you to figure out the issue. 
>
> [1] 
> https://cloud.google.com/appengine/docs/flexible/nodejs/reference/dispatch-yaml
>
>
> On Thursday, June 13, 2019 at 8:10:50 AM UTC-4, Peter Chen wrote:
>>
>> That's not the reason, I tried the url set in the urls file, still same 
>> error with a different request url.
>>
>> On Wednesday, June 12, 2019 at 1:38:37 AM UTC+2, Nicolas (Google Cloud 
>> Platform Support) wrote:
>>>
>>> Hi Peter,
>>>
>>> Thank you for your report,
>>>
>>> You can access different versions of your app in App Engine by clicking 
>>> on the Version number/name in the console. My assumption is the issue 
>>> originated from how up your app.yaml file is set up just like in this 
>>> thread 
>>> 
>>> .
>>>
>>> Also please note that these types of questions are better addressed on 
>>> StackOverflow where you have access to a large community of enthusiasts and 
>>> experts to share ideas with and get support from. Please make sure to 
>>> include all relevant details and error messages which would help the 
>>> community troubleshoot.
>>>
>>>
>>> On Tuesday, June 11, 2019 at 3:47:24 PM UTC-4, Peter Chen wrote:

 I deployed several versions of a Django app on appengine flexible 
 environment, but when I click on the version number, it says

 Error: Not FoundThe requested URL / was not found on this server.

 How can I visit different versions of the app?

>>>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/e1f33755-7010-49df-998e-c776f51cf958%40googlegroups.com.


[google-appengine] Re: Started having all sorts of import errors starting June 13

2019-06-18 Thread 'Yasser Karout' via Google App Engine
Hello,

I recommend posting this on Stackoverflow as it is better suited for 
development questions since the post will have more visibility. Groups is 
more geared towards high level discussions about Google Cloud products. But 
if you suspect the import error is caused by a release on the Google side, 
feel free to open a new issue here [1] to potentially have the App Engine 
Team look into it.

Thanks,

[1] https://issuetracker.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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/4ba233b5-5de2-401e-a17e-5b1901f39444%40googlegroups.com.


[google-appengine] Memcache Error in Google App Engine

2019-06-18 Thread Digital Services
Hi Guys,

We have an app deployed (Java) on the Google App Engine. Recently, we have 
been getting memcache-related errors routinely. It looks like the error is 
generated from the datastore.get() method that tries to access the GAP's 
datastore entites. The error disappears on redeploying the same version 
again, but then again starts to occur after some days. Have any of you come 
across such situations/ have any solutions to this ?

Thanks in advance.

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/81268665-82f3-4237-acdb-c6325c533d0a%40googlegroups.com.