bufbuild / httplb

Client-side load balancing for net/http
https://pkg.go.dev/github.com/bufbuild/httplb
Apache License 2.0
48 stars 2 forks source link

Preliminary support for testing code using timers with Clockwork #28

Closed jchadwick-buf closed 1 year ago

jchadwick-buf commented 1 year ago

This includes:

I think it's probably good if we don't expose this abstraction directly to users, as it would expose a lot of API surface/implementation details, even though it would be useful for their testing (of code using this package), but it might be worth thinking about anyways.

jchadwick-buf commented 1 year ago

(GitHub still doesn't have anything like Gerrit "attention" so I'm using the re-request review function as a facsimile. Please do let me know if that is annoying. Maybe there's a better way to handle this?)

jhump commented 1 year ago

(GitHub still doesn't have anything like Gerrit "attention" so I'm using the re-request review function as a facsimile. Please do let me know if that is annoying. Maybe there's a better way to handle this?)

Not annoying at all! I think that's actually the expected workflow.

jchadwick-buf commented 1 year ago

I did most of the internal reorganization stuff (and unexported ClockworkFakeClock), not clear if the MurmurHash stuff should be moved or not. Either way, thanks. Seems to be working well so I'll go ahead and merge.