Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-16003

ShardConsumer errors cannot be logged

    XMLWordPrintableJSON

Details

    Description

      Some of the errors in the Kinesis connector show on Flink UI, but are not logged. This causes a serious problem since we cannot see them in our logging aggregation platform, and we cannot create alerts on them. One of the errors is the following:

       

      java.lang.RuntimeException: Rate Exceeded for getRecords operation - all 3 retry attempts returned ProvisionedThroughputExceededException.
       at org.apache.flink.streaming.connectors.kinesis.proxy.KinesisProxy.getRecords(KinesisProxy.java:234)
       at org.apache.flink.streaming.connectors.kinesis.internals.ShardConsumer.getRecords(ShardConsumer.java:311)
       at org.apache.flink.streaming.connectors.kinesis.internals.ShardConsumer.run(ShardConsumer.java:219)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
       at java.lang.Thread.run(Thread.java:748)

       

       

      The code shows that this exception is not caught and hence is not logged and can be detected only from the "exceptions" tab in Flink UI. People who use the connector cannot leverage logging and metrics when such an exception occurs.

      It can be useful to catch all the throwables from the ShardConsumer's run() method and log them.

       

       

      Attachments

        Issue Links

          Activity

            People

              iemre Emre Kartoglu
              oripwk Ori Popowski
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: