On Wednesday, October 31, 2012 1:08:59 PM UTC+1, Moritz wrote:
Hi all,
I get a NoClassDefFoundError for com.google.gwt.core.client.GWTBridge when I throw a RuntimeException on a server RPC. When I do not throw the RuntimeException and the RPC completes fine also no NoClassDefFoundError is thrown.
As a workaround, I created an abstract com.google.gwt.core.client.GWTBridge which simply extends the ...shared.GWTBridge class. I read about http://code.google.com/p/ google-web-toolkit/issues/ but it seems that this is something different, or not? Any solution?detail?id=7527
Cheers,
Moritz.
PD, here comes the full stack trace, the exception seems to be related to the Guice filters:
SEVERE: javax.servlet.ServletContext log: Exception while dispatching incoming RPC call
java.lang.NoClassDefFoundError: com/google/gwt/core/client/ GWTBridge
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at com.google.appengine.tools.development.agent.runtime. RuntimeHelper.checkRestricted( RuntimeHelper.java:70)
at com.google.appengine.tools.development.agent.runtime. Runtime.checkRestricted( Runtime.java:64)
at com.google.gwt.user.client.rpc.core.java.util.Arrays$ ArrayList_ CustomFieldSerializer. serialize(Arrays.java:64)
at com.google.gwt.user.client.rpc.core.java.util.Arrays$ ArrayList_ CustomFieldSerializer. serializeInstance(Arrays.java: 94)
at com.google.gwt.user.client.rpc.core.java.util.Arrays$ ArrayList_ CustomFieldSerializer. serializeInstance(Arrays.java: 34)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serializeImpl( ServerSerializationStreamWrite r.java:786)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serialize( ServerSerializationStreamWrite r.java:667)
at com.google.gwt.user.client.rpc.impl. AbstractSerializationStreamWri ter.writeObject( AbstractSerializationStreamWri ter.java:126)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r$ValueWriter$8.write( ServerSerializationStreamWrite r.java:153)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serializeValue( ServerSerializationStreamWrite r.java:585)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serializeClass( ServerSerializationStreamWrite r.java:755)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serializeImpl( ServerSerializationStreamWrite r.java:794)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serialize( ServerSerializationStreamWrite r.java:667)
at com.google.gwt.user.client.rpc.impl. AbstractSerializationStreamWri ter.writeObject( AbstractSerializationStreamWri ter.java:126)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r$ValueWriter$8.write( ServerSerializationStreamWrite r.java:153)
at com.google.gwt.user.server.rpc.impl. ServerSerializationStreamWrite r.serializeValue( ServerSerializationStreamWrite r.java:585)
at com.google.gwt.user.server.rpc.RPC.encodeResponse(RPC. java:605)
at com.google.gwt.user.server.rpc.RPC. encodeResponseForFailure(RPC. java:393)
at com.google.gwt.user.server.rpc.RPC. invokeAndEncodeResponse(RPC. java:579)
at com.google.gwt.user.server.rpc.RemoteServiceServlet. processCall( RemoteServiceServlet.java:208)
at com.google.gwt.user.server.rpc.RemoteServiceServlet. processPost( RemoteServiceServlet.java:248)
at com.google.gwt.user.server.rpc. AbstractRemoteServiceServlet. doPost( AbstractRemoteServiceServlet. java:62)
at javax.servlet.http.HttpServlet.service( HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service( HttpServlet.java:717)
at com.google.inject.servlet.ServletDefinition.doService( ServletDefinition.java:263)
at com.google.inject.servlet.ServletDefinition.service( ServletDefinition.java:178)
at com.google.inject.servlet.ManagedServletPipeline. service( ManagedServletPipeline.java: 91)
at com.google.inject.servlet.FilterChainInvocation. doFilter( FilterChainInvocation.java:62)
at com.googlecode.objectify.cache.AsyncCacheFilter. doFilter(AsyncCacheFilter. java:59)
at com.googlecode.objectify.ObjectifyFilter.doFilter( ObjectifyFilter.java:49)
at com.google.inject.servlet.FilterDefinition.doFilter( FilterDefinition.java:163)
at com.google.inject.servlet.FilterChainInvocation. doFilter( FilterChainInvocation.java:58)
at com.MYPROJECT.server.NamespaceFilter.doFilter( NamespaceFilter.java:22)
at com.google.inject.servlet.FilterDefinition.doFilter( FilterDefinition.java:163)
at com.google.inject.servlet.FilterChainInvocation. doFilter( FilterChainInvocation.java:58)
at com.google.inject.servlet.ManagedFilterPipeline. dispatch( ManagedFilterPipeline.java: 118)
at com.google.inject.servlet.GuiceFilter.doFilter( GuiceFilter.java:113)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.api.socket.dev.DevSocketFilter. doFilter(DevSocketFilter.java: 74)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.tools.development. ResponseRewriterFilter. doFilter( ResponseRewriterFilter.java: 123)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.tools.development. HeaderVerificationFilter. doFilter( HeaderVerificationFilter.java: 34)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.api.blobstore.dev.ServeBlobFilter. doFilter(ServeBlobFilter.java: 61)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.apphosting.utils.servlet. TransactionCleanupFilter. doFilter( TransactionCleanupFilter.java: 43)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.tools.development.StaticFileFilter. doFilter(StaticFileFilter. java:125)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at com.google.appengine.tools.development. BackendServersFilter.doFilter( BackendServersFilter.java:97)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain. doFilter(ServletHandler.java: 1157)
at org.mortbay.jetty.servlet.ServletHandler.handle( ServletHandler.java:388)
at org.mortbay.jetty.security.SecurityHandler.handle( SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle( SessionHandler.java:182)
at org.mortbay.jetty.handler.ContextHandler.handle( ContextHandler.java:765)
at org.mortbay.jetty.webapp.WebAppContext.handle( WebAppContext.java:418)
at com.google.appengine.tools.development. DevAppEngineWebAppContext. handle( DevAppEngineWebAppContext. java:94)
at org.mortbay.jetty.handler.HandlerWrapper.handle( HandlerWrapper.java:152)
at com.google.appengine.tools.development. JettyContainerService$ ApiProxyHandler.handle( JettyContainerService.java: 383)
at org.mortbay.jetty.handler.HandlerWrapper.handle( HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest( HttpConnection.java:542)
at org.mortbay.jetty.HttpConnection$RequestHandler. content(HttpConnection.java: 938)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:755)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser. java:218)
at org.mortbay.jetty.HttpConnection.handle( HttpConnection.java:404)
at org.mortbay.io.nio.SelectChannelEndPoint.run( SelectChannelEndPoint.java: 409)
at org.mortbay.thread.QueuedThreadPool$PoolThread. run(QueuedThreadPool.java:582)
Caused by: java.lang.ClassNotFoundException: com.google.gwt.core.client. GWTBridge
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged( Native Method)