- java.lang.Object
-
- javax.management.NotificationBroadcasterSupport
-
- javax.management.monitor.Monitor
-
- javax.management.monitor.GaugeMonitor
-
- すべての実装されたインタフェース:
MBeanRegistration
,GaugeMonitorMBean
,MonitorMBean
,NotificationBroadcaster
,NotificationEmitter
public class GaugeMonitor extends Monitor implements GaugeMonitorMBean
ゲージ属性の値を監視するように設計されたモニターMBeanを定義します。ゲージ・モニターは、時間の経過とともに変化する属性を監視します。 ゲージ・モニターは、次のようにして通知を送信します。
- 属性値が大きくなり、上限値以上になると、
threshold high notification
が送信されます。 通知の上限フラグはtrue
に設定する必要があります。
その後は、上限値を超過しても、属性値が下限値以下にならないかぎり、通知は送信されません。 - 属性値が小さくなり、下限値以下になると、
threshold low notification
が送信されます。 通知の下限フラグはtrue
に設定する必要があります。
その後は、下限値を超えても、属性値が上限値以上にならないかぎり、通知は送信されません。
ゲージ差分モードを使用している場合、派生ゲージの値は、連続した2回の観測によって得られた2つのゲージ値の差分として計算されます。
派生ゲージの値(V[t])は、次のようにして計算されます。- V[t] = gauge[t] - gauge[t-GP]
Byte
、Integer
、Short
、Long
、Float
、Double
)である必要があります。- 導入されたバージョン:
- 1.5
-
-
フィールドのサマリー
-
クラス javax.management.monitor.Monitorで宣言されたフィールド
alreadyNotified, alreadyNotifieds, capacityIncrement, dbgTag, elementCount, OBSERVED_ATTRIBUTE_ERROR_NOTIFIED, OBSERVED_ATTRIBUTE_TYPE_ERROR_NOTIFIED, OBSERVED_OBJECT_ERROR_NOTIFIED, RESET_FLAGS_ALREADY_NOTIFIED, RUNTIME_ERROR_NOTIFIED, server
-
-
コンストラクタのサマリー
コンストラクタ コンストラクタ 説明 GaugeMonitor()
デフォルトのコンストラクタです。
-
メソッドのサマリー
修飾子と型 メソッド 説明 Number
getDerivedGauge()
非推奨。JMX 1.2以降は、getDerivedGauge(ObjectName)
に置き換えられています。Number
getDerivedGauge(ObjectName object)
指定のオブジェクトが監視対象のMBeanのセットに含まれる場合、このオブジェクトの派生ゲージを取得します。そうでない場合はnull
を取得します。long
getDerivedGaugeTimeStamp()
非推奨。JMX 1.2以降は、getDerivedGaugeTimeStamp(ObjectName)
に置き換えられています。long
getDerivedGaugeTimeStamp(ObjectName object)
指定のオブジェクトが監視対象のMBeanのセットに含まれる場合、このオブジェクトの派生ゲージのタイムスタンプを取得します。そうでない場合は0
を取得します。boolean
getDifferenceMode()
監視対象のMBeanすべてに共通の差分モード・フラグ値を取得します。Number
getHighThreshold()
監視対象のMBeanすべてに共通の上限値を取得します。Number
getLowThreshold()
監視対象のMBeanすべてに共通の下限値を取得します。MBeanNotificationInfo[]
getNotificationInfo()
ゲージ・モニターによって送信される通知のJavaクラス名と通知タイプを含むNotificationInfo
オブジェクトを返します。boolean
getNotifyHigh()
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の上限値を取得します。boolean
getNotifyLow()
監視対象のMBean共通の通知のオン/オフ・スイッチ値の下限値を取得します。void
setDifferenceMode(boolean value)
監視対象のMBeanすべてに共通の差分モード・フラグ値を設定します。void
setNotifyHigh(boolean value)
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の上限値を設定します。void
setNotifyLow(boolean value)
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の下限値を設定します。void
setThresholds(Number highValue, Number lowValue)
監視対象のMBeanすべてに共通の上限および下限のしきい値を設定します。void
start()
ゲージ・モニターを開始します。void
stop()
ゲージ・モニターを停止します。-
クラス javax.management.monitor.Monitorで宣言されたメソッド
addObservedObject, containsObservedObject, getGranularityPeriod, getObservedAttribute, getObservedObject, getObservedObjects, isActive, postDeregister, postRegister, preDeregister, preRegister, removeObservedObject, setGranularityPeriod, setObservedAttribute, setObservedObject
-
クラス javax.management.NotificationBroadcasterSupportで宣言されたメソッド
addNotificationListener, handleNotification, sendNotification
-
クラス java.lang.Objectで宣言されたメソッド
clone、equals、finalize、getClass、hashCode、notify、notifyAll、toString、wait、wait、wait
-
インタフェース javax.management.monitor.MonitorMBeanで宣言されたメソッド
addObservedObject, containsObservedObject, getGranularityPeriod, getObservedAttribute, getObservedObject, getObservedObjects, isActive, removeObservedObject, setGranularityPeriod, setObservedAttribute, setObservedObject
-
インタフェース javax.management.NotificationBroadcasterで宣言されたメソッド
removeNotificationListener
-
インタフェース javax.management.NotificationEmitterで宣言されたメソッド
removeNotificationListener
-
-
-
-
メソッドの詳細
-
start
public void start()
ゲージ・モニターを開始します。- 定義:
start
、インタフェース:MonitorMBean
- 定義:
start
、クラス:Monitor
-
stop
public void stop()
ゲージ・モニターを停止します。- 定義:
stop
、インタフェース:MonitorMBean
- 定義:
stop
、クラス:Monitor
-
getDerivedGauge
public Number getDerivedGauge(ObjectName object)
指定のオブジェクトが監視対象のMBeanのセットに含まれる場合、このオブジェクトの派生ゲージを取得します。そうでない場合はnull
を取得します。- 定義:
getDerivedGauge
、インタフェース:GaugeMonitorMBean
- パラメータ:
object
- MBeanの名前。- 戻り値:
- 指定されたオブジェクトの派生ゲージ。
-
getDerivedGaugeTimeStamp
public long getDerivedGaugeTimeStamp(ObjectName object)
指定のオブジェクトが監視対象のMBeanのセットに含まれる場合、このオブジェクトの派生ゲージのタイムスタンプを取得します。そうでない場合は0
を取得します。- 定義:
getDerivedGaugeTimeStamp
、インタフェース:GaugeMonitorMBean
- パラメータ:
object
- オブジェクトの名前。このオブジェクトの派生ゲージのタイムスタンプが返される。- 戻り値:
- 指定されたオブジェクトの派生ゲージのタイムスタンプ。
-
getDerivedGauge
@Deprecated public Number getDerivedGauge()
非推奨。JMX 1.2以降は、getDerivedGauge(ObjectName)
に置き換えられています。監視対象のMBeanのセットに含まれる最初のオブジェクトの派生ゲージを返します。- 定義:
getDerivedGauge
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 派生ゲージ。
-
getDerivedGaugeTimeStamp
@Deprecated public long getDerivedGaugeTimeStamp()
非推奨。JMX 1.2以降は、getDerivedGaugeTimeStamp(ObjectName)
に置き換えられています。監視対象のMBeanのセットに含まれる最初のオブジェクトの派生ゲージのタイムスタンプを取得します。- 定義:
getDerivedGaugeTimeStamp
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 派生ゲージのタイムスタンプ。
-
getHighThreshold
public Number getHighThreshold()
監視対象のMBeanすべてに共通の上限値を取得します。- 定義:
getHighThreshold
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 上限値。
- 関連項目:
setThresholds(java.lang.Number, java.lang.Number)
-
getLowThreshold
public Number getLowThreshold()
監視対象のMBeanすべてに共通の下限値を取得します。- 定義:
getLowThreshold
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 下限値。
- 関連項目:
setThresholds(java.lang.Number, java.lang.Number)
-
setThresholds
public void setThresholds(Number highValue, Number lowValue) throws IllegalArgumentException
監視対象のMBeanすべてに共通の上限および下限のしきい値を設定します。- 定義:
setThresholds
、インタフェース:GaugeMonitorMBean
- パラメータ:
highValue
- 上限値。lowValue
- 下限値。- 例外:
IllegalArgumentException
- 上限および下限のしきい値としてnullが指定された場合、下限値が上限値より大きい場合、または上限値と下限値の型が異なる場合。- 関連項目:
getHighThreshold()
,getLowThreshold()
-
getNotifyHigh
public boolean getNotifyHigh()
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の上限値を取得します。- 定義:
getNotifyHigh
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 上限値を超過したときゲージ・モニターが通知を送る場合は
true
、そうでない場合はfalse
。 - 関連項目:
setNotifyHigh(boolean)
-
setNotifyHigh
public void setNotifyHigh(boolean value)
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の上限値を設定します。- 定義:
setNotifyHigh
、インタフェース:GaugeMonitorMBean
- パラメータ:
value
- 通知のオン/オフ・スイッチ値の上限値。- 関連項目:
getNotifyHigh()
-
getNotifyLow
public boolean getNotifyLow()
監視対象のMBean共通の通知のオン/オフ・スイッチ値の下限値を取得します。- 定義:
getNotifyLow
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 下限値を超過したときゲージ・モニターが通知を送る場合は
true
、そうでない場合はfalse
。 - 関連項目:
setNotifyLow(boolean)
-
setNotifyLow
public void setNotifyLow(boolean value)
監視対象のMBeanすべてに共通の通知のオン/オフ・スイッチ値の下限値を設定します。- 定義:
setNotifyLow
、インタフェース:GaugeMonitorMBean
- パラメータ:
value
- 通知のオン/オフ・スイッチ値の下限値。- 関連項目:
getNotifyLow()
-
getDifferenceMode
public boolean getDifferenceMode()
監視対象のMBeanすべてに共通の差分モード・フラグ値を取得します。- 定義:
getDifferenceMode
、インタフェース:GaugeMonitorMBean
- 戻り値:
- 差分モードを使用している場合は
true
、そうでない場合はfalse
。 - 関連項目:
setDifferenceMode(boolean)
-
setDifferenceMode
public void setDifferenceMode(boolean value)
監視対象のMBeanすべてに共通の差分モード・フラグ値を設定します。- 定義:
setDifferenceMode
、インタフェース:GaugeMonitorMBean
- パラメータ:
value
- 差分モード・フラグ値。- 関連項目:
getDifferenceMode()
-
getNotificationInfo
public MBeanNotificationInfo[] getNotificationInfo()
ゲージ・モニターによって送信される通知のJavaクラス名と通知タイプを含むNotificationInfo
オブジェクトを返します。- 定義:
getNotificationInfo
、インタフェース:NotificationBroadcaster
- 戻り値:
- 可能な通知の配列。
-
-