aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2015-07-23 09:57:58 -0700
committerGravatar Craig Tiller <ctiller@google.com>2015-07-23 09:57:58 -0700
commit5126bb6d8261ef07fb8132d5b5937f149cf315c8 (patch)
treed82bde630eed6055237935b386b2edbbef98500b /include
parentb70440bb1dfe90f27b31d169f82a549f2aa17084 (diff)
parentb46f3f400e4966f89737c376f7eb39b9511e375b (diff)
Merge pull request #2493 from a-veitch/record_stat
Census record stats API
Diffstat (limited to 'include')
-rw-r--r--include/grpc/census.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/grpc/census.h b/include/grpc/census.h
index 3fc07affc8..379783905a 100644
--- a/include/grpc/census.h
+++ b/include/grpc/census.h
@@ -100,6 +100,17 @@ int census_context_deserialize(const char *buffer, census_context **context);
* future census calls will result in undefined behavior. */
void census_context_destroy(census_context *context);
+/* A census statistic to be recorded comprises two parts: an ID for the
+ * particular statistic and the value to be recorded against it. */
+typedef struct {
+ int id;
+ double value;
+} census_stat;
+
+/* Record new stats against the given context. */
+void census_record_stat(census_context *context, census_stat *stats,
+ size_t nstats);
+
#ifdef __cplusplus
}
#endif