paypalx/SDKs — pull request #8 by bpossolo (2012-06-17 13:08:38+00:00)
Title: Added support for PayPal AdaptivePayments JavaSDK on Google App Engine

Hello,

I was attempting to use the new PayPal Adaptive Payments java SDK on Google App Engine but encountered problems because GAE does not support most of the classes in javax.net.ssl
See: https://developers.google.com/appengine/docs/java/jrewhitelist

However, GAE does support HTTPS urls using the normal HttpURLConnection class.
See: https://developers.google.com/appengine/docs/java/urlfetch/usingjavanet
Therefore, I renamed HttpConnection to DefaultHttpConnection. Then I abstracted most of the reusable code into a parent class called HttpConnection. Then I created a new subclass called GoogleAppEngineHttpConnection.

In order to make this configurable, I added a new http configuration property. The ConnectionManager now looks at that property and determines which HttpConnection to instantiate (either DefaultHttpConnection or GoogleAppEngineHttpConnection).

I did not make any backwards breaking changes. Everything else still functions as it did before.

I have verified that the PayPal AdaptivePayments SDK now works on the latest version of GAE 1.6.5