FW: Calculate Product Price Service - Product Price Rule Performance

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

FW: Calculate Product Price Service - Product Price Rule Performance

Len Shein
I am using Ofbiz 10.04.

I have on my DB 3000 Product price rules (entity PRODUCT_PRICE_RULE) and
6000 Product Price Conditions (entity PRODUCT_PRIE_COND).  All of my price
conditions are setup for Quantity Breaks in pricing.

When calling the 'caclulateProductPrice' service for a single product; the
service reads 'all' of the Product Price Rules (using cache) and 'all' of
the product price conditions for each price rule.  Two lists are then built
of 'quantity product Prices Rules' and 'non quantity product price rules'.
The 'quantity product price rules' list is now interrogated to determine if
any price conditions are 'true'  by calling method 'checkPriceCondition'.

 

In my scenario over '3000' DB hits would have been made and processing of
6000 rows is performed to determine if a 'single' product has price rules.

 

Has anyone come across any performance issues since calculateProductPrice
service may be called from multiple areas of an eCommerce Site (list page
and detail page)?

Has any work been done in later versions of Ofbiz (11.04) to optimize this?

Would it make more sense to first see if Product Price Condition is 'true'
before reading the associated Product Price Rule is active?

 

 

 Thank You

 

Len Shein

 

[hidden email]

[hidden email]

 

516.742.7888 ext.225

732.333.4303

 

Reply | Threaded
Open this post in threaded view
|

Re: Calculate Product Price Service - Product Price Rule Performance

Jacques Le Roux
Administrator
From: "Len Shein" <[hidden email]>

>I am using Ofbiz 10.04.
>
> I have on my DB 3000 Product price rules (entity PRODUCT_PRICE_RULE) and
> 6000 Product Price Conditions (entity PRODUCT_PRIE_COND).  All of my price
> conditions are setup for Quantity Breaks in pricing.
>
> When calling the 'caclulateProductPrice' service for a single product; the
> service reads 'all' of the Product Price Rules (using cache) and 'all' of
> the product price conditions for each price rule.  Two lists are then built
> of 'quantity product Prices Rules' and 'non quantity product price rules'.
> The 'quantity product price rules' list is now interrogated to determine if
> any price conditions are 'true'  by calling method 'checkPriceCondition'.
>
>
>
> In my scenario over '3000' DB hits would have been made and processing of
> 6000 rows is performed to determine if a 'single' product has price rules.
>
>
>
> Has anyone come across any performance issues since calculateProductPrice
> service may be called from multiple areas of an eCommerce Site (list page
> and detail page)?

I remember the Neogia project did something about that. It's at least used in the OYA ERP http://www.c-libre.net/web/guest/oya which is Neogia based. I can't say more since I did not participate to the development.
 
> Has any work been done in later versions of Ofbiz (11.04) to optimize this?

Nope

> Would it make more sense to first see if Product Price Condition is 'true'
> before reading the associated Product Price Rule is active?

Maybe :)

Jacques

>
>
>
>
> Thank You
>
>
>
> Len Shein
>
>
>
> [hidden email]
>
> [hidden email]
>
>
>
> 516.742.7888 ext.225
>
> 732.333.4303
>
>
>
>