Conversation
dv/dv/insertion.go
Outdated
| } | ||
|
|
||
| pfx.Announce(prefix, faceId, cost, params.ValidityPeriod) | ||
| pfx.Announce(prefix, faceId, cost, cost == 1, params.ValidityPeriod) |
dv/dv/mgmt.go
Outdated
|
|
||
| dv.mutex.Lock() | ||
| dv.pfx.Announce(name, faceID, cost, validity) | ||
| dv.pfx.Announce(name, faceID, cost, cost == 1, validity) |
dv/dv/table_algo.go
Outdated
| // Rebuild the BIFT whenever the FIB changes so BIER forwarding paths | ||
| // are always consistent with the routing table. | ||
| if fw.IsBierEnabled() { | ||
| fw.Bift.BuildFromFibPet() |
There was a problem hiding this comment.
I thought BIFT is solely built from FIB? What you need PET for?
| } `json:"tables"` | ||
| } | ||
|
|
||
| // (AI GENERATED DESCRIPTION): Creates and returns a `Config` object pre‑populated with default settings for core parameters, face types, forwarding, management, and table options. |
There was a problem hiding this comment.
Why you delete those?
tianyuan129
left a comment
There was a problem hiding this comment.
Two additional things.
1/ I didn't catch where the BIFT is rebuilt on FIB changes?
2/ You should include sample BIER config in yanfd.sample.yaml
dv/dv/prefix.go
Outdated
| } | ||
|
|
||
| // AnnounceSync adds or updates a Sync group prefix marked for BIER multicast. | ||
| func (pfx *PrefixModule) AnnounceSync(name enc.Name, face uint64, cost uint64, validity *spec.ValidityPeriod) { |
There was a problem hiding this comment.
Having one Announce() is a lot simpler.
There was a problem hiding this comment.
Ok should we then overload the Announce() method with cost? This was originally implemented in the last commit as cost encoded multicast behavior previously. To my understanding, in Announce(), cost feeds into DV routing metric computation. In AnnounceSync(), cost only configures the local PET nexthop. BIER builds the BIFT independently from the FIB, so the prefix-level cost is irrelevant to multicast tree construction.
There was a problem hiding this comment.
You can have an additional parameter as the multicast flag.
| return | ||
| } | ||
|
|
||
| bfrId := params.Cost.GetOr(0) |
There was a problem hiding this comment.
I am fine with overloading the Cost field, but just a reminder that we do something hacky here.
No description provided.