public class CloudWatchWriterStatistics extends AbstractWriterStatistics implements CloudWatchWriterStatisticsMXBean
| Constructor and Description |
|---|
CloudWatchWriterStatistics() |
| Modifier and Type | Method and Description |
|---|---|
String |
getActualLogGroupName()
Returns the actual log group name for the appender, after substitutions.
|
String |
getActualLogStreamName()
Returns the actual log stream name for the appender, after substitutions.
|
int |
getMessagesDiscarded()
Returns the number of messages discarded by the current writer's message queue.
|
int |
getUnrecoveredWriterRaceRetries()
Returns the times that the writer had to requeue a batch after receiving and
repeated
InvalidSequenceTokenException errors. |
int |
getWriterRaceRetries()
Returns the number of retries due to
InvalidSequenceTokenException
response from PutLogEvents. |
void |
setActualLogGroupName(String actualLogGroupName) |
void |
setActualLogStreamName(String actualLogStreamName) |
void |
updateUnrecoveredWriterRaceRetries() |
void |
updateWriterRaceRetries() |
getLastBatchSize, getLastError, getLastErrorMessage, getLastErrorStacktrace, getLastErrorTimestamp, getMessagesRequeuedLastBatch, getMessagesSent, getMessagesSentLastBatch, getOversizeMessages, getThrottledWrites, incrementOversizeMessages, incrementThrottledWrites, setLastBatchSize, setLastError, setMessageQueue, setMessagesRequeuedLastBatch, setMessagesSentLastBatch, updateMessagesSentclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetLastBatchSize, getLastErrorMessage, getLastErrorStacktrace, getLastErrorTimestamp, getMessagesRequeuedLastBatch, getMessagesSent, getMessagesSentLastBatch, getOversizeMessages, getThrottledWritespublic String getActualLogGroupName()
CloudWatchWriterStatisticsMXBeangetActualLogGroupName in interface CloudWatchWriterStatisticsMXBeanpublic void setActualLogGroupName(String actualLogGroupName)
public String getActualLogStreamName()
CloudWatchWriterStatisticsMXBeangetActualLogStreamName in interface CloudWatchWriterStatisticsMXBeanpublic void setActualLogStreamName(String actualLogStreamName)
public int getMessagesDiscarded()
CloudWatchWriterStatisticsMXBeangetMessagesDiscarded in interface CloudWatchWriterStatisticsMXBeangetMessagesDiscarded in class AbstractWriterStatisticspublic int getWriterRaceRetries()
CloudWatchWriterStatisticsMXBeanInvalidSequenceTokenException
response from PutLogEvents. This exception will be thrown when
there is a race between two writers: both get the same sequence token but only
once can use it. This may happen when there are many instances that are started
at the same time or have a low batch delay.getWriterRaceRetries in interface CloudWatchWriterStatisticsMXBeanpublic void updateWriterRaceRetries()
public int getUnrecoveredWriterRaceRetries()
CloudWatchWriterStatisticsMXBeanInvalidSequenceTokenException errors. This number should
remain 0; if it is non-zero, and particularly if it is a noticeable percentage
of WriterRaceRetries, it indicates that you have too many writers
concurrently accessing the same stream. Either increase batch delay or (better)
direct output to different streams.getUnrecoveredWriterRaceRetries in interface CloudWatchWriterStatisticsMXBeanpublic void updateUnrecoveredWriterRaceRetries()
Copyright © 2023. All rights reserved.