Hook tool for sending metrics from charm.

A hook tool metric-add is made available to charm authors for sending metrics to state.
the error will be discarded if a metric which is not the last metric in the list fails