MultiFile segment handler does not handle existing segments properly
Expected Behavior
When picking a segment file to write to, the MultiFile
backend should use the first non-full, non-locked segment by numerical order.
Actual Behavior
The multifile segment handler only checks the highest numbered segment file, and if it is full or locked, will create a new one. regardless of the fullness or lockedness of other segment files.
Steps to Reproduce
- Have a multifile backend connection to a repository with a number of non-full, non-locked segment files, but with the highest one (by numerical order) locked
- Attempt to open a new segment for writing.
- Observe the segment handler ignoring all the non-full, non-locked segments and creating a new one
Edited by Nathan McCarty