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

sbctl chassis operation replace with libovsdb #3119

Merged
merged 28 commits into from
Aug 17, 2023

Conversation

zbb88888
Copy link
Collaborator

@zbb88888 zbb88888 commented Aug 7, 2023

What type of this PR

Examples of user facing changes:

  • Features
    sbctl need replaced with libovsdb #3106

  • 基于 kube-ovn 目前在用 ovn 导出 sb shcema 并生成 sb db model

  • 将 sbctl 替换为 libovsdb 来操作 chassis

  • 去除 之前用于sbctl 过滤用的 external ids 冗余 node tag

  • 简化一些判断冲突 chassis 清理的逻辑

  • kube-ovn-controller 区分 nbclient 以及 sb client

WHAT

🤖 Generated by Copilot at ad1dfb0

No summary available (Limit exceeded: required to process 73498 tokens, but only 50000 are allowed per call)

🤖 Generated by Copilot at 2d5e395

To work with the OVN northbound
We used to have ovnClient around
But now we've refactored
And ovnNbClient captured
The logic for that database's sound

HOW

🤖 Generated by Copilot at ad1dfb0

No walkthrough available (Limit exceeded: required to process 73498 tokens, but only 50000 are allowed per call)

@zbb88888 zbb88888 changed the title Libovsdb sbctl chassis operation replace with libovsdb Aug 7, 2023
pkg/ovsdb/client/client.go Fixed Show resolved Hide resolved
@zbb88888 zbb88888 marked this pull request as ready for review August 9, 2023 02:18
@zbb88888 zbb88888 requested a review from oilbeater August 11, 2023 01:02
@oilbeater oilbeater requested a review from zhangzujian August 11, 2023 01:11
pkg/ovs/ovn-sbctl.go Outdated Show resolved Hide resolved
Co-authored-by: 张祖建 <zhangzujian.7@gmail.com>
@zhangzujian
Copy link
Member

Which version of the ovn sb schema did you use to generate the Model types?

pkg/ovs/ovn.go Outdated Show resolved Hide resolved
@zhangzujian
Copy link
Member

NewLegacyClient() defined in pkg/ovs/ovn.go should be updated.

@zbb88888
Copy link
Collaborator Author

Which version of the ovn sb schema did you use to generate the Model types?

the version is kube-ovn master is using now. i export the schema from kube-ovn-cni pod

@zbb88888
Copy link
Collaborator Author

zbb88888 commented Aug 11, 2023

NewLegacyClient() defined in pkg/ovs/ovn.go should be updated.

已移除 sb 在 NewLegacyClient 中的字段

@zbb88888 zbb88888 requested a review from zhangzujian August 14, 2023 01:16
pkg/ovs/ovn.go Outdated Show resolved Hide resolved
@zbb88888 zbb88888 requested a review from zhangzujian August 16, 2023 03:15
Signed-off-by: bobz965 <zhangbingbing2_yewu@cmss.chinamobile.com>
pkg/ovs/ovn.go Outdated Show resolved Hide resolved
Co-authored-by: 张祖建 <zhangzujian.7@gmail.com>
@zhangzujian
Copy link
Member

These fields defined in struct LegacyClient should be removed:

	ClusterRouter                 string
	ClusterTcpLoadBalancer        string
	ClusterUdpLoadBalancer        string
	ClusterTcpSessionLoadBalancer string
	ClusterUdpSessionLoadBalancer string
	NodeSwitch                    string
	NodeSwitchCIDR                string
	Version                       string

Signed-off-by: bobz965 <zhangbingbing2_yewu@cmss.chinamobile.com>
@zhangzujian zhangzujian added the performance Anything that can make Kube-OVN faster label Aug 17, 2023
@zbb88888 zbb88888 merged commit bcbae34 into kubeovn:master Aug 17, 2023
@zbb88888 zbb88888 deleted the libovsdb branch August 17, 2023 07:09
zbb88888 added a commit that referenced this pull request Aug 17, 2023
* add ovnsb mod

* ovn 层名统一复用用底层 ovs client 命名

* kube-ovn-controller 需要使用 sb nb client, 所以调整命名

* replace sbctl operate chassis

Signed-off-by: bobz965 <zhangbingbing2_yewu@cmss.chinamobile.com>
Co-authored-by: 张祖建 <zhangzujian.7@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Anything that can make Kube-OVN faster
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants