ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/server/uk/org/iscream/cms/server/client/monitors/CPU__Monitor.java
(Generate patch)

Comparing projects/cms/source/server/uk/org/iscream/cms/server/client/monitors/CPU__Monitor.java (file contents):
Revision 1.14 by ajm, Mon Mar 5 12:45:51 2001 UTC vs.
Revision 1.15 by ajm, Tue Mar 6 02:33:55 2001 UTC

# Line 140 | Line 140 | public class CPU__Monitor implements PluginMonitor {
140          String currentValue = packet.getParam(_attributes[attributeNum]);
141          String attributeName = _attributeNames[attributeNum];
142          String thresholdValue = Double.toString(reg.getThreshold(thresholdLevel));
143 <        String time = Long.toString(reg.getAlertTimeout(reg.getLastAlertLevel(attributeNum), attributeNum) / 1000);
143 >        String timeout = Long.toString(reg.getAlertTimeout(reg.getLastAlertLevel(attributeNum), attributeNum) / 1000);
144          if (thresholdLevel == Alert.thresholdNORMAL) {
145              thresholdValue = "-";
146          }
147          if (alertLevel == Alert.alertOK) {
148 <            time = "0";
148 >            timeout = "0";
149          }
150 <        Alert alert = new Alert(alertLevel, lastAlert, thresholdLevel, source, thresholdValue, currentValue, attributeName, time);
150 >        Alert alert = new Alert(alertLevel, lastAlert, thresholdLevel, source, thresholdValue, currentValue, attributeName, timeout, reg.getInitialAlertTime(attributeNum));
151          _alerterQueue.add(alert);
152 <        _logger.write(toString(), Logger.DEBUG, "Fired alert for source:" + source + " at alert level:" + Alert.alertLevels[alertLevel] + " on:" + attributeName + " for threshold level:" + Alert.thresholdLevels[thresholdLevel] + " at:" +  currentValue + " exceeding threshold of:" +thresholdValue + " next alert sent in:" + time + "secs");
152 >        _logger.write(toString(), Logger.DEBUG, "Fired alert for source:" + source + " at alert level:" + Alert.alertLevels[alertLevel] + " on:" + attributeName + " for threshold level:" + Alert.thresholdLevels[thresholdLevel] + " at:" +  currentValue + " exceeding threshold of:" +thresholdValue + " next alert sent in:" + timeout + "secs");
153      }
154  
155   //---ACCESSOR/MUTATOR METHODS---

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines