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

Get latest vpc data from apiserver instead of cache #1684

Merged
merged 1 commit into from
Jul 14, 2022

Conversation

chestack
Copy link
Contributor

@chestack chestack commented Jul 12, 2022

Fixes #1683

low priority

@oilbeater
Copy link
Collaborator

status field cannot be created, should use UpdateStatus

@chestack
Copy link
Contributor Author

status field cannot be created, should use UpdateStatus

oopsie, thank you for pointing that out.

Maybe we don't need this change or

func (c *Controller) handleAddOrUpdateVpc(key string) error {
-	orivpc, err := c.vpcsLister.Get(key)
+	// get latest vpc info
+	orivpc, err := c.config.KubeOvnClient.KubeovnV1().Vpcs().Get(context.Background(), key, metav1.GetOptions{})

@chestack chestack changed the title Create default vpc with 'Status.Default = true' Get latest vpc data from apiserver instead of cache Jul 14, 2022
@oilbeater oilbeater added bug Something isn't working need backport labels Jul 14, 2022
@oilbeater
Copy link
Collaborator

Thanks! @chestack

@oilbeater oilbeater merged commit c4e91cb into kubeovn:master Jul 14, 2022
oilbeater pushed a commit that referenced this pull request Jul 14, 2022
oilbeater pushed a commit that referenced this pull request Jul 14, 2022
oilbeater pushed a commit that referenced this pull request Jul 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working need backport
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[discussion] get latest vpc data from k8s api instead of cache
2 participants