Create a UidFormatter class

How about put the following here:

client.allocateUID("sys.cpu.0", new byte[]{0, 0, 1}, METRIC);
client.allocateUID("host", new byte[]{0, 0, 1}, TAGK);
client.allocateUID("web01", new byte[]{0, 0, 1}, TAGV);

Or even better:

client.allocateUID("sys.cpu.0", METRIC, METRIC.width);
client.allocateUID("host", TAGK, TAGK.width);
client.allocateUID("web01", TAGV, TAGV.width);

The the class should allocate the numbering for you.
Then:
assertEquals("thename", formatter.formatMetric(new byte[]{0, 0, 1}).joinUninterruptibly());
assertEquals("sys.cpu.0", formatter.formatMetric(new byte[]{0, 0, 1}).joinUninterruptibly());

formatter.formatMetric(new byte[] {0, 0, 2}).joinUninterruptibly();