refactoring sync gateway KPI

Change-Id: Idadb4715c7e36a1fff95354edabf38dfa4e9633f
Reviewed-on: http://review.couchbase.org/37163
Tested-by: buildbot <build@couchbase.com>
Reviewed-by: Li Yang <lichenyang2@gmail.com>