19 #ifndef GRPC_INTERNAL_CPP_THREAD_MANAGER_H 20 #define GRPC_INTERNAL_CPP_THREAD_MANAGER_H 36 int min_pollers,
int max_pollers);
76 virtual void DoWork(
void* tag,
bool ok,
bool resources) = 0;
125 bool created()
const {
return created_; }
126 void Start() { thd_.Start(); }
141 void MarkAsCompleted(WorkerThread* thd);
142 void CleanupCompletedThreads();
173 int max_active_threads_sofar_;
176 std::list<WorkerThread*> completed_threads_;
181 #endif // GRPC_INTERNAL_CPP_THREAD_MANAGER_H
bool IsShutdown()
Definition: thread_manager.cc:87
ThreadManager(const char *name, grpc_resource_quota *resource_quota, int min_pollers, int max_pollers)
Definition: thread_manager.cc:52
void Initialize()
Definition: thread_manager.cc:126
virtual void Wait()
Definition: thread_manager.cc:75
Definition: thread_manager.h:43
virtual void Shutdown()
Definition: thread_manager.cc:82
Definition: thread_manager.h:33
struct grpc_resource_user grpc_resource_user
Definition: resource_quota.h:87
virtual void DoWork(void *tag, bool ok, bool resources)=0
This header provides an object that reads bytes directly from a grpc::ByteBuffer, via the ZeroCopyInp...
Definition: alarm.h:24
struct grpc_resource_quota grpc_resource_quota
Definition: grpc_types.h:677
virtual ~ThreadManager()
Definition: thread_manager.cc:64
virtual WorkStatus PollForWork(void **tag, bool *ok)=0
Definition: thread_manager.h:43
Definition: thread_manager.h:43
int GetMaxActiveThreadsSoFar()
Definition: thread_manager.cc:92
WorkStatus
Definition: thread_manager.h:43