Add Producer.retry

This implementation allows API consumers the choice of retry strategy without being overly burdensome.

Resolves #1046.
I personally gravitate towards using closures internal to the definition of the `public` API instead of `public`/`private` pairs like this; I wonder if that’s a subject for the style guide?