1. #1
    Sencha User
    Join Date
    Dec 2012
    Posts
    5
    Vote Rating
    0
    ramaraju256 is on a distinguished road

      0  

    Default Answered: Grid server-side paging is failed in web-mode

    Answered: Grid server-side paging is failed in web-mode


    Hi All,

    Gxt Version-->gxt-2.2.4-gwt22

    Grid server-side paging is failed in web-mode but it is working fine in dev-mode in web-mode it throws excepton

    SEVERE: data: An IncompatibleRemoteServiceException was thrown while processing this call.
    com.google.gwt.user.client.rpc.IncompatibleRemoteServiceException: java.lang.NoClassDefFoundError: com/google/gwt/core/client/GWTBridge
    at com.google.gwt.user.server.rpc.RPC.decodeRequest(RPC.java:323)
    at com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServiceServlet.java:206)
    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 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
    at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:877)
    at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:594)
    at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1675)
    at java.lang.Thread.run(Thread.java:662)
    Caused by: com.google.gwt.user.client.rpc.SerializationException: java.lang.NoClassDefFoundError: com/google/gwt/core/client/GWTBridge
    at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader.deserialize(ServerSerializationStreamReader.java:691)
    at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader.readObject(ServerSerializationStreamReader.java:567)
    at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader$ValueReader$8.readValue(ServerSerializationStreamReader.java:140)
    at com.google.gwt.user.server.rpc.impl.ServerSerializationStreamReader.deserializeValue(ServerSerializationStreamReader.java:425)
    at com.google.gwt.user.server.rpc.RPC.decodeRequest(RPC.java:312)
    ... 17 more

  2. This exception is being thrown on the server - there isn't a difference in the server code when you are running in Dev Mode versus compiled Web Mode. So there is some other difference in how you are running in web mode than prod mode.

    From this part of your error message, it appears that you are using gwt-servlet.jar version 2.5.0 when running web mode, and either using a 2.4.0 version for dev mode, or adding other jars to the classpath when in dev mode.
    Code:
    java.lang.NoClassDefFoundError: com/google/gwt/core/client/GWTBridge
    A simple google search on this text brings up this bug report that affects only GWT 2.5.0: http://code.google.com/p/google-web-...detail?id=7527

    As discussed there, there are several fixes: Copy the GWTBridge class into your project, or add requestfactory-server.jar to your WEB-INF/lib/, or update to GWT trunk version, or back off to GWT 2.4.0.

  3. #2
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,717
    Answers
    109
    Vote Rating
    89
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    This exception is being thrown on the server - there isn't a difference in the server code when you are running in Dev Mode versus compiled Web Mode. So there is some other difference in how you are running in web mode than prod mode.

    From this part of your error message, it appears that you are using gwt-servlet.jar version 2.5.0 when running web mode, and either using a 2.4.0 version for dev mode, or adding other jars to the classpath when in dev mode.
    Code:
    java.lang.NoClassDefFoundError: com/google/gwt/core/client/GWTBridge
    A simple google search on this text brings up this bug report that affects only GWT 2.5.0: http://code.google.com/p/google-web-...detail?id=7527

    As discussed there, there are several fixes: Copy the GWTBridge class into your project, or add requestfactory-server.jar to your WEB-INF/lib/, or update to GWT trunk version, or back off to GWT 2.4.0.

  4. #3
    Ext GWT Premium Member
    Join Date
    Jul 2011
    Location
    Cluj-Napoca
    Posts
    70
    Vote Rating
    6
    lucaalex87 is on a distinguished road

      0  

    Default Solution

    Solution


    Hi,

    As Colin mentions, it's a defect in GWT 2.5 that google fixed, and will be released in 2.5.1.

    A quick fix is to add GWTBridge to your project. Add this in your project:

    Code:
    package com.google.gwt.core.client;
    import com.google.gwt.core.shared.*;
    /**
    * Date: 1/17/13
    * Time: 12:37 PM
    * This class is used for fixing class not found com.google.gwt.core.client.GWTBridge;
    *
    */
    public abstract class GWTBridge extends com.google.gwt.core.shared.GWTBridge {
    }
    If you want more details read here:

    http://alexluca.com/2013/01/17/gwt-2...ientgwtbridge/

    Regards,
    Alex.

  5. #4
    Sencha User
    Join Date
    Nov 2011
    Posts
    1
    Vote Rating
    0
    solidmcg is on a distinguished road

      0  

    Default


    I am currently using GWT 2.5.1 and GXT 2.3.1 and after deployment I am experiencing java.lang.NoClassDefFoundError: com/google/gwt/core/client/GWTBridge error.

    In my opinion GWT team moved GWT and GWTBridge class to new package com.google.gwt.core.shared. GXT team should refactor current version of library and i.e. FastMap implementation should reference com.google.gwt.core.shared package.

    Is there any hope for releasing GXT 2.3.1 version compatible with new GWT 2.5.1 codebase?

  6. #5
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,717
    Answers
    109
    Vote Rating
    89
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      -1  

    Default


    This issue will affect any GWT library that works with RPC, uses the GWT class, and happens to be compatible with more than just 2.5.0, when the shared version of that class was introduced. To maintain backward compatibility, GXT 2 and 3.0 both point at the .client. version of that class. We can either deliberately break compatibility with GWT 2.2-2.4, or rely on one of the many valid ways to solve this. (requestfactory-server.jar, extend GWTBridge, copy GWTBridge, etc).

    GXT 3.1 is being made *only* compatible with GWT 2.6+, which among other things involves using the shared GWT class. GXT 3 is more closely tracking GWT changes, while GXT 2 is compatible with all the way back to GWT 1.7, and introduces a new jar for any binary incompatibility.

    We've received surprisingly little negative feedback on this decision, and so for the time being I think we are staying with it - by and large, teams that are still using GXT 2 won't get anywhere near the as much benefit from moving to a newer GWT version than they would from moving to a newer GXT *and* GWT version.