Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle Event Processing
11g Release 1 (11.1.1.7)

E14303-11
FRAMES    NO FRAMES
DETAIL:  FIELD | CONSTR | METHOD


com.bea.wlevs.monitor
Interface Monitor


public interface Monitor
extends Stage, EventSink

The Monitor service allows one to monitor the throughput and latency of Event Server application endpoints. An Event Server endpoint is either the entry or the exit point in an application stage. Clients can register at the Monitor service to receive events in the form of a MetricEvent that indicate the throughput and the latency metric of an endpoint as defined by the interval parameter. Even though the monitoring activities are processed separately from the application events, monitoring still adds some overhead to the system, hence it is disabled by default.

See Also:
Endpoint, Stage, MetricEvent

Field Summary
static java.lang.String CONTROL_STREAM_FILTER
           
static java.lang.String CONTROL_STREAM_ID
           
static java.lang.String SERVICE_FILTER
           
static java.lang.String SERVICE_ID
           
static java.lang.String STREAM_FILTER
           
static java.lang.String STREAM_ID
           
static java.util.concurrent.TimeUnit TIME_UNIT
           

 

Method Summary
 Endpoint createEndpoint(java.lang.String applicationId, java.lang.String stageId, Endpoint.Direction stagepoint)
          Returns endpoint that represents a 'place' in the Event Server that can be monitored.
 boolean isEnabled()
          Returns if the Monitor service is enabled.
 Statement monitorAvgLatency(Endpoint start, Endpoint end, long averageInterval, java.util.concurrent.TimeUnit unit)
          Starts monitoring the average latency of events between specified end points.
 java.lang.String monitorAvgLatency(Endpoint start, Endpoint end, long averageInterval, java.util.concurrent.TimeUnit unit, EventSink listener)
          Starts monitoring the average latency of events between specified end points.
 Statement monitorAvgLatencyThreshold(Endpoint start, Endpoint end, long averageInterval, long threshold, java.util.concurrent.TimeUnit unit)
          Starts monitoring the average latency of events between specified end points to see if it crosses the specified threshold.
 java.lang.String monitorAvgLatencyThreshold(Endpoint start, Endpoint end, long averageInterval, long threshold, java.util.concurrent.TimeUnit unit, EventSink listener)
          Starts monitoring the average latency of events between specified end points to see if it crosses the specified threshold.
 Statement monitorAvgThroughput(Endpoint endpoint, long throughputInterval, long averageInterval, java.util.concurrent.TimeUnit unit)
          Starts monitoring average throughput of events at the specified endpoint.
 java.lang.String monitorAvgThroughput(Endpoint endpoint, long throughputInterval, long averageInterval, java.util.concurrent.TimeUnit unit, EventSink listener)
          Starts monitoring average throughput of events at the specified endpoint.
 Statement monitorMaxLatency(Endpoint start, Endpoint end, long maxInterval, java.util.concurrent.TimeUnit unit)
          Starts monitoring the maximum latency of events between specified end points.
 java.lang.String monitorMaxLatency(Endpoint start, Endpoint end, long averageInterval, java.util.concurrent.TimeUnit unit, EventSink listener)
          Starts monitoring the maximum latency of events between specified end points.
 void setEnabled(boolean enabled)
          Enables the Monitor service.
 void terminateAllMonitoring(Endpoint endpoint)
          Terminates all monitoring activity for the specified Endpoint.

 

Methods inherited from interface com.bea.wlevs.ede.api.EventSink
onEvent

 

Field Detail

TIME_UNIT

public static final java.util.concurrent.TimeUnit TIME_UNIT

SERVICE_ID

public static final java.lang.String SERVICE_ID

SERVICE_FILTER

public static final java.lang.String SERVICE_FILTER

STREAM_ID

public static final java.lang.String STREAM_ID

STREAM_FILTER

public static final java.lang.String STREAM_FILTER

CONTROL_STREAM_ID

public static final java.lang.String CONTROL_STREAM_ID

CONTROL_STREAM_FILTER

public static final java.lang.String CONTROL_STREAM_FILTER

Method Detail

setEnabled

public void setEnabled(boolean enabled)
Enables the Monitor service.
Parameters:
enabled -  

isEnabled

public boolean isEnabled()
Returns if the Monitor service is enabled. Note that enabling the Monitor service does not enable any particular stages for monitoring. One still has to explicitly enable the stages for monitoring.
Returns:
boolean - true if the Monitor service is enabled

createEndpoint

public Endpoint createEndpoint(java.lang.String applicationId,
                               java.lang.String stageId,
                               Endpoint.Direction stagepoint)
Returns endpoint that represents a 'place' in the Event Server that can be monitored.
Returns:
Endpoint - monitorable stage end-point

monitorAvgThroughput

public Statement monitorAvgThroughput(Endpoint endpoint,
                                      long throughputInterval,
                                      long averageInterval,
                                      java.util.concurrent.TimeUnit unit)
Starts monitoring average throughput of events at the specified endpoint. Throughput is defined as the number of events that pass through the endpoint during the interval defined by throughputInterval parameter. Average throughput is calculated by averaging the throughput across averageInterval parameter. A MetricEvent containing the average throughput is output at the end of every averageInterval.
Parameters:
endpoint - the Endpoint to be monitored
throughputInterval - throughput interval defined in units specified by unit parameter
averageInterval - average interval defined in units specified by unit parameter
unit - time unit for intervals specified by throughputInterval and averageInterval parameters. This must be seconds or milliseconds and cannot be less than 100 milliseconds
Returns:
Statement used by monitoring processor for this monitoring request. This may be used to register for MetricEvents
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if intervals are less than 100 milliseconds or if throughput interval is greater than average interval

monitorAvgThroughput

public java.lang.String monitorAvgThroughput(Endpoint endpoint,
                                             long throughputInterval,
                                             long averageInterval,
                                             java.util.concurrent.TimeUnit unit,
                                             EventSink listener)
Starts monitoring average throughput of events at the specified endpoint. Throughput is defined as the number of events that pass through the endpoint during the interval defined by throughputInterval parameter. Average throughput is calculated by averaging the throughput across averageInterval parameter. A MetricEvent containing the average throughput is output at the end of every averageInterval.
Parameters:
endpoint - the Endpoint to be monitored
throughputInterval - throughput interval defined in units specified by unit parameter
averageInterval - average interval defined in units specified by unit parameter
unit - time unit for intervals specified by throughputInterval and averageInterval parameters. This must be seconds or milliseconds and cannot be less than 100 milliseconds
listener - (@link com.bea.wlevs.ede.api.EventSink} listener for MetricEvents with average throughput values
Returns:
String id of the Statement used by monitoring processor for this monitoring request.
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if intervals are less than 100 milliseconds or if throughput interval is greater than average interval

monitorAvgLatency

public Statement monitorAvgLatency(Endpoint start,
                                   Endpoint end,
                                   long averageInterval,
                                   java.util.concurrent.TimeUnit unit)
Starts monitoring the average latency of events between specified end points. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Average latency is calculated by averaging the latency values across averageInterval parameter. A MetricEvent containing the average latency in microseconds is output at the end of every averageInterval.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
averageInterval - the time interval for average calculation in units specified by unit parameter
unit - TimeUnit for averageInterval parameter
Returns:
Statement used by monitoring processor for this monitoring request. This may be used to register for MetricEvents
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

monitorAvgLatency

public java.lang.String monitorAvgLatency(Endpoint start,
                                          Endpoint end,
                                          long averageInterval,
                                          java.util.concurrent.TimeUnit unit,
                                          EventSink listener)
Starts monitoring the average latency of events between specified end points. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Average latency is calculated by averaging the latency values across averageInterval parameter. A MetricEvent containing the average latency in microseconds is output at the end of every averageInterval.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
averageInterval - the time interval for average calculation in units specified by unit parameter
unit - TimeUnit for averageInterval parameter
listener - (@link com.bea.wlevs.ede.api.EventSink} listener for MetricEvents with average latency values
Returns:
String id of the Statement used by monitoring processor for this monitoring request
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

monitorAvgLatencyThreshold

public Statement monitorAvgLatencyThreshold(Endpoint start,
                                            Endpoint end,
                                            long averageInterval,
                                            long threshold,
                                            java.util.concurrent.TimeUnit unit)
Starts monitoring the average latency of events between specified end points to see if it crosses the specified threshold. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Average latency is calculated by averaging the latency values across averageInterval parameter. A MetricEvent containing the average latency in microseconds is output at the end of every averageInterval where the average latency crosses the specified threshold.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
averageInterval - the time interval for average calculation in units specified by unit parameter
threshold - latency threshold value in microseconds
unit - TimeUnit for averageInterval parameter
Returns:
Statement used by monitoring processor for this monitoring request. This may be used to register for MetricEvents
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

monitorAvgLatencyThreshold

public java.lang.String monitorAvgLatencyThreshold(Endpoint start,
                                                   Endpoint end,
                                                   long averageInterval,
                                                   long threshold,
                                                   java.util.concurrent.TimeUnit unit,
                                                   EventSink listener)
Starts monitoring the average latency of events between specified end points to see if it crosses the specified threshold. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Average latency is calculated by averaging the latency values across averageInterval parameter. A MetricEvent containing the average latency in microseconds is output at the end of every averageInterval where the average latency crosses the specified threshold.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
averageInterval - the time interval for average calculation in units specified by unit parameter
threshold - latency threshold value in microseconds
unit - TimeUnit for averageInterval parameter
listener - EventSink listener for MetricEvents that contain the average latency values that cross the threshold
Returns:
String id of the Statement used by monitoring processor for this monitoring request. This may be used to register for MetricEvents
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

monitorMaxLatency

public Statement monitorMaxLatency(Endpoint start,
                                   Endpoint end,
                                   long maxInterval,
                                   java.util.concurrent.TimeUnit unit)
Starts monitoring the maximum latency of events between specified end points. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Maximum latency is the highest latency value during the interval specified by maxInterval parameter. A MetricEvent containing the maximum latency in microseconds is output at the end of every maxInterval.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
maxInterval - the time interval, in units specified by unit parameter, for which maximum latency is to be calculated
unit - TimeUnit for maxInterval parameter
Returns:
Statement used by monitoring processor for this monitoring request. This may be used to register for MetricEvents
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

monitorMaxLatency

public java.lang.String monitorMaxLatency(Endpoint start,
                                          Endpoint end,
                                          long averageInterval,
                                          java.util.concurrent.TimeUnit unit,
                                          EventSink listener)
Starts monitoring the maximum latency of events between specified end points. Latency between two end points is defined as the time it takes for an event to flow from the first end point to the second one. Maximum latency is the highest latency value during the interval specified by maxInterval parameter. A MetricEvent containing the maximum latency in microseconds is output at the end of every maxInterval.
Parameters:
start - start end-point for latency calculation
end - end end-point for latency calculatino
maxInterval - the time interval, in units specified by unit parameter, for which maximum latency is to be calculated
unit - TimeUnit for maxInterval parameter
listener - EventSink listener for MetricEvents that contain the maximum latency values
Returns:
String id of the Statement used by monitoring processor for this monitoring request.
Throws:
java.lang.IllegalArgumentException - if unit is not in seconds or milliseconds or if average interval is less than 100 milliseconds

terminateAllMonitoring

public void terminateAllMonitoring(Endpoint endpoint)
Terminates all monitoring activity for the specified Endpoint.
Parameters:
endpoint - The Endpoint for which monitoring activities must be stopped.

Overview  Package   Class   Use  Tree  Deprecated  Index  Help 
Copyright © 2007, 2013 Oracle and/or its affiliates. All rights reserved.
 PREV CLASS   NEXT CLASS FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD DETAIL:  FIELD | CONSTR | METHOD