Merge b0d25757cc into 1ce6123a78
This commit is contained in:
commit
338edba263
2 changed files with 2 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ public class DiagnosticUtils {
|
||||||
String resourceIdentifier, Instant enqueueTimestamp, Logger log) {
|
String resourceIdentifier, Instant enqueueTimestamp, Logger log) {
|
||||||
final long durationBetweenEnqueueAndAckInMillis =
|
final long durationBetweenEnqueueAndAckInMillis =
|
||||||
Duration.between(enqueueTimestamp, Instant.now()).toMillis();
|
Duration.between(enqueueTimestamp, Instant.now()).toMillis();
|
||||||
if (durationBetweenEnqueueAndAckInMillis > MAX_TIME_BETWEEN_REQUEST_RESPONSE / 3) {
|
if (durationBetweenEnqueueAndAckInMillis > 11000) {
|
||||||
// The above condition logs the warn msg if the delivery time exceeds 11 seconds.
|
// The above condition logs the warn msg if the delivery time exceeds 11 seconds.
|
||||||
log.warn(
|
log.warn(
|
||||||
"{}: Record delivery time to shard consumer is high at {} millis. Check the ExecutorStateEvent logs"
|
"{}: Record delivery time to shard consumer is high at {} millis. Check the ExecutorStateEvent logs"
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,7 @@ import software.amazon.kinesis.retrieval.RecordsPublisher;
|
||||||
@KinesisClientInternalApi
|
@KinesisClientInternalApi
|
||||||
public class ShardConsumer {
|
public class ShardConsumer {
|
||||||
|
|
||||||
public static final int MAX_TIME_BETWEEN_REQUEST_RESPONSE = 60 * 1000;
|
public static final int MAX_TIME_BETWEEN_REQUEST_RESPONSE = Integer.parseInt(System.getProperty("software.amazon.kinesis.lifecycle.ShardConsumer.max_time", "60000"));
|
||||||
private final RecordsPublisher recordsPublisher;
|
private final RecordsPublisher recordsPublisher;
|
||||||
private final ExecutorService executorService;
|
private final ExecutorService executorService;
|
||||||
private final ShardInfo shardInfo;
|
private final ShardInfo shardInfo;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue