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

cannot GetSnapshot or CloneSnapshot for GenericSnapshot #461

Open
kdorosh opened this issue Mar 29, 2022 · 2 comments
Open

cannot GetSnapshot or CloneSnapshot for GenericSnapshot #461

kdorosh opened this issue Mar 29, 2022 · 2 comments

Comments

@kdorosh
Copy link
Contributor

kdorosh commented Mar 29, 2022

this line of code always throws an interface panic https://github.com/solo-io/solo-kit/blob/v0.24.2/pkg/api/v1/control-plane/cache/generic_snapshot.go#L134

we need to fix it so we can test / validate generic snapshot marshalling

resolving this will require updates to the base Resource interface and perhaps sweeping changes across codegen

@kdorosh
Copy link
Contributor Author

kdorosh commented Apr 8, 2022

also highly relevant to this part of the code https://bryanftan.medium.com/accept-interfaces-return-structs-in-go-d4cab29a301b

@kdorosh kdorosh removed their assignment Apr 13, 2022
@kdorosh
Copy link
Contributor Author

kdorosh commented Apr 13, 2022

this codepath is never currently called hence why it has not been an issue, but if we ever start getting snapshots in the ratelimit or extauth translator syncers then this code will panic

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

No branches or pull requests

1 participant