@Beta public class AppEngineNotificationServlet extends javax.servlet.http.HttpServlet
Beta
In order to use this servlet you need to register the servlet in your web.xml. You may optionally
extend AppEngineNotificationServlet
with custom behavior.
It is a simple wrapper around WebhookUtils.processWebhookNotification(HttpServletRequest,
HttpServletResponse, DataStoreFactory)
that uses
AppEngineDataStoreFactory.getDefaultInstance()
, so you may alternatively call that method
instead from your HttpServlet.doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
with no loss of functionality.
<servlet > <servlet-name >AppEngineNotificationServlet </servlet-name > <servlet-class >com.google.api.client.googleapis.extensions.appengine.notifications.AppEngineNotificationServlet </servlet-class > </servlet > <servlet-mapping > <servlet-name >AppEngineNotificationServlet </servlet-name > <url-pattern >/notifications </url-pattern > </servlet-mapping >
Constructor and Description |
---|
AppEngineNotificationServlet() |
Modifier and Type | Method and Description |
---|---|
protected void |
doPost(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp) |
doDelete, doGet, doHead, doOptions, doPut, doTrace, getLastModified, service, service
protected void doPost(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, IOException
doPost
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
IOException
Copyright © 2010–2020 Google. All rights reserved.