You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, TimeoutLayer accepts a Duration parameter which specifies how long to wait before aborting a response. I'd like to customize this parameter on a per-request basis.
I'm envisioning this should be doable with a trait with one method; that method takes in a request and returns the Duration. We should be able to implement this trait for Duration itself so this won't be a breaking change.
The text was updated successfully, but these errors were encountered:
I like the idea, but to be clear, this is by definition a non-breaking change. E.g. in case someone was passing a type T as .into() it will no longer compile given the compiler wouldn't know to what concrete type you want to into it.
Another thought, if it's cheap for you to create or clone that portion of your service, you could inspect the request, and then clone your inner service and wrap it in a new Timeout layer and the basically oneshot.
Right now,
TimeoutLayer
accepts aDuration
parameter which specifies how long to wait before aborting a response. I'd like to customize this parameter on a per-request basis.I'm envisioning this should be doable with a trait with one method; that method takes in a request and returns the
Duration
. We should be able to implement this trait forDuration
itself so this won't be a breaking change.The text was updated successfully, but these errors were encountered: