站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 4.0.1 sp1 deployment API Documentation 英文版文档

DeploymentManagerImpl (JBoss JSR-88 Deployment API) - JBoss 4.0.1 sp1 deployment API Documentation 英文版文档


org.jboss.deployment.spi
Class DeploymentManagerImpl

java.lang.Object
  extended byorg.jboss.deployment.spi.DeploymentManagerImpl
All Implemented Interfaces:
javax.enterprise.deploy.spi.DeploymentManager

public class DeploymentManagerImpl
extends Object
implements javax.enterprise.deploy.spi.DeploymentManager

The DeploymentManager object provides the core set of functions a J2EE platform must provide for J2EE application deployment. It provides server related information, such as, a list of deployment targets, and vendor unique runtime configuration information.

Version:
$Revision: 1.1.1.1 $
Author:
thomas.diesler@jboss.org

Constructor Summary
DeploymentManagerImpl(URI deployURI, boolean isConnected)
          Create a deployment manager for the given URL and connected mode.
DeploymentManagerImpl(URI deployURI, boolean isConnected, String username, String password)
          Create a deployment manager for the given URL and connected mode, username and password.
 
Method Summary
 javax.enterprise.deploy.spi.DeploymentConfiguration createConfiguration(javax.enterprise.deploy.model.DeployableObject obj)
          Retrieve server specific configuration for a component
 javax.enterprise.deploy.spi.status.ProgressObject distribute(javax.enterprise.deploy.spi.Target[] targets, File moduleArchive, File deploymentPlan)
          Validates the configuration, generates all container specific classes and moves the archive to the targets
 javax.enterprise.deploy.spi.status.ProgressObject distribute(javax.enterprise.deploy.spi.Target[] targets, InputStream moduleArchive, InputStream deploymentPlan)
          Validates the configuration, generates all container specific classes and moves the archive to the targets
 javax.enterprise.deploy.spi.TargetModuleID[] getAvailableModules(javax.enterprise.deploy.shared.ModuleType moduleType, javax.enterprise.deploy.spi.Target[] targets)
          Retrieve the list of all J2EE application modules running or not running on the identified targets.
 Locale getCurrentLocale()
          Currently we only support the default locale
 javax.enterprise.deploy.shared.DConfigBeanVersionType getDConfigBeanVersion()
          Get the J2EE platform version
 Locale getDefaultLocale()
          Get the default locale
 javax.enterprise.deploy.spi.TargetModuleID[] getNonRunningModules(javax.enterprise.deploy.shared.ModuleType moduleType, javax.enterprise.deploy.spi.Target[] targets)
          Get the non running modules
 javax.enterprise.deploy.spi.TargetModuleID[] getRunningModules(javax.enterprise.deploy.shared.ModuleType moduleType, javax.enterprise.deploy.spi.Target[] targets)
          Get the running modules
 Locale[] getSupportedLocales()
          Currently we only support the default locale
 javax.enterprise.deploy.spi.Target[] getTargets()
          Get the available targets.
 boolean isDConfigBeanVersionSupported(javax.enterprise.deploy.shared.DConfigBeanVersionType dConfigBeanVersionType)
           
 boolean isDConfigBeanVersionTypeSupported(javax.enterprise.deploy.shared.DConfigBeanVersionType version)
          Test whether the version is supported
 boolean isLocaleSupported(Locale locale)
          Currently we only support the default locale
 boolean isRedeploySupported()
          Is redeploy supported
 javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] moduleIDList)
          Redeploys the modules
 javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs, File file, File file1)
           
 javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs, InputStream inputStream, InputStream inputStream1)
           
 void release()
          The release method is the mechanism by which the tool signals to the DeploymentManager that the tool does not need it to continue running connected to the platform.
 void setDConfigBeanVersion(javax.enterprise.deploy.shared.DConfigBeanVersionType dConfigBeanVersionType)
           
 void setDConfigBeanVersionType(javax.enterprise.deploy.shared.DConfigBeanVersionType version)
          Set the J2EE version
 void setLocale(Locale locale)
          Currently we only support the default locale
 javax.enterprise.deploy.spi.status.ProgressObject start(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
          Start the modules
 javax.enterprise.deploy.spi.status.ProgressObject stop(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
          Stop the modules
 javax.enterprise.deploy.spi.status.ProgressObject undeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
          Removes the modules
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeploymentManagerImpl

public DeploymentManagerImpl(URI deployURI,
                             boolean isConnected)
Create a deployment manager for the given URL and connected mode.

Parameters:
deployURI -
isConnected -

DeploymentManagerImpl

public DeploymentManagerImpl(URI deployURI,
                             boolean isConnected,
                             String username,
                             String password)
Create a deployment manager for the given URL and connected mode, username and password.

Parameters:
deployURI -
isConnected -
username -
password -
Method Detail

getTargets

public javax.enterprise.deploy.spi.Target[] getTargets()
Get the available targets. This is determined by parsing the deployURI. Currently there is only one target, either a JMXTarget that uses the RMIAdaptor based on the URI info, or a LocalhostTarget if the URI opaque.

Specified by:
getTargets in interface javax.enterprise.deploy.spi.DeploymentManager
Returns:
the available targets
Throws:
IllegalStateException - when the manager is disconnected

getRunningModules

public javax.enterprise.deploy.spi.TargetModuleID[] getRunningModules(javax.enterprise.deploy.shared.ModuleType moduleType,
                                                                      javax.enterprise.deploy.spi.Target[] targets)
                                                               throws javax.enterprise.deploy.spi.exceptions.TargetException
Get the running modules

Specified by:
getRunningModules in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
javax.enterprise.deploy.spi.exceptions.TargetException - an invalid target
IllegalStateException - when the manager is disconnected

getNonRunningModules

public javax.enterprise.deploy.spi.TargetModuleID[] getNonRunningModules(javax.enterprise.deploy.shared.ModuleType moduleType,
                                                                         javax.enterprise.deploy.spi.Target[] targets)
                                                                  throws javax.enterprise.deploy.spi.exceptions.TargetException
Get the non running modules

Specified by:
getNonRunningModules in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
javax.enterprise.deploy.spi.exceptions.TargetException - an invalid target
IllegalStateException - when the manager is disconnected

getAvailableModules

public javax.enterprise.deploy.spi.TargetModuleID[] getAvailableModules(javax.enterprise.deploy.shared.ModuleType moduleType,
                                                                        javax.enterprise.deploy.spi.Target[] targets)
                                                                 throws javax.enterprise.deploy.spi.exceptions.TargetException
Retrieve the list of all J2EE application modules running or not running on the identified targets.

Specified by:
getAvailableModules in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
javax.enterprise.deploy.spi.exceptions.TargetException - an invalid target
IllegalStateException - when the manager is disconnected

createConfiguration

public javax.enterprise.deploy.spi.DeploymentConfiguration createConfiguration(javax.enterprise.deploy.model.DeployableObject obj)
                                                                        throws javax.enterprise.deploy.spi.exceptions.InvalidModuleException
Retrieve server specific configuration for a component

Specified by:
createConfiguration in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
obj - the deployable component
Returns:
the configuration
Throws:
javax.enterprise.deploy.spi.exceptions.InvalidModuleException - when the module does not exist or is not supported

distribute

public javax.enterprise.deploy.spi.status.ProgressObject distribute(javax.enterprise.deploy.spi.Target[] targets,
                                                                    File moduleArchive,
                                                                    File deploymentPlan)
Validates the configuration, generates all container specific classes and moves the archive to the targets

Specified by:
distribute in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
targets - the targets
moduleArchive - the module archive
deploymentPlan - the runtime configuration
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected

distribute

public javax.enterprise.deploy.spi.status.ProgressObject distribute(javax.enterprise.deploy.spi.Target[] targets,
                                                                    InputStream moduleArchive,
                                                                    InputStream deploymentPlan)
Validates the configuration, generates all container specific classes and moves the archive to the targets

Specified by:
distribute in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
targets - the targets
moduleArchive - the module archive
deploymentPlan - the runtime configuration
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected

redeploy

public javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs,
                                                                  File file,
                                                                  File file1)
                                                           throws UnsupportedOperationException,
                                                                  IllegalStateException
Specified by:
redeploy in interface javax.enterprise.deploy.spi.DeploymentManager
Throws:
UnsupportedOperationException
IllegalStateException

redeploy

public javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs,
                                                                  InputStream inputStream,
                                                                  InputStream inputStream1)
                                                           throws UnsupportedOperationException,
                                                                  IllegalStateException
Specified by:
redeploy in interface javax.enterprise.deploy.spi.DeploymentManager
Throws:
UnsupportedOperationException
IllegalStateException

start

public javax.enterprise.deploy.spi.status.ProgressObject start(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
Start the modules

Specified by:
start in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
targetModuleIDs - the list of modules
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected

stop

public javax.enterprise.deploy.spi.status.ProgressObject stop(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
Stop the modules

Specified by:
stop in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
targetModuleIDs - the list of modules
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected

undeploy

public javax.enterprise.deploy.spi.status.ProgressObject undeploy(javax.enterprise.deploy.spi.TargetModuleID[] targetModuleIDs)
Removes the modules

Specified by:
undeploy in interface javax.enterprise.deploy.spi.DeploymentManager
Parameters:
targetModuleIDs - the list of modules
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected

isRedeploySupported

public boolean isRedeploySupported()
Is redeploy supported

Specified by:
isRedeploySupported in interface javax.enterprise.deploy.spi.DeploymentManager
Returns:
true when redeploy is supported, false otherwise

redeploy

public javax.enterprise.deploy.spi.status.ProgressObject redeploy(javax.enterprise.deploy.spi.TargetModuleID[] moduleIDList)
Redeploys the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
IllegalStateException - when the manager is disconnected
UnsupportedOperationException - when redeploy is not supported

release

public void release()
The release method is the mechanism by which the tool signals to the DeploymentManager that the tool does not need it to continue running connected to the platform. The tool may be signaling it wants to run in a disconnected mode or it is planning to shutdown. When release is called the DeploymentManager may close any J2EE resource connections it had for deployment configuration and perform other related resource cleanup. It should not accept any new operation requests (i.e., distribute, start stop, undeploy, redeploy. It should finish any operations that are currently in process. Each ProgressObject associated with a running operation should be marked as released (see the ProgressObject).

Specified by:
release in interface javax.enterprise.deploy.spi.DeploymentManager

getDefaultLocale

public Locale getDefaultLocale()
Get the default locale

Specified by:
getDefaultLocale in interface javax.enterprise.deploy.spi.DeploymentManager
Returns:
the default locale

getCurrentLocale

public Locale getCurrentLocale()
Currently we only support the default locale

Specified by:
getCurrentLocale in interface javax.enterprise.deploy.spi.DeploymentManager

setLocale

public void setLocale(Locale locale)
Currently we only support the default locale

Specified by:
setLocale in interface javax.enterprise.deploy.spi.DeploymentManager

isLocaleSupported

public boolean isLocaleSupported(Locale locale)
Currently we only support the default locale

Specified by:
isLocaleSupported in interface javax.enterprise.deploy.spi.DeploymentManager

getSupportedLocales

public Locale[] getSupportedLocales()
Currently we only support the default locale

Specified by:
getSupportedLocales in interface javax.enterprise.deploy.spi.DeploymentManager
Returns:
the supported locales

getDConfigBeanVersion

public javax.enterprise.deploy.shared.DConfigBeanVersionType getDConfigBeanVersion()
Get the J2EE platform version

Specified by:
getDConfigBeanVersion in interface javax.enterprise.deploy.spi.DeploymentManager
Returns:
the version

setDConfigBeanVersion

public void setDConfigBeanVersion(javax.enterprise.deploy.shared.DConfigBeanVersionType dConfigBeanVersionType)
                           throws javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException
Specified by:
setDConfigBeanVersion in interface javax.enterprise.deploy.spi.DeploymentManager
Throws:
javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException

isDConfigBeanVersionSupported

public boolean isDConfigBeanVersionSupported(javax.enterprise.deploy.shared.DConfigBeanVersionType dConfigBeanVersionType)
Specified by:
isDConfigBeanVersionSupported in interface javax.enterprise.deploy.spi.DeploymentManager

isDConfigBeanVersionTypeSupported

public boolean isDConfigBeanVersionTypeSupported(javax.enterprise.deploy.shared.DConfigBeanVersionType version)
Test whether the version is supported

Parameters:
version - the version
Returns:
true when supported, false otherwise

setDConfigBeanVersionType

public void setDConfigBeanVersionType(javax.enterprise.deploy.shared.DConfigBeanVersionType version)
Set the J2EE version

Parameters:
version - the version
Throws:
UnsupportedOperationException - when the version is not supported


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.