![JAR search and dependency download from the Maven repository](/logo.png)
org.jboss.deployers.spi.management.deploy.DeploymentManager Maven / Gradle / Ivy
/*
* JBoss, Home of Professional Open Source
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* This is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation; either version 2.1 of
* the License, or (at your option) any later version.
*
* This software is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this software; if not, write to the Free
* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
*/
package org.jboss.deployers.spi.management.deploy;
import java.net.URL;
import java.util.Collection;
import org.jboss.profileservice.spi.ProfileKey;
/**
* An interface for uploading and controlling deployments in a profile.
*
* @author [email protected]
* @author Emanuel Muckenhuber
* @version $Revision:$
*/
public interface DeploymentManager
{
/**
* Load and associate the given profile with the DeploymentManager
* for future operations.
*
* @param key - the profile to load
* @throws Exception for any error
*/
public void loadProfile(ProfileKey key) throws Exception;
/**
* Release the previous loaded profile.
*
* @throws Exception
*/
public void releaseProfile() throws Exception;
/**
* Get a collection of profiles supporting deployment actions.
*
* @return a collection of profiles keys
*/
Collection getProfiles();
/**
* Map from the external name passed to distribute to the uploaded
* deployment repository name.
*
* @param names - the list of external deployment names
* @return the mapped list of unique names in the deployment repository.
* @throws Exception for any error
*/
String[] getRepositoryNames(String[] names) throws Exception;
/**
* Add raw deployment content to the profile.
*
* @param name the deployment name
* @param contentURL - URL for obtaining the deployment archive
* @param copyContent should we copy content or just reference it
* @return a DeploymentProgress used to run and track the distribute progress.
* @throws Exception for any error
*/
DeploymentProgress distribute(String name, URL contentURL, boolean copyContent) throws Exception;
/**
* Prepare a set of deployments through their dependency analysis phase.
*
* @param names the unique names of the deployments
* @return a DeploymentProgress used to run and track the prepare progress.
* @throws Exception for any error
*/
DeploymentProgress prepare(String... names) throws Exception;
/**
* Start a previously distributed deployment.
*
* @param names the unique names of the deployments
* @return a DeploymentProgress used to run and track the start progress.
* @throws Exception for any error
*/
DeploymentProgress start(String... names) throws Exception;
/**
* Is redeploy supported.
*
* @return true if the loaded profile supports redeploy
*/
boolean isRedeploySupported();
/**
* Do redeploy.
*
* @param name the deployment to redeploy
* @return a DeploymentProgress used to run and track the redeploy progress.
* @throws Exception for any error
*/
DeploymentProgress redeploy(String name) throws Exception;
/**
* Stop a previously started deployment.
*
* @param names the unique names of the deployments
* @return a DeploymentProgress used to run and track the stop progress.
* @throws Exception for any error
*/
DeploymentProgress stop(String... names) throws Exception;
/**
* Remove a previously distributed deployment.
*
* @param names the unique names of the deployments
* @return a DeploymentProgress used to run and track the remove progress.
* @throws Exception for any error
*/
DeploymentProgress remove(String... names) throws Exception;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy