Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upLoad balance across module connections in v4 #2466
Comments
alandekok
added
feature enhancement
v4.0.x
labels
Feb 6, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
alandekok commentedFeb 6, 2019
We want to have modules (e.g.
radius
) open multiple connections, and manage connections to multiple home servers. At the same time, we want to do load-balancing, etc. in the server core, instead of pushing that to the modules.We can't instantiate multiple versions of the same module, one for each connection / home server. The issue there is that the module instance tree isn't thread-local (tho maybe it should be). Also, if a module clones itself, what does that mean?
i.e. we have:
How will the module tell the parent keyword that there are multiple instances of itself?
One option is to just have the module register keyword-specific callbacks. That way the
load-balance
keyword can ask the module how many connections it has, and then do load-balancing across those connections.That does seem somewhat solution-specific tho.
The
unlang
compile && interpret phase then have to be updated to know about the dynamic number of children, instead of usingg->num_children
.