vocdoni/multirpc

router handlers/endpoints should include a context

Opened this issue · 5 comments

mvdan commented

So that the context can be cancelled when a client disconnects, or so that an entire router can have a default timeout for all requests to avoid leaking goroutines or DoS attacks with clients keeping connections open for hours.

p4u commented

Yes, that makes sense and we should do it ASAP. Is it fine if I assign it to you? Else it might be done also by @jordipainan or myself.

mvdan commented

Sure - I think we should do it at the same time as reviewing the interfaces. Do you prefer if I propose changes directly as a PR, or if I explain the changes I want to make in written text or on a call?

p4u commented

Well, if they are not very structural changes a PR would be the best. If you want to discuss some general design, then lets talk :)

mvdan commented

Yep, I do mean structural changes, mainly on the interfaces :)

p4u commented

Ok, so lets arrange a meeting.