diff options
author | Craig Tiller <ctiller@google.com> | 2017-09-12 15:18:54 -0700 |
---|---|---|
committer | Craig Tiller <ctiller@google.com> | 2017-09-12 15:18:54 -0700 |
commit | 50e11005a1f3de0a36f9d040a39696241b1f883f (patch) | |
tree | f94593797e87fd948dacb526ae71539a87faee3b /src/core/lib/surface | |
parent | 8e90f6955a3f3aca7ba99577fc59e910996dd380 (diff) | |
parent | 6d4c993289875b04b35c32bcf854cf2013305ecc (diff) |
Merge github.com:grpc/grpc into grpc_millis
Diffstat (limited to 'src/core/lib/surface')
-rw-r--r-- | src/core/lib/surface/server.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/lib/surface/server.c b/src/core/lib/surface/server.c index 008d36d1cb..64e5ce78e7 100644 --- a/src/core/lib/surface/server.c +++ b/src/core/lib/surface/server.c @@ -29,6 +29,7 @@ #include "src/core/lib/channel/channel_args.h" #include "src/core/lib/channel/connected_channel.h" +#include "src/core/lib/debug/stats.h" #include "src/core/lib/iomgr/executor.h" #include "src/core/lib/iomgr/iomgr.h" #include "src/core/lib/slice/slice_internal.h" @@ -542,6 +543,7 @@ static void publish_new_rpc(grpc_exec_ctx *exec_ctx, void *arg, if (request_id == -1) { continue; } else { + GRPC_STATS_INC_SERVER_CQS_CHECKED(exec_ctx, i); gpr_mu_lock(&calld->mu_state); calld->state = ACTIVATED; gpr_mu_unlock(&calld->mu_state); @@ -552,6 +554,7 @@ static void publish_new_rpc(grpc_exec_ctx *exec_ctx, void *arg, } /* no cq to take the request found: queue it on the slow list */ + GRPC_STATS_INC_SERVER_SLOWPATH_REQUESTS_QUEUED(exec_ctx); gpr_mu_lock(&server->mu_call); gpr_mu_lock(&calld->mu_state); calld->state = PENDING; @@ -1434,6 +1437,7 @@ grpc_call_error grpc_server_request_call( grpc_call_error error; grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; requested_call *rc = (requested_call *)gpr_malloc(sizeof(*rc)); + GRPC_STATS_INC_SERVER_REQUESTED_CALLS(&exec_ctx); GRPC_API_TRACE( "grpc_server_request_call(" "server=%p, call=%p, details=%p, initial_metadata=%p, " @@ -1480,6 +1484,7 @@ grpc_call_error grpc_server_request_registered_call( grpc_exec_ctx exec_ctx = GRPC_EXEC_CTX_INIT; requested_call *rc = (requested_call *)gpr_malloc(sizeof(*rc)); registered_method *rm = (registered_method *)rmp; + GRPC_STATS_INC_SERVER_REQUESTED_CALLS(&exec_ctx); GRPC_API_TRACE( "grpc_server_request_registered_call(" "server=%p, rmp=%p, call=%p, deadline=%p, initial_metadata=%p, " |