my first shot
now it works
Integrated failure action.

Also improved the timespan support.
Defaulting to ms for backward compatibility.