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

itopo.TopologyHandler endpoint broken in non-core AS #3745

Closed
matzf opened this issue May 5, 2020 · 0 comments · Fixed by #3746
Closed

itopo.TopologyHandler endpoint broken in non-core AS #3745

matzf opened this issue May 5, 2020 · 0 comments · Fixed by #3746

Comments

@matzf
Copy link
Contributor

matzf commented May 5, 2020

The /topology HTTP endpoint on CS, SD and BR, implemented in lib/infra/modules/itopo.TopologyHandler, appears to be broken. This works in core ASes, but fails and returns empty content in non-core ASes. The (hidden) error is json: error calling MarshalJSON for type trc.Attributes: invalid attributes size len="0".

If I understand right, the itopo.TopologyHandler tries to json-ize the RWTopology object and fails due to the length check in trc.Attributes (as alluded to in topology/json).

oncilla added a commit to oncilla/scion that referenced this issue May 5, 2020
Change the `Attributes` field type to []trc.Attribute in order to
allow marshalling the RWTopology for non-primary ASes.

fixes scionproto#3745
oncilla added a commit to oncilla/scion that referenced this issue May 8, 2020
Change the `Attributes` field type to []trc.Attribute in order to
allow marshalling the RWTopology for non-primary ASes.

fixes scionproto#3745
oncilla added a commit that referenced this issue May 8, 2020
Change the `Attributes` field type to []trc.Attribute in order to
allow marshalling the RWTopology for non-primary ASes.

fixes #3745
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 a pull request may close this issue.

1 participant