Finomnis/tokio-graceful-shutdown

Make errors types adjustable

Closed this issue · 4 comments

Currently everything is a Box<dyn Error>, but as default template arguments for classes exist, we might make that a template argument with the default to Box<dyn Error>.

Reasoning is that this simplifies passing errors from subsystems to this crate and back to the user again, without the user having to resort to weird runtime matching to get the original error type back.

This was a suggestion by @TheButlah in #13.

@TheButlah what's your opinion about this?

Released as 0.8.0-beta.0.
Feedback appreciated.

Released as 0.8.0