Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0011681Openbravo ERPA. Platformpublic2009-12-08 13:152009-12-11 06:38
mtaal 
mtaal 
normalmajoralways
closedfixed 
5
pi 
pi 
Core
No
0011681: Hibernate actions are not flushed before DalConnectionProvider is used
The DalConnectionProvider is used in scenarios where actions through the hibernate session have to occur in the same transaction as traditional Openbravo logic using a ConnectionProvider. Hibernate does not flush all actions immediately to the database (flush mode has been set to manually). This means that when someone first does an action through hibernate and then uses a DalConnectionProvider that the connection (retrieved through the DalConnectionProvider) does not always see all hibernate actions.
The proposal is to automatically flush the hibernate session before returning a connection from the DalConnectionProvider. The same for getting the connection from the OBDal class. In this way the connection will see the actions performed in hibernate.
No tags attached.
Issue History
2009-12-08 13:15mtaalNew Issue
2009-12-08 13:15mtaalAssigned To => rafaroda
2009-12-08 14:32mtaalAssigned Torafaroda => mtaal
2009-12-08 14:41mtaalSummaryWhen the DalConnectionProvider not all hibernate actions are flushed before => When the DalConnectionProvider is used not all hibernate actions are flushed before
2009-12-08 16:41mtaalSummaryWhen the DalConnectionProvider is used not all hibernate actions are flushed before => Hibernate actions are not flushed before DalConnectionProvider is used
2009-12-08 16:44hgbotCheckin
2009-12-08 16:44hgbotNote Added: 0022545
2009-12-08 16:44hgbotStatusnew => resolved
2009-12-08 16:44hgbotResolutionopen => fixed
2009-12-08 16:44hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/4cb0d4d3bfd2b700c7258d837dcd2f4fca52f2c1 [^]
2009-12-09 12:26hgbotCheckin
2009-12-09 12:26hgbotNote Added: 0022574
2009-12-09 12:26hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/4cb0d4d3bfd2b700c7258d837dcd2f4fca52f2c1 [^] => http://code.openbravo.com/erp/devel/pi/rev/f3ebfe1924eb60c461b1950d2566b2e97b73c30b [^]
2009-12-09 12:28iperdomoNote Added: 0022575
2009-12-09 12:28iperdomoStatusresolved => closed
2009-12-10 00:00anonymoussf_bug_id0 => 2911686
2009-12-11 06:35hudsonbotCheckin
2009-12-11 06:35hudsonbotNote Added: 0022668
2009-12-11 06:38hudsonbotCheckin
2009-12-11 06:38hudsonbotNote Added: 0022675

Notes
(0022545)
hgbot   
2009-12-08 16:44   
Repository: erp/devel/pi
Changeset: 4cb0d4d3bfd2b700c7258d837dcd2f4fca52f2c1
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Tue Dec 08 16:40:50 2009 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/4cb0d4d3bfd2b700c7258d837dcd2f4fca52f2c1 [^]

fixes issue 11681: Hibernate actions are not flushed before DalConnectionProvider is used

---
M src/org/openbravo/dal/service/OBDal.java
M src/org/openbravo/service/db/DalConnectionProvider.java
---
(0022574)
hgbot   
2009-12-09 12:26   
Repository: erp/devel/pi
Changeset: f3ebfe1924eb60c461b1950d2566b2e97b73c30b
Author: Iván Perdomo <ivan.perdomo <at> openbravo.com>
Date: Wed Dec 09 12:26:12 2009 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/f3ebfe1924eb60c461b1950d2566b2e97b73c30b [^]

Added test case for issue 11681

---
M src-test/org/openbravo/test/dal/IssuesTest.java
---
(0022575)
iperdomo   
2009-12-09 12:28   
Tested on pi @ rev f3ebfe1924eb
(0022668)
hudsonbot   
2009-12-11 06:35   
---
A changeset related to this issue has passed a series of tests and has been promoted to main:

Changeset: http://code.openbravo.com/erp/devel/main/rev/789f4e19eaf7 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
---
(0022675)
hudsonbot   
2009-12-11 06:38   
---
An OBX is generated including a changeset related to this issue and is available at:

OBX: http://builds.openbravo.com/erp/obx/core/OpenbravoERP-2.50CI.15682.obx [^]
---