Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0038289 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] I. Performance | minor | always | 2018-04-06 13:59 | 2018-04-13 10:53 | |||
Reporter | ngarcia | View Status | public | |||||
Assigned To | alostale | |||||||
Priority | high | Resolution | fixed | Fixed in Version | 3.0PR18Q3 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 0b70358a2e29 | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | ||||||||
Review Assigned To | caristu | |||||||
OBNetwork customer | OBPS | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | 1096 | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0038289: Log Clean Up Process takes too long to delete the records in AD_PROCESS_REQUEST window with Process Groups | |||||||
Description | Log Clean Up Process takes too long to delete the records in AD_PROCESS_REQUEST window with Process Groups Having an environment with around 700000 records to be deleted in ad_process_request (status = 'COM' created < now()-15), the following query lasts 22 hours delete from AD_Process_Request where Created<now()-15 and Status='COM' and AD_Client_ID=<>; Result of Explain Analyze was: 'Delete on ad_process_request (cost=0.00..380218.30 rows=718678 width=6) (actual time=46464.380..46464.380 rows=0 loops=1)' ' -> Seq Scan on ad_process_request (cost=0.00..380218.30 rows=718678 width=6) (actual time=0.031..2275.472 rows=720995 loops=1)' ' Filter: (((status)::text = 'COM'::text) AND ((ad_client_id)::text = '101C8C9C4A8D4C84857E3F5FBD722757'::text) AND (created < (now() - 15::numeric)))' ' Rows Removed by Filter: 162711' 'Trigger for constraint ad_process_request_group: time=79140555.117 calls=720995' 'Trigger for constraint ad_process_run_ad_process_requ: time=27889.646 calls=720995' 'Trigger ad_process_request_trg: time=12800.440 calls=720995' 'Total runtime: 79215399.399 ms' | |||||||
Steps To Reproduce | Ask for an environment in which the problem can be reproduced in case is needed | |||||||
Proposed Solution | Create an index similar to CREATE INDEX ad_process_reqgroup_idx ON ad_process_request USING btree (ad_process_request_group_id COLLATE pg_catalog."default") WHERE ad_process_request_group_id IS NOT NULL | |||||||
Tags | Performance | |||||||
Attached Files | ||||||||
![]() |
|||||||||
|
![]() |
|
(0103870) hgbot (developer) 2018-04-13 09:35 |
Repository: erp/devel/pi Changeset: 0b70358a2e29459502143a08f3ba30ae440be92f Author: Asier Lostalé <asier.lostale <at> openbravo.com> Date: Fri Apr 13 09:35:13 2018 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/0b70358a2e29459502143a08f3ba30ae440be92f [^] fixed 38289: slow Log Clean Up with records in AD_PROCESS_REQUEST using Groups Added index to ad_process_request.ad_process_request_group_id to prevent seq scans when deleing on this table having requests linked to groups. --- M src-db/database/model/tables/AD_PROCESS_REQUEST.xml --- |
(0103871) caristu (viewer) 2018-04-13 10:53 |
Reviewed |
![]() |
|||
Date Modified | Username | Field | Change |
2018-04-06 13:59 | ngarcia | New Issue | |
2018-04-06 13:59 | ngarcia | Assigned To | => platform |
2018-04-06 13:59 | ngarcia | OBNetwork customer | => Yes |
2018-04-06 13:59 | ngarcia | Modules | => Core |
2018-04-06 13:59 | ngarcia | Support ticket | => 1096 |
2018-04-06 13:59 | ngarcia | Triggers an Emergency Pack | => No |
2018-04-06 13:59 | ngarcia | Issue Monitored: networkb | |
2018-04-06 14:00 | ngarcia | Priority | urgent => high |
2018-04-06 14:00 | ngarcia | Severity | major => minor |
2018-04-09 10:10 | Practics | Issue Monitored: Practics | |
2018-04-13 09:23 | alostale | Tag Attached: Performance | |
2018-04-13 09:23 | alostale | Relationship added | related to 0038291 |
2018-04-13 09:32 | alostale | Assigned To | platform => alostale |
2018-04-13 09:32 | alostale | Review Assigned To | => caristu |
2018-04-13 09:35 | hgbot | Checkin | |
2018-04-13 09:35 | hgbot | Note Added: 0103870 | |
2018-04-13 09:35 | hgbot | Status | new => resolved |
2018-04-13 09:35 | hgbot | Resolution | open => fixed |
2018-04-13 09:35 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/0b70358a2e29459502143a08f3ba30ae440be92f [^] |
2018-04-13 10:53 | caristu | Note Added: 0103871 | |
2018-04-13 10:53 | caristu | Status | resolved => closed |
2018-04-13 10:53 | caristu | Fixed in Version | => 3.0PR18Q3 |
Copyright © 2000 - 2009 MantisBT Group |