Using Process Managers

146 views
Skip to first unread message

Dennis Yurkevich

unread,
Jul 19, 2018, 5:38:12 AM7/19/18
to google-a...@googlegroups.com
Hello All!

When deploying apps using GAE - is a process manager needed?

Right now I am using the Nodejs Flexible environment, and in my npm run start command -> simply running node app.js

The application seems to be live most of the time, but not sure on what the best practice is. When I was using Compute engine I also used PM2.

If the answer is that no process manager is needed it would be great to understand why also!

Any help would be great.

Thanks!

Kenworth (Google Cloud Platform)

unread,
Jul 19, 2018, 12:32:27 PM7/19/18
to Google App Engine
It comes down to preference. It always makes sense to have a process manager running in Node.js production. It would be a better user experience to have an application restart after being down for example. Note that having a process manager will impact resources / performance.  However, if you have mission critical apps, then it would be worth the performance hit to have a PM running. 


Dennis Yurkevich

unread,
Jul 19, 2018, 12:56:48 PM7/19/18
to google-a...@googlegroups.com
Thanks Kenworth.

So GAE env itself or the Docker env provides nothing of this sort?

On Thu, Jul 19, 2018 at 5:32 PM, 'Kenworth (Google Cloud Platform)' via Google App Engine <google-a...@googlegroups.com> wrote:
It comes down to preference. It always makes sense to have a process manager running in Node.js production. It would be a better user experience to have an application restart after being down for example. Note that having a process manager will impact resources / performance.  However, if you have mission critical apps, then it would be worth the performance hit to have a PM running. 


--
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+unsubscribe@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/28b57b11-fec9-48b3-a9bc-fa95bb7de91d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Julie (cloud platform support)

unread,
Jul 25, 2018, 9:15:17 AM7/25/18
to Google App Engine
How you are planning to use the Process Manager? I can check to see if that functionality is supported. 

gnome rock

unread,
Jul 25, 2018, 9:22:42 AM7/25/18
to google-a...@googlegroups.com
Excuse me, What is Process Manager ?
I never used it.


On 25 Jul BE 2561, at 20:15, 'Julie (cloud platform support)' via Google App Engine <google-a...@googlegroups.com> wrote:

How you are planning to use the Process Manager? I can check to see if that functionality is supported. 

--
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.

Dennis Yurkevich

unread,
Jul 25, 2018, 9:56:14 AM7/25/18
to google-a...@googlegroups.com
A process manager is something which at the very basic level restarts the app if it crashes - most popular for node is http://pm2.keymetrics.io/

@Julie, if you feel it is needed I would install PM2 and use it to start the server script instead of using node.

On Wed, Jul 25, 2018 at 2:20 PM, gnome rock <nuttakorn...@gmail.com> wrote:
Excuse me, What is Process Manager ?
I never used it.


On 25 Jul BE 2561, at 20:15, 'Julie (cloud platform support)' via Google App Engine <google-appengine@googlegroups.com> wrote:

How you are planning to use the Process Manager? I can check to see if that functionality is supported. 

--
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+unsubscribe@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.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+unsubscribe@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.

Julie (cloud platform support)

unread,
Jul 26, 2018, 4:15:51 PM7/26/18
to Google App Engine
The decision on whether or not to include a process manager really depends on your application and if it is critical that it avoids/minimizes downtime. As mentioned by Kenworth, including one would likely improve user experience but may increase resource usage and therefore cost.

Dennis Yurkevich

unread,
Jul 26, 2018, 6:10:08 PM7/26/18
to google-a...@googlegroups.com
Thank you Julie and Kenworth.

I will add one and measure the overhead.

However from my testing it seems GAE keeps the app running. Not sure if there is anything which does that or the code is awesome 😎 

Thank you for your help!
Dennis

On Thu, 26 Jul 2018 at 21:15, 'Julie (cloud platform support)' via Google App Engine <google-a...@googlegroups.com> wrote:
The decision on whether or not to include a process manager really depends on your application and if it is critical that it avoids/minimizes downtime. As mentioned by Kenworth, including one would likely improve user experience but may increase resource usage and therefore cost.

--
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.

Kenworth (Google Cloud Platform)

unread,
Jul 27, 2018, 12:58:41 PM7/27/18
to Google App Engine

So GAE env itself or the Docker env provides nothing of this sort?

Not on GAE. For Docker, you can try look at restart policies and see if it fits your use-case.

Dennis Yurkevich

unread,
Jul 27, 2018, 1:07:13 PM7/27/18
to google-a...@googlegroups.com
Thanks Kenworth so does the default docker context of GAE set any of these.

The default for docker is NO restart, which looking at my logs does not match as I can see the process restart on error. Not sure what is triggering this...

On Fri, 27 Jul 2018 at 17:58, 'Kenworth (Google Cloud Platform)' via Google App Engine <google-a...@googlegroups.com> wrote:

So GAE env itself or the Docker env provides nothing of this sort?

Not on GAE. For Docker, you can try look at restart policies and see if it fits your use-case.

--
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.

Julie (cloud platform support)

unread,
Jul 31, 2018, 1:35:23 PM7/31/18
to Google App Engine
Can you provide the full details of the error when the restart is occurring(perhaps, a screenshot of the error) as it is not clear why a restart would be occurring. 
Reply all
Reply to author
Forward
0 new messages