public interface NonJavaBackend
The primary focus of
Smart GWT integration is connecting DataSource operations to your server. The
Client-side Data Integration chapter covers the
key approaches, including cookbook approaches for REST-based integration with any server that
can return XML or JSON over HTTP.
RPCRequest.evalResult to directly turn JSON
lets you load arbitrary server results, including JSON results that need to be processed before
they can be eval()'d.
Alternatively, if you are familiar with WSDL web services, you can
implement simple RPCs as web service operations: use
XMLTools.loadWSDL() to load the service definition,
and then use
WebService.callOperation() to call the operations. We don't generally recommend this approach
unless you are already deeply familiar with WSDL - it's far more complicated that producing and
If you develop a prototype using the Smart GWT SDK and Smart GWT Java Server, and then you migrate the prototype to another server technology, you need to be aware that the Smart GWT Java Server includes an HTTPProxy servlet that allows Smart GWT interfaces to contact servers other than the origin server (bypassing what is called the "same origin policy").
Smart GWT uses the HttpProxy automatically when needed, so it may not be obvious that the HTTPProxy is in use. Then, your migrated application will encounter errors attempting to contact the HTTPProxy servlet.
To avoid these errors, ensure that all
services that your application uses are accessed using the same hostname and port as the page
was loaded from. In particular, watch for WSDL files, which contain the service URL - you may
need to use
ensure that the web service URL and page URL match.
If your production application really does need to access services or content hosted on other servers, typical practice is to pursue normal Smart GWT integration with your server, then write server-side code that contacts other hosts on behalf of your Smart GWT interface.