Centralize JournalSegmentFile creation 26/111626/2
authorRobert Varga <robert.varga@pantheon.tech>
Sun, 5 May 2024 21:03:03 +0000 (23:03 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Sun, 5 May 2024 21:13:57 +0000 (23:13 +0200)
commit3526a7735a3fbe62773d5edd23290e5e4d94b197
tree80011385f41b2cc07ac48c7cd47cf3d1b507264f
parentf197f0c598819fd37a32aceab0f6a22fb81bf420
Centralize JournalSegmentFile creation

There are only two callers of the constructor: we are either creating
a new file (in which case we initialize the descriptor) or we are
opening a file (in which case we read the descriptor).

JIRA: CONTROLLER-2099
Change-Id: Id3943a637067d3b7f2ba7384e417e935df65276a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
atomix-storage/src/main/java/io/atomix/storage/journal/JournalSegmentFile.java
atomix-storage/src/main/java/io/atomix/storage/journal/SegmentedJournal.java