In Java 1.5, java.nio.channels.FileLock did not check for files that were already locked. Link here
The fingerprint says:
The java.nio.channels.FileLock class checks files already locked by other instances of FileChannelJava SE 6 throws an OverlappingFileLockException if an application tries to block a region that overlaps an area locked through another FileChannel instance. previous versions did not check file locks received by other FileChannel instances. By default, the java.nio.channels.FileChannel.lock method checks whether the requested lock overlaps with the area held by this Java Virtual Machine.
The java.nio.channels.FileLock class checks files already locked by other instances of FileChannel
Java SE 6 throws an OverlappingFileLockException if an application tries to block a region that overlaps an area locked through another FileChannel instance. previous versions did not check file locks received by other FileChannel instances. By default, the java.nio.channels.FileChannel.lock method checks whether the requested lock overlaps with the area held by this Java Virtual Machine.
So, in pre-Java 6, exclusive file locking did not work if you had several programs writing one file (each program tried to get an exclusive lock). How did people get around this with Java 5 before?
I do not think Java5 behavior is a serious problem.
, . , , . "" . , , , , , .
JVM , , . , . - , Java6 . (, )
, , . , . , JVM, JVM. , Java5 , , , .