Skip to content

Initialize NexthopCache for OSS next-hop tracking - #17

Draft
selekkala wants to merge 1 commit into
meta:mainfrom
selekkala:fix/oss-next-hop-tracking-init
Draft

selekkala wants to merge 1 commit into
meta:mainfrom
selekkala:fix/oss-next-hop-tracking-init

Conversation

@selekkala

@selekkala selekkala commented Nov 3, 2026 •

Copy link
Copy Markdown

Summary

When enable_next_hop_tracking is enabled in the DC/OSS daemon, MainOSS previously passed a null NexthopCache to RibDC. The RIB later dereferenced that cache while processing a route update and aborted.

This change:

  • creates the cache only when next-hop tracking is enabled;
  • wires connected-neighbor and FIB host-route tracking through NeighborWatcher;
  • registers configured static BGP peer addresses before the shared FSDB subscription starts; and
  • passes the cache and watcher into RibDC so RIB-IN nexthops are subscribed for tracking.

The existing startup path remains unchanged when next-hop tracking is disabled.

Test plan

  • git diff --check
  • Attempted the documented DC build with getdeps.py; the host requires sudo for dependency installation, and the non-root retry is missing the gcc12 system-package metadata.
  • Existing NeighborWatcherFibTest coverage exercises creation and shutdown of the FIB watcher with next-hop tracking enabled.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant