From 7b704246e27944403f0b4aac05a6dbbf028d6111 Mon Sep 17 00:00:00 2001 From: Ashwin Giridharan Date: Wed, 15 Jul 2020 14:52:12 -0700 Subject: [PATCH] Fixing NPE in log --- .../java/software/amazon/kinesis/lifecycle/ShutdownTask.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/amazon-kinesis-client/src/main/java/software/amazon/kinesis/lifecycle/ShutdownTask.java b/amazon-kinesis-client/src/main/java/software/amazon/kinesis/lifecycle/ShutdownTask.java index f72b31f8..208498bc 100644 --- a/amazon-kinesis-client/src/main/java/software/amazon/kinesis/lifecycle/ShutdownTask.java +++ b/amazon-kinesis-client/src/main/java/software/amazon/kinesis/lifecycle/ShutdownTask.java @@ -130,7 +130,7 @@ public class ShutdownTask implements ConsumerTask { // If InvalidStateException happens, it indicates we have a non recoverable error in short term. // In this scenario, we should shutdown the shardConsumer with LEASE_LOST reason to allow other worker to take the lease and retry shutting down. log.warn("Lease {}: Invalid state encountered while shutting down shardConsumer with SHARD_END reason. " + - "Dropping the lease and shutting down shardConsumer using LEASE_LOST reason. ", currentShardLease.leaseKey(), e); + "Dropping the lease and shutting down shardConsumer using LEASE_LOST reason. ", leaseKeyProvider.apply(shardInfo), e); dropLease(currentShardLease); throwOnApplicationException(leaseLostAction, scope, startTime); }