This gem extends PayPal SDK and allows you to set specific http library.
Currently it supports two adapters:
:net_http- Net::HTTP (default, blocking I/O)
:em_http- EM::Http (non-blocking I/0)
Add this line to your application's Gemfile:
And then execute:
Or install it yourself as:
$ gem install paypal-sdk-http-adapters
PayPal::SDK.http_adapter_name = :net_http
This is default adapter that actually is very simple wrapper for standard
PayPal::SDK.http_adapter_name = :em_http
This is adapter for
When EventMachine is already running we assume that you are responsible for Fiber allocation.
You can add
Rack::FiberPool to your application middleware and it automatically provides a Fiber for each incoming HTTP request.
It creates pool of Fibers and re-use fiber for each incoming HTTP request.
Also you can control the connection pool size.