Examples of AlarmSpecImpl


Examples of com.vmware.vim.binding.impl.vim.alarm.AlarmSpecImpl

      tSpec.setStartState(Status.green);
      tSpec.setFinalState(Status.yellow);
      alarmAction.setTransitionSpecs(new TransitionSpec[] { tSpec });
      alarmAction.setGreen2yellow(true);

      AlarmSpec spec = new AlarmSpecImpl();
      spec.setActionFrequency(0);
      spec.setExpression(or);

      /* the name has to be unique, but we need a way to find any matching
      alarms later so we use a known prefix */
      String alarmName = "BDE Health " + SERENGETI_UUID;
      if (alarmName.length() > 80) {
         alarmName = alarmName.substring(0, 80);
      }
      spec.setName(alarmName);
      spec.setSystemName(null);
      spec.setDescription("Indicates a health issue with a compute VM managed by Big Data Extensions. The specific health issue is detailed in a warning event in the event log.");
      spec.setEnabled(true);

      AlarmSetting as = new AlarmSettingImpl();
      as.setReportingFrequency(0);
      as.setToleranceRange(0);

      spec.setSetting(as);

      ManagedObjectReference[] existingAlarms = alarmManager.getAlarm(rootFolder._getRef());
      Alarm existing = null;
      try {
         if (existingAlarms != null) {
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.