Problems with GWT 2.4

谁说我不能喝 提交于 2019-12-23 05:52:36

问题


I compiled the version in svn tagged as gwt2.4rc. Now there are a couple of more libraries than I had the last time. Are the any instructions on which library is needed for what? I tried it with only the standard libraries (servlet, servlet-deps, user) but I get the following error when a requestfactory call is made:

java.lang.NoSuchMethodError: com.google.gwt.core.client.impl.WeakMapping.setWeak(Ljava/lang/ Object;Ljava/lang/String;Ljava/lang/Object;)

I tried declaring the requestfactory-client and requestfactory-server jars as dependencies, but i doesn't help. I am using maven to manage my dependencies. I would go back to 2.4 beta, but I need the drag&drop features that were introduced later. Does anybody has an idea what could be wrong? or any hints how i can dig deeper into this? I spend a lot of time trying to figure this out but without any success :( Do I need to provide more information?

Regards, arne


回答1:


Are you sure you deployed the 2.4-rc1 gwt-servlet.jar in your war/WEB-INF/lib ? Also, make sure you override the SDK for the gwt-maven-plugin: http://mojo.codehaus.org/gwt-maven-plugin/user-guide/using-different-gwt-sdk-version.html

That being said:

  • when using Maven, you shouldn't use gwt-servlet-deps but instead reference org.json:json and javax.validation:validation-api
  • requestfactory-server can be used instead of gwt-servlet if you only use RequestFactory on the server-side (no GWT-RPC, no SafeHtml, no RegExp, etc.); requestfactory-client is to be used for Java clients (such as Android), not the case here.


来源:https://stackoverflow.com/questions/6649483/problems-with-gwt-2-4

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!