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

There is no need to call GetIPAMConfig multiple times during the AssignIP process #8747

Open
gongzixiangyuan opened this issue Apr 23, 2024 · 1 comment

Comments

@gongzixiangyuan
Copy link

gongzixiangyuan commented Apr 23, 2024

Expected Behavior

When CNI is called, the interaction with ApiServer should be minimized.

Current Behavior

cfg, err := c.GetIPAMConfig(ctx)

cfg, err = c.GetIPAMConfig(ctx)

Possible Solution

Can IPAMConfig be used as a property of ipamClient?

@caseydavenport
Copy link
Member

We do need to call GetIPAMConfig each time, as the configuration may have changed since the last call (or since the client was instantiated).

We could adjust so that we are instead watching IPAM config, to avoid the extra Get call.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants