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

Examples of org.jboss.deployers.spi.management.deploy.DeploymentManager.stop()


     */
    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()) {
View Full Code Here


                OperationResult result = new OperationResult();
                result.setErrorMessage(deploymentFile.getName() + " is already started.");
                return result;
            }
        } else if (name.equals("stop")) {
            progress = deploymentManager.stop(deploymentName);
        } else if (name.equals("restart")) {
            progress = deploymentManager.stop(deploymentName);
            DeploymentUtils.run(progress);
            // Still try to start, even if stop fails (maybe the app wasn't running to begin with).
            progress = deploymentManager.start(deploymentName);
View Full Code Here

                return result;
            }
        } else if (name.equals("stop")) {
            progress = deploymentManager.stop(deploymentName);
        } else if (name.equals("restart")) {
            progress = deploymentManager.stop(deploymentName);
            DeploymentUtils.run(progress);
            // Still try to start, even if stop fails (maybe the app wasn't running to begin with).
            progress = deploymentManager.start(deploymentName);
        } else {
            throw new UnsupportedOperationException(name);
View Full Code Here

      // The deployment manager
      DeploymentManager deployMgr = getDeploymentManager();

      try
      {
         DeploymentProgress stop = deployMgr.stop(names);
         stop.run();
         assertComplete(stop);
         assertDeploymentState(stop.getDeploymentID(), DeploymentState.STOPPED);
      }
      catch(Exception e)
View Full Code Here

         finally
         {
            //Thread.sleep(15 * 1000); // 15 secs >> more than it takes for reaper to run :-)

            // Stop/remove the deployment
            progress = deployMgr.stop(uploadedNames);
            progress.addProgressListener(this);
            progress.run();
            status = progress.getDeploymentStatus();
            assertTrue("DeploymentStatus.isCompleted: " + status, status.isCompleted());
            assertFalse("DeploymentStatus.isFailed: " + status, status.isFailed());
View Full Code Here

         finally
         {
            //Thread.sleep(15 * 1000); // 15 secs >> more than it takes for reaper to run :-)

            // Stop/remove the deployment
            progress = deployMgr.stop(uploadedNames);
            progress.addProgressListener(this);
            progress.run();
            status = progress.getDeploymentStatus();
            assertTrue("DeploymentStatus.isCompleted: " + status, status.isCompleted());
            assertFalse("DeploymentStatus.isFailed: " + status, status.isFailed());
View Full Code Here

   {
      String names[] = new String[] {deployment};
      DeploymentManager deployMgr = getDeploymentManager();
      try
      {
         DeploymentProgress progress = deployMgr.stop(names);
         progress.run();
         assertFalse("failed: " + progress.getDeploymentStatus().getFailure(), progress.getDeploymentStatus().isFailed());
      }
      finally
      {
View Full Code Here

    */
   private void undeployResource(String resourceName) throws Exception
   {
      // stop the resource deployment.
      DeploymentManager manager = super.getDeploymentManager();
      DeploymentProgress progress = manager.stop(resourceName);
      progress.addProgressListener(this.listener);
      progress.run();

      // undeploy the resource.
      progress = manager.remove(resourceName);
View Full Code Here

   {
      String names[] = new String[] {deployment};
      DeploymentManager deployMgr_ = getDeploymentManager();
      try
      {
         DeploymentProgress progress = deployMgr_.stop(names);
         progress.run();
         assertFalse("failed: " + progress.getDeploymentStatus().getFailure(), progress.getDeploymentStatus().isFailed());
      }
      finally
      {
View Full Code Here

       finally
       {
          //Thread.sleep(15 * 1000); // 15 secs >> more than it takes for reaper to run :-)

          // Stop/remove the deployment
          progress = deployMgr.stop(uploadedNames);
          progress.addProgressListener(this);
          progress.run();
          status = progress.getDeploymentStatus();
          assertTrue("DeploymentStatus.isCompleted: " + status, status.isCompleted());
          assertFalse("DeploymentStatus.isFailed: " + status, status.isFailed());
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.