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

Implement Versioned Deserialize #643

Open
nomaxg opened this issue Jun 12, 2024 · 0 comments
Open

Implement Versioned Deserialize #643

nomaxg opened this issue Jun 12, 2024 · 0 comments

Comments

@nomaxg
Copy link
Contributor

nomaxg commented Jun 12, 2024

The query data types (LeafQueryData, BlockQueryData, etc) need to implement Deserialize to work nicely with surf-disco. I would suggest adding a version field to each of these as the first field (again, we can always pull this version from the database whenever we need to construct one of these) and manually implementing deserialize to first read the version, then the remaining fields, using Deserialize for normal fields and DeserializeForVersion for HotShot types.

This manual deserialize implementation might be pretty verbose and repetitive, so ideally we could find some way to do it with serde attributes or potentially write our own macro

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant