jQuery in Action, 3rd edition
The moose likes GWT and the fly likes GWT Spring Integration. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "GWT Spring Integration. " Watch "GWT Spring Integration. " New topic

GWT Spring Integration.

kartik hedau

Joined: Feb 12, 2013
Posts: 8
hello i am trying to integrate GWT with spring,when ever i run the code it shows following error.

Exception while dispatching incoming RPC call
com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.lang.String com.login.client.GreetingService.login(java.lang.String,java.lang.String)' threw an unexpected exception: java.lang.NullPointerException





when ever i use following code

its working well but i want to use logindao(Autowired) instance to access the method directly to access dao.

Thank you in Advance.
Ankit Garg

Joined: Aug 03, 2008
Posts: 9453

There are two instance of GreetingServiceImpl. One instance gets the auto-wired LoginDao instance through Spring. The second instance is registered as a Servlet in your web.xml file. As a quick hack you can try to make the LoginDao property in GreetingServiceImpl static. You can also try following this tutorial or use spring4gwt...

SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
spec india

Joined: Apr 09, 2013
Posts: 1
Hi There,

I would suggest you go for this library


It is very easy to use. You just need to follow couple of steps

1) Add the Library into your Project.

2) Add the below mentioned entry in web.xml



3) Define below in your applicationContext.xml for your RPC classes

<context:component-scan base-package=

4) Mark your Remove Service with Below mentioned Annotation


5) Make sure that your RPC implementation is marked with below mentioned annotation. Also they should purely implement RemoteServiceInterface. Nothing else.


Let me know if this helps.


I agree. Here's the link: http://aspose.com/file-tools
subject: GWT Spring Integration.
It's not a secret anymore!