camitz/aws-cloudwatch-statsd-backend — pull request #1 by tuxpiper (2012-12-19 16:28:14+00:00)
Title: Support for Cloudwatch dimensions

I missed the ability of using Cloudwatch dimensions. With the changes, dimensions can be specified in the configuration file, i.e.:

cloudwatch:
{
accessKeyId: 'xxx',
secretAccessKey: 'yyy',
region:"US_EAST_1",
processKeyForNamespace: true,
dimensions:[
{ "Name": "Instance", "Value": "i-2bc24da" }
]
}

Dimensions can also be specified in the statistic name:

Namespace.__dimension1_value1.__dimension2_value2.latency:300|ms

Additionally, a string may be provided to the "processKeyForNamespace" option, so instead of splitting the stat name as usual, the provided string will be used for building another regexp that will be used for splitting.