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
Frr max med administrative #6086
Frr max med administrative #6086
Conversation
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 7 of 7 files at r1.
Reviewable status: all files reviewed, 4 unresolved discussions (waiting on @kylehoferamzn)
a discussion (no related file):
please add conversion test as well
projects/batfish/src/main/antlr4/org/batfish/grammar/cumulus_frr/CumulusFrr_bgp.g4, line 356 at r1 (raw file):
; max_med_administrative_value
This isn't used, I think you can remove.
projects/batfish/src/main/java/org/batfish/grammar/cumulus_frr/CumulusFrrConfigurationBuilder.java, line 759 at r1 (raw file):
public void exitSbb_max_med_administrative(Sbb_max_med_administrativeContext ctx) { if (ctx.med != null) _currentBgpVrf.setMaxMedAdministrative(Long.parseLong(ctx.med.getText())); else _currentBgpVrf.setMaxMedAdministrative(4294967294L);
what's the magic value? please pull out in to named constant.
projects/batfish/src/main/java/org/batfish/representation/cumulus/CumulusConversions.java, line 756 at r1 (raw file):
private static List<Statement> getAcceptStatements(BgpNeighbor neighbor, BgpVrf bgpVrf) { ArrayList<Statement> acceptStatements = new ArrayList<>();
prefer ImmutableList.builder()
to which you can add
conditionally, then just return builder.build()
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)
a discussion (no related file):
Previously, progwriter (Victor Heorhiadi) wrote…
please add conversion test as well
Were you looking for something more than testGetSetMaxMedMetric?
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 4 of 4 files at r2.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @kylehoferamzn)
a discussion (no related file):
Previously, kylehoferamzn wrote…
Were you looking for something more than testGetSetMaxMedMetric?
thats a good start, but what's missing is a check that the statement actually makes it to peer's export policy
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: 3 of 7 files reviewed, 1 unresolved discussion (waiting on @progwriter)
a discussion (no related file):
Previously, progwriter (Victor Heorhiadi) wrote…
thats a good start, but what's missing is a check that the statement actually makes it to peer's export policy
Good call, added that in.
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 4 of 4 files at r3.
Reviewable status: complete! all files reviewed, all discussions resolved
Codecov Report
@@ Coverage Diff @@
## master #6086 +/- ##
============================================
+ Coverage 72.51% 72.67% +0.15%
- Complexity 34575 34625 +50
============================================
Files 2816 2815 -1
Lines 141407 141276 -131
Branches 16989 16965 -24
============================================
+ Hits 102548 102676 +128
+ Misses 30946 30436 -510
- Partials 7913 8164 +251 |
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 r4.
Reviewable status: complete! all files reviewed, all discussions resolved
No description provided.