vahmed-hamdy commented on code in PR #39:
URL: 
https://github.com/apache/flink-connector-aws/pull/39#discussion_r1055833568


##########
flink-connector-kinesis/src/main/java/org/apache/flink/streaming/connectors/kinesis/internals/publisher/fanout/StreamConsumerRegistrar.java:
##########
@@ -218,7 +219,7 @@ private void waitForConsumerToDeregister(
             @Nullable final DescribeStreamConsumerResponse 
describeStreamConsumerResponse,
             final String streamConsumerArn,
             final int initialAttempt)
-            throws InterruptedException, ExecutionException {
+            throws Exception {

Review Comment:
   Same goes here



##########
flink-connector-kinesis/src/main/java/org/apache/flink/streaming/connectors/kinesis/internals/publisher/fanout/StreamConsumerRegistrar.java:
##########
@@ -77,8 +79,8 @@ public StreamConsumerRegistrar(
      * @throws InterruptedException
      */
     public String registerStreamConsumer(final String stream, final String 
streamConsumerName)
-            throws ExecutionException, InterruptedException {
-        LOG.debug("Registering stream consumer - {}::{}", stream, 
streamConsumerName);
+            throws Exception {

Review Comment:
   I agree with @dannycranmer , we would better not generalize the Exception.



##########
flink-connector-kinesis/src/main/java/org/apache/flink/streaming/connectors/kinesis/proxy/KinesisProxyAsyncV2Interface.java:
##########
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.streaming.connectors.kinesis.proxy;
+
+import org.apache.flink.annotation.Internal;
+
+import software.amazon.awssdk.services.kinesis.model.SubscribeToShardRequest;
+import 
software.amazon.awssdk.services.kinesis.model.SubscribeToShardResponseHandler;
+
+import java.util.concurrent.CompletableFuture;
+
+/**
+ * Interface for a Kinesis proxy using AWS SDK v2.x operating on multiple 
Kinesis streams within the
+ * same AWS service region.
+ */
+@Internal
+public interface KinesisProxyAsyncV2Interface {
+
+    CompletableFuture<Void> subscribeToShard(
+            SubscribeToShardRequest request, SubscribeToShardResponseHandler 
responseHandler);
+
+    /** Destroy any open resources used by the factory. */
+    default void close() {

Review Comment:
   Why do we provide a default no-op method?



-- 
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