Package org.jboss.deployers.spi.management.deploy

Examples of org.jboss.deployers.spi.management.deploy.DeploymentProgress.run()


        if (repositoryName != null) {
          DeploymentProgress stop   = null;
          try {
            stop = deployMgr.stop(repositoryName);
              if (stop != null)
                stop.run();
          } catch (Throwable t) {
            log.error("Could not find deployment to delete.  " + t.getMessage());  
            return;
          } finally {
              jbossASComponent.disconnectFromProfileService();
View Full Code Here


              throw new Exception("Failed to stop deployment '" + repositoryName + "' - cause: "
                  + stopStatus.getFailure());
          }       
            DeploymentProgress remove = deployMgr.remove(repositoryName);       
            if (remove != null) {
                remove.run();
              DeploymentStatus status = remove.getDeploymentStatus();
              if (status.isFailed()) {
                log.error("Failed to remove deployment '" + repositoryName + "'.", status.getFailure());
                throw new Exception("Failed to remove deployment '" + repositoryName + ".    "
                    + "If the deployment has already been removed through other means and you want to "
View Full Code Here

     */
    public static void deployFileToAS(String name, File archiveFile, boolean exploded) throws Exception {
        DeploymentManager deploymentManager = getDeploymentManager();

        DeploymentProgress progress = deploymentManager.distribute(name, archiveFile.toURI().toURL(), exploded);
        progress.run();

        DeploymentStatus status = progress.getDeploymentStatus();

        if (status.isFailed()) {
            throw new IllegalStateException("Failed to distribute " + archiveFile.getAbsolutePath() + " with message: "
View Full Code Here

        }

        String[] deploymentNames = progress.getDeploymentID().getRepositoryNames();

        progress = deploymentManager.start(deploymentNames);
        progress.run();

        status = progress.getDeploymentStatus();

        if (status.isFailed()) {
            throw new IllegalStateException("Failed to start " + archiveFile.getAbsolutePath() + " with message: "
View Full Code Here

    public static void undeployFromAS(String archiveName) throws Exception {
        DeploymentManager deploymentManager = getDeploymentManager();

       
        DeploymentProgress progress = deploymentManager.stop(archiveName);
        progress.run();

        DeploymentStatus status = progress.getDeploymentStatus();

        if (status.isFailed()) {
            throw new IllegalStateException("Failed to stop " + archiveName + " with message: "
View Full Code Here

            throw new IllegalStateException("Failed to stop " + archiveName + " with message: "
                + status.getMessage());
        }

        progress = deploymentManager.remove(archiveName);
        progress.run();

        status = progress.getDeploymentStatus();

        if (status.isFailed()) {
            throw new IllegalStateException("Failed to undeploy " + archiveName + " with message: "
View Full Code Here

      boolean exploded) throws Exception {
    DeploymentManager deploymentManager = getDeploymentManager();

    DeploymentProgress progress = deploymentManager.distribute(name,
        archiveFile.toURI().toURL(), exploded);
    progress.run();

    DeploymentStatus status = progress.getDeploymentStatus();

    if (status.isFailed()) {
      throw new IllegalStateException("Failed to distribute "
View Full Code Here

    String[] deploymentNames = progress.getDeploymentID()
        .getRepositoryNames();

    progress = deploymentManager.start(deploymentNames);
    progress.run();

    status = progress.getDeploymentStatus();

    if (status.isFailed()) {
      throw new IllegalStateException("Failed to start "
View Full Code Here

   */
  public static void undeployFromAS(String archiveName) throws Exception {
    DeploymentManager deploymentManager = getDeploymentManager();

    DeploymentProgress progress = deploymentManager.remove(archiveName);
    progress.run();

    DeploymentStatus status = progress.getDeploymentStatus();

    if (status.isFailed()) {
      throw new IllegalStateException("Failed to undeploy " + archiveName
View Full Code Here

      DeploymentManager deployMgr = getDeploymentManager();

      // Distribute
      DeploymentProgress distribute = deployMgr.distribute(deploymentName,
            getDeployURL(deploymentName), copyContent);
      distribute.run();
      // Distribute always has to complete
      assertComplete(distribute);
      // check if the app is stopped
      if(checkStopped)
         assertDeploymentState(distribute.getDeploymentID(), DeploymentState.STOPPED);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.