Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Client max routing in workers #713

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

rkhapov
Copy link
Collaborator

@rkhapov rkhapov commented Nov 5, 2024

No description provided.

Current od_worker function is quite heavy: it performs all message
type processing in single switch construction.

This patchs makes two new functions for every message types.

Signed-off-by: rkhapov <[email protected]>
When checking the `client_max_routing` option in od_system(),
it creates some problems with monitoring tools such as pgconsul
(which assumes that Odyssey is not accepting new connections
and needs to be restarted), and it is a poor design choice overall,
aimed at solving the problem of CPU consumption by TLS handshakes.

To solve this issue, tls threads needs to be created.
They will only do the tls handshakes, it will allows to unload workers
threads, which will be just ready to send the bytes between clients and servers,
and even accept new connections.

This patch performs one of the first steps to introduce tls threads: it moves
the logic of 'client max routing' into worker from od_system().

Signed-off-by: rkhapov <[email protected]>
This function will be used to obtain information about workers
task_channel size in future commits.

Signed-off-by: rkhapov <[email protected]>
(cherry picked from commit fe27077)
Signed-off-by: rkhapov <[email protected]>
Signed-off-by: rkhapov <[email protected]>
(cherry picked from commit 1655bc2)
Signed-off-by: rkhapov <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant