View Full Version : Common RPC problem but no solution with BaseModelData

15 Sep 2011, 2:03 AM
Hi ,
i've a class that extends BaseModelData and implements IsSerializable.
if I use this class in client side i've no error,
but if I call a RPC that return a List of this object , i've

[ERROR] javax.servlet.ServletContext log: Exception while dispatching incoming RPC call
java.lang.NoClassDefFoundError: com/extjs/gxt/ui/client/data/BaseModelData

How can i solve this?

i've put gxt-2.2.4-gwt2 in WEB-INF /lib folder but still not working

Colin Alworth
15 Sep 2011, 8:24 AM
There are many reasons that a web server can throw a NoClassDefFound error, none of them related to GWT or the gxt jar you are using. This is more of a java, j2ee problem than a gxt one.

A few thoughts that might help:
* If running from eclipse or another IDE, it might be managing the classpath rather than using everything in the WEB-INF/lib.
* If running from a command line tool (like mvn jetty:run) your dependency declarations might be phrased such that this jar will not be included on the classpath.
* If using a .war file, your servlet container could be ignoring the directory and running straight from the war.
* As servlet containers have a specialized webapp class loader which can mean that the same class made available in multiple places is actually different, you could be seeing an issue where you added the jar to the wrong lib (or even the wrong WEB-INF/lib) directory.

15 Sep 2011, 9:44 AM
webapp is running from eclipse.

1 Mar 2012, 9:55 AM
copy jar GXT in WEB-INF/llib/ ... it work !!!!