GetMetricData |
|
 |
Description
|
Gets server performance metrics.
|
|
Returns
|
ColdFusion structure that contains metric data, depending on the mode value.
|
|
Category
|
System functions
|
|
Function syntax |
GetMetricData(mode)
|
|
History
|
ColdFusion MX: Deprecated the cachepops parameter. It might not work, and it might cause an error, in later releases.
|
|
Parameters
|
|
Parameter |
Description |
iniFile |
Absolute path (drive, directory, filename, extension) of initialization file; for example, |
|
C:\boot.ini |
|
|
Usage
|
If mode = "perf_monitor", the function returns a structure with these data fields:
|
Field |
Description |
InstanceName |
The name of the ColdFusion server. Default: cfserver |
PageHits |
Number of HTTP requests received since ColdFusion MX was started. |
ReqQueued |
Number of HTTP requests in the staging queue, waiting for processing. |
DBHits |
Number of database requests since the server was started. |
ReqRunning |
Number of HTTP requests currently running. |
|
In the ColdFusion Administrator, you can set the maximum number of requests that run concurrently. |
ReqTimedOut |
Number of HTTP requests that timed out while in the staging queue or during processing. |
BytesIn |
Number of bytes in HTTP requests to ColdFusion MX |
BytesOut |
Number of bytes in HTTP responses from ColdFusion MX |
AvgQueueTime |
For the last two HTTP requests (current and previous), the average length of time the request waited in the staging queue. |
AvgReqTime |
For the last two HTTP requests (current and previous), the average length of time the server required to process the request |
AvgDBTime |
For the last two HTTP requests (current and previous), the average length of time the server took to process CFQueries in the request. |
cachepops |
This parameter is deprecated.ColdFusion automatically sets its value to -1. |
|
|
|
Example<!--- This example gets and displays metric data from Windows NT PerfMonitor -
-->
<cfset pmData = GetMetricData( "PERF_MONITOR" ) >
<cfoutput>
Current PerfMonitor data is: <p>
InstanceName: #pmData.InstanceName# <p>
PageHits: #pmData.PageHits# <p>
ReqQueued: #pmData.ReqQueued# <p>
DBHits: #pmData.DBHits# <p>
ReqRunning: #pmData.ReqRunning# <p>
ReqTimedOut: #pmData.ReqTimedOut# <p>
BytesIn: #pmData.BytesIn# <p>
BytesOut: #pmData.BytesOut# <p>
AvgQueueTime: #pmData.AvgQueueTime# <p>
AvgReqTime: #pmData.AvgReqTime# <p>
AvgDBTime: #pmData.AvgDBTime# <p>
</cfoutput>
|