}
public static File pickCurrentLogFile(File file1, File file2) throws IOException {
RandomAccessFile activeRandomAccessFile;
activeRandomAccessFile = new RandomAccessFile(file1, "r");
int formatId1 = activeRandomAccessFile.readInt();
if (formatId1 != BitronixXid.FORMAT_ID)
throw new IOException("log file 1 " + file1.getName() + " is not a Bitronix Log file (incorrect header)");
long timestamp1 = activeRandomAccessFile.readLong();
activeRandomAccessFile.close();