Eventing Statistics, for each deployed Function, can be fetched from an Eventing node using the Web Console or using the REST API.
Via the Web Console
Eventing Statistics, for each deployed Function, can be fetched from an Eventing node using the Web Console.
To fetch Eventing Statistics for a deployed Function, from the Couchbase Web Console > Servers page, now click Statistics. This page will only show deployed Eventing functions, you can scroll to any section labeled
"Eventing Stats: deployed_function_name" and expand the section to show the four graphs listed below:
Processed - displays the number of processed Functions.
Failures - displays the number of failures while processing the Function handler code.
Backlogs - displays the number of mutations to be processed by a Function.
Timeouts - displays the number of Functions which have encountered a timeout condition.
Note, you may click and expand any of the above graphs for any deployed Eventing Function.
Via the REST API
|The Functions REST API is a Beta feature intended for development purposes only, do not use them in production; no Enterprise Support is provided for Beta features.|
Eventing statistics can be fetched from each eventing node using REST API bound to localhost. The resulting JSON based responses are local to the node, and suitable for further aggregation across nodes of the cluster.
The following REST endpoint could be used to get the full set of Eventing statistics:
This will return the full statistics set inclusive of events processing, events remaining, execution, failure, latency, worker PIDs and sequence processed.
Note, omitting the parameter
type=full will exclude
seqs_processed from the response.
The above statistics can also be individually obtained through the following REST endpoints:
curl http://user:pass@localhost:8096/getExecutionStats?name=function_name curl http://user:pass@localhost:8096/getLatencyStats?name=function_name curl http://user:pass@localhost:8096/getFailureStats?name=function_name