The Particular throughput tool can be installed locally and run against a production system to discover the throughput of each endpoint in a system over a period of time.
This article details how to collect endpoint and throughput data when the system uses the Amazon SQS transport. Refer to the throughput counter main page for information how to install/uninstall the tool or for other data collection options.
Running the tool
Collecting metrics for SQS relies upon AWSSDK.SQS to discover queue names and AWSSDK.CloudWatch to gather per-queue metrics.
Authentication to AWS requires a AWS credentials profile, or credentials can be created from the AWS_ACCESS_KEY_ID
and AWS_SECRET_ACCESS_KEY
environment variables, if both are not empty. The tool uses default constructors for the SQS and CloudWatch clients and follows the credential and profile resolution rules determined by the AWS SDK.
The AWS region can be specified either by command-line parameter or by the AWS_REGION
environment variable.
If the tool was installed as a .NET tool, execute the tool as shown:
throughput-counter sqs [options]
Or, if using the self-contained executable:
Particular.EndpointThroughputCounter.exe sqs [options]
Options
Option | Description |
---|---|
--profile | The name of a local AWS credentials profile. If not included, credentials can be read from the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables. |
--region | The AWS region to use when accessing AWS services. If not provided, the default profile value or AWS_REGION environment variable will be used. |
--prefix | Report only on queues that begin with a specific prefix. This is commonly used when one AWS account must contain queues for multiple projects or multiple environments. Example: --prefix "prod-" |
--queueNameMasks | Masks sensitive information in the generated report. See masking private data. |
--customerName | Sets the customer name. If not provided, the tool will prompt for the information. Example: --customerName "Particular Software" |
--unattended | Will not prompt for user input, so that the tool can be used from environments such as a continuous integration system. |
--skipVersionCheck | Will not perform the check, for use in environments when outgoing network access creates alerts. |
What the tool does
The tool first queries the SQS API to fetch all queue names. Then, for each queue that is discovered, the tool queries the CloudWatch API for the NumberOfMessagesDeleted
metrics for the past 30 days.
Unlike ServiceControl, using SQS and CloudWatch metrics allows the tool to capture the last 30 days worth of data at once, which means that the report will be generated without delay. Although the tool collects 30 days worth of data, only the highest daily throughput is included in the report.