generic websocket consumer for one or more event streams from knots
Signed-off-by: oppiliappan me@oppi.li
generic websocket consumer for one or more event streams from knots
Signed-off-by: oppiliappan me@oppi.li
generic websocket consumer for one or more event streams from knots
Signed-off-by: oppiliappan <me@oppi.li>
generic websocket consumer for one or more event streams from knots
Signed-off-by: oppiliappan <me@oppi.li>
generic websocket consumer for one or more event streams from knots
Signed-off-by: oppiliappan <me@oppi.li>
Nice, mostly OK. Some points to improve on:
let's not embed the context in the struct; https://go.dev/blog/context-and-structs is a good read for idiomatic context use. Essentially,
Start(ctx context.Context)is best, and the caller can decide how they want to handle cancellation. Consequently this context is then passed down toc.worker,c.runConnectionetc.perhaps we can make
EventConsumer.jobQueuesize configurable? With a default set to 100, maybe.Rest looks good!