Skip to content

Conversation

@klihub
Copy link
Member

@klihub klihub commented Oct 24, 2024

With no NRI plugins registered or none of the registered plugins requesting changes to a container, we should ideally skip applying NRI adjustments on the runtime side altogether, instead of going through the motions without any effective changes. Having seen #117 (quickly fixed by #116), this is not the case.

This PR is the first part in an attempt to change that. With this PR in place, we don't create an a priori empty adjustment in preparation to process NRI requests. We only create it once a plugin makes an actual change to the container being created. Effectively, this should result in a nil adjustment reply when there are no plugins present, or none of the present plugins touches a container.

The other part is a related change to the runtime integration code to check for this and short-circuit processing.

@klihub klihub requested review from mikebrow and samuelkarp October 24, 2024 16:08
@klihub klihub force-pushed the devel/use-nil-as-nop-adjustment branch from f765fc8 to 362c075 Compare October 24, 2024 16:09
@klihub klihub force-pushed the devel/use-nil-as-nop-adjustment branch from 362c075 to a39f4c4 Compare January 23, 2025 08:45
@klihub klihub marked this pull request as ready for review January 23, 2025 09:12
Copy link
Member

@mikebrow mikebrow left a comment

Choose a reason for hiding this comment

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

LGTM just have to push and cherry the nil check referenced in the PR desc.

@klihub klihub force-pushed the devel/use-nil-as-nop-adjustment branch from a39f4c4 to 4eab409 Compare March 9, 2025 15:27
@klihub klihub force-pushed the devel/use-nil-as-nop-adjustment branch from 4eab409 to fd82b8b Compare August 27, 2025 15:12
Don't create an empty adjustment a priori. Only create once
a plugin makes an adjustment to the container being created.
In particular, this should result in a nil adjustment if no
plugin touches a container.

Signed-off-by: Krisztian Litkey <[email protected]>
@klihub klihub force-pushed the devel/use-nil-as-nop-adjustment branch from fd82b8b to 633857b Compare August 27, 2025 15:18
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.

3 participants