Examples of localHost()


Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

                                MHost anMHost = aConfig.hostWithName(name);
                                if (anMHost == null) {
                                    element = new NSDictionary(new Object[]{Boolean.FALSE, _hostName + ": Host " +name+ " not found; REMOVE failed"}, errorKeys);
                                    hostArrayResponse.addObject(element);
                                } else {
                                    if ( anMHost == aConfig.localHost()) {
                                        stopAllInstances();
                                        ( (Application) WOApplication.application()).setSiteConfig(new MSiteConfig(null));
                                    } else {
                                        aConfig.removeHost_W(anMHost);
                                    }
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

                    hostResponse = new NSMutableDictionary(new Object[]{runningInstances, processorType, operatingSystem}, hostQueryKeys);
                }
                theApplication._lock.startReading();
                try {
                    if (aConfig.localHost() != null) {
                        hostResponse.takeValueForKey(aConfig.localHost().runningInstancesCount_W(), "runningInstances");
                    } else {
                        hostResponse.takeValueForKey(_NSUtilities.IntegerForInt(0), "runningInstances");
                    }
                } finally {
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

                    hostResponse = new NSMutableDictionary(new Object[]{runningInstances, processorType, operatingSystem}, hostQueryKeys);
                }
                theApplication._lock.startReading();
                try {
                    if (aConfig.localHost() != null) {
                        hostResponse.takeValueForKey(aConfig.localHost().runningInstancesCount_W(), "runningInstances");
                    } else {
                        hostResponse.takeValueForKey(_NSUtilities.IntegerForInt(0), "runningInstances");
                    }
                } finally {
                    theApplication._lock.endReading();
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

                queryWotaskdResponse.takeValueForKey(applicationResponse, "applicationResponse");
            } else if (queryWotaskdString.equals("INSTANCE")) {
                NSMutableArray instanceResponse = null;
                theApplication._lock.startReading();
                try {
                    NSArray instanceArray = (aConfig.localHost() != null) ? aConfig.localHost().instanceArray() : NSArray.EmptyArray;
                    int instanceArrayCount = instanceArray.count();

                    MInstance anInstance;
                    String applicationName;
                    Integer id;
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

                queryWotaskdResponse.takeValueForKey(applicationResponse, "applicationResponse");
            } else if (queryWotaskdString.equals("INSTANCE")) {
                NSMutableArray instanceResponse = null;
                theApplication._lock.startReading();
                try {
                    NSArray instanceArray = (aConfig.localHost() != null) ? aConfig.localHost().instanceArray() : NSArray.EmptyArray;
                    int instanceArrayCount = instanceArray.count();

                    MInstance anInstance;
                    String applicationName;
                    Integer id;
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

            }
        }
        // remove all hosts remaining in currentHosts
        for (Enumeration e = currentHosts.objectEnumerator(); e.hasMoreElements(); ) {
            MHost anMHost = (MHost) e.nextElement();
            if ( anMHost == aConfig.localHost()) {
                stopAllInstances();
                ( (Application) WOApplication.application()).setSiteConfig(new MSiteConfig(null));
                break;
            }
            aConfig.removeHost_W(anMHost);
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

    @Override
    public String startInstance(MInstance anInstance) {
        MSiteConfig aConfig = theApplication.siteConfig();
        if (anInstance == null)
            return "Attempt to start null instance on " + _hostName;
        if (anInstance.host() != aConfig.localHost())
            return anInstance.displayName() + " does not exist on " + _hostName + "; START instance failed";
        if (anInstance.isRunning_W())
            //            return _hostName + ": " + anInstance.displayName() + " is already running";
            return null;
        if (anInstance.state == MObject.STARTING)
View Full Code Here

Examples of com.webobjects.monitor._private.MSiteConfig.localHost()

    protected void catchInstanceErrors(MInstance anInstance) throws MonitorException {
        MSiteConfig aConfig = theApplication.siteConfig();
        if (anInstance == null)
            throw new MonitorException("Attempt to command null instance on " + _hostName);
        if (anInstance.host() != aConfig.localHost())
            throw new MonitorException(anInstance.displayName() + " does not exist on " + _hostName + "; command failed");
        if (!anInstance.isRunning_W())
            throw new MonitorException(_hostName + ": " + anInstance.displayName() + " is not running");
    }
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.