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

Examples of org.apache.stratos.manager.deploy.service.Service


        return null;
    }

    public static ServiceDefinitionBean getDeployedServiceInformation (String type) throws RestAPIException {

        Service service = null;

        try {
            service = serviceDeploymentManager.getService(type);

        } catch (ADCException e) {
View Full Code Here


        }

        // get the cluster domain and host name from deployed Service
        DataInsertionAndRetrievalManager dataInsertionAndRetrievalManager = new DataInsertionAndRetrievalManager();

        Service deployedService;
        try {
            deployedService = dataInsertionAndRetrievalManager.getService(cartridgeInfo.getType());

        } catch (PersistenceManagerException e) {
            String errorMsg = "Error in checking if Service is available is PersistenceManager";
            log.error(errorMsg, e);
            throw new ADCException(errorMsg, e);
        }

        if (deployedService == null) {
            String errorMsg = "There is no deployed Service for type " + cartridgeInfo.getType();
            log.error(errorMsg);
            throw new ADCException(errorMsg);
        }

        //set the cluster and hostname
        cluster.setClusterDomain(deployedService.getClusterId());
        cluster.setHostName(deployedService.getHostName());

        if (repository != null) {

            // publish the ArtifactUpdated event
            log.info(" Multitenant --> Publishing Artifact update event -- ");
View Full Code Here

      return cluster;
    }
   
    public Cluster getCluster (String cartridgeType) {

      Service service;
      Cluster cluster = null;
    try {
      service = dataInsertionNRetrievalMgr.getService(cartridgeType);
    } catch (PersistenceManagerException e) {
      log.error("Exception occurred when retrieving service [" + cartridgeType +"] ");
      return null;
    }
   
    if(service != null) {
      String clusterId = service.getClusterId();
        cluster = clusterIdToClusterMap.get(clusterId);
        if(log.isDebugEnabled()) {
          log.debug(" Found cluster ["+cluster+"] with id ["+clusterId+"] ");
        }
    }     
View Full Code Here

                return null;
            }

            if (serviceObj != null && serviceObj instanceof Service) {

                Service deserilizedService = (Service) serviceObj;
                if (log.isDebugEnabled()) {
                    log.debug("Successfully de-serialized Service: " + deserilizedService.toString());
                }

                services.add(deserilizedService);

            }
View Full Code Here

      // the load balancer should be already up and running from service
      // cluster deployment

      // get the cluster domain and host name from deployed Service

      Service deployedLBService;
      try {
        deployedLBService = new DataInsertionAndRetrievalManager()
            .getService(cartridgeInfo.getType());

      } catch (PersistenceManagerException e) {
        String errorMsg = "Error in checking if Service is available is PersistenceManager";
        log.error(errorMsg, e);
        throw new ADCException(errorMsg, e);
      }

      if (deployedLBService == null) {
        String errorMsg = "There is no deployed Service for type "
            + cartridgeInfo.getType();
        log.error(errorMsg);
        throw new ADCException(errorMsg);
      }

      if(log.isDebugEnabled()){
        log.debug(" Setting cluster Domain : " + deployedLBService.getClusterId());
        log.debug(" Setting Host Name : " + deployedLBService.getHostName());
      }
     
      // set the cluster and hostname
      cluster.setClusterDomain(deployedLBService.getClusterId());
      cluster.setHostName(deployedLBService.getHostName());

      return null;
    } else {
            // set cluster domain
      cluster.setClusterDomain(generateClusterId(alias, cartridgeInfo.getType()));
View Full Code Here

TOP

Related Classes of org.apache.stratos.manager.deploy.service.Service

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.