org.figure8.join.control.action
Class DeploymentActions

java.lang.Object
  extended by org.apache.struts.action.Action
      extended by org.figure8.join.control.JoinAction
          extended by org.figure8.join.control.action.DeploymentActions

public class DeploymentActions
extends JoinAction

This is a Struts action controller for managind Deployment related operations.

Version:
$Revision: 1.2 $
Author:
Laurent Broudoux

Field Summary
protected  AssemblyManager assemblyManager
          The AssemblyManager implementation to use
static java.lang.String CANCEL_OP
          Operation code for cancelling a specified Deployment
static java.lang.String CREATE_OP
          Operation code for creating a new Deployment
static java.lang.String DEPLOYMENT_KEY
          The request scope attribute under which the Deployment object currently selected by our logged-in User is stored.
static java.lang.String DEPLOYMENTS_KEY
          The request scope attribute under which the retrivied deployments list is stored.
static java.lang.String END_OP
          Operation code for ending a specified Deployment
protected  EnvironmentManager environmentManager
          The EnvironmentManager implementation to use
static java.lang.String FORM_OP
          Operation code for showing a deployment creation form
static java.lang.String LOAD_OP
          Operation code for loading a specific Deployment
static java.lang.String NOT_ALLOWED_OPERATION_KEY
          The request scope attribute under which is stored the code of operation that has raised a NotAllowedOperationException during workflow.
static java.lang.String NOT_ALLOWED_OPERATION_MSG
          The request scope attribute under which is stored the message of raised NotAllowedOperationException during workflow.
static java.lang.String PREPARE_OP
          Operation code for preparing a specified Deployment
static java.lang.String PREPARING_OP
          Operation code for getting deployments being prepared at that time
protected  IntegrationProcessManager processManager
          The IntegrationProcessManager implementation to use
static java.lang.String REALIZE_OP
          Operation code for realizing a specified Deployment
static java.lang.String REALIZING_OP
          Operation code for getting deployments being realized at that time
static java.lang.String SCREEN_KEY
          The request scope for specifying on which screen we are (used by view)
static java.lang.String STATUS_OP
          Operation code for forcing status of a specified Deployment
static java.lang.String TITLE_KEY
          The request scope for specifying the title of the screen (used by view)
 
Fields inherited from class org.figure8.join.control.JoinAction
BODY_ATTRIBUTE, BODY_PARAMETER, EXCEPTION_KEY, GUI_KEY, OP_PARAMETER, REND_MAIN, REND_NONE, REND_PARAMETER, REND_POPUP, XHR_PARAMETER
 
Fields inherited from class org.apache.struts.action.Action
defaultLocale, servlet
 
Constructor Summary
DeploymentActions()
          Creates a new instance of DeploymentActions
 
Method Summary
protected  org.apache.struts.action.ActionForward cancelDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Cancel a specified deployment.
protected  org.apache.struts.action.ActionForward createDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Create a new deployment into environment manager.
 org.apache.struts.action.ActionForward doExecute(java.lang.String operation, org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Abstract method that subclasses must implement.
protected  org.apache.struts.action.ActionForward endDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          End a specified deployment.
protected  org.apache.struts.action.ActionForward forceStatus(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Force the status of a given deployment.
protected  org.apache.struts.action.ActionForward getPreparingDeployments(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Retrieve deployments being prepared at that time.
protected  org.apache.struts.action.ActionForward getRealizingDeployments(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Retrieve deployments being realized at that time.
protected  org.apache.struts.action.ActionForward loadDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Load a specified deployment into request attribute.
protected  org.apache.struts.action.ActionForward prepareDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Launch preparation of specified deployment
protected  org.apache.struts.action.ActionForward realizeDeployment(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Launch realization of specified deployment.
 void setAssemblyManager(AssemblyManager assemblyManager)
           
 void setEnvironmentManager(EnvironmentManager environmentManager)
           
 void setIntegrationProcessManager(IntegrationProcessManager processManager)
           
protected  org.apache.struts.action.ActionForward showDeploymentForm(org.apache.struts.action.ActionMapping mapping, DeploymentForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Prepare all we need for displaying a deployment creation form
 
Methods inherited from class org.figure8.join.control.JoinAction
execute, getUserContainer, isLoggedIn, isXhrRequest, removeObsoleteForm
 
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, saveMessages, saveMessages, saveToken, setLocale, setServlet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FORM_OP

public static final java.lang.String FORM_OP
Operation code for showing a deployment creation form

See Also:
Constant Field Values

LOAD_OP

public static final java.lang.String LOAD_OP
Operation code for loading a specific Deployment

See Also:
Constant Field Values

CREATE_OP

public static final java.lang.String CREATE_OP
Operation code for creating a new Deployment

See Also:
Constant Field Values

PREPARE_OP

public static final java.lang.String PREPARE_OP
Operation code for preparing a specified Deployment

See Also:
Constant Field Values

PREPARING_OP

public static final java.lang.String PREPARING_OP
Operation code for getting deployments being prepared at that time

See Also:
Constant Field Values

REALIZE_OP

public static final java.lang.String REALIZE_OP
Operation code for realizing a specified Deployment

See Also:
Constant Field Values

REALIZING_OP

public static final java.lang.String REALIZING_OP
Operation code for getting deployments being realized at that time

See Also:
Constant Field Values

CANCEL_OP

public static final java.lang.String CANCEL_OP
Operation code for cancelling a specified Deployment

See Also:
Constant Field Values

END_OP

public static final java.lang.String END_OP
Operation code for ending a specified Deployment

See Also:
Constant Field Values

STATUS_OP

public static final java.lang.String STATUS_OP
Operation code for forcing status of a specified Deployment

See Also:
Constant Field Values

TITLE_KEY

public static final java.lang.String TITLE_KEY
The request scope for specifying the title of the screen (used by view)

See Also:
Constant Field Values

SCREEN_KEY

public static final java.lang.String SCREEN_KEY
The request scope for specifying on which screen we are (used by view)

See Also:
Constant Field Values

DEPLOYMENT_KEY

public static final java.lang.String DEPLOYMENT_KEY
The request scope attribute under which the Deployment object currently selected by our logged-in User is stored.

See Also:
Constant Field Values

DEPLOYMENTS_KEY

public static final java.lang.String DEPLOYMENTS_KEY
The request scope attribute under which the retrivied deployments list is stored.

See Also:
Constant Field Values

NOT_ALLOWED_OPERATION_KEY

public static final java.lang.String NOT_ALLOWED_OPERATION_KEY
The request scope attribute under which is stored the code of operation that has raised a NotAllowedOperationException during workflow.

See Also:
Constant Field Values

NOT_ALLOWED_OPERATION_MSG

public static final java.lang.String NOT_ALLOWED_OPERATION_MSG
The request scope attribute under which is stored the message of raised NotAllowedOperationException during workflow.

See Also:
Constant Field Values

assemblyManager

protected AssemblyManager assemblyManager
The AssemblyManager implementation to use


environmentManager

protected EnvironmentManager environmentManager
The EnvironmentManager implementation to use


processManager

protected IntegrationProcessManager processManager
The IntegrationProcessManager implementation to use

Constructor Detail

DeploymentActions

public DeploymentActions()
Creates a new instance of DeploymentActions

Method Detail

setAssemblyManager

public void setAssemblyManager(AssemblyManager assemblyManager)
Parameters:
assemblyManager - The AssemblyManager implementation to use

setEnvironmentManager

public void setEnvironmentManager(EnvironmentManager environmentManager)
Parameters:
environmentManager - The EnvironmentManager implementation to use

setIntegrationProcessManager

public void setIntegrationProcessManager(IntegrationProcessManager processManager)
Parameters:
processManager - The IntegrationProcessManager implementation to use

doExecute

public org.apache.struts.action.ActionForward doExecute(java.lang.String operation,
                                                        org.apache.struts.action.ActionMapping mapping,
                                                        org.apache.struts.action.ActionForm form,
                                                        javax.servlet.http.HttpServletRequest request,
                                                        javax.servlet.http.HttpServletResponse response)
                                                 throws java.lang.Exception
Description copied from class: JoinAction
Abstract method that subclasses must implement. The real execution must be done here according to the specified operation. ActionForward returned by execution should only point on page fragment : this superclass is responsible of including them within a whole page.

Specified by:
doExecute in class JoinAction
Parameters:
operation - String representing the operation to invoke on Action
mapping - Mapping between forwards name and path for this action
form - The form object containing request parameters
request - The servlet container request wrapper
response - The servlet container response wrapper
Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception - such as InfraStructureExceptions ...

showDeploymentForm

protected org.apache.struts.action.ActionForward showDeploymentForm(org.apache.struts.action.ActionMapping mapping,
                                                                    DeploymentForm form,
                                                                    javax.servlet.http.HttpServletRequest request,
                                                                    javax.servlet.http.HttpServletResponse response)
                                                             throws java.lang.Exception
Prepare all we need for displaying a deployment creation form

Returns:
A forward to the next view ti render and display
Throws:
java.lang.Exception

loadDeployment

protected org.apache.struts.action.ActionForward loadDeployment(org.apache.struts.action.ActionMapping mapping,
                                                                DeploymentForm form,
                                                                javax.servlet.http.HttpServletRequest request,
                                                                javax.servlet.http.HttpServletResponse response)
                                                         throws java.lang.Exception
Load a specified deployment into request attribute.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

createDeployment

protected org.apache.struts.action.ActionForward createDeployment(org.apache.struts.action.ActionMapping mapping,
                                                                  DeploymentForm form,
                                                                  javax.servlet.http.HttpServletRequest request,
                                                                  javax.servlet.http.HttpServletResponse response)
                                                           throws java.lang.Exception
Create a new deployment into environment manager.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

prepareDeployment

protected org.apache.struts.action.ActionForward prepareDeployment(org.apache.struts.action.ActionMapping mapping,
                                                                   DeploymentForm form,
                                                                   javax.servlet.http.HttpServletRequest request,
                                                                   javax.servlet.http.HttpServletResponse response)
                                                            throws java.lang.Exception
Launch preparation of specified deployment

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

getPreparingDeployments

protected org.apache.struts.action.ActionForward getPreparingDeployments(org.apache.struts.action.ActionMapping mapping,
                                                                         DeploymentForm form,
                                                                         javax.servlet.http.HttpServletRequest request,
                                                                         javax.servlet.http.HttpServletResponse response)
                                                                  throws java.lang.Exception
Retrieve deployments being prepared at that time.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

realizeDeployment

protected org.apache.struts.action.ActionForward realizeDeployment(org.apache.struts.action.ActionMapping mapping,
                                                                   DeploymentForm form,
                                                                   javax.servlet.http.HttpServletRequest request,
                                                                   javax.servlet.http.HttpServletResponse response)
                                                            throws java.lang.Exception
Launch realization of specified deployment.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

getRealizingDeployments

protected org.apache.struts.action.ActionForward getRealizingDeployments(org.apache.struts.action.ActionMapping mapping,
                                                                         DeploymentForm form,
                                                                         javax.servlet.http.HttpServletRequest request,
                                                                         javax.servlet.http.HttpServletResponse response)
                                                                  throws java.lang.Exception
Retrieve deployments being realized at that time.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

cancelDeployment

protected org.apache.struts.action.ActionForward cancelDeployment(org.apache.struts.action.ActionMapping mapping,
                                                                  DeploymentForm form,
                                                                  javax.servlet.http.HttpServletRequest request,
                                                                  javax.servlet.http.HttpServletResponse response)
                                                           throws java.lang.Exception
Cancel a specified deployment.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

endDeployment

protected org.apache.struts.action.ActionForward endDeployment(org.apache.struts.action.ActionMapping mapping,
                                                               DeploymentForm form,
                                                               javax.servlet.http.HttpServletRequest request,
                                                               javax.servlet.http.HttpServletResponse response)
                                                        throws java.lang.Exception
End a specified deployment.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

forceStatus

protected org.apache.struts.action.ActionForward forceStatus(org.apache.struts.action.ActionMapping mapping,
                                                             DeploymentForm form,
                                                             javax.servlet.http.HttpServletRequest request,
                                                             javax.servlet.http.HttpServletResponse response)
                                                      throws java.lang.Exception
Force the status of a given deployment. This is a 2 step operation : retrieve possible status first and display a form ; then set the choosen status for deployment.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception


Copyright © 2005-2008 Join. All Rights Reserved.