Allow applicationName to be configured

The cloudwatch plugin used to explicitly look at the instanceId and add
it as a label for the generated metrics.

This is fine for single Gerrit installations, but it does not work for
HA setups where the instance ID is the same for all Gerrit peers in the
cluster, making it impossible to differentiate metrics origin.

Allow an explicit `applicationName`, defaulting to the instanceId, to be
configured so that Gerrit admin can explicitly decide the value of this
Gerrit's metric dimension.

Bug: Issue 16772
Change-Id: Id792c09c0af071024bcf10383a3d9dea7006f13b
5 files changed
tree: 101777db5fa75e5482ce0c8da081ea42dd773a81
  1. src/
  2. BUILD
  3. external_plugin_deps.bzl