I am trying to use RemoteServiceServlet within a mobile app. (GWT 2.7.0)
Server Side :
public class MyRpcServiceImpl extends RemoteServiceServlet implements MyRpcService{
private static final long serialVersionUID = 1L;
@Override
public String getString(String widgetRequest)
throws IllegalArgumentException {
return "String from server";
}
}
App Side :
public void onModuleLoad() {
myRpcServiceAsync.getString("", new AsyncCallback<String>(){
@Override
public void onFailure(Throwable caught) {
SC.warn(caught.getMessage() + "\n" + caught.toString());
}
@Override
public void onSuccess(String result) {
SC.say(result);
}
});
....
Works fine when I test under eclipse/Jetty.
When I deploy to PhoneGap (developper) and test, I receive the message from SC.warn...
WARNING
0
com.google.gwt.user.client.rpc.StatusCodeException
0
It looks like node.js is not able to handle my servlet.
I cannot see any error message in phonegap log.
Could you help ?
Any other way to use Jetty/Tomcat instead of node.js within Phonegap.
I would save redevelopping backend services if I could make it work.
Thanks for help
Server Side :
public class MyRpcServiceImpl extends RemoteServiceServlet implements MyRpcService{
private static final long serialVersionUID = 1L;
@Override
public String getString(String widgetRequest)
throws IllegalArgumentException {
return "String from server";
}
}
App Side :
public void onModuleLoad() {
myRpcServiceAsync.getString("", new AsyncCallback<String>(){
@Override
public void onFailure(Throwable caught) {
SC.warn(caught.getMessage() + "\n" + caught.toString());
}
@Override
public void onSuccess(String result) {
SC.say(result);
}
});
....
Works fine when I test under eclipse/Jetty.
When I deploy to PhoneGap (developper) and test, I receive the message from SC.warn...
WARNING
0
com.google.gwt.user.client.rpc.StatusCodeException
0
It looks like node.js is not able to handle my servlet.
I cannot see any error message in phonegap log.
Could you help ?
Any other way to use Jetty/Tomcat instead of node.js within Phonegap.
I would save redevelopping backend services if I could make it work.
Thanks for help
Comment