Skip to content
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

Parse eigrp stub #6275

Merged
merged 4 commits into from
Oct 5, 2020
Merged

Parse eigrp stub #6275

merged 4 commits into from
Oct 5, 2020

Conversation

ratulm
Copy link
Member

@ratulm ratulm commented Oct 3, 2020

Fixes #6236

@batfish-bot
Copy link

This change is Reviewable

@codecov
Copy link

codecov bot commented Oct 3, 2020

Codecov Report

Merging #6275 into master will decrease coverage by 0.01%.
The diff coverage is 71.42%.

@@             Coverage Diff              @@
##             master    #6275      +/-   ##
============================================
- Coverage     72.92%   72.90%   -0.02%     
+ Complexity    35028    35021       -7     
============================================
  Files          2832     2832              
  Lines        142317   142326       +9     
  Branches      17090    17090              
============================================
- Hits         103782   103763      -19     
- Misses        30311    30330      +19     
- Partials       8224     8233       +9     
Impacted Files Coverage Δ Complexity Δ
...tfish/representation/cisco/CiscoConfiguration.java 85.87% <ø> (-0.14%) 492.00 <0.00> (-1.00)
...fish/grammar/cisco/CiscoControlPlaneExtractor.java 65.36% <69.23%> (-0.03%) 1206.00 <2.00> (+2.00) ⬇️
...fish/representation/cisco/CiscoStructureUsage.java 100.00% <100.00%> (ø) 3.00 <0.00> (ø)
...rg/batfish/identifiers/StorageBasedIdResolver.java 85.29% <0.00%> (-5.89%) 22.00% <0.00%> (ø%)
.../org/batfish/dataplane/rib/RouteAdvertisement.java 83.67% <0.00%> (-4.09%) 18.00% <0.00%> (-1.00%)
...c/main/java/org/batfish/dataplane/rib/RibTree.java 88.33% <0.00%> (-1.67%) 28.00% <0.00%> (-1.00%)
...col/src/main/java/org/batfish/role/InferRoles.java 89.54% <0.00%> (-1.37%) 50.00% <0.00%> (-1.00%)
...src/main/java/org/batfish/coordinator/PoolMgr.java 59.25% <0.00%> (-1.24%) 15.00% <0.00%> (-1.00%)
...ain/java/org/batfish/storage/FileBasedStorage.java 86.42% <0.00%> (-0.95%) 250.00% <0.00%> (ø%)
...java/org/batfish/dataplane/ibdp/VirtualRouter.java 90.47% <0.00%> (-0.33%) 208.00% <0.00%> (-1.00%)
... and 3 more

Copy link
Member

@dhalperi dhalperi left a 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, 1 unresolved discussion (waiting on @arifogel and @ratulm)


projects/batfish/src/main/antlr4/org/batfish/grammar/cisco/Cisco_eigrp.g4, line 175 at r1 (raw file):

;

re_eigrp_stub

not a blocker, but better to write like an LL1 parser:

  • create re_eigrp
  • (really opt: move re_rigrp_null inside of it, dropping the no?)
  • create re_eigrp_stub (or ree_stub?)
  • create rees_null and rees_leak_map

and only do the leak_map handling inside of leak_map.

This both makes the parser more efficient, the grammar easier to read, and the extraction code simpler

Copy link
Member Author

@ratulm ratulm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: 5 of 8 files reviewed, all discussions resolved (waiting on @arifogel and @dhalperi)


projects/batfish/src/main/antlr4/org/batfish/grammar/cisco/Cisco_eigrp.g4, line 175 at r1 (raw file):

Previously, dhalperi (Dan Halperin) wrote…

not a blocker, but better to write like an LL1 parser:

  • create re_eigrp
  • (really opt: move re_rigrp_null inside of it, dropping the no?)
  • create re_eigrp_stub (or ree_stub?)
  • create rees_null and rees_leak_map

and only do the leak_map handling inside of leak_map.

This both makes the parser more efficient, the grammar easier to read, and the extraction code simpler

done. left re_eigrp_router_id alone as its leading 'no' is being processed in the extractor.

Copy link
Member

@dhalperi dhalperi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 3 of 3 files at r2.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @arifogel)

@dhalperi dhalperi merged commit b100939 into master Oct 5, 2020
@dhalperi dhalperi deleted the parse-eigrp-stub branch October 5, 2020 01:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cisco IOS EIGRP stub leak-map not recognized
3 participants