class ResourceQuota
Defined at line 34 of file ../../third_party/grpc-migrating/src/include/grpcpp/resource_quota.h
ResourceQuota represents a bound on memory and thread usage by the gRPC
library. A ResourceQuota can be attached to a server (via
or a client channel (via
gRPC will attempt to keep memory and threads used by all attached entities
below the ResourceQuota bound.
Public Methods
void ResourceQuota (const std::string & name)
Parameters
void ResourceQuota ()
void ~ResourceQuota ()
ResourceQuota & Resize (size_t new_size)
Resize this
to a new size. If
is smaller
than the current size of the pool, memory usage will be monotonically
decreased until it falls under
No time bound is given for this to occur however.
ResourceQuota & SetMaxThreads (int new_max_threads)
Set the max number of threads that can be allocated from this
ResourceQuota object.
If the new_max_threads value is smaller than the current value, no new
threads are allocated until the number of active threads fall below
new_max_threads. There is no time bound on when this may happen i.e none
of the current threads are forcefully destroyed and all threads run their
normal course.
grpc_resource_quota * c_resource_quota ()
Defined at line 57 of file ../../third_party/grpc-migrating/src/include/grpcpp/resource_quota.h