org.opencrx.kernel.workflow.servlet
Class SubscriptionHandlerServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.opencrx.kernel.workflow.servlet.SubscriptionHandlerServlet
- All Implemented Interfaces:
- Serializable, Servlet, ServletConfig
public class SubscriptionHandlerServlet
- extends HttpServlet
The SubscriptionHandlerServlet handles two use cases:
- It monitors object modifications by scanning the audit entries. If the modified object has a
matching topic, all subscriptions for this topic are handled by executing the configured workflow.
- It monitors upcoming reminders and performs a sendAlert().
- See Also:
- Serialized Form
|
Method Summary |
protected void |
doGet(HttpServletRequest req,
HttpServletResponse res)
|
protected void |
doPost(HttpServletRequest req,
HttpServletResponse res)
|
void |
handleReminders(String id,
String providerName,
String segmentName,
HttpServletRequest req,
HttpServletResponse res)
|
protected void |
handleRequest(HttpServletRequest req,
HttpServletResponse res)
|
void |
handleSubscriptions(String id,
String providerName,
String segmentName,
HttpServletRequest req,
HttpServletResponse res)
|
void |
init(ServletConfig config)
|
boolean |
subscriptionAcceptsMessage(Subscription subscription,
AuditEntry auditEntry)
|
protected boolean |
testFilterValue(String filterName,
String filterValue,
Object message)
|
boolean |
topicAcceptsObject(String providerName,
String segmentName,
Topic topic,
String objectXri)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SubscriptionHandlerServlet
public SubscriptionHandlerServlet()
init
public void init(ServletConfig config)
throws ServletException
- Specified by:
init in interface Servlet- Overrides:
init in class GenericServlet
- Throws:
ServletException
testFilterValue
protected boolean testFilterValue(String filterName,
String filterValue,
Object message)
subscriptionAcceptsMessage
public boolean subscriptionAcceptsMessage(Subscription subscription,
AuditEntry auditEntry)
topicAcceptsObject
public boolean topicAcceptsObject(String providerName,
String segmentName,
Topic topic,
String objectXri)
handleSubscriptions
public void handleSubscriptions(String id,
String providerName,
String segmentName,
HttpServletRequest req,
HttpServletResponse res)
throws IOException
- Throws:
IOException
handleReminders
public void handleReminders(String id,
String providerName,
String segmentName,
HttpServletRequest req,
HttpServletResponse res)
throws IOException
- Throws:
IOException
handleRequest
protected void handleRequest(HttpServletRequest req,
HttpServletResponse res)
throws ServletException,
IOException
- Throws:
ServletException
IOException
doGet
protected void doGet(HttpServletRequest req,
HttpServletResponse res)
throws ServletException,
IOException
- Overrides:
doGet in class HttpServlet
- Throws:
ServletException
IOException
doPost
protected void doPost(HttpServletRequest req,
HttpServletResponse res)
throws ServletException,
IOException
- Overrides:
doPost in class HttpServlet
- Throws:
ServletException
IOException
This software is published under the BSD license. Copyright © 2003-2012, CRIXP AG, Switzerland, All rights reserved. Use is subject to license terms.