finagle-stats: Easier migration from Ostrich
finagle-stats: Easier migration from Ostrich

Problem

It is a bit more work necessary for users to migrate
from finagle-ostrich4 to finagle-stats. This is due to
counters not being delta-ed in finagle-stats as they are
in Ostrich as well as histogram labels having slightly
different names.

Solution

Add two flags that enable a compatibility mode:

  -com.twitter.finagle.stats.useCounterDeltas=true
  -com.twitter.finagle.stats.format=ostrich

The first flag enables per-minute delta computations
of counters on calls to "/admin/stats.json?period=60"
and the second flag makes the histograms use the same
labels as Ostrich.

Result

finagle-ostrich4 users should be able to migrate more
easily to finagle-stats.

RB_ID=571868

takei-shg/twitter-server,twitter/twitter-server,BuoyantIO/twitter-server,BuoyantIO/twitter-server,twitter/twitter-server,wwezhuimeng/twitter-server,cogitate/twitter-server-uuid,travisbrown/twitter-server,travisbrown/twitter-server,BuoyantIO/twitter-server,takei-shg/twitter-server,takei-shg/twitter-server,wwezhuimeng/twitter-server,cogitate/twitter-server-uuid,wwezhuimeng/twitter-server,BuoyantIO/twitter-server,cogitate/twitter-server-uuid,twitter/twitter-server,travisbrown/twitter-server,takei-shg/twitter-server,travisbrown/twitter-server