public class PublicationImage extends java.lang.Object implements NakMessageSender, DriverManagedResource
| Constructor and Description |
|---|
PublicationImage(long correlationId,
long imageLivenessTimeoutNs,
ReceiveChannelEndpoint channelEndpoint,
java.net.InetSocketAddress controlAddress,
int sessionId,
int streamId,
int initialTermId,
int activeTermId,
int initialTermOffset,
int initialWindowLength,
RawLog rawLog,
FeedbackDelayGenerator lossFeedbackDelayGenerator,
java.util.List<org.agrona.concurrent.status.ReadablePosition> subscriberPositions,
org.agrona.concurrent.status.Position hwmPosition,
org.agrona.concurrent.NanoClock clock,
SystemCounters systemCounters,
java.net.InetSocketAddress sourceAddress) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
channelUriString()
Get the string representation of the channel URI.
|
void |
close() |
long |
correlationId() |
void |
delete() |
boolean |
hasReachedEndOfLife()
Has resource reached end of its life and should be reclaimed?
|
boolean |
matches(ReceiveChannelEndpoint channelEndpoint,
int streamId)
Does this image match a given
ReceiveChannelEndpoint and stream id? |
void |
onLossDetected(int termId,
int termOffset,
int length)
Called from the
LossDetector when gap is detected. |
void |
onTimeEvent(long time,
DriverConductor conductor)
Inform resource of time passing and pass it DriverConductor to inform of any state transitions.
|
int |
sessionId()
The session id of the channel from a publisher.
|
io.aeron.driver.PublicationImage.Status |
status()
Return status of the image.
|
void |
status(io.aeron.driver.PublicationImage.Status status)
Set status of the image.
|
int |
streamId()
The stream id of this image within a channel.
|
long |
timeOfLastStateChange() |
void |
timeOfLastStateChange(long time) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitconsumerPosition, decRef, incRef, producerPosition, unblockAtConsumerPositionpublic PublicationImage(long correlationId,
long imageLivenessTimeoutNs,
ReceiveChannelEndpoint channelEndpoint,
java.net.InetSocketAddress controlAddress,
int sessionId,
int streamId,
int initialTermId,
int activeTermId,
int initialTermOffset,
int initialWindowLength,
RawLog rawLog,
FeedbackDelayGenerator lossFeedbackDelayGenerator,
java.util.List<org.agrona.concurrent.status.ReadablePosition> subscriberPositions,
org.agrona.concurrent.status.Position hwmPosition,
org.agrona.concurrent.NanoClock clock,
SystemCounters systemCounters,
java.net.InetSocketAddress sourceAddress)
public void close()
public long correlationId()
public int sessionId()
public int streamId()
public java.lang.String channelUriString()
public boolean matches(ReceiveChannelEndpoint channelEndpoint, int streamId)
ReceiveChannelEndpoint and stream id?channelEndpoint - to match by identity.streamId - to match on value.public io.aeron.driver.PublicationImage.Status status()
DriverConductor.public void status(io.aeron.driver.PublicationImage.Status status)
Set by Receiver for INIT to ACTIVE to INACTIVE
Set by DriverConductor for INACTIVE to LINGER
status - of the imagepublic void onLossDetected(int termId,
int termOffset,
int length)
LossDetector when gap is detected.onLossDetected in interface NakMessageSendertermId - for the gaptermOffset - for the beginning of the gaplength - of the gapNakMessageSenderpublic void onTimeEvent(long time,
DriverConductor conductor)
DriverManagedResourceonTimeEvent in interface DriverManagedResourcetime - now in nanosecondsconductor - to inform of any state transitionspublic boolean hasReachedEndOfLife()
DriverManagedResourcehasReachedEndOfLife in interface DriverManagedResourcepublic void timeOfLastStateChange(long time)
timeOfLastStateChange in interface org.agrona.ManagedResourcepublic long timeOfLastStateChange()
timeOfLastStateChange in interface org.agrona.ManagedResourcepublic void delete()
delete in interface org.agrona.ManagedResourceCopyright © 2014 - 2016 Real Logic Ltd. All Rights Reserved.