Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fredericvauchelles/serde-version
Versioning support for serde
https://github.com/fredericvauchelles/serde-version
deserialization serde versioning
Last synced: about 12 hours ago
JSON representation
Versioning support for serde
- Host: GitHub
- URL: https://github.com/fredericvauchelles/serde-version
- Owner: fredericvauchelles
- License: apache-2.0
- Created: 2019-09-06T19:28:55.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-07-29T13:34:13.000Z (4 months ago)
- Last Synced: 2024-11-14T13:12:12.916Z (6 days ago)
- Topics: deserialization, serde, versioning
- Language: Rust
- Size: 136 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
# Serde version [![Build Status]][travis] [![Latest Version]][crates.io]
[Build Status]: https://travis-ci.org/fredericvauchelles/serde-version.svg?branch=master
[travis]: https://travis-ci.org/fredericvauchelles/serde-version
[Latest Version]: https://img.shields.io/crates/v/serde-version.svg
[crates.io]: https://crates.io/crates/serde-version
# Serde versionVersioning support for serde.
When software are developped and used at the same time the data formats may change
from one version to another and persisting data may be produced by a specific version
and loaded by another version.Serde version provide a versioning feature for serde for the main use cases.
See the guide [here](https://fredericvauchelles.github.io/crates/serde-version/).
Note 1: Requires the specialization feature.
Note 2: Use the `derive` feature to generate the `DeserializeVersioned` implementation## Goals of Serde version
We aim at solving the case were a type or a set of types in a deserializer's
data needs to be upgraded to their latest format.
This is the case when a mandatory property was added or removed,
or an existing property changed.## Non goals
This is based on types that can be upgraded individually.
Types that needs to be upgraded together is way more complex to handle
and usually relies on domain specific deserializer.So, these data format should be handle with specific `Deserialize` traits implementations.