[NO ISSUE][TX] Stop reading logs when an empty file is encountered
authorMurtadha Hubail <mhubail@apache.org>
Sun, 7 Feb 2021 21:07:44 +0000 (00:07 +0300)
committerMurtadha Hubail <mhubail@apache.org>
Sun, 7 Feb 2021 23:11:00 +0000 (23:11 +0000)
commit1f238097fb756556628f2027f47acd4390ace36f
tree4a77c07499022eeb09d07f3dedd017569f9bb07c
parent9f454cdb48537e1fc0f9dd7b66ad75470a8c514a
[NO ISSUE][TX] Stop reading logs when an empty file is encountered

- user model changes: no
- storage format changes: no
- interface changes: no

Details:

- Whenever an empty txn log file is encountered, do not
  attempt to read the next log file since an empty log
  file indicates that no more logs exist.
- Add test case.

Change-Id: I8d95c9e444dcdea21c4af35779d4c0c38f6577e5
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/9883
Reviewed-by: Murtadha Hubail <mhubail@apache.org>
Reviewed-by: Ian Maxon <imaxon@uci.edu>
Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Tested-by: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/txn/LogManagerTest.java
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/txn/RecoveryManagerTest.java
asterixdb/asterix-transactions/src/main/java/org/apache/asterix/transaction/management/service/logging/LogReader.java