Tuesday, June 25, 2013

Hybris Performance


For best performance results on your Hybris eCommerce system below are few key things -

Ensure following - 

Your cluster broad casting thread max wait is updated from default 60000 to 60 seconds
cluster.broadcast.senderthreads.maxwait=60

Prefer UDP as a broadcasting method instead of TCP.

Keep tomcat connector maxThread 400, going beyond this it adds less value but more overhead.

Allocating bigger cache sizes does not help and some time ends up eating lot of memory, so ensure cache sizes are determined after some test and analysis.

Keep back office servers outside from customer facing hybris nodes and distribute your cron jobs on multiple back office nodes.

Lucene Indexing - I am sure you must be using solr or some other search engine for customer facing search requirements. If yes then having lucene indexes just for hmc search does not make any sense after acknowledging the overhead it adds on the system. I suggest disable all rebuild and update lucene jobs forever.

Physical vs VM machines - Hybris instances perform far better on a Physical machine. if possible never opt VM machines for your hybris cluster.

Cluster size - Be careful here, keep adding node in existing cluster might not be a right approach.

A reasonable cluster configuration is-
4 hybris front instances  - 400 http + 200 https connector threads
2 hybris back office  - 200 http + 100 https connector threads
Above configuration is good enough o handle ~6000 concurrent hits on your site where concurrency level is 1 sec.

1 hit  = 1 connector thread
You must be thinking 6000 concurrent hits means = 6000 threads but we have not configured that many then how to handle

will all threads stay for 1 sec (our concurrency level)? No, some will get response in micro, some in mills but some might take few seconds.
If any thread staying in your system for more then 3-4 seconds then a serious code review required.

Page views in a hour, day, month etc. - nothing matters. You should prepare yourself at lowest possible concurrency level. if your system could handle load for a given time 't' then application will last for longer.

Media Serving - Ensure your hybris instance not serving any static content. Application server do something more intelligent.   You can simply configure your front web server/load balancer  to serve media directly. Review your hybris access log and ensure no static content reached upto them.

CDN - if your organization can afford this then definitely go for this. It can give offload even beyond 90%. Less infrastructure cost, less overhead and moreover not only static you can also cache dynamic pages, if coded smartly.

continued......