| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Variant performance improvement in 4.0 | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
Variant performance improvement in 4.0
More results from my profiling work. It seems when X-Cart is displaying the product page it gets pricing for each of the variants for the product. One of the things that requires is looking up the tax rates for the product. No matter which variant you are talking about the tax rate is the same but X-Cart calls a function to find out for every variant anyway. In one lower level function they they tried to cache the result to speed it up but they goofed and it only works for logged in users. This mod fixes the low level caching to work for not logged in users and adds caching at a higher level function for even more improvement. The performance improvement naturally depends on the number of variants the product has. On my test box I'm seeing roughly 1/4 second for 40 variants. On my faster production server its a little more than 1/2 that. It makes a product page with a lot of variants about as fast as one with only a couple of variants.
This is for version 4.0.x. Looks like at least 4.0.12 through 4.0.19. I guess X-Cart must have done some profiling too as they have added the higher level caching in 4.1 which is where the big gain is. I don't think 4.1 users will find any noticeable improvement if they were to implement the lower level cache fix only. In func.php function func_get_customer_zones_avail find this: PHP Code:
PHP Code:
Then in func.php function func_get_product_tax_rates find: PHP Code:
And replace it with this: PHP Code:
__________________
Manuka Bay Company X-Cart Version 4.0.19 [Linux] UGG Boots and other fine sheepskin products http://www.snowriver.com |
|||||||
#2
|
|||||||
|
|||||||
Re: Variant performance improvement in 4.0
Interesting mod, ill definately check this one out as soon as i get the other mods installed Ill keep you updated.
__________________
Xcart v4.0.18 Current one |
|||||||
#3
|
|||||||
|
|||||||
Re: Variant performance improvement in 4.0
Just wondered if you have had a go with this yet???
__________________
www.rollersnakes.co.uk 4.0.19 [getting faster] 2 x dedicated servers, Dual Quad Core processors, 16gb ram, Raid 0 for the os, Raid 5 for the data and a whole host of tweaks. Some might say its a little over kill for one site |
|||||||
#4
|
|||||||
|
|||||||
Re: Variant performance improvement in 4.0
Thanks, this is working well on my 4.0.18 installation.
Jeanne 4.0.18 gold |
|||||||
|
|||
X-Cart forums © 2001-2020
|