Class GAEApplicationServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
com.vaadin.terminal.gwt.server.AbstractApplicationServlet
com.vaadin.terminal.gwt.server.ApplicationServlet
com.vaadin.terminal.gwt.server.GAEApplicationServlet
All Implemented Interfaces:
Constants, Serializable, Servlet, ServletConfig
public class GAEApplicationServlet- extends ApplicationServlet
ApplicationServlet to be used when deploying to Google App Engine, in
web.xml:
<servlet>
<servlet-name>HelloWorld</servlet-name>
<servlet-class>com.vaadin.terminal.gwt.server.GAEApplicationServlet</servlet-class>
<init-param>
<param-name>application</param-name>
<param-value>com.vaadin.demo.HelloWorld</param-value>
</init-param>
</servlet>
Session support must be enabled in appengine-web.xml:
<sessions-enabled>true</sessions-enabled>
Appengine datastore cleanup can be invoked by calling one of the applications
with an additional path "/CLEAN". This can be set up as a cron-job in
cron.xml (see appengine documentation for more information):
<cronentries>
<cron>
<url>/HelloWorld/CLEAN</url>
<description>Clean up sessions</description>
<schedule>every 2 hours</schedule>
</cron>
</cronentries>
It is recommended (but not mandatory) to extract themes and widgetsets and
have App Engine server these statically. Extract VAADIN folder (and it's
contents) 'next to' the WEB-INF folder, and add the following to
appengine-web.xml:
<static-files>
<include path="/VAADIN/**" />
</static-files>
Additional limitations:
- Do not change application state when serving an ApplicationResource.
- Avoid changing application state in transaction handlers, unless you're
confident you fully understand the synchronization issues in App Engine.
- The application remains locked while uploading - no progressbar is
possible.
See Also:
Serialized Form
Fields inherited from class com.vaadin.terminal.gwt.server.AbstractApplicationServlet |
REQUEST_APPSTYLE, REQUEST_DEFAULT_THEME, REQUEST_FRAGMENT, REQUEST_SHARED_WIDGETSET, REQUEST_VAADIN_STATIC_FILE_PATH, REQUEST_WIDGETSET, VERSION, VERSION_BUILD, VERSION_MAJOR, VERSION_MINOR, VERSION_REVISION |
Fields inherited from interface com.vaadin.terminal.gwt.server.Constants |
AJAX_UIDL_URI, DEFAULT_BUFFER_SIZE, DEFAULT_THEME_CACHETIME, DEFAULT_THEME_NAME, DEFAULT_WIDGETSET, ERROR_NO_WINDOW_FOUND, INVALID_SECURITY_KEY_MSG, MAX_BUFFER_SIZE, NOT_PRODUCTION_MODE_INFO, PARAMETER_VAADIN_RESOURCES, PARAMETER_WIDGETSET, PORTAL_PARAMETER_VAADIN_RESOURCE_PATH, PORTAL_PARAMETER_VAADIN_THEME, PORTAL_PARAMETER_VAADIN_WIDGETSET, SERVLET_PARAMETER_DEBUG, SERVLET_PARAMETER_DISABLE_XSRF_PROTECTION, SERVLET_PARAMETER_PRODUCTION_MODE, SERVLET_PARAMETER_RESOURCE_CACHE_TIME, THEME_DIRECTORY_PATH, URL_PARAMETER_CLOSE_APPLICATION, URL_PARAMETER_REPAINT_ALL, URL_PARAMETER_RESTART_APPLICATION, URL_PARAMETER_THEME, WARNING_RESOURCE_CACHING_TIME_NOT_NUMERIC, WARNING_XSRF_PROTECTION_DISABLED, WIDGETSET_DIRECTORY_PATH, WIDGETSET_MISMATCH_INFO |
Methods inherited from class com.vaadin.terminal.gwt.server.AbstractApplicationServlet |
createCommunicationManager, createPreventCachingQueryString, criticalNotification, getApplicationContext, getApplicationCSSClassName, getApplicationProperty, getApplicationUrl, getApplicationWindow, getClassLoader, getDefaultTheme, getExistingApplication, getNoScriptMessage, getRequestPathInfo, getRequestType, getResourceCacheTime, getResourceLocation, getResourcePath, getStaticFilesLocation, getSystemMessages, getSystemProperty, handleURI, isAllowedVAADINResourceUrl, isProductionMode, isStandalone, safeEscapeForHtml, setAjaxPageHeaders, stripSpecialChars, writeAjaxPage, writeAjaxPageHtmlBodyStart, writeAjaxPageHtmlHeader, writeAjaxPageHtmlHeadStart, writeAjaxPageHtmlMainDiv, writeAjaxPageHtmlVaadinScripts, writeStaticResourceResponse |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GAEApplicationServlet
public GAEApplicationServlet()
sendDeadlineExceededNotification
protected void sendDeadlineExceededNotification(HttpServletRequest request,
HttpServletResponse response)
throws IOException
- Throws:
IOException
sendNotSerializableNotification
protected void sendNotSerializableNotification(HttpServletRequest request,
HttpServletResponse response)
throws IOException
- Throws:
IOException
sendCriticalErrorNotification
protected void sendCriticalErrorNotification(HttpServletRequest request,
HttpServletResponse response)
throws IOException
- Throws:
IOException
service
protected void service(HttpServletRequest request,
HttpServletResponse response)
throws ServletException,
IOException
Description copied from class: AbstractApplicationServlet
Receives standard HTTP requests from the public service method and
dispatches them.
- Overrides:
service
in class AbstractApplicationServlet
- Parameters:
request
- the object that contains the request the client made of the
servlet.response
- the object that contains the response the servlet returns to
the client.
- Throws:
ServletException
- if an input or output error occurs while the servlet is
handling the TRACE request.
IOException
- if the request for the TRACE cannot be handled.
getApplicationContext
protected ApplicationContext getApplicationContext(HttpServletRequest request,
com.google.appengine.api.memcache.MemcacheService memcache)