Skip navigation links

Package com.google.gwt.user.server.rpc

Package class diagram package com.google.gwt.user.server.rpc
Classes used in server-side implementation of remote procedure calls.

See: Description

Package com.google.gwt.user.server.rpc Description

Classes used in server-side implementation of remote procedure calls.

The RemoteServiceServlet class provides the most convenient implementation of server-side GWT RPC. This class can be used in two ways: it can be subclassed by servlets that directly implement one or more service interfaces, in which case incoming RPC calls will be directed to the servlet subclass itself; or it can be overridden to give finer control over routing RPC calls within a server framework. (For more details on the latter, see the RemoteServiceServlet.processCall(String) method.)

Alternatively, GWT RPC can be integrated into an existing framework, by using the RPC class to perform GWT RPC decoding, invocation, and encoding. RemoteServiceServlet need not be subclassed at all in this case, though reading its source is advisable.

Note that the default RemoteServiceServlet implementation never throws exceptions to the servlet container. All exceptions that escape the RemoteServiceServlet.processCall(String) method will be caught, logged in the servlet context, and will cause a generic failure message to be sent to the GWT client -- with a 500 status code. To customize this behavior, override RemoteServiceServlet.doUnexpectedFailure(java.lang.Throwable).

Skip navigation links

Copyright © 2018. All rights reserved.