public static final class Archive.Context extends Object implements Cloneable
The context will be owned by ArchiveConductor after a successful
Archive.launch(Context) and closed via Archive.close().
| Constructor and Description |
|---|
Context() |
| Modifier and Type | Method and Description |
|---|---|
Aeron |
aeron()
Aeron client for communicating with the local Media Driver. |
Archive.Context |
aeron(Aeron aeron)
Aeron client for communicating with the local Media Driver. |
String |
aeronDirectoryName()
Get the top level Aeron directory used for communication between the Aeron client and Media Driver.
|
Archive.Context |
aeronDirectoryName(String aeronDirectoryName)
Set the top level Aeron directory used for communication between the Aeron client and Media Driver.
|
AeronArchive.Context |
archiveClientContext()
Get the
AeronArchive.Context that should be used for communicating
with a remote archive for replication. |
Archive.Context |
archiveClientContext(AeronArchive.Context archiveContext)
Set the
AeronArchive.Context that should be used for communicating
with a remote archive for replication. |
File |
archiveDir()
Get the directory in which the Archive will store recordings and the
Catalog. |
Archive.Context |
archiveDir(File archiveDir)
Set the directory in which the Archive will store recordings and the
Catalog. |
FileChannel |
archiveDirChannel()
Get the
FileChannel for the directory in which the Archive will store recordings and the
Catalog. |
String |
archiveDirectoryName()
Get the directory name to be used to store recordings and the
Catalog. |
Archive.Context |
archiveDirectoryName(String archiveDirectoryName)
Set the directory name to be used for the archive to store recordings and the
Catalog. |
FileStore |
archiveFileStore()
Get the
FileStore where the archive will record streams. |
Archive.Context |
archiveFileStore(FileStore fileStore)
Set the
FileStore where the archive will record streams. |
long |
archiveId()
Get the id of this Archive instance.
|
Archive.Context |
archiveId(long archiveId)
Set the id for this Archive instance.
|
ArchiveMarkFile |
archiveMarkFile()
The
ArchiveMarkFile for the Archive. |
Archive.Context |
archiveMarkFile(ArchiveMarkFile archiveMarkFile)
The
ArchiveMarkFile for the Archive. |
AuthenticatorSupplier |
authenticatorSupplier()
Get the
AuthenticatorSupplier that should be used for the Archive. |
Archive.Context |
authenticatorSupplier(AuthenticatorSupplier authenticatorSupplier)
Set the
AuthenticatorSupplier that will be used for the Archive. |
AuthorisationServiceSupplier |
authorisationServiceSupplier()
Get the
AuthorisationServiceSupplier that should be used for the Archive. |
Archive.Context |
authorisationServiceSupplier(AuthorisationServiceSupplier authorisationServiceSupplier)
Set the
AuthorisationServiceSupplier that will be used for the Archive. |
long |
catalogCapacity()
Capacity in bytes of the
Catalog. |
Archive.Context |
catalogCapacity(long catalogCapacity)
Capacity in bytes of the
Catalog. |
Archive.Context |
catalogFileSyncLevel(int syncLevel)
Set level at which the catalog file should be sync'ed to disk.
|
Archive.Context |
clone()
Perform a shallow copy of the object.
|
void |
close()
Close the context and free applicable resources.
|
void |
conclude()
Conclude the configuration parameters by resolving dependencies and null values to use defaults.
|
long |
conductorCycleThresholdNs()
Threshold for the conductor work cycle time which when exceed it will increment the
conductor cycle time exceeded count.
|
Archive.Context |
conductorCycleThresholdNs(long thresholdNs)
Set a threshold for the conductor work cycle time which when exceed it will increment the
conductor cycle time exceeded count.
|
DutyCycleTracker |
conductorDutyCycleTracker()
The duty cycle tracker for the conductor.
|
Archive.Context |
conductorDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
Set the duty cycle tracker for the conductor.
|
long |
connectTimeoutNs()
The timeout in nanoseconds to wait for connection to be established.
|
Archive.Context |
connectTimeoutNs(long connectTimeoutNs)
The timeout in nanoseconds to wait for connection to be established.
|
String |
controlChannel()
Get the channel URI on which the control request subscription will listen.
|
Archive.Context |
controlChannel(String controlChannel)
Set the channel URI on which the control request subscription will listen.
|
boolean |
controlChannelEnabled()
Should the UDP control channel be enabled.
|
Archive.Context |
controlChannelEnabled(boolean controlChannelEnabled)
Set if the UDP control channel should be enabled.
|
int |
controlMtuLength()
Get the MTU length for the control streams.
|
Archive.Context |
controlMtuLength(int controlMtuLength)
Set the MTU length for the control streams.
|
Counter |
controlSessionsCounter()
Get the counter used to track the number of active control sessions.
|
Archive.Context |
controlSessionsCounter(Counter controlSessionsCounter)
Set the counter used to track the number of active control sessions.
|
int |
controlStreamId()
Get the stream id on which the control request subscription will listen.
|
Archive.Context |
controlStreamId(int controlStreamId)
Set the stream id on which the control request subscription will listen.
|
int |
controlTermBufferLength()
Get the term buffer length for the control streams.
|
Archive.Context |
controlTermBufferLength(int controlTermBufferLength)
Set the term buffer length for the control streams.
|
boolean |
controlTermBufferSparse()
Should the control streams use sparse file term buffers.
|
Archive.Context |
controlTermBufferSparse(boolean controlTermBufferSparse)
Should the control streams use sparse file term buffers.
|
CountedErrorHandler |
countedErrorHandler()
The
errorHandler() that will increment errorCounter() by default. |
Archive.Context |
countedErrorHandler(CountedErrorHandler countedErrorHandler)
Non-default for context.
|
void |
deleteArchiveDirectory()
Deprecated.
|
boolean |
deleteArchiveOnStart()
Should an existing archive be deleted on start.
|
Archive.Context |
deleteArchiveOnStart(boolean deleteArchiveOnStart)
Should an existing archive be deleted on start.
|
void |
deleteDirectory()
Delete the archive directory if the
archiveDir() value is not null. |
EpochClock |
epochClock()
Get the
EpochClock to used for tracking wall clock time. |
Archive.Context |
epochClock(EpochClock clock)
Set the
EpochClock to be used for tracking wall clock time. |
int |
errorBufferLength()
The error buffer length in bytes.
|
Archive.Context |
errorBufferLength(int errorBufferLength)
Set the error buffer length in bytes to use.
|
AtomicCounter |
errorCounter()
Get the error counter that will record the number of errors observed.
|
Archive.Context |
errorCounter(AtomicCounter errorCounter)
Set the error counter that will record the number of errors observed.
|
ErrorHandler |
errorHandler()
Get the
ErrorHandler to be used by the Archive. |
Archive.Context |
errorHandler(ErrorHandler errorHandler)
Set the
ErrorHandler to be used by the Archive. |
int |
fileIoMaxLength()
Get the max length of a file IO operation.
|
Archive.Context |
fileIoMaxLength(int fileIoMaxLength)
Set the max length of a file IO operation.
|
Archive.Context |
fileSyncLevel(int syncLevel)
Set level at which files should be sync'ed to disk.
|
IdleStrategy |
idleStrategy()
Get a new
IdleStrategy for idling the conductor or composite Agent. |
Archive.Context |
idleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
Provides an
IdleStrategy supplier for idling the conductor or composite Agent. |
String |
localControlChannel()
Get the driver local channel URI on which the control request subscription will listen.
|
Archive.Context |
localControlChannel(String controlChannel)
Set the driver local channel URI on which the control request subscription will listen.
|
int |
localControlStreamId()
Get the local stream id on which the control request subscription will listen.
|
Archive.Context |
localControlStreamId(int controlStreamId)
Set the local stream id on which the control request subscription will listen.
|
long |
lowStorageSpaceThreshold()
Threshold below which the archive will reject new recording requests.
|
Archive.Context |
lowStorageSpaceThreshold(long lowStorageSpaceThreshold)
Threshold below which the archive will reject new recording requests.
|
File |
markFileDir()
Get the directory in which the Archive will store mark file (i.e.
|
Archive.Context |
markFileDir(File markFileDir)
Set the directory in which the Archive will store mark file (i.e.
|
long |
maxCatalogEntries()
Deprecated.
This method was deprecated in favor of
catalogCapacity() which returns capacity of
the Catalog in bytes rather than in number of entries. |
Archive.Context |
maxCatalogEntries(long maxCatalogEntries)
Deprecated.
This method was deprecated in favor of
catalogCapacity(long) which works with bytes
rather than number of entries. |
int |
maxConcurrentRecordings()
Get the max number of concurrent recordings.
|
Archive.Context |
maxConcurrentRecordings(int maxConcurrentRecordings)
Set the max number of concurrent recordings.
|
int |
maxConcurrentReplays()
Get the max number of concurrent replays.
|
Archive.Context |
maxConcurrentReplays(int maxConcurrentReplays)
Set the max number of concurrent replays.
|
Counter |
maxReadTimeCounter()
Get the counter used to track the max time used by the replayer to read a block of data.
|
Archive.Context |
maxReadTimeCounter(Counter counter)
Set the counter used to track the max time used by the replayer to read a block of data.
|
Counter |
maxWriteTimeCounter()
Get the counter used to track the max time used by the recorder to write a block of data.
|
Archive.Context |
maxWriteTimeCounter(Counter counter)
Set the counter used to track the max time used by the recorder to write a block of data.
|
Archive.Context |
mediaDriverAgentInvoker(AgentInvoker mediaDriverAgentInvoker)
Set the
AgentInvoker that should be used for the Media Driver if running in a lightweight mode. |
NanoClock |
nanoClock()
Get the
NanoClock to used for tracking wall clock time. |
Archive.Context |
nanoClock(NanoClock clock)
Set the
NanoClock to be used for tracking wall clock time. |
boolean |
ownsAeronClient()
Does this context own the
aeron() client and this takes responsibility for closing it? |
Archive.Context |
ownsAeronClient(boolean ownsAeronClient)
Does this context own the
aeron() client and this takes responsibility for closing it? |
Checksum |
recordChecksum()
Get the
Checksum for checksum computation during recording. |
Archive.Context |
recordChecksum(Checksum recordChecksum)
Provides an explicit
Checksum for checksum computation during recording. |
long |
recorderCycleThresholdNs()
Threshold for the recorder work cycle time which when exceed it will increment the
recorder cycle time exceeded count.
|
Archive.Context |
recorderCycleThresholdNs(long thresholdNs)
Set a threshold for the recorder work cycle time which when exceed it will increment the
recorder cycle time exceeded count.
|
DutyCycleTracker |
recorderDutyCycleTracker()
The duty cycle tracker for the recorder.
|
Archive.Context |
recorderDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
Set the duty cycle tracker for the recorder.
|
IdleStrategy |
recorderIdleStrategy()
Get a new
IdleStrategy for idling the recorder Agent. |
Archive.Context |
recorderIdleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
Provides an
IdleStrategy supplier for idling the recorder Agent. |
ThreadFactory |
recorderThreadFactory()
Get the thread factory used for creating the recorder thread when running in DEDICATED threading mode.
|
Archive.Context |
recorderThreadFactory(ThreadFactory threadFactory)
Set the thread factory used for creating the recorder thread when running in DEDICATED threading mode.
|
String |
recordingEventsChannel()
Get the channel URI on which the recording events publication will publish.
|
Archive.Context |
recordingEventsChannel(String recordingEventsChannel)
Set the channel URI on which the recording events publication will publish.
|
boolean |
recordingEventsEnabled()
Should the recording events channel be enabled.
|
Archive.Context |
recordingEventsEnabled(boolean recordingEventsEnabled)
Set if the recording events channel should be enabled.
|
int |
recordingEventsStreamId()
Get the stream id on which the recording events publication will publish.
|
Archive.Context |
recordingEventsStreamId(int recordingEventsStreamId)
Set the stream id on which the recording events publication will publish.
|
Counter |
recordingSessionCounter()
Get the counter used to track the count of concurrent recording sessions.
|
Archive.Context |
recordingSessionCounter(Counter counter)
Set the counter used to track the count of concurrent recording sessions.
|
Checksum |
replayChecksum()
Get the
Checksum for checksum computation during replay. |
Archive.Context |
replayChecksum(Checksum replayChecksum)
The
Checksum for checksum computation during replay. |
long |
replayerCycleThresholdNs()
Threshold for the replayer work cycle time which when exceed it will increment the
replayer cycle time exceeded count.
|
Archive.Context |
replayerCycleThresholdNs(long thresholdNs)
Set a threshold for the replayer work cycle time which when exceed it will increment the
replayer cycle time exceeded count.
|
DutyCycleTracker |
replayerDutyCycleTracker()
The duty cycle tracker for the replayer.
|
Archive.Context |
replayerDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
Set the duty cycle tracker for the replayer.
|
IdleStrategy |
replayerIdleStrategy()
Get a new
IdleStrategy for idling the replayer Agent. |
Archive.Context |
replayerIdleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
Provides an
IdleStrategy supplier for idling the replayer Agent. |
ThreadFactory |
replayerThreadFactory()
Get the thread factory used for creating the replayer thread when running in DEDICATED threading mode.
|
Archive.Context |
replayerThreadFactory(ThreadFactory threadFactory)
Set the thread factory used for creating the replayer thread when running in DEDICATED threading mode.
|
long |
replayLingerTimeoutNs()
The timeout in nanoseconds for a replay publication to linger after draining.
|
Archive.Context |
replayLingerTimeoutNs(long replayLingerTimeoutNs)
The timeout in nanoseconds for or a replay publication to linger after draining.
|
Counter |
replaySessionCounter()
Get the counter used to track the count of concurrent replay sessions.
|
Archive.Context |
replaySessionCounter(Counter counter)
Set the counter used to track the count of concurrent replay sessions.
|
String |
replicationChannel()
Get the channel URI for replicating stream from another archive as replays.
|
Archive.Context |
replicationChannel(String replicationChannel)
The channel URI for replicating stream from another archive as replays.
|
Archive.Context |
segmentFileLength(int segmentFileLength)
Set the file length to be used for recording data segment files.
|
ThreadFactory |
threadFactory()
Get the thread factory used for creating threads in
ArchiveThreadingMode.SHARED and
ArchiveThreadingMode.DEDICATED threading modes. |
Archive.Context |
threadFactory(ThreadFactory threadFactory)
Set the thread factory used for creating threads in
ArchiveThreadingMode.SHARED and
ArchiveThreadingMode.DEDICATED threading modes. |
ArchiveThreadingMode |
threadingMode()
Get the archive threading mode.
|
Archive.Context |
threadingMode(ArchiveThreadingMode threadingMode)
Set the archive threading mode.
|
String |
toString() |
Counter |
totalReadBytesCounter()
Get the counter used to track the total number of bytes read by the replayer.
|
Archive.Context |
totalReadBytesCounter(Counter counter)
Set the counter used to track the total number of bytes read by the replayer.
|
Counter |
totalReadTimeCounter()
Get the counter used to track the total time used by the replayer to read data.
|
Archive.Context |
totalReadTimeCounter(Counter counter)
Set the counter used to track the total time used by the replayer to read data.
|
Counter |
totalWriteBytesCounter()
Get the counter used to track the total number of bytes written by the recorder.
|
Archive.Context |
totalWriteBytesCounter(Counter counter)
Set the counter used to track the total number of bytes written by the recorder.
|
Counter |
totalWriteTimeCounter()
Get the counter used to track the total time used by the recorder to write data.
|
Archive.Context |
totalWriteTimeCounter(Counter counter)
Set the counter used to track the total time used by the recorder to write data.
|
public Archive.Context clone()
public void conclude()
public Archive.Context deleteArchiveOnStart(boolean deleteArchiveOnStart)
deleteArchiveOnStart - true if an existing archive should be deleted on startup.public boolean deleteArchiveOnStart()
true if an existing archive should be deleted on start up.public Archive.Context archiveDirectoryName(String archiveDirectoryName)
Catalog.
This name is used if archiveDir(File) is not set.archiveDirectoryName - to store recordings and the Catalog.Archive.Configuration.ARCHIVE_DIR_PROP_NAMEpublic String archiveDirectoryName()
Catalog.Catalog.public File archiveDir()
Catalog.Catalog.public Archive.Context archiveDir(File archiveDir)
Catalog.archiveDir - the directory in which the Archive will store recordings and the Catalog.public File markFileDir()
archive-mark.dat). It defaults to
archiveDir() if it is not set explicitly via the
Archive.Configuration.MARK_FILE_DIR_PROP_NAME.archive-mark.dat).Archive.Configuration.MARK_FILE_DIR_PROP_NAME,
archiveDir()public Archive.Context markFileDir(File markFileDir)
archive-mark.dat).markFileDir - the directory in which the Archive will store mark file (i.e. archive-mark.dat).public FileStore archiveFileStore()
FileStore where the archive will record streams.FileStore where the archive will record streams.public Archive.Context archiveFileStore(FileStore fileStore)
FileStore where the archive will record streams. This should only be used for testing.fileStore - where the archive will record streams.public FileChannel archiveDirChannel()
FileChannel for the directory in which the Archive will store recordings and the
Catalog. This can be used for sync'ing the directory.Catalog.public Archive.Context archiveClientContext(AeronArchive.Context archiveContext)
AeronArchive.Context that should be used for communicating
with a remote archive for replication.archiveContext - that should be used for communicating with a remote Archive.public AeronArchive.Context archiveClientContext()
AeronArchive.Context that should be used for communicating
with a remote archive for replication.AeronArchive.Context that should be used for communicating
with a remote archive for replication.public boolean controlChannelEnabled()
true if the UDP control channel should be enabled.Archive.Configuration.CONTROL_CHANNEL_ENABLED_PROP_NAMEpublic Archive.Context controlChannelEnabled(boolean controlChannelEnabled)
controlChannelEnabled - indication of if the network control channel should be enabled.Archive.Configuration.CONTROL_CHANNEL_ENABLED_PROP_NAMEpublic String controlChannel()
AeronArchive.Configuration.CONTROL_CHANNEL_PROP_NAMEpublic Archive.Context controlChannel(String controlChannel)
controlChannel - channel URI on which the control request subscription will listen.AeronArchive.Configuration.CONTROL_CHANNEL_PROP_NAMEpublic int controlStreamId()
AeronArchive.Configuration.CONTROL_STREAM_ID_PROP_NAMEpublic Archive.Context controlStreamId(int controlStreamId)
controlStreamId - stream id on which the control request subscription will listen.AeronArchive.Configuration.CONTROL_STREAM_ID_PROP_NAMEpublic String localControlChannel()
AeronArchive.Configuration.LOCAL_CONTROL_CHANNEL_PROP_NAMEpublic Archive.Context localControlChannel(String controlChannel)
controlChannel - channel URI on which the control request subscription will listen.AeronArchive.Configuration.LOCAL_CONTROL_CHANNEL_PROP_NAMEpublic int localControlStreamId()
AeronArchive.Configuration.LOCAL_CONTROL_STREAM_ID_PROP_NAMEpublic Archive.Context controlTermBufferSparse(boolean controlTermBufferSparse)
controlTermBufferSparse - for the control stream.AeronArchive.Configuration.CONTROL_TERM_BUFFER_SPARSE_PROP_NAMEpublic boolean controlTermBufferSparse()
true if the control stream should use sparse file term buffers.AeronArchive.Configuration.CONTROL_TERM_BUFFER_SPARSE_PROP_NAMEpublic Archive.Context controlTermBufferLength(int controlTermBufferLength)
controlTermBufferLength - for the control streams.AeronArchive.Configuration.CONTROL_TERM_BUFFER_LENGTH_PROP_NAMEpublic int controlTermBufferLength()
AeronArchive.Configuration.CONTROL_TERM_BUFFER_LENGTH_PROP_NAMEpublic Archive.Context controlMtuLength(int controlMtuLength)
controlMtuLength - for the control streams.AeronArchive.Configuration.CONTROL_MTU_LENGTH_PROP_NAMEpublic int controlMtuLength()
AeronArchive.Configuration.CONTROL_MTU_LENGTH_PROP_NAMEpublic Archive.Context localControlStreamId(int controlStreamId)
controlStreamId - stream id on which the control request subscription will listen.AeronArchive.Configuration.LOCAL_CONTROL_STREAM_ID_PROP_NAMEpublic String recordingEventsChannel()
AeronArchive.Configuration.RECORDING_EVENTS_CHANNEL_PROP_NAMEpublic Archive.Context recordingEventsChannel(String recordingEventsChannel)
To support dynamic subscribers then this can be set to multicast or MDC (Multi-Destination-Cast) if multicast cannot be supported for on the available the network infrastructure.
recordingEventsChannel - channel URI on which the recording events publication will publish.AeronArchive.Configuration.RECORDING_EVENTS_CHANNEL_PROP_NAME,
CommonContext.MDC_CONTROL_PARAM_NAMEpublic int recordingEventsStreamId()
AeronArchive.Configuration.RECORDING_EVENTS_STREAM_ID_PROP_NAMEpublic Archive.Context recordingEventsStreamId(int recordingEventsStreamId)
recordingEventsStreamId - stream id on which the recording events publication will publish.AeronArchive.Configuration.RECORDING_EVENTS_STREAM_ID_PROP_NAMEpublic boolean recordingEventsEnabled()
true if the recording events channel should be enabled.AeronArchive.Configuration.RECORDING_EVENTS_ENABLED_PROP_NAMEpublic Archive.Context recordingEventsEnabled(boolean recordingEventsEnabled)
recordingEventsEnabled - indication of if the recording events channel should be enabled.AeronArchive.Configuration.RECORDING_EVENTS_ENABLED_PROP_NAMEpublic String replicationChannel()
Archive.Configuration.REPLICATION_CHANNEL_PROP_NAMEpublic Archive.Context replicationChannel(String replicationChannel)
replicationChannel - channel URI for replicating stream from another archive as replays.Archive.Configuration.REPLICATION_CHANNEL_PROP_NAMEpublic Archive.Context connectTimeoutNs(long connectTimeoutNs)
connectTimeoutNs - to wait for a connection to be established.Archive.Configuration.CONNECT_TIMEOUT_PROP_NAMEpublic long connectTimeoutNs()
Archive.Configuration.CONNECT_TIMEOUT_PROP_NAMEpublic Archive.Context replayLingerTimeoutNs(long replayLingerTimeoutNs)
replayLingerTimeoutNs - in nanoseconds for a replay publication to linger after draining.Archive.Configuration.REPLAY_LINGER_TIMEOUT_PROP_NAME,
Configuration.PUBLICATION_LINGER_PROP_NAMEpublic long replayLingerTimeoutNs()
Archive.Configuration.REPLAY_LINGER_TIMEOUT_PROP_NAME,
Configuration.PUBLICATION_LINGER_PROP_NAMEpublic Archive.Context conductorCycleThresholdNs(long thresholdNs)
thresholdNs - value in nanosecondsArchive.Configuration.CONDUCTOR_CYCLE_THRESHOLD_PROP_NAME,
Archive.Configuration.CONDUCTOR_CYCLE_THRESHOLD_DEFAULT_NSpublic long conductorCycleThresholdNs()
public Archive.Context recorderCycleThresholdNs(long thresholdNs)
thresholdNs - value in nanosecondsArchive.Configuration.RECORDER_CYCLE_THRESHOLD_PROP_NAME,
Archive.Configuration.RECORDER_CYCLE_THRESHOLD_DEFAULT_NSpublic long recorderCycleThresholdNs()
public Archive.Context replayerCycleThresholdNs(long thresholdNs)
thresholdNs - value in nanosecondsArchive.Configuration.REPLAYER_CYCLE_THRESHOLD_PROP_NAME,
Archive.Configuration.REPLAYER_CYCLE_THRESHOLD_DEFAULT_NSpublic long replayerCycleThresholdNs()
public Archive.Context conductorDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
dutyCycleTracker - for the conductor.public DutyCycleTracker conductorDutyCycleTracker()
public Archive.Context recorderDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
dutyCycleTracker - for the recorder.public DutyCycleTracker recorderDutyCycleTracker()
public Archive.Context replayerDutyCycleTracker(DutyCycleTracker dutyCycleTracker)
dutyCycleTracker - for the replayer.public DutyCycleTracker replayerDutyCycleTracker()
public Archive.Context recordChecksum(Checksum recordChecksum)
Checksum for checksum computation during recording.recordChecksum - to be used for recordings.Archive.Configuration.RECORD_CHECKSUM_PROP_NAMEpublic Checksum recordChecksum()
Checksum for checksum computation during recording.Checksum instance for checksum computation during recording or
null if no Checksum was configured.Archive.Configuration.RECORD_CHECKSUM_PROP_NAMEpublic Archive.Context replayChecksum(Checksum replayChecksum)
Checksum for checksum computation during replay.replayChecksum - to be used for replays.Archive.Configuration.REPLAY_CHECKSUM_PROP_NAMEpublic Checksum replayChecksum()
Checksum for checksum computation during replay.Checksum instance for checksum computation during replay or
null if no replay Checksum was configured.Archive.Configuration.REPLAY_CHECKSUM_PROP_NAMEpublic Archive.Context idleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
IdleStrategy supplier for idling the conductor or composite Agent. Which is also
the default for recorder and replayer Agents.idleStrategySupplier - supplier for idling the conductor.public IdleStrategy idleStrategy()
IdleStrategy for idling the conductor or composite Agent. Which is also
the default for recorder and replayer Agents.IdleStrategy for idling the conductor or composite Agent.public Archive.Context recorderIdleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
IdleStrategy supplier for idling the recorder Agent.idleStrategySupplier - supplier for idling the conductor.public IdleStrategy recorderIdleStrategy()
IdleStrategy for idling the recorder Agent.IdleStrategy for idling the recorder Agent.public Archive.Context replayerIdleStrategySupplier(Supplier<IdleStrategy> idleStrategySupplier)
IdleStrategy supplier for idling the replayer Agent.idleStrategySupplier - supplier for idling the replayer.public IdleStrategy replayerIdleStrategy()
IdleStrategy for idling the replayer Agent.IdleStrategy for idling the replayer Agent.public Archive.Context epochClock(EpochClock clock)
EpochClock to be used for tracking wall clock time.clock - EpochClock to be used for tracking wall clock time.public EpochClock epochClock()
EpochClock to used for tracking wall clock time.EpochClock to used for tracking wall clock time.public Archive.Context nanoClock(NanoClock clock)
NanoClock to be used for tracking wall clock time.clock - NanoClock to be used for tracking wall clock time.public NanoClock nanoClock()
NanoClock to used for tracking wall clock time.NanoClock to used for tracking wall clock time.public Archive.Context segmentFileLength(int segmentFileLength)
Image.termBufferLength() is
larger than the segment file length then the term length will be used.segmentFileLength - the file length to be used for recording data segment files.Archive.Configuration.SEGMENT_FILE_LENGTH_PROP_NAMEpublic Archive.Context fileSyncLevel(int syncLevel)
syncLevel - to be applied for file writes.catalogFileSyncLevel(),
Archive.Configuration.FILE_SYNC_LEVEL_PROP_NAMEpublic Archive.Context catalogFileSyncLevel(int syncLevel)
syncLevel - to be applied for file writes.fileSyncLevel(),
Archive.Configuration.CATALOG_FILE_SYNC_LEVEL_PROP_NAMEpublic Archive.Context mediaDriverAgentInvoker(AgentInvoker mediaDriverAgentInvoker)
AgentInvoker that should be used for the Media Driver if running in a lightweight mode.mediaDriverAgentInvoker - that should be used for the Media Driver if running in a lightweight mode.public ErrorHandler errorHandler()
ErrorHandler to be used by the Archive.ErrorHandler to be used by the Archive.public Archive.Context errorHandler(ErrorHandler errorHandler)
ErrorHandler to be used by the Archive.errorHandler - the error handler to be used by the Archive.public Archive.Context countedErrorHandler(CountedErrorHandler countedErrorHandler)
countedErrorHandler - to override the default.public CountedErrorHandler countedErrorHandler()
errorHandler() that will increment errorCounter() by default.errorHandler() that will increment errorCounter() by default.public ArchiveThreadingMode threadingMode()
Archive.Configuration.THREADING_MODE_PROP_NAMEpublic Archive.Context threadingMode(ArchiveThreadingMode threadingMode)
threadingMode - archive threading mode.Archive.Configuration.THREADING_MODE_PROP_NAMEpublic ThreadFactory threadFactory()
ArchiveThreadingMode.SHARED and
ArchiveThreadingMode.DEDICATED threading modes.public Archive.Context threadFactory(ThreadFactory threadFactory)
ArchiveThreadingMode.SHARED and
ArchiveThreadingMode.DEDICATED threading modes. The thread factories can be overridden for the
recorder and replayer by using recorderThreadFactory(ThreadFactory) and
replayerThreadFactory(ThreadFactory) respectively.threadFactory - used for creating threads in SHARED and DEDICATED threading modes.public ThreadFactory recorderThreadFactory()
public Archive.Context recorderThreadFactory(ThreadFactory threadFactory)
threadFactory.threadFactory - used for creating the recorder thread when running in DEDICATED threading mode.public ThreadFactory replayerThreadFactory()
public Archive.Context replayerThreadFactory(ThreadFactory threadFactory)
threadFactory.threadFactory - used for creating the replayer thread when running in DEDICATED threading mode.public Archive.Context errorBufferLength(int errorBufferLength)
errorBufferLength - in bytes to use.Archive.Configuration.ERROR_BUFFER_LENGTH_PROP_NAMEpublic int errorBufferLength()
Archive.Configuration.ERROR_BUFFER_LENGTH_PROP_NAMEpublic Archive.Context archiveId(long archiveId)
archiveId - for this Archive instance.Archive.Configuration.ARCHIVE_ID_PROP_NAMEpublic long archiveId()
Archive.Configuration.ARCHIVE_ID_PROP_NAMEpublic AtomicCounter errorCounter()
public Archive.Context errorCounter(AtomicCounter errorCounter)
errorCounter - the error counter that will record the number of errors observed.public Counter controlSessionsCounter()
public Archive.Context controlSessionsCounter(Counter controlSessionsCounter)
controlSessionsCounter - the counter used to track the number of active control sessions.public Counter recordingSessionCounter()
public Archive.Context recordingSessionCounter(Counter counter)
counter - used to track the count of concurrent recording sessions.public Counter replaySessionCounter()
public Archive.Context replaySessionCounter(Counter counter)
counter - used to track the count of concurrent replay sessions.public Counter totalWriteBytesCounter()
public Archive.Context totalWriteBytesCounter(Counter counter)
counter - used to track the total number of bytes written by the recorder.public Counter totalWriteTimeCounter()
public Archive.Context totalWriteTimeCounter(Counter counter)
counter - used to track the total time used by the recorder to write data.public Counter maxWriteTimeCounter()
public Archive.Context maxWriteTimeCounter(Counter counter)
counter - used to track the max time used by the recorder to write a block of data.public Counter totalReadBytesCounter()
public Archive.Context totalReadBytesCounter(Counter counter)
counter - used to track the total number of bytes read by the replayer.public Counter totalReadTimeCounter()
public Archive.Context totalReadTimeCounter(Counter counter)
counter - used to track the total time used by the replayer to read data.public Counter maxReadTimeCounter()
public Archive.Context maxReadTimeCounter(Counter counter)
counter - used to track the max time used by the replayer to read a block of data.public int maxConcurrentRecordings()
Archive.Configuration.MAX_CONCURRENT_RECORDINGS_PROP_NAMEpublic Archive.Context maxConcurrentRecordings(int maxConcurrentRecordings)
maxConcurrentRecordings - the max number of concurrent recordings.Archive.Configuration.MAX_CONCURRENT_RECORDINGS_PROP_NAMEpublic int maxConcurrentReplays()
Archive.Configuration.MAX_CONCURRENT_REPLAYS_PROP_NAMEpublic Archive.Context maxConcurrentReplays(int maxConcurrentReplays)
maxConcurrentReplays - the max number of concurrent replays.Archive.Configuration.MAX_CONCURRENT_REPLAYS_PROP_NAMEpublic int fileIoMaxLength()
Archive.Configuration.FILE_IO_MAX_LENGTH_PROP_NAMEpublic Archive.Context fileIoMaxLength(int fileIoMaxLength)
fileIoMaxLength - the max length of a file IO operation.Archive.Configuration.FILE_IO_MAX_LENGTH_PROP_NAMEpublic Archive.Context lowStorageSpaceThreshold(long lowStorageSpaceThreshold)
lowStorageSpaceThreshold - in bytes.Archive.Configuration.LOW_STORAGE_SPACE_THRESHOLD_PROP_NAMEpublic long lowStorageSpaceThreshold()
Archive.Configuration.LOW_STORAGE_SPACE_THRESHOLD_PROP_NAME@Deprecated public void deleteArchiveDirectory()
archiveDir() value is not null.
Use deleteDirectory() instead.
public void deleteDirectory()
archiveDir() value is not null.public Archive.Context aeronDirectoryName(String aeronDirectoryName)
aeronDirectoryName - the top level Aeron directory.public String aeronDirectoryName()
public Archive.Context aeron(Aeron aeron)
Aeron client for communicating with the local Media Driver.
This client will be closed when the Archive.close() or close() methods are called if
ownsAeronClient() is true.
aeron - client for communicating with the local Media Driver.Aeron.connect()public Aeron aeron()
Aeron client for communicating with the local Media Driver.
If not provided then a default will be established during conclude() by calling
Aeron.connect().
public Archive.Context ownsAeronClient(boolean ownsAeronClient)
aeron() client and this takes responsibility for closing it?ownsAeronClient - does this context own the aeron() client.public boolean ownsAeronClient()
aeron() client and this takes responsibility for closing it?aeron() client and this takes responsibility for closing it?public Archive.Context archiveMarkFile(ArchiveMarkFile archiveMarkFile)
ArchiveMarkFile for the Archive.archiveMarkFile - ArchiveMarkFile for the Archive.public ArchiveMarkFile archiveMarkFile()
ArchiveMarkFile for the Archive.ArchiveMarkFile for the Archive.@Deprecated public Archive.Context maxCatalogEntries(long maxCatalogEntries)
catalogCapacity(long) which works with bytes
rather than number of entries.Note: This method has no effect.
maxCatalogEntries - for the archive.catalogCapacity(long)@Deprecated public long maxCatalogEntries()
catalogCapacity() which returns capacity of
the Catalog in bytes rather than in number of entries.Note: This method is not used.
catalogCapacity()public Archive.Context catalogCapacity(long catalogCapacity)
Catalog.catalogCapacity - in bytes.Archive.Configuration.CATALOG_CAPACITY_PROP_NAMEpublic long catalogCapacity()
Catalog.Catalog.Archive.Configuration.CATALOG_CAPACITY_PROP_NAMEpublic AuthenticatorSupplier authenticatorSupplier()
AuthenticatorSupplier that should be used for the Archive.AuthenticatorSupplier to be used for the Archive.public Archive.Context authenticatorSupplier(AuthenticatorSupplier authenticatorSupplier)
AuthenticatorSupplier that will be used for the Archive.authenticatorSupplier - AuthenticatorSupplier to use for the Archive.public AuthorisationServiceSupplier authorisationServiceSupplier()
AuthorisationServiceSupplier that should be used for the Archive.AuthorisationServiceSupplier to be used for the Archive.public Archive.Context authorisationServiceSupplier(AuthorisationServiceSupplier authorisationServiceSupplier)
Set the AuthorisationServiceSupplier that will be used for the Archive.
When using an authorisation service for the ConsensusModule, then the following values for protocolId, actionId, and type should be considered.
| Description | protocolId | actionId | type(s) |
| Start the recording of a stream | MessageHeaderDecoder.SCHEMA_ID |
StartRecordingRequestDecoder.TEMPLATE_ID |
(null) |
| Start the recording of a stream (version 2) | StartRecordingRequest2Decoder.TEMPLATE_ID |
(null) |
|
| Stop the recording of a stream | StopRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Replay a stream from the archive | ReplayRequestDecoder.TEMPLATE_ID |
(null) |
|
| Stop a replay from the archive | StopReplayRequestDecoder.TEMPLATE_ID |
(null) |
|
| List the recordings from the archive | ListRecordingsRequestDecoder.TEMPLATE_ID |
(null) |
|
| List the recordings from the archive for a specific URI | ListRecordingsForUriRequestDecoder.TEMPLATE_ID |
(null) |
|
| List a specific recording from the archive | ListRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Extend a recording | ExtendRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Extend a recording (version 2) | ExtendRecordingRequest2Decoder.TEMPLATE_ID |
(null) |
|
| Gets the position of a recording | RecordingPositionRequestDecoder.TEMPLATE_ID |
(null) |
|
| Truncate a recording | TruncateRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Stop a recording by subscription | StopRecordingSubscriptionRequestDecoder.TEMPLATE_ID |
(null) |
|
| Extend a recording | ExtendRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Get the stop position for a recording | StopPositionRequestDecoder.TEMPLATE_ID |
(null) |
|
| Find the last recording for a given stream, session and channel fragment | FindLastMatchingRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| List subscriptions being used for recordings | ListRecordingSubscriptionsRequestDecoder.TEMPLATE_ID |
(null) |
|
| Stop all replays | StopAllReplaysRequestDecoder.TEMPLATE_ID |
(null) |
|
| Start replicating a recording | ReplicateRequestDecoder.TEMPLATE_ID |
(null) |
|
| Start replicating a recording (version 2) | ReplicateRequest2Decoder.TEMPLATE_ID |
(null) |
|
| Stop replication a recording | StopReplicationRequestDecoder.TEMPLATE_ID |
(null) |
|
| Get the start position of a recording | StartRecordingRequestDecoder.TEMPLATE_ID |
(null) |
|
| Detach segment files from a recording | DetachSegmentsRequestDecoder.TEMPLATE_ID |
(null) |
|
| Delete detached segments | DeleteDetachedSegmentsRequestDecoder.TEMPLATE_ID |
(null) |
|
| Attach new segments for a recording | AttachSegmentsRequestDecoder.TEMPLATE_ID |
(null) |
|
| Migrate segments from one recording to another | MigrateSegmentsRequestDecoder.TEMPLATE_ID |
(null) |
|
| Keep alive the archive connection | KeepAliveRequestDecoder.TEMPLATE_ID |
(null) |
|
| Replicate a recording with a tag | TaggedReplicateRequestDecoder.TEMPLATE_ID |
(null) |
|
| Stop recording by recording id | StopRecordingByIdentityRequestDecoder.TEMPLATE_ID |
(null) |
|
| Purge a recording by recording id | PurgeRecordingRequestDecoder.TEMPLATE_ID |
(null) |
authorisationServiceSupplier - AuthorisationServiceSupplier to use for the Archive.public void close()
If ownsAeronClient() is true then the aeron() client will be closed.
Copyright © 2014-2023 Real Logic Limited. All Rights Reserved.