google app engine - GAE Flexible Environment Service error in memcache -


i use jetty9-compat + java8 configuration , receive following exception. because of not able store objects in session, in end cannot log in service.

[info] cze 28, 2016 11:17:56 com.google.apphosting.vmruntime.vmmetadatacache getmetadata [info]  [info] info: meta-data 'attributes/gae_affinity' path retrieval error: metadata [info]  [info] cze 28, 2016 11:17:56 com.google.apphosting.vmruntime.vmapiproxydelegate runsynccall [info]  [info] info: http apiproxy i/o error memcache.get: target server failed respond [info]  [info] cze 28, 2016 11:17:56 com.google.appengine.api.memcache.logandcontinueerrorhandler handleserviceerror [info]  [info] info: service error in memcache [info]  [info] com.google.appengine.api.memcache.memcacheserviceexception: rcp failure api call: memcache [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate.constructapiexception(vmapiproxydelegate.java:232) [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate.runsynccall(vmapiproxydelegate.java:195) [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate.makeapicall(vmapiproxydelegate.java:154) [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate.access$000(vmapiproxydelegate.java:60) [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate$makesynccall.call(vmapiproxydelegate.java:436) [info]  [info]  @ com.google.apphosting.vmruntime.vmapiproxydelegate$makesynccall.call(vmapiproxydelegate.java:412) [info]  [info]  @ java.util.concurrent.futuretask.run(futuretask.java:266) [info]  [info]  @ java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor.java:1142) [info]  [info]  @ java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor.java:617) [info]  [info]  @ java.lang.thread.run(thread.java:745) [info]  [info]  [info]  [info] debug    2016-06-28 11:17:56,493 api_server.py:277] handled datastore_v3.get in 0.0000 [info] cze 28, 2016 11:17:59 com.mysql.jdbc.log.slf4jlogger loginfo 

this issue reproduced locally, face too. assume caused incorrect configuration of local memcached run dev server.

i'll try explain point. in case first request successful. because in case of first request apache httpclient opens new connection , puts pool. there source code https://github.com/googlecloudplatform/appengine-java-vm-runtime/blob/master/appengine-managed-runtime/src/main/java/com/google/apphosting/vmruntime/vmapiproxydelegate.java

all further requests successful too, if executed interval 10 seconds. if there no request within 10 seconds, next request fails. happens because memcached service closes connection side, httpclient doesn't know it.

in vmapiproxydelegate httpclient configured close idle connections after 60 seconds. so, if wait more 1 minute instead of 10 seconds, next request doesn't fail. because in case httpclient opens new connection not closed yet.

to avoid issue correct configure connection timeout memcached stub side. documentation says requests memcached can fail , must handle these errors. so, offer add error handler , retry mechanism.

of course of above fits case, if ok in configuration. taking account did not provide examples of configuration , code, assume there ok.


Comments

Popular posts from this blog

sql - invalid in the select list because it is not contained in either an aggregate function -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

How to start daemon on android by adb -