Integrate ActiveMerchant With Rails
Bala Paranj
6 posts
|
I find it shocking to read this recipe. Toy examples and no thoughts about robustness makes this a recipe for disaster. Check out my critical feedback about this recipe on my blog: http://bparanj.blogspot.com/2008/09/integrate-activemerchant-with-rails.html |
Maik Schmidt
8 posts
|
Hi, Bala! Thank you for your comment on the “Integrate ActiveMerchant With Rails” recipe. You are right: the order process has been simplified to put emphasis on integrating ActiveMerchant with Rails. I did that to keep the recipe short and to not distract the reader from the recipe’s main topic. Order processing is a problem that cannot be solved with a general solution and strongly differs from company to company. Hence, I did not devote a recipe to it and I assume that the reader is familiar with order processing at least in his environment. But you can find a more elaborate example in the “Transfer Money with PayPal” recipe. In your blog entry you write the following: “As soon as you create an order, you must set it’s initial state and process that order in the background. You can use run rake task using a CRON job that processes the orders. What happens if the Gateway is down? What will you recover from network errors? These things happen in the real world and your software that affect the bottom line must be able to handle it.” Most of your points are valid although I do not think that all orders have to be processed in the background. I present solutions for all nasty real-world problems you’ve mentioned in the Messaging chapter. In addition, these solutions are more sophisticated and more reliable than cron jobs. For example, you’d better use asynchronous messaging for processing your orders in the background. Maik |
2 posts, 2 voices
