-
Notifications
You must be signed in to change notification settings - Fork 15
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
Supporting serde serialization and deserialization of encoder object #60
Comments
Hi! I think that would be pretty tricky on the full object: Line 150 in f31a4dd
You could theoretically grab the dictionary though. Can you describe more about |
Yeah, I was more so referring to errors in other sections of the application, specifically a long running application that does compression. I want to be able to recreate the state of the compressor even if the entire application crashes and I need to relaunch the binary. I suppose this is a good explanation of what I had in mind.
Do you think serde is even the right tool for this? Maybe making some of the attributes like the dictionary public and adding something to |
Making the dictionary accessible and also allowing a dict to be passed in do seem like the way to go for that. You may have to just dump the dictionary at some interval, but the Bytes crate has a serde feature, so that should all wire together okay. I don't think that I'm going to be able to implement this myself anytime soon, but would be totally open to PRs! I think you described the work already:
|
Okay, sounds great! I'll see what I can do. |
Hey, I'm not really sure how difficult this would be but would it be at all possible to make the
ParCompress<Zlib>
encoder support serialization?The use case for this is to allow for saving the encoder state using something like this to disk so that application errors can be recovered.
The text was updated successfully, but these errors were encountered: