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

all MGNP frames should include a version #26

Open
hawkw opened this issue Nov 11, 2023 · 1 comment
Open

all MGNP frames should include a version #26

hawkw opened this issue Nov 11, 2023 · 1 comment
Labels
enhancement New feature or request
Milestone

Comments

@hawkw
Copy link
Contributor

hawkw commented Nov 11, 2023

currently, MGNP lacks any kind of provision for versioning wire frames. this will be an issue if we want to stabilize the wire format in the future.

we should consider adding a version identifier to wire messages now. we could do this either by adding an integer version to the frame header, or by wrapping the entire frame in a

#[derive(Serialize, Deserialize)]
#[non_exhaustive]
pub enum Version {
   V1(Frame),
}
@hawkw hawkw added the enhancement New feature or request label Nov 11, 2023
@hawkw hawkw added this to the MGNP v0.1 milestone Nov 11, 2023
@hawkw
Copy link
Contributor Author

hawkw commented Nov 11, 2023

IMHO the enum is probably the Right Thing, especially because we can then just remove #[non_exhaustive] from most of the other enums. but i think @jamesmunns has opinions on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant