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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0033750
TypeCategorySeverityReproducibilityDate SubmittedLast Update
feature request[Openbravo ERP] A. Platformminoralways2016-08-19 12:162016-09-02 13:39
ReportergorkaionView Statuspublic 
Assigned Togorkaion 
PrioritynormalResolutionfixedFixed in Version3.0PR16Q4
StatusclosedFix in branchFixed in SCM revision2255a1048867
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

0033750: Add API in SessionHandler to create new Transactions on active Session

DescriptionWhen implementing a TransactionCompleted event the Transaction on the active Session is not active. This means that it is not possible to do database changes in those event handlers.

It should be possible to begin a new transaction when needed. Currently this is only possible by deleting the session which can create issues in processes that do commitAndStart().
Steps To Reproduce* Create an event handler that implements the TransactionCompleted event.

Case 1:
* Try to do an insert or an update on some entity on the event handler.
* It fails with a Transaction not active error.
Case 2:
* Do a SessionHandler.deleteSession() at the beginning of the TransactionCompleted event implementation.
* The event handler does not fail but the Physical Inventory Count process fails. (it does a commitAndStart() which fires the event handler which deletes the session)


Proposed SolutionCreate a new public method in SessionHandler that begins a new transaction in the current active Session.
TagsNo tags attached.
Attached Filespatch file icon issue33750.patch [^] (803 bytes) 2016-08-19 12:19 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]
blocks design defect 0033210pi closedgorkaion VariantChDescUpdateProcess executed using ImportEntries instead of ProcessBundle 

-  Notes
(0089595)
hgbot (developer)
2016-08-31 11:44

Repository: erp/devel/pi
Changeset: 4ece62a0e09c265e63eaa42b9c73acbef98c8996
Author: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
Date: Wed Aug 31 11:42:06 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/4ece62a0e09c265e63eaa42b9c73acbef98c8996 [^]

Fixed issue 33750.Add new methods in SessionHandler to manage transactions.

Two new public methods added:
- isCurrentTransactionActive()
- beginNewTransaction()

These methods are needed to be able to modify the database in EventHandlers
that are fired when the transaction is completed.

---
M src-db/database/sourcedata/AD_MESSAGE.xml
M src/org/openbravo/dal/core/SessionHandler.java
---
(0089596)
hgbot (developer)
2016-08-31 12:23

Repository: erp/devel/pi
Changeset: 2255a10488676a72f7b311ef7ea433f59dc19fab
Author: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
Date: Wed Aug 31 12:22:30 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/2255a10488676a72f7b311ef7ea433f59dc19fab [^]

Fixed issue 33750.Add new methods in SessionHandler to manage transactions.

Two new public methods added:
- isCurrentTransactionActive()
- beginNewTransaction()

These methods are needed to be able to modify the database in EventHandlers
that are fired when the transaction is completed.

---
M src/org/openbravo/dal/core/SessionHandler.java
---
(0089650)
hudsonbot (developer)
2016-09-01 12:12

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/a321ec570edd [^]
Maturity status: Test
(0089651)
hudsonbot (developer)
2016-09-01 12:12

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/a321ec570edd [^]
Maturity status: Test
(0089703)
alostale (manager)
2016-09-02 13:39

code reviewed

- Issue History
Date Modified Username Field Change
2016-08-19 12:16 gorkaion New Issue
2016-08-19 12:16 gorkaion Assigned To => gorkaion
2016-08-19 12:16 gorkaion Modules => Core
2016-08-19 12:16 gorkaion Triggers an Emergency Pack => No
2016-08-19 12:19 gorkaion Relationship added related to 0033210
2016-08-19 12:19 gorkaion File Added: issue33750.patch
2016-08-19 12:30 gorkaion Relationship deleted related to 0033210
2016-08-19 12:30 gorkaion Relationship added blocks 0033210
2016-08-31 11:21 gorkaion Review Assigned To => alostale
2016-08-31 11:44 hgbot Checkin
2016-08-31 11:44 hgbot Note Added: 0089595
2016-08-31 11:44 hgbot Status new => resolved
2016-08-31 11:44 hgbot Resolution open => fixed
2016-08-31 11:44 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/4ece62a0e09c265e63eaa42b9c73acbef98c8996 [^]
2016-08-31 12:23 hgbot Checkin
2016-08-31 12:23 hgbot Note Added: 0089596
2016-08-31 12:23 hgbot Fixed in SCM revision http://code.openbravo.com/erp/devel/pi/rev/4ece62a0e09c265e63eaa42b9c73acbef98c8996 [^] => http://code.openbravo.com/erp/devel/pi/rev/2255a10488676a72f7b311ef7ea433f59dc19fab [^]
2016-09-01 12:12 hudsonbot Checkin
2016-09-01 12:12 hudsonbot Note Added: 0089650
2016-09-01 12:12 hudsonbot Checkin
2016-09-01 12:12 hudsonbot Note Added: 0089651
2016-09-02 13:39 alostale Note Added: 0089703
2016-09-02 13:39 alostale Status resolved => closed
2016-09-02 13:39 alostale Fixed in Version => 3.0PR16Q4


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker