-
Notifications
You must be signed in to change notification settings - Fork 229
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
Use BgpSessionProperties IPs instead peers' local IPs #3917
Conversation
These IPs are nonnull; local IP in peer config can be null.
Codecov Report
@@ Coverage Diff @@
## master #3917 +/- ##
============================================
- Coverage 74.87% 74.82% -0.05%
+ Complexity 24061 24043 -18
============================================
Files 2027 2027
Lines 96681 96622 -59
Branches 11496 11492 -4
============================================
- Hits 72390 72301 -89
- Misses 19034 19063 +29
- Partials 5257 5258 +1
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 2 files at r1, 1 of 1 files at r2.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @corinaminer)
projects/question/src/main/java/org/batfish/question/VIModelQuestionPlugin.java, line 238 at r2 (raw file):
if (bgpPeerConfig != null && remoteBgpPeerConfig != null) { Ip localIp = sessionProperties.getTailIp();
isn't head the local IP?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @progwriter)
projects/question/src/main/java/org/batfish/question/VIModelQuestionPlugin.java, line 238 at r2 (raw file):
Previously, progwriter (Victor Heorhiadi) wrote…
isn't head the local IP?
i don't think so... i believe bgpTopology.edgeValue(id1, id2)
gives the session where id1
is local and id2
is remote, so the local IP should be the tail, right?
If this were wrong, the test should surface the issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @progwriter)
projects/question/src/main/java/org/batfish/question/VIModelQuestionPlugin.java, line 238 at r2 (raw file):
Previously, corinaminer (Corina Miner) wrote…
i don't think so... i believe
bgpTopology.edgeValue(id1, id2)
gives the session whereid1
is local andid2
is remote, so the local IP should be the tail, right?If this were wrong, the test should surface the issue.
actually the test wouldn't have surfaced the issue before, but now it should.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 2 of 2 files at r3.
Reviewable status: complete! all files reviewed, all discussions resolved
projects/question/src/main/java/org/batfish/question/VIModelQuestionPlugin.java, line 238 at r2 (raw file):
Previously, corinaminer (Corina Miner) wrote…
actually the test wouldn't have surfaced the issue before, but now it should.
Ah, I'm just in bdp-queue-mode.
The head and tail IPs in
BgpSessionProperties
are guaranteed to be nonnull, whereas BGP peer config IDs can have null local IPs even if they have edges in the BGP topology.Separation of
getBgpEdges()
methods is solely for easier testing and should not affect functionality.