Package org.apache.stratos.manager.deploy.service.multitenant.lb

Examples of org.apache.stratos.manager.deploy.service.multitenant.lb.MultiTenantLBService


        // set the relevant deployment policy
        log.info(" ******* Setting Deployment Policy name : ------>  " + lbDataCtxt.getDeploymentPolicy());
        loadBalancerCategory.setDeploymentPolicyName(lbDataCtxt.getDeploymentPolicy());

        Service lbService = new MultiTenantLBService(lbDataCtxt.getLbCartridgeInfo().getType(), lbDataCtxt.getAutoscalePolicy(),
                lbDataCtxt.getDeploymentPolicy(), -1234, lbDataCtxt.getLbCartridgeInfo(),
                tenantRange, loadBalancerCategory);

        Properties lbProperties = null;
        if (lbDataCtxt.getLbProperperties() != null && !lbDataCtxt.getLbProperperties().isEmpty())  {
            lbProperties = new Properties();
            lbProperties.setProperties(lbDataCtxt.getLbProperperties().toArray(new Property[0]));
        }

        // create service
        lbService.create();

        // add LB category to the payload
        lbService.getPayloadData().add(CartridgeConstants.LB_CATEGORY, lbDataCtxt.getLbCategory());

        // delpoy
        lbService.deploy(lbProperties);

        // persist
        persist(lbService);
    }
View Full Code Here

TOP

Related Classes of org.apache.stratos.manager.deploy.service.multitenant.lb.MultiTenantLBService

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.