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

Add ability for channels to pause/resume processing of incoming messages #4612

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

clemahieu
Copy link
Contributor

This is a follow on to PR #4609 and responds to the fair queue for a channel being full by pausing incoming message processing for the channel.

Pausing incoming message handling will cause TCP flow control to back up to the sender and limit incoming data.

When a message is received from the network and placed in to the fair_queue, the queue is checked to see if the message queue is full for this channel. If full, the channel is placed in a paused state where new messages are not received.
When the message_processor processes items for a channel, it signals the associated channel to resume if it was in a paused state.
@clemahieu clemahieu requested a review from pwojcikdev May 10, 2024 11:32
@qwahzi qwahzi added this to the V27 milestone May 11, 2024
@pwojcikdev
Copy link
Contributor

pwojcikdev commented May 11, 2024

I don't think it works right now, I added a new core test to ensure proper behavior. Throttling is a bit tricky with the current networking architecture. Depending on how critical it is to get it working right now, this will probably be much easier to implement with networking code implemented using coroutines, using primitives like asynchronous conditions.

@qwahzi qwahzi modified the milestones: V27, V28 Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Progress / V28.0
Development

Successfully merging this pull request may close these issues.

3 participants