nodejs instance and 502 errors

259 views
Skip to first unread message

Jeff Gold

unread,
Aug 31, 2016, 10:47:02 AM8/31/16
to Google Cloud Developers
So i am running a single app-engine instance nodejs project. I run through my application as much as I can stress test it and receive no errors now. Often when I come back to the site and check it the next day I get the 502 error bad gateway though. My instance doesnt appear to have received any errors in the gcloud console / logs. I pasted my app.yaml below. Would anyone have any suggestions to increase stability? I have never had this crashing issue from local use using the gcloud sdk.

runtime: nodejs
vm: true
threadsafe: false

manual_scaling:
  instances: 1
  
resources:
  cpu: .5
  memory_gb: 1.0
  disk_size_gb: 10

# [START network]
# This ensures clients will be able to connect via websockets to any instance of
# this app using websockets
network:
  forwarded_ports:
  - 65080
  instance_tag: websocket
# [END network]


Jeff Gold

unread,
Aug 31, 2016, 11:12:16 AM8/31/16
to Google Cloud Developers
Also if it helps when it happens it says the instance is still running and no errors, but reports latency as like 12000ms in the instance list.

Jeff Gold

unread,
Sep 6, 2016, 9:50:09 AM9/6/16
to Google Cloud Developers
so in the middle of the night i constantly get these background calls in the log /_ah/background sometimes they result in a error 200. I am not sure what these processes are and what to do about it.

Joe Burnett

unread,
Sep 21, 2016, 2:48:23 PM9/21/16
to Google Cloud Developers
The /_ah/background requests are normal.  Ignore them.

Is your app deployed right now and getting 502s?  Go into the cloud console and find the Compute Engine instance for your version.  SSH into the instance and look at the nginx logs (/var/log/nginx/*.log)  Anything interesting there?

- Joe
Reply all
Reply to author
Forward
0 new messages