Skip to content

Replace Bincode with Postcard#540

Merged
ranile merged 1 commit into
masterfrom
replace-bincode
Mar 27, 2026
Merged

Replace Bincode with Postcard#540
ranile merged 1 commit into
masterfrom
replace-bincode

Conversation

@ranile

@ranile ranile commented Mar 26, 2026

Copy link
Copy Markdown
Owner

Postcard was chosen because it is recommended by the bincode current readme and uses serde instead of custom serialization/deserialization protocol

fixes #529

The breakage is removing the public Bincode type. Anyone who explicitly wrote:

use gloo_worker::Bincode;
WorkerSpawner<MyWorker, Bincode>

will get a compile error. But in practice, I think nobody does this.

The whole point of the CODEC = Bincode default type parameter is that users never name it.

@ranile ranile requested a review from Madoshakalaka March 26, 2026 11:13
Comment thread CHANGELOG.md

### Version 0.7.0

- **BREAKING:** Replace `Bincode` with `Postcard` (#540) by @ranile

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

The breakage is removing the public Bincode type. Anyone who explicitly wrote:

use gloo_worker::Bincode;
WorkerSpawner<MyWorker, Bincode>

will get a compile error. But in practice, I think nobody does this.

The whole point of the CODEC = Bincode default type parameter is that users never name it.

I think it's worth mentioning.

@ranile ranile Mar 27, 2026

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, I'll edit the PR description so anyone following the changelog can see it and include it in commit too

@ranile ranile merged commit 6eb2631 into master Mar 27, 2026
20 checks passed
@Madoshakalaka

Copy link
Copy Markdown
Collaborator

Need to edit the version of the root gloo crate in the CHANGELOG to 0.13.0 now though

@ranile

ranile commented Mar 27, 2026

Copy link
Copy Markdown
Owner Author

Need to edit the version of the root gloo crate in the CHANGELOG to 0.13.0 now though

I'll just let the tool from #542 re-generate it

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 this pull request may close these issues.

Bincode is unmaintained

2 participants