Closed
Description
I have created an appengine project using spring-boot.
This is how my code looks like
try {
CacheFactory cacheFactory = CacheManager.getInstance()
.getCacheFactory();
cache = cacheFactory.createCache(Collections.emptyMap());
LOG.info("Cache Created");
cache.put(key, value);
} catch (CacheException ex) {
LOG.error("cache exception encountered:{}", ex);
}
This is the Exception I get
com.google.apphosting.api.ApiProxy$CallNotFoundException: Can't make API call memcache.Set in a thread that is neither the original request thread nor a thread created by ThreadManager
at com.google.apphosting.api.ApiProxy$CallNotFoundException.foreignThread(ApiProxy.java:800) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.apphosting.api.ApiProxy$1.get(ApiProxy.java:175) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.apphosting.api.ApiProxy$1.get(ApiProxy.java:172) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.appengine.api.utils.FutureWrapper.get(FutureWrapper.java:89) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.appengine.api.memcache.MemcacheServiceImpl.quietGet(MemcacheServiceImpl.java:26) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.appengine.api.memcache.MemcacheServiceImpl.put(MemcacheServiceImpl.java:69) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
at com.google.appengine.api.memcache.stdimpl.GCache.put(GCache.java:157) ~[appengine-api-1.0-sdk-1.9.54.jar:na]
I have used the following dependency
<dependency>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-api-1.0-sdk</artifactId>
<version>1.9.54</version>
</dependency>
Metadata
Metadata
Assignees
Labels
No labels