Community
Participate
Working Groups
1. Create a New Test Case and a New Category 2. Open the New Test Case 3. Move the New Test Case into the New Category (while the Test Case is opened) --> At first four DatabaseLoadFailed-errors appear, than appears a Non-recoverable-error: An error occurred. Reason: 2001: Database load failed. An error occurred. Reason: 7007: Non-recoverable error. Please restart the application. In GUIdancer 4.3 it was possible to move a opened Test Case into a category. We should decide if it should be possible to move opened test cases or we should modify the error message text to "object is in use by another transaction".
The problem seems to be caused by a combination of EntityManager management, JFace TreeViewers, and Decorators. When the Test Case Editor is opened, the Workbench's Managed Decorator is triggered. As a result, the elements in the Tree Viewer in the TCB are updated (the TreeItems receive new data). This confuses EclipseLink, because there is a "new" object (not Java identical, or ==, to any other managed object) in the EntityManager. This is what causes the error: At some point later, a JPA query is executed, and the pre-query flush causes an exception because the PK constraint for the Test Case (the object that is recognized by EclipseLink as "new") is violated.
A possible fix might be to somehow separate the Decorators by EntityManager. This would mean that each Editor has its own set of Decorators, and the views that use the master session would share a set of Decorators.
fixed with http://git.eclipse.org/c/jubula/org.eclipse.jubula.core.git/commit/?id=930bbdca27fd2eb32b2d95fbd67b1e04b66f456d
Bug fixed, tested manually