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

DISPATCH-451: Configurable settings for session capacity and max sessions #106

Merged
merged 5 commits into from Oct 10, 2016

Conversation

ChugR
Copy link
Contributor

@ChugR ChugR commented Oct 4, 2016

This patch allows listener and connector settings for session capacity and for max sessions.

It does not allow a setting for max-message-size. Proton does not provide an interface for changing max message size. This issue is tracked at PROTON-1311

Work is progressing on self tests for this feature. Proton python and wrapper interfaces tend to hide sessions and make finding session state difficult.

uint32_t max_sessions;

/**
* The max_session_window value is the maximum number of outstanding octets that are
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might it be easier to explain this if the units were frames instead of octets?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good suggestion. The setting down to proton would be * max-frame-size octets.
There is an identical setting in policy that operates this way, too. Again, they ought to be the same either way.

* The max_sessions value is the number of sessions allowed on the Connection.
* This value minus one is the Open performative channel-max setting.
*/
uint32_t max_sessions;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What will be do with the value 0? Should we use channel_max to avoid this question?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There should be a comment that says if you specify zero then you get the default number. Using channel_max is awkward in its own way: if the setting is 1 then you get 2.
There is an identical setting in policy that already used the 1..N numbering (and not 0..N-1). They ought to be the same either way.

Chuck Rolke added 3 commits October 7, 2016 17:23
The logic behind the config settings for listeners and connectors is
the same. Add tests to verify that connector settings are propagated
over the wire.
Clarify how maxSessionFrames may be adjusted when the product of
maxFrameSize and maxSessionFrames exceeds 2^31-1.
@asfgit asfgit merged commit 2bab3f3 into apache:master Oct 10, 2016
asfgit pushed a commit that referenced this pull request Oct 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants