add support for Long and Duration conversions

In my experience, configuring timeouts happens a lot, but without ability to inject it directly from configuration it is harder to read.

This PR adds support for wiring Long and Duration; also, it switches the catch to the recommended `NonFatal` control.