Instance restart

129 views
Skip to first unread message

Stefano Ciccarelli

unread,
Dec 5, 2016, 8:58:07 AM12/5/16
to GAE Group
Hello!

After the deprecation of the compat java flexible runtime we must come back to standard environment. Using VMs we solved our latency problems, but now we must solve them using standard env.

I've attached a screenshot of a graph from Stackdriver showing one hour traffic, a screenshot of loading requests in that hour and the life of one single instance appeared and the disappeared after a couple of minutes during that hour.

We need help because there are instances that live one or two hours, and instances that live a couple minutes; when instances restart we have latency spikes.

Can anyone help us understand what we should do?

Thank you
Stefano

--
Stefano Ciccarelli 
GAE Application Division 
/ Director 
stefano.c...@mmbsoftware.it 

M.M.B. s.r.l. 
via Granarolo, 177/7 - 48018 Faenza (RA) - Italy 
tel. +39.0546.637711 - fax +39.0546.46077 
www.mmbsoftware.it - in...@mmbsoftware.it

Le informazioni contenute in questa comunicazione sono riservate e destinate esclusivamente alla/e persona/e o all'ente sopra indicati. E' vietato ai soggetti diversi dai destinatari qualsiasi uso, copia, diffusione di quanto in esso contenuto sia ai sensi dell'art. 616 c.p., sia ai sensi del DL n. 196/03. Se questa comunicazione Vi e' pervenuta per errore, Vi preghiamo di rispondere a questa e-mail e successivamente cancellarla dal Vostro sistema.
single-instance.PNG
traffic.PNG
loading-requests.PNG

George (Cloud Platform Support)

unread,
Dec 5, 2016, 1:15:28 PM12/5/16
to Google App Engine

Hello Stefano,


When you say that after the deprecation of the compat java flexible runtime one is force to come back to the standard environment, you might have overlooked one of the alternatives. This excellent alternative would be the flexible environment, that offers some services similar to the standard environment, especially important among these being scalability. You can simply adapt your app to the Flexible Environment using Google Cloud Client libraries.


If you decide to keep your application running in the standard environment, there are a few avenues leading to improved latency.


Firstly, your code seems to take the bulk of the response time, one sees 17746 ms for yap/action/TecDocGenericArticlesGetAction (Timestamp 2016-12-05 (12:12:20.790)). By contrast, Google platform services provide about 2 ms reaction time.


The app.yaml settings you have chosen can be fine tuned too. The two main parameters are min pending latency of 0.500 ms, that can be increased, and Max Concurrent Request set to 5 when the default is 50. Playing around with these 2 parameters may improve latency markedly, and avoid the launching of new instances, but the main source of delay seems to be somewhere in your code.

Thomas Baldauf

unread,
Dec 8, 2016, 1:29:17 PM12/8/16
to Google App Engine
Same problem here! I also migrated my Standard Java app to Flex Env and was surprised by the great performance there. Unfortunately, with the deprecation of the compat runtime, there's no easy way to leave it there any more. We'd have to rewrite lots of our code and some vital services like memcache are not even available at the moment. So we had to go back to Standard and there we experience very bad performance, same as in the logs you just showed. More than 10s response latency for really no special reason is not ok for user frontends.

George (Cloud Platform Support)

unread,
Dec 9, 2016, 12:08:29 PM12/9/16
to Google App Engine
We all agree on the stellar performance of the flexible environment. It may prove a wise decision to invest time and effort for a migration now, and then profit on the long term.

Joshua Fox

unread,
Dec 11, 2016, 8:19:46 AM12/11/16
to google-a...@googlegroups.com
I don't understand the value proposition of the Flex Environment, especially the non-compat one.

It does not support AppEngine APIs, Memcache, or built-in credentials. Scaling is nice, and there are some management tools, but is that enough reason for users to adopt it, in contrast to an IaaS or container solution?

I am asking a high-level question here: Why would a software architect, seeing a variety  of choices for building an application (beyond a standard webapp or pipeline), choose to use Flexible Environment?

--
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/a5594b85-a03b-455d-a523-0c4cfd58f3d0%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
JOSHUA FOX
Principal Software Architect | Freightos


 (Israel): +972-545691165 |  (US):  +1-3123400953 | Skypejoshuafox.freightos
Smoother shipping with the world's online freight marketplace.

Message has been deleted
Message has been deleted
Message has been deleted

Attila-Mihaly Balazs

unread,
Dec 12, 2016, 2:35:54 AM12/12/16
to Google App Engine
AFAIK the flexible environment is not available in the EU region and there is no word when it will be available (been in beta for over a year now in other regions).

Really sad.
Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
0 new messages