コード例 #1
0
ファイル: resource_quota.c プロジェクト: pmarks-net/grpc
static void rq_step_sched(grpc_exec_ctx *exec_ctx,
                          grpc_resource_quota *resource_quota) {
  if (resource_quota->step_scheduled) return;
  resource_quota->step_scheduled = true;
  grpc_resource_quota_internal_ref(resource_quota);
  grpc_combiner_execute_finally(exec_ctx, resource_quota->combiner,
                                &resource_quota->rq_step_closure,
                                GRPC_ERROR_NONE, false);
}
コード例 #2
0
ファイル: stream_lists.c プロジェクト: peterhuene/grpc
void grpc_chttp2_list_add_check_read_ops(
    grpc_exec_ctx *exec_ctx, grpc_chttp2_transport_global *transport_global,
    grpc_chttp2_stream_global *stream_global) {
  grpc_chttp2_transport *t = TRANSPORT_FROM_GLOBAL(transport_global);
  if (!t->executor.check_read_ops_scheduled) {
    grpc_combiner_execute_finally(exec_ctx, t->executor.combiner,
                                  &t->initiate_read_flush_locked,
                                  GRPC_ERROR_NONE, false);
    t->executor.check_read_ops_scheduled = true;
  }
  stream_list_add(TRANSPORT_FROM_GLOBAL(transport_global),
                  STREAM_FROM_GLOBAL(stream_global),
                  GRPC_CHTTP2_LIST_CHECK_READ_OPS);
}