Package com.sun.enterprise.admin.servermgmt

Examples of com.sun.enterprise.admin.servermgmt.InstancesManager


    try
    {
      ClientPluggableFeatureFactory  cpff  = getFeatureFactory();
      DomainsManager          dm    = cpff.getDomainsManager();
      DomainConfig          dc    = getDomainConfig(domainName);
      InstancesManager        im    = dm.getInstancesManager(dc);
      final int            state  = im.getInstanceStatus();

      return state == Status.kInstanceNotRunningCode;
    }
    catch(Exception e)
    {
View Full Code Here


    {
        try {           
            final ClientPluggableFeatureFactory fac     = getFeatureFactory();
            final DomainsManager                mgr     = fac.getDomainsManager();
            final DomainConfig                  cfg     = getDomainConfig(domainName);
            final InstancesManager              im      = mgr.getInstancesManager(cfg);
            final int                           state   = im.getInstanceStatus();
            final String[]      domains = mgr.listDomains(cfg);
            boolean        exists  = false;
     
            for(int i = 0; domains != null && i < domains.length; i++)
           {
View Full Code Here

    private boolean isNotRunning(DomainsManager mgr, DomainConfig cfg) throws Exception
    {
        // note that checking for kInstanceRunningCode is not desired here

        InstancesManager im = mgr.getInstancesManager(cfg);
        int state = im.getInstanceStatus();

        return state == Status.kInstanceNotRunningCode;
    }
View Full Code Here

        return state == Status.kInstanceNotRunningCode;
    }

    private boolean isStopping(DomainsManager mgr, DomainConfig cfg) throws Exception
    {
        InstancesManager im = mgr.getInstancesManager(cfg);
        int state = im.getInstanceStatus();

        return state == Status.kInstanceStoppingCode;
    }
View Full Code Here

    public void stopDomainForcibly(DomainConfig domainConfig, int timeout)
        throws DomainException
    {
        try {
            checkRepository(domainConfig);
            InstancesManager domainMgr = getInstancesManager(domainConfig);

            boolean stopped = false;
           
            if(timeout > 0)
                stopped = domainMgr.stopInstanceWithinTime(timeout);
           
            if (!stopped) domainMgr.killRelatedProcesses();
        } catch (Exception e) {
            throw new DomainException(e);
        }       
    }
View Full Code Here

    }

    private boolean isDomainNotRunning(DomainConfig domainConfig)
        throws InstanceException
    {
        InstancesManager instMgr = getInstancesManager(domainConfig);
       
        return (Status.kInstanceNotRunningCode ==
                instMgr.getInstanceStatus());
    }
View Full Code Here

    }

   
    boolean isNotRunning(AgentManager mgr, AgentConfig cfg) throws Exception
    {
        InstancesManager im = mgr.getInstancesManager(cfg);
        int state = im.getInstanceStatus();
        return state == Status.kInstanceNotRunningCode;
    }
View Full Code Here

        String domainName = null;
        try {
            domainName = getDomainName();
            DomainConfig config = getDomainConfig(domainName);
            DomainsManager mgr = getFeatureFactory().getDomainsManager();
            InstancesManager im = mgr.getInstancesManager(config);
            int state = im.getInstanceStatus();
            boolean printMessage = (state == Status.kInstanceNotRunningCode);
            super.runCommand();
  
            if (printMessage) {
                String xmlPath = new PEFileLayout(config).getDomainConfigFile().getAbsolutePath();
View Full Code Here

TOP

Related Classes of com.sun.enterprise.admin.servermgmt.InstancesManager

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.