[grpc-io] Re: Setting gRPC internal threads' affinity

2024-02-09 Thread Dan Cohen
Hi AJ, If I may - a follow-up question after looking a little bit into the EventEngine interface. I need to satisfy a very minimal requirement - being able to control the number of internal threads and the cpu affinity of those threads. I wouldn't want to change any other default behavior of g

[grpc-io] Re: Setting gRPC internal threads' affinity

2024-02-07 Thread Dan Cohen
Thanks AJ. Will have a look at the EventEngine then. Sorry about replying privately, not sure how it happened, it wasn't my intention. On Tuesday, February 6, 2024 at 8:01:35 PM UTC+2 AJ Heller wrote: Dan, Replying here on the mailing list thread. > Thanks AJ! > > Using taskset is not an opt

[grpc-io] Re: Setting gRPC internal threads' affinity

2024-02-06 Thread 'AJ Heller' via grpc.io
Dan, Replying here on the mailing list thread. > Thanks AJ! > > Using taskset is not an option for me, as my gRPC server is part of the executable that also does the more sensitive work IO load work. So what I need is an internal process differentiation between the threads' affinity. You would

[grpc-io] Re: Setting gRPC internal threads' affinity

2024-02-05 Thread 'AJ Heller' via grpc.io
Hi Dan, If you're interested in CPU affinity for the entire server process on Linux, you can use `taskset` https://linux.die.net/man/1/taskset. Otherwise, you'll likely want to patch `thd.cc` and use pthread's affinity APIs, but I don't recommend it. For more advanced use cases with the C/C++