Examples of MInstance


Examples of com.webobjects.monitor._private.MInstance

    public WOComponent schedulingDisableAllClicked() {
        handler().startReading();
        try {
            NSArray instancesArray = selectedInstances();
            for (int i = 0; i < instancesArray.count(); i++) {
                MInstance anInst = (MInstance) instancesArray.objectAtIndex(i);
                anInst.setSchedulingEnabled(Boolean.FALSE);
            }
            handler().sendUpdateInstancesToWotaskds(instancesArray, allHosts());
        } finally {
            handler().endReading();
        }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

    }

    public void selectRunning() {
        NSMutableArray selected = new NSMutableArray<MInstance>();
        for (Enumeration enumerator = displayGroup.allObjects().objectEnumerator(); enumerator.hasMoreElements();) {
            MInstance instance = (MInstance) enumerator.nextElement();
            if (instance.isRunning_M()) {
                selected.addObject(instance);
            }
        }
        displayGroup.setSelectedObjects(selected);
    }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

    }

    public void selectNotRunning() {
        NSMutableArray selected = new NSMutableArray<MInstance>();
        for (Enumeration enumerator = displayGroup.allObjects().objectEnumerator(); enumerator.hasMoreElements();) {
            MInstance instance = (MInstance) enumerator.nextElement();
            if (!instance.isRunning_M()) {
                selected.addObject(instance);
            }
        }
        displayGroup.setSelectedObjects(selected);
    }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

        return aPage;
    }

    public WOComponent deleteInstanceClicked() {

        final MInstance instance = currentInstance;

        return ConfirmationPage.create(context(), new ConfirmationPage.Delegate() {

            public WOComponent cancel() {
                return AppDetailPage.create(context(), instance.application());
            }

            public WOComponent confirm() {
                handler().startWriting();
                try {
                    siteConfig().removeInstance_M(instance);

                    if (siteConfig().hostArray().count() != 0) {
                        handler().sendRemoveInstancesToWotaskds(new NSArray(instance), siteConfig().hostArray());
                    }
                } finally {
                    handler().endWriting();
                }
                return AppDetailPage.create(context(), instance.application());
            }

            public String explaination() {
                return "Selecting 'Yes' will shutdown the selected instance of this application and delete its instance configuration.";
            }

            public int pageType() {
                return APP_PAGE;
            }

            public String question() {
                return "Are you sure you want to delete this instance (" + instance.displayName() + " running on " + instance.hostName() + ")";
            }

        });
    }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

                    if (application.hostArray().count() != 0) {
                        handler().sendStopInstancesToWotaskds(instances, application.hostArray());
                    }

                    for (int i = 0; i < instances.count(); i++) {
                        MInstance anInst = (MInstance) instances.objectAtIndex(i);
                        if (anInst.state != MObject.DEAD) {
                            anInst.state = MObject.STOPPING;
                        }
                    }
                } finally {
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

    public WOComponent autoRecoverEnableAllClicked() {
        handler().startReading();
        try {
            NSArray instancesArray = selectedInstances();
            for (int i = 0; i < instancesArray.count(); i++) {
                MInstance anInst = (MInstance) instancesArray.objectAtIndex(i);
                anInst.setAutoRecover(Boolean.TRUE);
            }
            handler().sendUpdateInstancesToWotaskds(instancesArray, allHosts());
        } finally {
            handler().endReading();
        }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

    public WOComponent autoRecoverDisableAllClicked() {
        handler().startReading();
        try {
            NSArray instancesArray = selectedInstances();
            for (int i = 0; i < instancesArray.count(); i++) {
                MInstance anInst = (MInstance) instancesArray.objectAtIndex(i);
                anInst.setAutoRecover(Boolean.FALSE);
            }
            handler().sendUpdateInstancesToWotaskds(instancesArray, allHosts());
        } finally {
            handler().endReading();
        }
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

    public WOComponent schedulingEnableAllClicked() {
        handler().startReading();
        try {
            NSArray instancesArray = selectedInstances();
            for (int i = 0; i < instancesArray.count(); i++) {
                MInstance anInst = (MInstance) instancesArray.objectAtIndex(i);
                anInst.setSchedulingEnabled(Boolean.TRUE);
            }
            if (allHosts().count() != 0) {
                handler().sendUpdateInstancesToWotaskds(instancesArray, allHosts());
            }
        } finally {
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

      handler().endWriting();
    }
  }

  private void deleteInstance(MApplication application, Integer instanceId) {
    final MInstance instance = application.instanceWithID(instanceId);
    handler().startWriting();
    try {
      siteConfig().removeInstance_M(instance);
      if (siteConfig().hostArray().count() != 0) {
        handler().sendRemoveInstancesToWotaskds(new NSArray(instance), siteConfig().hostArray());
View Full Code Here

Examples of com.webobjects.monitor._private.MInstance

        }
        if (_InstanceArray != null) {
            int instanceCount = _InstanceArray.count();
            NSMutableArray instanceArray = new NSMutableArray(instanceCount);
            for (int i = 0; i < instanceCount; i++) {
                MInstance anInst = (MInstance) _InstanceArray.objectAtIndex(i);
                instanceArray.addObject(anInst.values());
            }
            requestTypeDict.takeValueForKey(instanceArray, "instanceArray");
        }

        updateWotaskd.takeValueForKey(requestTypeDict, requestType);
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.