Github user tzulitai commented on a diff in the pull request:

    https://github.com/apache/flink/pull/2916#discussion_r90410106
  
    --- Diff: 
flink-streaming-connectors/flink-connector-kinesis/src/main/java/org/apache/flink/streaming/connectors/kinesis/internals/ShardConsumer.java
 ---
    @@ -107,6 +112,17 @@ protected ShardConsumer(KinesisDataFetcher<T> 
fetcherRef,
                this.fetchIntervalMillis = 
Long.valueOf(consumerConfig.getProperty(
                        
ConsumerConfigConstants.SHARD_GETRECORDS_INTERVAL_MILLIS,
                        
Long.toString(ConsumerConfigConstants.DEFAULT_SHARD_GETRECORDS_INTERVAL_MILLIS)));
    +
    +           if 
(lastSequenceNum.equals(SentinelSequenceNumber.SENTINEL_AT_TIMESTAMP_SEQUENCE_NUM.get()))
 {
    --- End diff --
    
    I think it might be cleaner if we extract / parse the `initTimestamp` in 
the sentinel sequence number case determination at the beginning of run().
    
    As for checking if the timestamp is parseable, we should do that when 
validating the user-provided property configs locally at the job client. You 
can take a look at the constructor code of `FlinkKinesisConsumer` - that's 
where we validate the properties. This validation is done at the job client, so 
that if in any case the properties is errorneous / unparseable, we can handle 
that _before_ a Flink job is actually launched.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to