org.jboss.deployers.spi.management.deploy
Interface DeploymentManager


public interface DeploymentManager

An interface for uploading and controlling deployments in a profile.

Version:
$Revision:$
Author:
Scott.Stark@jboss.org, Emanuel Muckenhuber

Method Summary
 DeploymentProgress distribute(String name, URL contentURL, boolean copyContent)
          Add raw deployment content to the profile.
 DeploymentProgress distribute(String name, URL contentURL, DeploymentOption... options)
          Add raw deployment to the profile without starting the deployment.
 Collection<ProfileKey> getProfiles()
          Get a collection of profiles supporting deployment actions.
 String[] getRepositoryNames(String[] names)
          Map from the external name passed to distribute to the uploaded deployment repository name.
 boolean isRedeploySupported()
          Is redeploy supported.
 void loadProfile(ProfileKey key)
          Load and associate the given profile with the DeploymentManager for future operations.
 DeploymentProgress prepare(String... names)
          Prepare a set of deployments through their dependency analysis phase.
 DeploymentProgress redeploy(String name)
          Do redeploy.
 void releaseProfile()
          Release the previous loaded profile.
 DeploymentProgress remove(String... names)
          Remove a previously distributed deployment.
 DeploymentProgress start(String... names)
          Start a previously distributed deployment.
 DeploymentProgress stop(String... names)
          Stop a previously started deployment.
 

Method Detail

loadProfile

void loadProfile(ProfileKey key)
                 throws Exception
Load and associate the given profile with the DeploymentManager for future operations.

Parameters:
key - - the profile to load
Throws:
Exception - for any error

releaseProfile

void releaseProfile()
                    throws Exception
Release the previous loaded profile.

Throws:
Exception

getProfiles

Collection<ProfileKey> getProfiles()
Get a collection of profiles supporting deployment actions.

Returns:
a collection of profiles keys

getRepositoryNames

String[] getRepositoryNames(String[] names)
                            throws Exception
Map from the external name passed to distribute to the uploaded deployment repository name.

Parameters:
names - - the list of external deployment names
Returns:
the mapped list of unique names in the deployment repository.
Throws:
Exception - for any error

distribute

DeploymentProgress distribute(String name,
                              URL contentURL,
                              boolean copyContent)
                              throws Exception
Add raw deployment content to the profile.

Parameters:
name - the deployment name
contentURL - - URL for obtaining the deployment archive
copyContent - should we copy content or just reference it
Returns:
a DeploymentProgress used to run and track the distribute progress.
Throws:
Exception - for any error

distribute

DeploymentProgress distribute(String name,
                              URL contentURL,
                              DeploymentOption... options)
                              throws Exception
Add raw deployment to the profile without starting the deployment. The deployments options can be used to specify certain behavior.

Parameters:
name - the deployment name
contentURL - - URL for obtaining the deployment archive
options - - the deployment options
Returns:
a DeploymentProgress used to run and track the distribute progress.
Throws:
Exception - for any error

prepare

DeploymentProgress prepare(String... names)
                           throws Exception
Prepare a set of deployments through their dependency analysis phase.

Parameters:
names - the unique names of the deployments
Returns:
a DeploymentProgress used to run and track the prepare progress.
Throws:
Exception - for any error

start

DeploymentProgress start(String... names)
                         throws Exception
Start a previously distributed deployment.

Parameters:
names - the unique names of the deployments
Returns:
a DeploymentProgress used to run and track the start progress.
Throws:
Exception - for any error

isRedeploySupported

boolean isRedeploySupported()
Is redeploy supported.

Returns:
true if the loaded profile supports redeploy

redeploy

DeploymentProgress redeploy(String name)
                            throws Exception
Do redeploy.

Parameters:
name - the deployment to redeploy
Returns:
a DeploymentProgress used to run and track the redeploy progress.
Throws:
Exception - for any error

stop

DeploymentProgress stop(String... names)
                        throws Exception
Stop a previously started deployment.

Parameters:
names - the unique names of the deployments
Returns:
a DeploymentProgress used to run and track the stop progress.
Throws:
Exception - for any error

remove

DeploymentProgress remove(String... names)
                          throws Exception
Remove a previously distributed deployment.

Parameters:
names - the unique names of the deployments
Returns:
a DeploymentProgress used to run and track the remove progress.
Throws:
Exception - for any error


Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.