Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0033507
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformcriticalrandom2016-07-20 12:402016-08-30 10:08
ReporteralostaleView Statuspublic 
Assigned ToNaroaIriarte 
PriorityurgentResolutionfixedFixed in Version3.0PR16Q4
StatusclosedFix in branchFixed in SCM revision6bef7cf32538
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toalostale
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0033507: copy lines can generate incorrect audit trail info

DescriptionSome sqlc processes can generate incorrect audit trail information.

Sqlc processes making use of getTransactionConnection do not set properly context information table, this can lead to incorrect audit information.
Steps To Reproduce1. Activate the instance
2. As System Admin set C_Order table as fully audited
3. Generate Audit trail infrastructure
4. Login as Openbravo Admin
5. Create a new Sales Order header
6. Open chrome's dev tools > network
7. Open Copy Lines process
8. Select a line and execute
9. In dev tools select CopyFromOrder.html request and copy as curl
10. Execute bench 2000 "curl whateverYouCopied --silent" [1]
11. Execute this query: select count(*), processtype, process_id from ad_audit_trail where action='I' group by 2,3

  -> Expected: all records should have 211 (Copy From) as process_id
  -> Got: some of them have different process_id

[1] https://raw.githubusercontent.com/alostale/ob-scripts/master/misc/bench [^]
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0033438 closedalostale DalConnectionProvider.getTransactionConnection does not obtain connection from common pool 

-  Notes
(0088707)
hgbot (developer)
2016-08-01 09:54

Repository: erp/devel/pi
Changeset: 6bef7cf32538272b1119cafab0ab29d998d5d5c4
Author: Naroa Iriarte <naroa.iriarte <at> openbravo.com>
Date: Fri Jul 29 11:18:31 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/6bef7cf32538272b1119cafab0ab29d998d5d5c4 [^]

Fixed issue 33507: Incorrect Audit info was generated sometimes.

There was a problem when creating audit info data by some sqlc processes, sometimes wrong data was being created. The problem was that when the processes used the getTransactionConnection, the context information table was not correctly set. This table is set by the SessionInfo.setDBSessionInfo method.
To fix this, a call to this method has been added in the ConnectionProviderImpl.getTransactionConnection() and in the DalConnectionProvider.getTransactionConnection().

---
M src-core/src/org/openbravo/database/ConnectionProviderImpl.java
M src/org/openbravo/service/db/DalConnectionProvider.java
---
(0089027)
hudsonbot (developer)
2016-08-11 18:40

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/edaa05b1fb18 [^]
Maturity status: Test
(0089532)
alostale (developer)
2016-08-30 10:08

code reviewed

tested with old and new db pools

- Issue History
Date Modified Username Field Change
2016-07-20 12:40 alostale New Issue
2016-07-20 12:40 alostale Assigned To => platform
2016-07-20 12:40 alostale Modules => Core
2016-07-20 12:40 alostale Triggers an Emergency Pack => No
2016-07-20 12:45 alostale Steps to Reproduce Updated View Revisions
2016-07-20 12:48 alostale Relationship added related to 0033438
2016-07-20 12:48 alostale Status new => scheduled
2016-07-20 12:48 alostale Assigned To platform => NaroaIriarte
2016-08-01 09:54 hgbot Checkin
2016-08-01 09:54 hgbot Note Added: 0088707
2016-08-01 09:54 hgbot Status scheduled => resolved
2016-08-01 09:54 hgbot Resolution open => fixed
2016-08-01 09:54 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/6bef7cf32538272b1119cafab0ab29d998d5d5c4 [^]
2016-08-01 10:02 NaroaIriarte Review Assigned To => alostale
2016-08-11 18:40 hudsonbot Checkin
2016-08-11 18:40 hudsonbot Note Added: 0089027
2016-08-30 10:08 alostale Note Added: 0089532
2016-08-30 10:08 alostale Status resolved => closed
2016-08-30 10:08 alostale Fixed in Version => 3.0PR16Q4


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker