Friday, May 13, 2011

Commerce Server Performance Tips

Any great site using the best technologies is slow if you don't plan it carefully. Several clients have had us doing an Architectural Review of their site based upon performance issues. Microsoft has a performance guide here evaluating tests run against the OOB Extensibility Kit. Most Commerce Server based sites are radically customized from the Extensibility Kit as discussed in my prior post.

The main area we've seen having issues are the Basket operations. The Ext Kit has some caching around the query which is helpful, yet easily missed. The basket also gets into a state that requires both the basket and total pipeline components to be called for every basket query or manipulation. This often coupled with invalid caching of shipping, tax and credit card services along with fees per transaction that are often incurred are problematic.

Therefore, three quick wins:

1) Cache all information that the Mini Cart needs so that it doesn't ever need to call the Basket Query operation.
2) Override the PipelineProcessor sequence component and add better logic as to when the total pipeline should be called.
3) Cache the calls to expensive (time and per transaction) services by storing values in weakly typed properties of the orderform or shipment which will enable you to skip unnecessary calculations. If you store the information in the shipments, you'll need to write your own shipping splitter.

No comments:

Post a Comment