class KamonCounter implements Counter {

    @Override
    public boolean reset() {
        try {
            final kamon.metric.Counter kamonInternalCounter = getKamonInternalCounter();
            if (kamonInternalCounter instanceof kamon.metric.Counter.LongAdder) {
                ((kamon.metric.Counter.LongAdder) kamonInternalCounter).snapshot(true);
                LOGGER.trace("Reset counter with name <{}>.", name);
                return true;
            }
            LOGGER.warn("Could not reset counter with name <{}>.", name);
            return false;
        } catch (final IllegalStateException e) {
            LOGGER.warn("Could not reset counter with name <{}>.", name);
            return false;
        }
    }

    private  KamonCounter(final String name, final Map<String, String> tags);

}