tidwall / redcon

Redis compatible server framework for Go
MIT License
2.16k stars 159 forks source link

Support for context.Context #51

Open nathanhack opened 2 years ago

nathanhack commented 2 years ago

It would be great if there was support for context.Context. So that I could capture os.Signals and kill the server in a nice way.

nathanhack commented 2 years ago

I have added in my fork https://github.com/nathanhack/redcon I directly added context, making it not backwards compatible with v1. Would a PR be something you're interested in (I would expect you would have some feedback on matching your style and backwards compatibility)?

nathanhack commented 2 years ago

I added a PR https://github.com/tidwall/redcon/pull/52 for this issue

hiqsociety commented 1 year ago

@nathanhack can u help add context and pub/sub to redhub? https://github.com/IceFireDB/redhub thx in advance! can i buy u a coffee for doing so pls? hope to see it in production