Avoid broken net-http-persistent v2.9.2/3

Broken by drbrain/net-http-persistent#56
Allow jruby-XYmode failures on Travis due to RVM bug

travis-ci/travis-ci#1948
Adds a new option for the retry middleware allowing clients to give it a block that will say if a request should be retried or not - fixes #298