[jboss-dev-forums] [Design of POJO Server] - Re: Deploying Ears and Wars through ProfileService

scott.stark@jboss.org do-not-reply at jboss.com
Thu Mar 6 20:11:08 EST 2008


The jsr88 api has decent status object for its deployment api:

javax.enterprise.deploy.spi.status.ProgressObject:

  | public interface ProgressObject
  | {
  |    // Constants -----------------------------------------------------
  |    
  |    // Public --------------------------------------------------------
  |    
  |    /**
  |     * Retrieve the status of the deployment
  |     *
  |     * @return the status
  |     */
  |    DeploymentStatus getDeploymentStatus();
  |    
  |    /**
  |     * Retrieve the resulting target module ids
  |     *
  |     * @return the module ids
  |     */
  |    TargetModuleID[] getResultTargetModuleIDs();
  |    
  |    /**
  |     * Return the client configuration associated with the module
  |     *
  |     * @param id the module id
  |     * @return the client configuration or null if none exists
  |     */
  |    ClientConfiguration getClientConfiguration(TargetModuleID id);
  |    
  |    /**
  |     * Is cancel supported
  |     *
  |     * @return true when cancel is supported, false otherwise
  |     */
  |    boolean isCancelSupported();
  |    
  |    /**
  |     * Cancels the deployment
  |     *
  |     * @throws OperationUnsupportedException when cancel is not supported
  |     */
  |    void cancel() throws OperationUnsupportedException;
  |    
  |    /**
  |     * Is stop supported
  |     *
  |     * @return true when stop is supported, false otherwise
  |     */
  |    boolean isStopSupported();
  |    
  |    /**
  |     * Stops the deployment
  |     *
  |     * @throws OperationUnsupportedException when stop is not supported
  |     */
  |    void stop() throws OperationUnsupportedException;
  |    
  |    /**
  |     * Add a progress listener
  |     *
  |     * @param listener the listener
  |     */
  |    void addProgressListener(ProgressListener listener);
  |    
  |    /**
  |     * Remove a progress listener
  |     *
  |     * @param listener the listener
  |     */
  |    void removeProgressListener(ProgressListener listener);
  | }
  | 

We would drop the getClientConfiguration. TargetModuleID,DeploymentStatus,Target are:


  | public interface TargetModuleID
  | {
  |    // Constants -----------------------------------------------------
  |    
  |    // Public --------------------------------------------------------
  |    
  |    /**
  |     * Get the target
  |     *
  |     * @return the target
  |     */
  |    Target getTarget();
  |    
  |    /**
  |     * Get the module id
  |     *
  |     * @return the id
  |     */
  |    String getModuleID();
  |    
  |    /**
  |     * The URL for a web module
  |     *
  |     * @return the url
  |     */
  |    String getWebURL();
  | 
  |    /**
  |     * Return the identifier of this module 
  |     *
  |     * @return the identifier
  |     */
  |    String toString();
  |    
  |    /**
  |     * The parent of this module
  |     *
  |     * @return the parent or null if there is no parent
  |     */
  |    TargetModuleID getParentTargetModuleID();
  |    
  |    /**
  |     * Get the child modules
  |     *
  |     * @return an array of child modules or null if there are no children
  |     */
  |    TargetModuleID[] getChildTargetModuleID();
  | }
  | public interface DeploymentStatus
  | {
  |    // Constants -----------------------------------------------------
  |    
  |    // Public --------------------------------------------------------
  |    
  |    /**
  |     * Get the state of the deployment
  |     *
  |     * @return the state
  |     */
  |    StateType getState();
  |    
  |    /**
  |     * The deployment command
  |     *
  |     * @return the command
  |     */
  |    CommandType getCommand();
  |    
  |    /**
  |     * The action of this deployment
  |     *
  |     * @return the action
  |     */
  |    ActionType getAction();
  |    
  |    /**
  |     * Get the message
  |     *
  |     * @return the message
  |     */
  |    String getMessage();
  |    
  |    /**
  |     * Is the deployment complete
  |     *
  |     * @return true when complete, false otherwise
  |     */
  |    boolean isCompleted();
  |    
  |    /**
  |     * Has the deployment failed
  |     *
  |     * @return true when failed, false otherwise
  |     */
  |    boolean isFailed();
  |    
  |    /**
  |     * Is the deployment in progress
  |     *
  |     * @return true when in progress, false otherwise
  |     */
  |    boolean isRunning();
  | }
  |  */
  | public interface Target
  | {
  |    // Constants -----------------------------------------------------
  |    
  |    // Public --------------------------------------------------------
  |    
  |    /**
  |     * Get the target's name
  |     *
  |     * @return the name
  |     */
  |    String getName();
  |    
  |    /**
  |     * Get the target's description
  |     *
  |     * @return the description
  |     */
  |    String getDescription();
  | 
  | }
  | 


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4134724#4134724

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4134724



More information about the jboss-dev-forums mailing list