Package org.jboss.deployers.client.spi

Examples of org.jboss.deployers.client.spi.DeployerClient


      main.checkComplete();
   }
  
   public void testDeployParentOneChildFailInParentDeployer2() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      makeFail(deployment, deployer2);
      addChild(deployment, "child");
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild, deployer1.getUndeployedUnits());
      assertEquals(expectedParent, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(childName));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here


      main.checkComplete();
   }
  
   public void testDeployParentOneChildFailInChildDeployer1() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      ContextInfo child = addChild(deployment, childPath);
      makeFail(child, deployer1);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild, deployer1.getDeployedUnits());
      assertEquals(expectedParent, deployer1.getUndeployedUnits());
      assertEquals(expectedNothing, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(childName));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }
  
   public void testDeployParentOneChildFailInChildDeployer2() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      ContextInfo child = addChild(deployment, childPath);
      makeFail(child, deployer2);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild, deployer1.getUndeployedUnits());
      assertEquals(expectedParentChild, deployer2.getDeployedUnits());
      assertEquals(expectedParent, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(childName));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenNoErrors() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      addChild(deployment, child1Path);
      addChild(deployment, child2Path);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1Child2, deployer1.getDeployedUnits());
      assertEquals(expectedNothing, deployer1.getUndeployedUnits());
      assertEquals(expectedParentChild1Child2, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.DEPLOYED, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.DEPLOYED, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.DEPLOYED, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInParentDeployer1() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      makeFail(deployment, deployer1);
      addChild(deployment, child1Path);
      addChild(deployment, child2Path);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParent, deployer1.getDeployedUnits());
      assertEquals(expectedNothing, deployer1.getUndeployedUnits());
      assertEquals(expectedNothing, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInParentDeployer2() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      makeFail(deployment, deployer2);
      addChild(deployment, child1Path);
      addChild(deployment, child2Path);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1Child2, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild1Child2, deployer1.getUndeployedUnits());
      assertEquals(expectedParent, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInChild1Deployer1() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      ContextInfo child1 = addChild(deployment, child1Path);
      makeFail(child1, deployer1);
      addChild(deployment, child2Path);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1, deployer1.getDeployedUnits());
      assertEquals(expectedParent, deployer1.getUndeployedUnits());
      assertEquals(expectedNothing, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInChild1Deployer2() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      ContextInfo child1 = addChild(deployment, child1Path);
      makeFail(child1, deployer2);
      addChild(deployment, child2Path);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1Child2, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild1Child2, deployer1.getUndeployedUnits());
      assertEquals(expectedParentChild1, deployer2.getDeployedUnits());
      assertEquals(expectedParent, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInChild2Deployer1() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      addChild(deployment, child1Path);
      ContextInfo child2 = addChild(deployment, child2Path);
      makeFail(child2, deployer1);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1Child2, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild1, deployer1.getUndeployedUnits());
      assertEquals(expectedNothing, deployer2.getDeployedUnits());
      assertEquals(expectedNothing, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

      main.checkComplete();
   }

   public void testDeployParentMultipleChildrenFailInChild2Deployer2() throws Exception
   {
      DeployerClient main = getMainDeployer();
     
      Deployment deployment = createSimpleDeployment(parentName);
      addChild(deployment, child1Path);
      ContextInfo child2 = addChild(deployment, child2Path);
      makeFail(child2, deployer2);
      main.addDeployment(deployment);
      main.process();

      assertEquals(expectedParentChild1Child2, deployer1.getDeployedUnits());
      assertEquals(expectedParentChild1Child2, deployer1.getUndeployedUnits());
      assertEquals(expectedParentChild1Child2, deployer2.getDeployedUnits());
      assertEquals(expectedParentChild1, deployer2.getUndeployedUnits());
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(deployment.getName()));
      assertEquals(DeploymentState.UNDEPLOYED, main.getDeploymentState(child1Name));
      assertEquals(DeploymentState.ERROR, main.getDeploymentState(child2Name));
     
      main.removeDeployment(deployment);
      main.process();
      main.checkComplete();
   }
View Full Code Here

TOP

Related Classes of org.jboss.deployers.client.spi.DeployerClient

Copyright © 2018 www.massapicom. 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.