Is it possible to programmatically change GWT RPC servlet path?

I'm not sure, if this will solve the entire problem, because you say, that it already works for the first time you make the call - but can you try the following when you create the serviceAsync on the client side.

I'm not sure, if this will solve the entire problem, because you say, that it already works for the first time you make the call - but can you try the following when you create the serviceAsync on the client side: MyServiceAsync service = GWT. Create(MyService. Class); ServiceDefTarget serviceDefTarget = (ServiceDefTarget) service; serviceDefTarget.

SetServiceEntryPoint( "http://localhost:8080/foo/bar/00_00_00/myapp/MyApp/"); /* ^^ Use your full servlet path here ^^ */ If you wonder, why you'd have to cast this explicitly to ServiceDefTarget - here's an explanation from the Javadoc of ServiceDefTarget: /** * An interface implemented by client-side RPC proxy objects. Cast the object * returned from {@link com.google.gwt.core.client. GWT#create(Class)} on a * {@link RemoteService} to this interface to initialize the target URL for the * remote service.

*/ (I assume, that you're loading your html host page from "http://localhost:8080", otherwise this would fail because of the Same Origin Policy. ) Another problem I can imagine, may be related with caching in your proxy - so maybe try turning off any caching first, and then re-enable it only for resources with "*.cache. *" filenames (see also: Ideal HTTP cache control headers for different types of resources).

Thanks, this pointed me in the right direction. My web. Xml was defining url-mapping for my service as /myapp.

But I finally realized that you have to map the servlet url to the same url where all the compile gwt js stuff is. So, I changed url-mapping for the servlet to /MyApp/myapp. My GWT Module is named MyApp.So, now that the two paths match, it works!

– Dave Paroulek Apr 5 at 19:45.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions