Package javax.enterprise.deploy.spi

Examples of javax.enterprise.deploy.spi.DeploymentManager.start()


           if (found.length == 0) {
               throw new MojoExecutionException("Module is not deployed: " + moduleId);
           }

           log.info("Starting module: " + moduleId);
           ProgressObject progress = manager.start(found);

           DeploymentStatus status = waitFor(progress);
           if (status.isFailed()) {
               throw new MojoExecutionException("Failed to start module: " + moduleId);
           }
View Full Code Here


                po = mgr.distribute(targets, null, file);
            }
            waitForProgress(po);
            if (po.getDeploymentStatus().isCompleted()) {
                modules = po.getResultTargetModuleIDs();
                po = mgr.start(modules);
                waitForProgress(po);
                if (po.getDeploymentStatus().isCompleted()) {
                    completed = true;
                } else {
                    log.warn("Unable to start some modules for " + file.getAbsolutePath());
View Full Code Here

                   
                    ProgressObject po = mgr.distribute(targets, rarFile, tempFile);
                    waitForProgress(po);
                    if (po.getDeploymentStatus().isCompleted()) {
                        TargetModuleID[] ids = po.getResultTargetModuleIDs();
                        po = mgr.start(ids);
                        waitForProgress(po);
                        if (po.getDeploymentStatus().isCompleted()) {
                            ids = po.getResultTargetModuleIDs();
                            if (status != null) {
                                status.getCurrentPool().setName(data.getName());
View Full Code Here

        if (toStart.size() == 0) {
            System.out.println("Module is already running or may not be deployed: " + getId());
            return;
        }
        moduleIds = (TargetModuleID[]) toStart.toArray(new TargetModuleID[toStart.size()]);
        ProgressObject progress = manager.start(moduleIds);
        DeploymentClient.waitFor(progress);
    }

}
View Full Code Here

        while (po.getDeploymentStatus().isRunning()) {
            Thread.sleep(100);
        }
        System.out.println(po.getDeploymentStatus().getMessage());
        if (po.getDeploymentStatus().isCompleted()) {
            manager.start(po.getResultTargetModuleIDs());
        }

//        po = manager.stop(po.getResultTargetModuleIDs());
//        while (po.getDeploymentStatus().isRunning()) {
//            Thread.sleep(100);
View Full Code Here

               
                ProgressObject po = mgr.distribute(targets, null, tempFile);
                waitForProgress(po);
                if (po.getDeploymentStatus().isCompleted()) {
                    TargetModuleID[] ids = po.getResultTargetModuleIDs();
                    po = mgr.start(ids);
                    waitForProgress(po);
                    if (po.getDeploymentStatus().isCompleted()) {
                        log.info("Deployment completed successfully!");
                    }
                    else {
View Full Code Here

                po = mgr.distribute(targets, null, file);
            }
            waitForProgress(po);
            if (po.getDeploymentStatus().isCompleted()) {
                modules = po.getResultTargetModuleIDs();
                po = mgr.start(modules);
                waitForProgress(po);
                if (po.getDeploymentStatus().isCompleted()) {
                    completed = true;
                } else {
                    log.warn("Unable to start some modules for " + file.getAbsolutePath());
View Full Code Here

            if (found.length == 0) {
                throw new MojoExecutionException("Module is not deployed: " + moduleId);
            }

            log.info("Starting module: " + moduleId);
            ProgressObject progress = manager.start(found);
           
            DeploymentStatus status = waitFor(progress);
            if (status.isFailed()) {
                throw new MojoExecutionException("Failed to start module: " + moduleId);
            }
View Full Code Here

                String abbrStatusMessage;
                String fullStatusMessage = null;
                if (progress.getDeploymentStatus().isCompleted()) {
                    abbrStatusMessage = "The application was successfully deployed.<br/>";
                    // start installed app/s
                    progress = mgr.start(progress.getResultTargetModuleIDs());
                    while (progress.getDeploymentStatus().isRunning()) {
                        Thread.sleep(100);
                    }
                    abbrStatusMessage += "The application was successfully started";
                } else {
View Full Code Here

  }
 
  private void startSharedLib() throws Exception {
    DeploymentManager dm = DeploymentCommandFactory.getDeploymentManager(server);
    TargetModuleID id = getSharedLibTargetModuleID();
    ProgressObject po = dm.start(new TargetModuleID[]{id});
    waitForProgress(po);
    if(po.getDeploymentStatus().isFailed()) {
      throw new Exception(po.getDeploymentStatus().getMessage());
    }
  }
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.