Examples of AxiomXpathParser


Examples of org.apache.stratos.cloud.controller.axiom.AxiomXpathParser

        super(name);
    }
   
    protected void setUp() throws Exception {
        super.setUp();
        util1 = new AxiomXpathParser(new File(dir+"cartridges-1.xml"));
        util2 = new AxiomXpathParser(new File(dir+"cartridges-2.xml"));
        util3 = new AxiomXpathParser(new File(dir+"cartridges-3.xml"));
        util4 = new AxiomXpathParser(new File(dir+"cartridges-4.xml"));
        util5 = new AxiomXpathParser(new File(dir+"cartridges-5.xml"));
        util6 = new AxiomXpathParser(new File(dir+"cartridges-6.xml"));
        util7 = new AxiomXpathParser(new File(dir+"cartridges-7.xml"));
        util8 = new AxiomXpathParser(new File(dir+"cartridges-8.xml"));
        util9 = new AxiomXpathParser(new File(dir+"cartridges-9.xml"));
        util1.parse();
        util2.parse();
        util3.parse();
        util4.parse();
        util5.parse();
View Full Code Here

Examples of org.apache.stratos.cloud.controller.axiom.AxiomXpathParser

        super(name);
    }

    protected void setUp() throws Exception {
        super.setUp();
        parser = new AxiomXpathParser(xmlFile);
        parser.parse();
    }
View Full Code Here

Examples of org.apache.stratos.cloud.controller.axiom.AxiomXpathParser

        log.debug("Started to deploy the deployment artifact: "+deploymentFileData.getFile());
       
        // since cloud-controller.xml resides in repository/conf
    if (deploymentFileData.getName().contains(FILE_NAME)) {

      AxiomXpathParser parser = new AxiomXpathParser(deploymentFileData.getFile());

      // parse the file
      parser.parse();

      // load iaases
      parser.setIaasProvidersList();
      parser.setDataPublisherRelatedData();
      parser.setTopologySyncRelatedData();

      // update map
      fileToIaasProviderListMap.put(deploymentFileData.getAbsolutePath(),
                                    new ArrayList<IaasProvider>(
                                                                FasterLookUpDataHolder.getInstance()
View Full Code Here

Examples of org.apache.stratos.cloud.controller.axiom.AxiomXpathParser

    public void deploy(DeploymentFileData deploymentFileData) throws DeploymentException {
       
        log.debug("Started to deploy the deployment artefact: "+deploymentFileData.getFile());
        serviceContextLookUpStructure = FasterLookUpDataHolder.getInstance();
       
        AxiomXpathParser parser = new AxiomXpathParser(deploymentFileData.getFile());
        parser.parse();
       
        // validate
        try {
            validateService(parser);
           
        } catch (Exception e) {
            String msg = "Invalid deployment artefact at "+deploymentFileData.getAbsolutePath();
            // back up the file
            File f = deploymentFileData.getFile();
            f.renameTo(new File(deploymentFileData.getAbsolutePath()+".back"));
            log.error(msg, e);
            throw new DeploymentException(msg, e);
        }
       
        // deploy
        List<ServiceContext> services = parser.getServiceContexts();
       
        // notify consumer by adding the diff
        try {
          serviceContextLookUpStructure.getSharedTopologyDiffQueue().put(services);
        } catch (InterruptedException ignore) {
View Full Code Here

Examples of org.apache.stratos.cloud.controller.axiom.AxiomXpathParser

   
    public void deploy(DeploymentFileData deploymentFileData) throws DeploymentException {
       
        log.debug("Started to deploy the deployment artifact: "+deploymentFileData.getFile());
       
        AxiomXpathParser parser = new AxiomXpathParser(deploymentFileData.getFile());
        parser.parse();

        try {
          // validate
            validateCartridge(parser);
           
      // deploy - grab cartridges
      List<Cartridge> cartridges = parser.getCartridgesList();

      ThreadExecutor exec = new ThreadExecutor(3);
      // create Jclouds objects, for each IaaS
      for (Cartridge cartridge : cartridges) {
        // jclouds object building is time consuming, hence I use Java executor framework
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.