This following sections describe the Monitoring Statistics API and Streaming Statistics API, and the servlet actions they perform:
•Monitoring Statistics API Actions
•Streaming Statistics API Actions
This section describes the Monitoring Statistics API and the servlet actions it performs. The Monitoring Statistics API gets monitoring statistics data about a single Service Engine or all the Service Engines in a ECDS network. The Monitoring Statistics API is the MonitoringApiServlet.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.MonitoringApiServlet...
This servlet performs one or more of the following actions:
Obtains monitoring statistics information for the specified Service Engine.
Parameter
•Service Engine ID (required)—<SE_ID> entry in the form CeConfig_####
•Monitoring statistics type (required)
The monitoring statistics types are:
–bytes_served
–bandwidth_efficiency_gain
–streaming_sessions
–cpu_utilization
•Time frame (optional)—The time period over which monitoring statistics are obtained. The default is last_hour.
The options are:
–last_hour
–last_day
–last_week
–last_month
–custom
Note If you choose custom, you must specify the time frame using the End time from and End time to options.
•End time from (optional)—The date and time that collection of monitoring statistics data should start. You can specify only the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•End time to (optional)—The date and time that collection of monitoring statistics data should end. You can specify only the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•Time zone (optional)—The time zone used to generate the monitoring statistics data. The default is utc.
The time zones are:
–utc—Time in UTC (Coordinated Universal Time)
–se_local_time—Time zone specified on the Service Engine
–cdsm_local_time—Time zone specified on the CDSM
Return
Requested monitoring statistics data for the selected time period for the Service Engine.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.MonitoringApiServlet?action=getSEstats&id=<SE_ID>&type=<bytes_served | bandwidth_efficiency_gain | streaming_sessions | cpu_utilization>[&time_frame=<last_hour | last_day | last_week | last_month | custom>]
[&end_time_from=<mm/dd/yyyy [hh:mm[:ss]]>][&end_time_to=<mm/dd/yyyy [hh:mm[:ss]]>]
[&time_zone=<utc | se_local_time | cdsm_local_time>]
Example 5-1 getSeStats Query Success
<?xml version="1.0" ?>
- <MonitoringApi action="getSEstats" id="CeConfig_6812" type="bytes_served"
time_frame="last_hour" end_time_from="07/12/2012 21:33:47 UTC" end_time_to="07/12/2012
22:33:47 UTC" time_zone="utc">
<message status="success" message="MonitoringData is displayed" />
</MonitoringApi>
Obtains monitoring statistics information for all the Service Engines in the specified location.
Parameter
•Location ID (required)
•Monitoring statistics type (required)
The monitoring statistics types are:
–bytes_served
–bandwidth_efficiency_gain
–streaming_sessions
•Time frame (optional)—The time period over which monitoring statistics are obtained. The default is last_hour.
The options are:
–last_hour
–last_day
–last_week
–last_month
–custom
Note If you choose custom, you must specify the time frame using the End time from and End time to options.
•End time from (optional)—The date and time that collection of monitoring statistics data should start. You can specify only the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•End time to (optional)—The date and time that collection of monitoring statistics data should end. You can specify only the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•Time zone (optional)—The time zone used to generate the monitoring statistics data. The default is utc.
The time zones are:
–utc—Time in UTC (Coordinated Universal Time)
–cdsm_local_time—Time zone specified on the CDSM
Return
Requested monitoring statistics data for the selected time period for the Service Engines in the specified location.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.MonitoringApiServlet?action=
getLocationStats&id=<Location_ID>&type=<bytes_served | bandwidth_efficiency_gain | streaming_sessions>[&time_frame=<last_hour | last_day | last_week | last_month | custom>]
[&end_time_from=<mm/dd/yyyy [hh:mm[:ss]]>][&end_time_to=<mm/dd/yyyy [hh:mm[:ss]]>]
[&time_zone=<utc | cdsm_local_time>]
Obtains monitoring statistics information for the entire ECDS network.
Parameter
•Monitoring statistics type (required)
The monitoring statistics types are:
–bytes_served
–bandwidth_efficiency_gain
–streaming_sessions
•Time frame (optional)—The time period over which monitoring statistics are obtained. The default is last_hour.
The options are:
–last_hour
–last_day
–last_week
–last_month
–custom
Note If you choose custom, you must specify the time frame using the End time from and End time to options.
•End time from (optional)—The date and time that collection of monitoring statistics data should start. You can specify the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•End time to (optional)—The date and time that collection of monitoring statistics data should end. You can specify the date or the date and time. The date format is mm/dd/yyyy, and the time format is hh:mm. Optionally, you can specify the time in hh:mm:ss.
•Time zone (optional)—The time zone used to generate the monitoring statistics data. The default is utc.
The time zones are:
–utc—Time in UTC (Coordinated Universal Time)
–cdsm_local_time—Time zone specified on the CDSM
Return
Requested monitoring statistics data for the selected time period for all the Service Engines in the ECDS network.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.MonitoringApiServlet?action=getCdnStats&type=<bytes_served | bandwidth_efficiency_gain | streaming_sessions>[&time_frame=<last_hour | last_day | last_week | last_month | custom>][&end_time_from=<mm/dd/yyyy [hh:mm[:ss]]>]
[&end_time_to=<mm/dd/yyyy [hh:mm[:ss]]>][&time_zone=<utc | cdsm_local_time>]
This section describes the Streaming Statistics API and the servlet actions it performs. The streaming statistics are collected from the ECDS network Service Engines and device groups and sent to the CDSM. The HTTP, Movie Streamer, WMT streaming and Flash Media Streaming statistical data is monitored and displayed in the CDSM for all Service Engines, all device groups, or all the Service Engines within a selected device group.
The Streaming Statistics API is the SprayerApiServlet. The CDSM must be running for the servlet to function.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.SprayerApiServlet...
This servlet performs one or more of the following actions to collect statistics for each Service Engine (SE), device group (DG), or device group name for all the Service Engines in the specified device group:
Collects HTTP streaming statistics data from the Service Engines and device groups and sends it to the CDSM.
Parameter
The SE keyword, DG keyword, or the name of the device group is required.
Return
Requested HTTP streaming statistics data for the Service Engines or device groups.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.SprayerApiServlet?action=getHttp&
param=SE | DG | <DG_name>
Collects Movie Streamer streaming statistics data from the Service Engines and device groups and sends it to the CDSM.
Parameter
The SE keyword, DG keyword, or the name of the device group is required.
Return
Requested Movie Streamer streaming statistics data for the Service Engines or device groups.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.SprayerApiServlet?action=
getMovieStreamer¶m=SE | DG | <DG_name>
Collects WMT streaming statistics data from the Service Engines and device groups and sends it to the CDSM.
Parameter
The SE keyword, DG keyword, or the name of the device group is required.
Return
Requested WMT streaming statistics data for the Service Engines or device groups.
Syntax
https://<cdsmIpAddress>:8443/servlet/com.cisco.unicorn.ui.SprayerApiServlet?action=getWmt&
param=SE | DG | <DG_name>
The following is the Document Type Definition (DTD) of the XML-formatted output for streaming statistics:
<?xml version="1.0" ?>
DOCTYPE <!DOCTYPE sprayerStats [
<!ELEMENT sprayerStats (message, (HttpStats* | MovieStreamerStats* | WmtStats* | FmsStats*) )>
<!ATTLIST sprayerStats
action (getHttp | getMovieStreamer | getWmt | getFms )#REQUIRED count CDATA #REQUIRED>
<!ELEMENT message EMPTY>
<!ATTLIST message
status (success | fail) success message CDATA #IMPLIED>
<!ELEMENT HttpStats EMPTY>
<!ATTLIST HttpStats
name CDATA #REQUIRED
requestsPerSec CDATA #REQUIRED
bytesPerSec CDATA #REQUIRED
requestLatency CDATA #REQUIRED>
<!ELEMENT MovieStreamerStats EMPTY>
<!ATTLIST MovieStreamerStats
name CDATA #REQUIRED
totalBytes CDATA #REQUIRED
totalPackets CDATA #REQUIRED
rtspConnections CDATA #REQUIRED
allConnections CDATA #REQUIRED>
<!ELEMENT WmtStats EMPTY>
<!ATTLIST WmtStats
name CDATA #REQUIRED
requestsPerSec CDATA #REQUIRED
bytesPerSec CDATA #REQUIRED
hitRate CDATA #REQUIRED>
<!ELEMENT FmsStats EMPTY>
<!ATTLIST FmtStats
name CDATA #REQUIRED
allConnections CDATA #REQUIRED
bytesPerSec CDATA #REQUIRED
hitRate CDATA #REQUIRED>
]>
Note Beginning in Release 2.5.3, the serviceTime attribute of the HttpStats element is removed.