The autoload in https://github.com/drbrain/net-http-persistent/blob/master/lib/net/http/persistent.rb#L17 seems to fail on some Rubies. While I have not been able to find an root cause of WHY, I do have some examples. This can be seen in rubygems/rubygems-mirror#36 and bundler/bundler#3107. I have personally seen it on Ruby 2.2.2p95 with the following test:
The autoload in https://github.com/drbrain/net-http-persistent/blob/master/lib/net/http/persistent.rb#L17 seems to fail on some Rubies. While I have not been able to find an root cause of WHY, I do have some examples. This can be seen in rubygems/rubygems-mirror#36 and bundler/bundler#3107. I have personally seen it on Ruby 2.2.2p95 with the following test:
Where as on other machines (both different versions and 2.2.2p95) it works as intended:
This is causing programs that rely on this Net::HTTP::Persistent to have to account for this behavior and forcibly load OpenSSL upfront, in much the same way as net/http/pipeline is loaded in https://github.com/drbrain/net-http-persistent/blob/master/lib/net/http/persistent.rb#L12-15