I've changed the topic name from this thread but the issue is the same: https://groups.google.com/d/topic/google-appengine-java/nU1c9tHbG60/discussion
I want to know if this is a recognised problem with threads-safe=true apps and if work is being done to improve the situation. Can I expect a solution soon or should I revert to thread-safe=false in the mean time. Currently it is causing havoc with one of my sites and traffic has dropped very significantly over the last week. Using thread-safe=false raises the latency on average (but without the long loads) so that is not really ideal. To reiterate the problem, loading requests frequently time-out with DeadlineExceededException or HardDeadlineExceededError while loading classes. As my app uses Guice, this usually happens while creating the Injector from a ContextListener. Usually loading requests take 4 - 8 seconds. Recently (last week or more) they take either the normal time or an excessive amount of time (not in between), often causing a time-out. When they do time-out the exception is thrown while waiting for file system access which makes me think that this is the cause of the long delays and exceptions. This problem *only *occurs during loading requests - never during normal requests. This reinforces the theory that it is due to class loading or other initialisation work. The exception is never thrown while trying to read from memcache or the datastore so I don't think the recent memcache problems can be blamed. Below are some example stack traces from loading requests that time-out Caused by: com.google.apphosting.api.DeadlineExceededException: This request (87a9b70d2e6454ce) started at 2011/08/30 21:35:23.631 UTC and was still executing at 2011/08/30 21:36:07.688 UTC. at com.google.appengine.runtime.Request.process-87a9b70d2e6454ce(Request.java) at java.io.FileInputStream.readBytes(Native Method) at java.io.FileInputStream.read(FileInputStream.java:231) at sun.misc.Resource.getBytes(Resource.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:273) at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at java.lang.ClassLoader.loadClass(ClassLoader.java:266) Caused by: com.google.apphosting.runtime.HardDeadlineExceededError: This request (5d47b3fba3dc9418) started at 2011/08/30 21:35:53.131 UTC and was still executing at 2011/08/30 21:36:28.003 UTC. at com.google.appengine.runtime.Request.process-5d47b3fba3dc9418(Request.java) at java.io.FileInputStream.readBytes(Native Method) at java.io.FileInputStream.read(FileInputStream.java:231) at sun.misc.Resource.getBytes(Resource.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:273) at sun.reflect.GeneratedMethodAccessor5.invoke(Unknown Source) Caused by: com.google.apphosting.runtime.HardDeadlineExceededError: This request (969d70b821181c7d) started at 2011/08/30 04:05:53.874 UTC and was still executing at 2011/08/30 04:06:34.552 UTC. at com.google.appengine.runtime.Request.process-969d70b821181c7d(Request.java) at java.util.zip.ZipFile.read(Native Method) at java.util.zip.ZipFile.access$1200(ZipFile.java:57) at java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:476) at sun.misc.Resource.getBytes(Resource.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:273) at java.net.URLClassLoader.access$000(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:212) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at java.lang.ClassLoader.loadClass(ClassLoader.java:321) When the loading request take so long, many instances are started to handle the pending requests. This results in a lot of instances created that are not needed and they just sit there once the app eventually gets back on its feet again: <https://lh5.googleusercontent.com/-9ehwmZDo0ys/Tl3Aevbh45I/AAAAAAAAADg/VJfOXow4Rk8/Capture.PNG> I've seen related issues in the tracker but one discussion suggested that the problem was fixed in 1.5.2: https://groups.google.com/d/topic/google-appengine-java/6tnyfJLBIXM/discussion One issue in the tracker is "Started" but no update and it is now a couple of months old: http://code.google.com/p/googleappengine/issues/detail?id=5214 I hope someone can shed some light on this problem. Thanks, John -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-appengine-java/-/eKUvh_zhZScJ. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.