nesquena / backburner

Simple and reliable beanstalkd job queue for ruby
http://nesquena.github.com/backburner
MIT License
428 stars 68 forks source link

Add support for custom serialization formats #132

Closed eltone closed 7 years ago

eltone commented 7 years ago

By supporting configurable serialization and deserialization procs, we can allow users to format job bodies as they wish. Defaults to JSON for compatibility.

contentfree commented 7 years ago

Thanks. Looks good to me. @nesquena?

eltone commented 7 years ago

Hmm, I actually think this needs more work, jobs are enqueued with hash keys as sybols but are read with keys as strings. This is fine for JSON but would not work for binary formats like MessagePack. Will revisit tomorrow with a small change to Job.

nesquena commented 7 years ago

Agreed, I like where this is going, thanks for adding this. Once you have a chance to run through it and you think it's ready for merge let us know. We can do a preview release

nesquena commented 7 years ago

Also when you get a chance, can you add these options to the README with an example of how to override

eltone commented 7 years ago

This should now be good to merge.

nesquena commented 7 years ago

Looks good to me, thanks @eltone