Class AzureJournalFile
- java.lang.Object
-
- org.apache.jackrabbit.oak.segment.azure.AzureJournalFile
-
- All Implemented Interfaces:
JournalFile
public class AzureJournalFile extends Object implements JournalFile
-
-
Constructor Summary
Constructors Constructor Description AzureJournalFile(com.azure.storage.blob.BlobContainerClient readBlobContainerClient, com.azure.storage.blob.BlobContainerClient writeBlobContainerClient, String journalNamePrefix, WriteAccessController writeAccessController)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanexists()Check if the journal already exists.StringgetName()Return the name representing the journal file.JournalFileReaderopenJournalReader()Opens the journal file for reading.JournalFileWriteropenJournalWriter()Opens the journal file for writing.
-
-
-
Constructor Detail
-
AzureJournalFile
public AzureJournalFile(com.azure.storage.blob.BlobContainerClient readBlobContainerClient, com.azure.storage.blob.BlobContainerClient writeBlobContainerClient, String journalNamePrefix, WriteAccessController writeAccessController)
-
-
Method Detail
-
openJournalReader
public JournalFileReader openJournalReader() throws IOException
Description copied from interface:JournalFileOpens the journal file for reading. The returned object will represent the current state of the journal. Subsequent writes made by theJournalFileWriterwon't be visible until a newJournalFileReaderis opened.- Specified by:
openJournalReaderin interfaceJournalFile- Returns:
- the reader representing the current state of the journal
- Throws:
IOException
-
openJournalWriter
public JournalFileWriter openJournalWriter() throws IOException
Description copied from interface:JournalFileOpens the journal file for writing.- Specified by:
openJournalWriterin interfaceJournalFile- Returns:
- Throws:
IOException
-
getName
public String getName()
Description copied from interface:JournalFileReturn the name representing the journal file.- Specified by:
getNamein interfaceJournalFile- Returns:
- name (eg. file name) representing the journal
-
exists
public boolean exists()
Description copied from interface:JournalFileCheck if the journal already exists.- Specified by:
existsin interfaceJournalFile- Returns:
trueif the journal has been already created by theJournalFileWriter
-
-