Move retry settings into settings record.

Also expose `setRetrySettings` to allow changing the default (which can
be overriden through the use of `retry` on a per request basis).