On 12/5/24 1:59 PM, Felix Huettner wrote: > On Wed, Dec 04, 2024 at 02:18:31PM +0100, Dumitru Ceara wrote: >> On 12/3/24 3:58 PM, Felix Huettner via dev wrote: >>> The Route table will be used in the future to coordinate routing >>> information between northd and ovn-controller. >>> Northd will insert routes that should be advertised to the outside >>> fabric. >>> Ovn-controller will insert routes that have been learned from the >>> outside fabric. >>> >>> Signed-off-by: Felix Huettner <[email protected]> >>> --- >> >> Hi Felix, >> >> I have a few minor comments, otherwise, this looks ok to me. > > Hi Dimitru, > > thanks a lot for the review. > >> >>> ovn-sb.ovsschema | 29 ++++++++++++++++-- >>> ovn-sb.xml | 80 ++++++++++++++++++++++++++++++++++++++++++++++++ >>> 2 files changed, 107 insertions(+), 2 deletions(-) >>> >>> diff --git a/ovn-sb.ovsschema b/ovn-sb.ovsschema >>> index 73abf2c8d..76d32197d 100644 >>> --- a/ovn-sb.ovsschema >>> +++ b/ovn-sb.ovsschema >>> @@ -1,7 +1,7 @@ >>> { >>> "name": "OVN_Southbound", >>> - "version": "20.37.0", >>> - "cksum": "1950136776 31493", >>> + "version": "20.38.0", >>> + "cksum": "550338719 32889", >>> "tables": { >>> "SB_Global": { >>> "columns": { >>> @@ -617,6 +617,31 @@ >>> "type": {"key": "string", "value": "string", >>> "min": 0, "max": "unlimited"}}}, >>> "indexes": [["chassis"]], >>> + "isRoot": true}, >>> + "Route": { >>> + "columns": { >>> + "datapath": >>> + {"type": {"key": {"type": "uuid", >>> + "refTable": "Datapath_Binding"}}}, >>> + "logical_port": {"type": {"key": {"type": "uuid", >>> + "refTable": >>> "Port_Binding", >>> + "refType": "weak"}}}, >> >> It's probably fine to keep this as a strong reference, right? >> >>> + "ip_prefix": {"type": "string"}, >>> + "nexthop": {"type": "string"}, >>> + "tracked_port": {"type": {"key": {"type": "uuid", >>> + "refTable": >>> "Port_Binding", >>> + "refType": "weak"}, >> >> Same here, I guess. > > Yes, will both be changed in v3. > >> >>> + "min": 0, >>> + "max": 1}}, >>> + "type": {"type": {"key": {"type": "string", >>> + "enum": ["set", ["advertise", >>> + "receive"]]}, >>> + "min": 1, "max": 1}}, >>> + "external_ids": { >>> + "type": {"key": "string", "value": "string", >>> + "min": 0, "max": "unlimited"}}}, >>> + "indexes": [["datapath", "logical_port", "ip_prefix", >>> "nexthop", >>> + "type"]], >>> "isRoot": true} >> >> Do we really need this table to be root? > > As i understood the isRoot flag it keeps the records around even if > there is no incoming reference to any of the rows. As there are no > incoming references to the Route table at all we need this to be true. >
Ah, you're right about that. But shouldn't actually routes be referred by Datapath_Binding instead of routes pointing to Datapath_binding? Maybe that's a better schema definition? In that case isRoot can be false for the Routes table. It doesn't really make sense to have route records for routers that don't exist in the DB anymore. Thanks, Dumitru _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
