One of the probable cause of renaming failure is the inprogress file was not closed.
It is closed just before finalizedLogSegment() in JournalSet.JournalClosure.apply(), but the code block is not synchronized.

It seems that this tests failed only once as far as I can track on the Jenkins test result history.
I was trying to reproduce this failure, but have not been successful so far.
Then, I am now inspecting log messages.

Tomohiko Kinebuchi
added a comment - 25/Jun/12 15:28 It seems that this tests failed only once as far as I can track on the Jenkins test result history.
I was trying to reproduce this failure, but have not been successful so far.
Then, I am now inspecting log messages.
Does someone know what this test case tests?

The first error message is "Workload exception 4 testfile /15.dat java.io.EOFException: Premature EOF: no length prefix available", and after this moment all other Workload threads failed.

The essential problem on this test failure is unclearness of the objective of this test case and difficulties to understand what ever happened.
At least we should clear what error case we want to capture, then we are prepared to implement a test case.

Tomohiko Kinebuchi
added a comment - 22/Jul/12 14:26 Attached a patch and its intent is described below.
The first error message is "Workload exception 4 testfile /15.dat java.io.EOFException: Premature EOF: no length prefix available", and after this moment all other Workload threads failed.
The essential problem on this test failure is unclearness of the objective of this test case and difficulties to understand what ever happened.
At least we should clear what error case we want to capture, then we are prepared to implement a test case.
So, I propose to delete this test case.

I agree it's not a great unit test case for the reason you mentioned, but deleting it without understanding why it fails sometimes doesn't seem right. It acts as a decent stress-test/functional test, and it's still worrisome that it fails.

Todd Lipcon
added a comment - 22/Jul/12 21:48 I agree it's not a great unit test case for the reason you mentioned, but deleting it without understanding why it fails sometimes doesn't seem right. It acts as a decent stress-test/functional test, and it's still worrisome that it fails.