-
Notifications
You must be signed in to change notification settings - Fork 62
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
fixes: use multiple sync messages if we hit ttrpc max message limit. #111
Open
klihub
wants to merge
10
commits into
containerd:main
Choose a base branch
from
klihub:devel/split-sync-messages
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
klihub
force-pushed
the
devel/split-sync-messages
branch
4 times, most recently
from
September 27, 2024 11:08
13498d6
to
4d42d7c
Compare
klihub
force-pushed
the
devel/split-sync-messages
branch
from
September 27, 2024 11:13
4d42d7c
to
0d8ecbc
Compare
Add a mechanism to block and unblock plugin synchronization. We use this first in our tests to ensure that test plugins get properly synchronized either before or after we create a pod or a container, but not halfway through it. We should also do the same in the corresponding paths of the NRI runtime integration core where otherwise processing NRI events concurrent to plugin registration could result in an inconsistent initial state of a new plugin (missing pods or containers during sync, or omitted event for the plugin). Signed-off-by: Krisztian Litkey <[email protected]>
Block plugin sync/registration in mocked test suite runtime. Signed-off-by: Krisztian Litkey <[email protected]>
Don't ignore ginkgo test run exit status. Signed-off-by: Krisztian Litkey <[email protected]>
Update ttrpc to get sender-side reject of oversized messages. Although purely a cosmetic change, update sample plugins' NRI dependecy to our latest tag. Signed-off-by: Krisztian Litkey <[email protected]>
Signed-off-by: Krisztian Litkey <[email protected]>
Don't reject oversized messages. Split and transmit them in multiple chunks. Signed-off-by: Krisztian Litkey <[email protected]>
Signed-off-by: Krisztian Litkey <[email protected]>
Try using multiple messages if we hit maximum ttrpc payload limit for initial plugin synchronization. Signed-off-by: Krisztian Litkey <[email protected]>
Handle split sync messages in the stub, opaque to the client. Signed-off-by: Krisztian Litkey <[email protected]>
Signed-off-by: Krisztian Litkey <[email protected]>
klihub
force-pushed
the
devel/split-sync-messages
branch
from
September 27, 2024 12:07
0d8ecbc
to
503a859
Compare
mikebrow
reviewed
Sep 27, 2024
mikebrow
reviewed
Sep 27, 2024
mikebrow
approved these changes
Sep 30, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR updates the protocol to allow initial plugin sync to use multiple messages. This is necessary if we hit the maximum ttrpc message size limit. That in turn can happen, as the maximum limit for total annotation key
and values in K8s is 256k. The adaptation implementation is updated to fall back to multiple messages if necessary. The stub implementation is updated to transparently collect and recombine multipart sync messages into a single one before passing it up the stack to the plugin.