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

Fix inconsistencies on example topologies and add backward compatibility to Port.vlan_range #141

Merged
merged 2 commits into from
Aug 12, 2024

Conversation

italovalcy
Copy link
Contributor

Related to atlanticwave-sdx/pce#200

Description of the change

This pull request fix a few inconsistencies on the example topologies (amlight.json, sax.json and sdx.json). Most of the inconsistencies consist of:

  • wrong name/URL of the OXP (amlight -> amlight.net -- correct in some places, wrong in others)
  • wrong URN definition on some Port.node attributes (ex: node": "urn:sdx:port:sax:B1", -> "node": "urn:sdx:node:sax:B1")
  • wrong definition of the Port.node attribute (ex: "node": "A1:2" -> "node": "urn:sdx:node:zaoxi:A1",)

Because of those errors, the breakdowns failed to be computed, as well as VLAN reservations and other cases.

Additionally, I've also added backward compatibility for Port.vlan_range on Topology v1: if the vlan_range is not defined on the port but label_range is, PortHandler will leverage the former.

@coveralls
Copy link

Pull Request Test Coverage Report for Build 10331104302

Details

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.03%) to 80.545%

Totals Coverage Status
Change from base Build 10324380079: 0.03%
Covered Lines: 1349
Relevant Lines: 1656

💛 - Coveralls

Copy link
Member

@sajith sajith left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you!

@sajith
Copy link
Member

sajith commented Aug 12, 2024

@italovalcy Actually, on second thoughts, there are some *_v2.json files under src/sdx_datamodel/data/topologies: ampath_v2.json, sax_v2.json, and zaoxi_v2.json. Going forward, I believe those are the ones that we should be using, because they are the ones that are supposed to conform to datamodel v2 spec. Would you be able to check those for inconsistencies? I tried using them in pce tests but could not make much progress. Perhaps you will have better ideas.

I am also unsure if we should keep the old topology files around. They are likely to cause confusion.

@italovalcy
Copy link
Contributor Author

@italovalcy Actually, on second thoughts, there are some *_v2.json files under src/sdx_datamodel/data/topologies: ampath_v2.json, sax_v2.json, and zaoxi_v2.json. Going forward, I believe those are the ones that we should be using, because they are the ones that are supposed to conform to datamodel v2 spec. Would you be able to check those for inconsistencies? I tried using them in pce tests but could not make much progress. Perhaps you will have better ideas.

I am also unsure if we should keep the old topology files around. They are likely to cause confusion.

Good point, @sajith ! I've opened issue #142 for us to handle that. Thanks for your review!

@italovalcy italovalcy merged commit 0d6cbdf into main Aug 12, 2024
11 checks passed
@italovalcy italovalcy deleted the fix/issue_pce_200 branch August 12, 2024 11:06
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.

3 participants