On Thu, Apr 23, 2026 at 03:25:07PM +0200, Dumitru Ceara wrote: > On 4/21/26 12:14 PM, Mairtin O'Loingsigh via dev wrote: > > Add transit switch port to ovn-ic-nb schema. > > > > Signed-off-by: Mairtin O'Loingsigh <[email protected]> > > --- > > Hi Mairtin, > > Thanks for the patch! > > > ovn-ic-nb.ovsschema | 24 +++++++++++++++++++++++- > > ovn-ic-nb.xml | 42 ++++++++++++++++++++++++++++++++++++++++++ > > 2 files changed, 65 insertions(+), 1 deletion(-) > > > > diff --git a/ovn-ic-nb.ovsschema b/ovn-ic-nb.ovsschema > > index ca67a2fa9..b8db603b0 100644 > > --- a/ovn-ic-nb.ovsschema > > +++ b/ovn-ic-nb.ovsschema > > @@ -1,7 +1,7 @@ > > { > > "name": "OVN_IC_Northbound", > > "version": "1.3.0", > > We need to bump the y value in the x.y.z version when we add new > tables/columns. Ack > > > - "cksum": "1918565391 5082", > > + "cksum": "2501001826 6175", > > "tables": { > > "IC_NB_Global": { > > "columns": { > > @@ -24,9 +24,31 @@ > > "min": 0, "max": "unlimited"}}}, > > "maxRows": 1, > > "isRoot": true}, > > + "Transit_Switch_Port": { > > + "columns": { > > + "name": {"type": "string"}, > > + "other_config": { > > + "type": {"key": "string", "value": "string", > > + "min": 0, "max": "unlimited"}}, > > + "type": {"type": "string"}, > > + "chassis": {"type": "string"}, > > + "option": {"type": "string"}, > > This looks a bit weird, only a single string value option? > > > + "addresses": {"type": {"key": "string", > > + "min": 0, > > + "max": "unlimited"}}, > > + "ts_uuid": {"type": {"key": {"type": "uuid"}, > > + "min": 1, > > + "max": 1}}}, > > Why do we need this reference back to the transit switch? I guess only > for the helpers in ovn-ic-nbctl but you could do what we do in ovn-nbctl > for logical switch ports, i.e.: > Ack, ill remove the ts uuid. > /* Returns the logical switch that contains 'lsp'. */ > static char * OVS_WARN_UNUSED_RESULT > lsp_to_ls(struct ctl_context *ctx, > const struct nbrec_logical_switch_port *lsp, > const struct nbrec_logical_switch **ls_p) > { > struct nbctl_context *nbctx = nbctl_context_get(ctx); > const struct nbrec_logical_switch *ls; > *ls_p = NULL; > > ls = shash_find_data(&nbctx->lsp_to_ls_map, lsp->name); > if (ls) { > *ls_p = ls; > return NULL; > } > /* Can't happen because of the database schema */ > return xasprintf("logical port %s is not part of any logical switch", > lsp->name); > } > > > + "isRoot": false, > > + "indexes": [["name"]]}, > > "Transit_Switch": { > > "columns": { > > "name": {"type": "string"}, > > + "ports": {"type": {"key": {"type": "uuid", > > + "refTable": > > "Transit_Switch_Port", > > + "refType": "strong"}, > > + "min": 0, > > + "max": "unlimited"}}, > > "other_config": { > > "type": {"key": "string", "value": "string", > > "min": 0, "max": "unlimited"}}, > > diff --git a/ovn-ic-nb.xml b/ovn-ic-nb.xml > > index a3a35baf2..5eaf55332 100644 > > --- a/ovn-ic-nb.xml > > +++ b/ovn-ic-nb.xml > > @@ -112,6 +112,10 @@ > > </column> > > </group> > > > > + <column name="ports"> > > + The router's ports. > > Switch ports maybe? Ack > > > + </column> > > + > > <group title="Common Columns"> > > <column name="other_config"/> > > <column name="external_ids"> > > @@ -190,6 +194,44 @@ > > </group> > > </table> > > > > + <table name="Transit_Switch_Port" title="Transit logical switch port"> > > + <p> > > + Each row represents one transit logical switch port for > > interconnection > > + between different OVN deployments (availability zones). > > + </p> > > + > > + <group title="Naming"> > > + <column name="name"> > > + A name that uniquely identifies the transit logical switch port. > > + </column> > > + </group> > > + > > + <column name="type"> > > + Specify if the port if of type router or vif. > > + </column> > > + > > + <column name="chassis"> > > + The chassis this switch port should be bound to. > > + </column> > > + > > + <column name="option"> > > + Contains peer name or network information depending on port type. > > I think we should have an explicit peer column. What's the "network > information" that we'd store here otherwise? Agreed. Ill replace option with peer here. > > > + </column> > > + > > + <column name="addresses"> > > + Addresses to assign to port. > > + </column> > > + > > + <column name="ts_uuid"> > > + This is the UUID of the northbound IC logical datapath this port is > > + associated with. > > + </column> > > + > > + <group title="Common Columns"> > > + <column name="other_config"/> > > + </group> > > + </table> > > + > > <table name="SSL"> > > SSL/TLS configuration for ovn-nb database access. > > > > Regards, > Dumitru >
Thanks for the review Dumitru. Regards, Mairtin _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
