uwiger / gproc

Extended process registry for Erlang
Apache License 2.0
1.07k stars 232 forks source link

Reduce the amount of work done in the GPROC server process #96

Closed spc16670 closed 2 years ago

spc16670 commented 9 years ago

I had a quick look at the code an it looks like GPROC uses a pool of workers to manage load. Can you advise if the library was tested on a large system? Is there a mechanism to offload the main supervisor under massive loads e.g. enlarging the OTP tree and supervising the supervisors?

uwiger commented 9 years ago

Gproc does implement a pool mechanism, but doesn't use it itself.

Gproc has been used in several commercial systems, but there is definitely optimization potential. One of the things that would give Gproc a significant boost would be if OTP could introduce an ordered_set ets implementation with better concurrency characteristics. Also, reducing the amount of work done in the gproc server process should improve throughput.

spc16670 commented 9 years ago

Delegating off the amount of work done by the server process will effectively make the application scalable and remove a possible bottleneck. This is worth fixing. Did you let the OTP know about the ordered_set requirement?

uwiger commented 9 years ago

There is work being done on more scalable ordered_set implementations, e.g. http://winsh.me/papers/erlang_workshop_2014.pdf

I have no information on when something could be ready for inclusion in OTP though.