puppetlabs/puppetdb — pull request #897 by cprice404 (2014-03-26 00:39:28+00:00)
Title: Terminus: support an alternate HTTP client for JRuby

This PR does two things (both only affecting the terminus code):

1. Abstract the instantiation of HTTP client objects into a new class, Puppetdb::HttpClient
2. Use a different implementation of an HTTP client when running under JRuby.

The motivation for this:

* All of the HTTP requests made via the terminus are HTTPS
* The JRuby implementation of the Ruby SSL layer is not the most mature part of the Ruby code base

This approach gives us the ability to provide our own implementation of an HTTPS client that doesn't rely on the JRuby SSL layer at all.