safe stats getter

Change-Id: Ic097e7d1c6fe8488abf2636331a42eeeb42d1ddc
Reviewed-on: http://review.couchbase.org/37791
Tested-by: buildbot <build@couchbase.com>
Reviewed-by: Pavel Paulau <pavel.paulau@gmail.com>