|
@@ -139,6 +139,22 @@ This package also includes the +shopify+ executable to make it easy to open up a
|
|
shopify help
|
|
shopify help
|
|
|
|
|
|
|
|
|
|
|
|
+== Threadsafety
|
|
|
|
+
|
|
|
|
+ActiveResource is inherently non-threadsafe, because class variables like `ActiveResource::Base.site` and
|
|
|
|
+`ActiveResource::Base.headers` are shared between threads. This can cause conflicts when using
|
|
|
|
+threaded libraries, like Sidekiq.
|
|
|
|
+
|
|
|
|
+We have a forked version of ActiveResource that stores these class variables in threadlocal
|
|
|
|
+variables. Using this forked version will allow ShopifyAPI to be used in a threaded environment.
|
|
|
|
+
|
|
|
|
+To enable threadsafety with ShopifyAPI, add the following to your Gemfile:
|
|
|
|
+
|
|
|
|
+```
|
|
|
|
+gem 'activeresource', :git => 'git://github.com/peterjm/activeresource', :ref => '47e7f181d9'
|
|
|
|
+gem 'shopify_api', '>= 3.3.0'
|
|
|
|
+```
|
|
|
|
+
|
|
== Using Development Version
|
|
== Using Development Version
|
|
|
|
|
|
Download the source code and run:
|
|
Download the source code and run:
|