vahmed-hamdy commented on a change in pull request #18669:
URL: https://github.com/apache/flink/pull/18669#discussion_r802792404



##########
File path: 
flink-connectors/flink-connector-aws-kinesis-data-streams/src/main/java/org/apache/flink/connector/kinesis/sink/KinesisDataStreamsSink.java
##########
@@ -126,13 +126,19 @@
                 getMaxRecordSizeInBytes(),
                 failOnError,
                 streamName,
-                kinesisClientProperties);
+                kinesisClientProperties,
+                getInitialState(states));
+    }
+
+    private BufferedRequestState<PutRecordsRequestEntry> getInitialState(
+            List<BufferedRequestState<PutRecordsRequestEntry>> states) {
+        return states.isEmpty() ? BufferedRequestState.emptyState() : 
states.get(0);

Review comment:
       Yes, we wrap the entire state in a single item.
   I agree, will validate and fail




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to