org.kuali.rice.ksb.messaging.web
Class MessageQueueAction
java.lang.Object
org.apache.struts.action.Action
org.apache.struts.actions.DispatchAction
org.kuali.rice.ksb.messaging.web.KSBAction
org.kuali.rice.ksb.messaging.web.MessageQueueAction
public class MessageQueueAction
- extends KSBAction
Struts action for interacting with the queue of messages.
- Author:
- Kuali Rice Team (rice.collab@kuali.org)
Field Summary |
private static org.apache.log4j.Logger |
LOG
|
Fields inherited from class org.apache.struts.actions.DispatchAction |
clazz, log, messages, methods, types |
Fields inherited from class org.apache.struts.action.Action |
defaultLocale, servlet |
Method Summary |
org.apache.struts.action.ActionForward |
clear(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionForward |
delete(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionForward |
edit(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionMessages |
establishRequiredState(javax.servlet.http.HttpServletRequest request,
org.apache.struts.action.ActionForm form)
Sets up the expected state by retrieving the selected RouteQueue by RouteQueueId, and placing it in the
ExistingRouteQueue member. |
org.apache.struts.action.ActionForward |
executeMessageFetcher(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected List<PersistedMessage> |
findRouteQueues(javax.servlet.http.HttpServletRequest request,
MessageQueueForm routeQueueForm,
int maxRows)
|
private ForwardedCallHandler |
getAdminServiceToForwardTo(PersistedMessage message,
MessageQueueForm form)
|
private MessageQueueService |
getRouteQueueService()
|
org.apache.struts.action.ActionForward |
quickRequeueMessage(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected void |
quickRequeueMessage(PersistedMessage message)
Performs a quick ReQueue of the indicated persisted message. |
org.apache.struts.action.ActionForward |
reset(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionForward |
save(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
private PersistedMessage |
save(MessageQueueForm routeQueueForm)
|
org.apache.struts.action.ActionForward |
saveAndForward(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionForward |
saveAndResubmit(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
org.apache.struts.action.ActionForward |
start(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected AsynchronousCall |
unwrapPayload(PersistedMessage message)
Extracts the payload from a PersistedMessage, attempts to convert it to the expected AsynchronousCall type, and
returns it. |
org.apache.struts.action.ActionForward |
view(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
Methods inherited from class org.apache.struts.actions.DispatchAction |
cancelled, dispatchMethod, getMethod, getMethodName, getParameter, unspecified |
Methods inherited from class org.apache.struts.action.Action |
addErrors, addMessages, execute, generateToken, getDataSource, getDataSource, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, saveErrors, saveErrors, saveMessages, saveMessages, saveToken, setLocale, setServlet |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LOG
private static final org.apache.log4j.Logger LOG
MessageQueueAction
public MessageQueueAction()
start
public org.apache.struts.action.ActionForward start(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException,
javax.servlet.ServletException
- Specified by:
start
in class KSBAction
- Throws:
IOException
javax.servlet.ServletException
save
public org.apache.struts.action.ActionForward save(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
saveAndResubmit
public org.apache.struts.action.ActionForward saveAndResubmit(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
saveAndForward
public org.apache.struts.action.ActionForward saveAndForward(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
save
private PersistedMessage save(MessageQueueForm routeQueueForm)
getAdminServiceToForwardTo
private ForwardedCallHandler getAdminServiceToForwardTo(PersistedMessage message,
MessageQueueForm form)
quickRequeueMessage
protected void quickRequeueMessage(PersistedMessage message)
- Performs a quick ReQueue of the indicated persisted message.
The net effect of this requeue is to set the Date to now, and to reset the RetryCount to zero. The payload is not
modified.
- Parameters:
message
- The populated message to be requeued.
quickRequeueMessage
public org.apache.struts.action.ActionForward quickRequeueMessage(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
edit
public org.apache.struts.action.ActionForward edit(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException,
javax.servlet.ServletException
- Throws:
IOException
javax.servlet.ServletException
view
public org.apache.struts.action.ActionForward view(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
reset
public org.apache.struts.action.ActionForward reset(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
clear
public org.apache.struts.action.ActionForward clear(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
delete
public org.apache.struts.action.ActionForward delete(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
executeMessageFetcher
public org.apache.struts.action.ActionForward executeMessageFetcher(org.apache.struts.action.ActionMapping mapping,
org.apache.struts.action.ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws Exception
- Throws:
Exception
establishRequiredState
public org.apache.struts.action.ActionMessages establishRequiredState(javax.servlet.http.HttpServletRequest request,
org.apache.struts.action.ActionForm form)
throws Exception
- Sets up the expected state by retrieving the selected RouteQueue by RouteQueueId, and placing it in the
ExistingRouteQueue member.
Called by the super's Execute method on every request.
- Specified by:
establishRequiredState
in class KSBAction
- Throws:
Exception
findRouteQueues
protected List<PersistedMessage> findRouteQueues(javax.servlet.http.HttpServletRequest request,
MessageQueueForm routeQueueForm,
int maxRows)
getRouteQueueService
private MessageQueueService getRouteQueueService()
unwrapPayload
protected AsynchronousCall unwrapPayload(PersistedMessage message)
- Extracts the payload from a PersistedMessage, attempts to convert it to the expected AsynchronousCall type, and
returns it.
Throws an IllegalArgumentException if the decoded payload isnt of the expected type.
- Parameters:
message
- The populated PersistedMessage object to extract the payload from.
- Returns:
- Returns the payload if one is present and it can be deserialized, otherwise returns null.
Copyright © 2007-2011 The Kuali Foundation. All Rights Reserved.