|Re: [eclipselink-dev] lock issue with core tests on Derby|
Hi Dies,I believe all these tests are doing work on objects that map to the same database rows in multiple UnitOfWorks (and therefore multiple transactions).
If you are seeing issues with these tests, it is likely because there is something in the way transactions are implemented in Symfoware that is causing an issue. (Derby is likely having transaction issues here and the level of testing on Derby is lower since it is seen as a demo-level database.)
If you turn on logging, you may be able to see the issue. The easiest way to turn on logging is to run your tests from our test browser and set the log level to FINEST the log level can be found at the bottom of the testing browser window.
To find MultipleUnitOfWorkTest, double click on SRGTestModel, then click on ComplexUpdateAndUnitOfWorkTestModel and click the "Setup" button. That will refresh the list. Double click on SRGTestModelAgain, then on ComplexUpdateAndUnitOfWorkTestModel, then on UnitOfWorkTestSuite. MultipleUnitOfWorkTest is about the 10th test down. You should be able to run it by selecting it and clicking on the test button.
Take a look at the SQL statements that are generated by that test. What are they doing that is illegal in Symfoware? Do they uncover a Symfoware limitation we need to document?
(Testing browser info here http://wiki.eclipse.org/EclipseLink/Development/Testing/foundation#Testing_Browser)
-Tom Dies Koper wrote:
Hi, When I ran the core JUnit tests on Derby, I noticed a number of errors were the same as I get with Symfoware. Are these known issues? (I changed a few things in my local build but I can't imagine they could be causing these failures). MultipleUnitOfWorkTest(Employee: Bob Smith) Internal Exception: java.sql.SQLTransactionRollbackException: A lock could not be obtained within the time requested Error Code: 30000 Call: SELECT TYPE, AREA_CODE, P_NUMBER, EMP_ID FROM PHONE WHERE (EMP_ID = ?) bind =>  Query: ReadAllQuery(name="phoneNumbers" referenceClass=PhoneNumber sql="SELECT TYPE, AREA_CODE, P_NUMBER, EMP_ID FROM PHONE WHERE (EMP_ID = ?)") Other tests that fail with the same error on Derby: - UnitOfWorkResumeOnFailureTest(Employee: Bob Smith) - UnitOfWorkComplexRefreshTest - ComplexMultipleUnitOfWorkTest - UnitOfWorkResumeOnFailureTest(Employee: Bob Smith) Thanks, Dies _______________________________________________ eclipselink-dev mailing list eclipselink-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/eclipselink-dev
Back to the top