Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0025051 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] A. Platform | minor | have not tried | 2013-10-30 18:50 | 2013-11-01 01:07 | |||
Reporter | shuehner | View Status | public | |||||
Assigned To | shuehner | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | 3.0MP29 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 4a43e052de88 | ||||
Projection | none | ETA | none | Target Version | 3.0MP29 | |||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | ||||||||
Review Assigned To | alostale | |||||||
OBNetwork customer | No | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | ||||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0025051: AlertBackgroundProcess is very slow when having to reprocess many alerts already present in ad_alert | |||||||
Description | The alert background process does first check for alerts which are outcome of a alertrule (i.e. 15k). Then in a loop for every of those it checks if they have been already inserted into ad_alert and only if not it started processing them (insert + maybe mail). When a alertrule results in a high number of records i.e. 15k then this fires 15k small queries to check for ad_alert. Pushing that check directly into the initial query using a (not exists) removes the need for so many small extra queries and also avoids to load the 15k alerts at all into memory. | |||||||
Steps To Reproduce | Take a alertrule and make it create a high number of alerts (i.e. 15k). Example is create 15k ad_process_run entries in status 'ERR'. Check process monitor runtime for the alertbackground process and see it takes very long. Debugging timing shows not the initial query to take so long but instead the small utility queries. | |||||||
Proposed Solution | Push down the check against ad_alert into the initial query. | |||||||
Tags | Performance | |||||||
Attached Files | ||||||||
![]() |
|
![]() |
|
(0061990) hgbot (developer) 2013-10-30 23:54 |
Repository: erp/devel/pi Changeset: 4a43e052de886824a29774277c86040a2b14f6f1 Author: Stefan Hühner <stefan.huehner <at> openbravo.com> Date: Wed Oct 30 18:52:53 2013 +0100 URL: http://code.openbravo.com/erp/devel/pi/rev/4a43e052de886824a29774277c86040a2b14f6f1 [^] Fixed 25051: Improve alertbackground process with high number of alerts. Improve performance of that process when it need to process a high number of alerts created by an alertrule. Push down the check if that alert has already been inserted into ad_alert into the query getting the alerts instead of doing many small queries. --- M src/org/openbravo/erpCommon/ad_process/AlertProcess.java M src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql --- |
(0061998) alostale (viewer) 2013-10-31 12:55 |
Code reviewed + verified |
(0062014) hudsonbot (viewer) 2013-11-01 01:07 |
A changeset related to this issue has been promoted main and to the Central Repository, after passing a series of tests. Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/2d6c59f6dc4a [^] Maturity status: Test |
![]() |
|||
Date Modified | Username | Field | Change |
2013-10-30 18:50 | shuehner | New Issue | |
2013-10-30 18:50 | shuehner | Assigned To | => shuehner |
2013-10-30 18:50 | shuehner | Modules | => Core |
2013-10-30 18:50 | shuehner | OBNetwork customer | => No |
2013-10-30 18:50 | shuehner | Triggers an Emergency Pack | => No |
2013-10-30 19:00 | shuehner | Review Assigned To | => alostale |
2013-10-30 23:54 | hgbot | Checkin | |
2013-10-30 23:54 | hgbot | Note Added: 0061990 | |
2013-10-30 23:54 | hgbot | Status | new => resolved |
2013-10-30 23:54 | hgbot | Resolution | open => fixed |
2013-10-30 23:54 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/4a43e052de886824a29774277c86040a2b14f6f1 [^] |
2013-10-31 12:55 | alostale | Tag Attached: Performance | |
2013-10-31 12:55 | alostale | Note Added: 0061998 | |
2013-10-31 12:55 | alostale | Status | resolved => closed |
2013-10-31 12:55 | alostale | Fixed in Version | => 3.0MP29 |
2013-11-01 01:07 | hudsonbot | Checkin | |
2013-11-01 01:07 | hudsonbot | Note Added: 0062014 |
Copyright © 2000 - 2009 MantisBT Group |