Petals CLI SNAPSHOT

compared with
Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (5)

View Page History
An extension of Petals CLI was created to monitor Petals ESB.

This extension has several implementations. Each implementation is adapted to a monitoring tool, but can be used as a normal command. Now, only one implementation exist, [the Cacti's implementation. implementation|Command 'monitoring' for Cacti]

h3. Installing the monitoring command

To install the monitoring command, just put the JAR artifact '{{org.ow2.petals:petals-cli-cmd-monitoring}}' in the directory {{$PETALS_CLI_HOME/extensions}}. To check that the installation is correct, just get the list of available commands of your Petals CLI, you should see the command '{{monitoring}}' in the list:
{code}
> ./petals-cli.sh -c -- help
...
logger-set
Set the specified level to the specified logger.
loggers Return all the loggers.
monitoring
Get monitoring information.
print Print a message.
...
{code}

Next you must install the Cacti's implementation of monitored objects. Put the JAR artifact '{{org.ow2.petals:petals-cli-cmd-monitoring-mo-cacti}}' in the directory {{$PETALS_CLI_HOME/extensions}}. To check that the installation is correct, just get the list of monitored objects:
{code}
> ./petals-cli.sh -c -- help monitoring
...
MONITORING OBJECT & SUB-FUNCTIONS
- local-transporter: Message exchange local transporter
- delivered-messages: Delivered messages
- ...
- ...
...
{code}

h3. Monitored objects

Available monitored objects are the following:
|| Object || Metric || Command line ||
| Petals BC SOAP | Incoming HTTP request counters | {{-o petals-bc-soap -f incoming-http-requests-count}} |
| Petals BC SOAP | Incoming WS request counters | {{-o petals-bc-soap -f incoming-ws-requests-count}} |
| Petals BC SOAP | Incoming WS request response times | {{-o petals-bc-soap -f incoming-ws-requests-response-times}} |
| Petals BC SOAP | HTTP thread pool | {{-o petals-bc-soap -f http-thread-pool}} |
| Petals BC SOAP | WS-client pools | {{-o petals-bc-soap -f ws-clients-pools}} |
| Petals BC SOAP | Outgoing WS request counters | {{-o petals-bc-soap -f outgoing-ws-requests-count}} |
| Petals BC SOAP | Outgoing WS request response times | {{-o petals-bc-soap -f outgoing-ws-requests-response-times}} |
| Local transporter | Delivered messages | {{-o local-transporter -f delivered-messages}} |

h4. Petals BC SOAP

h5. Incoming WS request counters

Incoming WS request counters are available through the sub function '{{incoming-ws-requests-count}}' of the monitored object '{{petals-bc-soap}}'. It's usage is:
{code}
-n <component-name> [--list-operations] | [--query-operations [NAME] | [SUCCEEDED|FAULT|ERROR <index>]] | [-t]
{code}
where '{{<component-name>}}' is the unique name of the Petals BC SOAP with which it was deployed.

'{{--list-operations}}' returns the list of all operations of all web-services that were invoked since the last start of the component. Operations are returned with the following pattern: {{<operation>@<ws-path>}}, where {{<operation>}} is the qualified name of the operation and {{<ws-path>}} is the URL path of the web-service.
{code}
>./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-count -- -n petals-bc-soap --list-operations
{http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation@/ChargeService
{code}

'{{--query-operations}}' returns query result about operation:
* {{NAME}} returns operation names by index. It is used to known which operation is associated to index. The output format is: {{<index>!<operation>}}, one operation per line.
* {{SUCCEEDED}} returns the number of succeeded invocation per operation. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index.
* {{FAULT}} returns the number of faulty invocation per operation. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index.
* {{ERROR}} returns the number of failed invocation per operation. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index.
the list of all operations of all web-services that were invoked since the last start of the component. Operations are returned with the following pattern: {{<operation>@<ws-path>}}, where {{<operation>}} is the qualified name of the operation and {{<ws-path>}} is the URL path of the web-service.
{code}
>./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-count -- -n petals-bc-soap --query-operations SUCCEEDED
{http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation@/ChargeService!3
{code}

'{{-t}}' displays a human readable table of all values about incoming WS requests:
{code}
> ./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-count -- -n petals-bc-soap -t
| Service | Operation | WS-client | Execution status || Value |
---------------------------------------------------------------------------------------------------------------------------------------------------
| /ChargeService | {http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation | 127.0.0.1 | SUCCEEDED || 3 |
| /ChargeService | {http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation | 127.0.0.1 | PENDING || 0 |
{code}

h5. Incoming WS request response times

Incoming WS request response times are available through the sub function '{{incoming-ws-requests-count}}' of the monitored object '{{petals-bc-soap}}'. It's usage is:
{code}
-n <component-name> [--list-operations] | [--query-operations [NAME] | [SUCCEEDED_MIN|SUCCEEDED_AVG|SUCCEEDED_MAX|SUCCEEDED_10P|SUCCEEDED_50P|SUCCEEDED_90P|FAULT_MIN|FAULT_AVG|FAULT_MAX|FAULT_10P|FAULT_50P|FAULT_90P|ERROR_MIN|ERROR_AVG|ERROR_MAX|ERROR_10P|ERROR_50P|ERROR_90P <index>]] | [-t]
{code}
where '{{<component-name>}}' is the unique name of the Petals BC SOAP with which it was deployed.

\\
'{{--list-operations}}' returns the list of all operations of all web-services that were invoked since the last start of the component. Operations are returned with the following pattern: {{<operation>@<ws-path>}}, where {{<operation>}} is the qualified name of the operation and {{<ws-path>}} is the URL path of the web-service.
{code}
>./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-response-times -- -n petals-bc-soap --list-operations
{http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation@/ChargeService
{code}

\\
'{{--query-operations}}' returns query result about operation:
|| Query argument || Description ||
| {{NAME}} | returns operation names by index. It is used to known which operation is associated to index. The output format is: {{<index>!<operation>}}, one operation per line. |
| {{SUCCEEDED_MIN}} | returns the minimum value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{SUCCEEDED_AVG}} | returns the average value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{SUCCEEDED_MAX}} | returns the maximum value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{SUCCEEDED_10P}} | returns the 10-percentile value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{SUCCEEDED_50P}} | returns the 50-percentile value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{SUCCEEDED_90P}} | returns the 90-percentile value of response times of succeeded invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_MIN}} | returns the minimum value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_AVG}} | returns the average value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_MAX}} | returns the maximum value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_10P}} | returns the 10-percentile value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_50P}} | returns the 50-percentile value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{FAULT_90P}} | returns the 90-percentile value of response times of faulty invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_MIN}} | returns the minimum value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_AVG}} | returns the average value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_MAX}} | returns the maximum value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_10P}} | returns the 10-percentile value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_50P}} | returns the 50-percentile value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
| {{ERROR_90P}} | returns the 90-percentile value of response times of failed invocation per operation on the current sample. The operation is expressed by its index. The output format is: {{<index>!<value>}}, one operation per line. If an index value is set on the command line, the output is limited to the provided index |
{code}
>./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-response-times -- -n petals-bc-soap --query-operations SUCCEEDED
{http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation@/ChargeService!3
{code}

\\
'{{-t}}' displays a human readable table of all values about incoming WS-request response times:
{code}
> ./petals-cli.sh -h localhost -n 7700 -u petals -p petals -c -- monitoring -o petals-bc-soap -f incoming-ws-requests-response-times -- -n petals-bc-soap -t
| Service | Operation | WS-client | Execution status || Value |
---------------------------------------------------------------------------------------------------------------------------------------------------
| /ChargeService | {http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation | 127.0.0.1 | SUCCEEDED || 3 |
| /ChargeService | {http://esb.mediation.archi.acoss.fr/services/charge/se-diff-agreg/1.0}chargeOperation | 127.0.0.1 | PENDING || 0 |
{code}

h4. Petals container - Local transporter


h1. Known Problems