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

Expose exceptions in connector testing framework

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.17.0, 1.16.1, 1.18.0
    • None
    • None

    Description

      I noticed for a few interfaces that we don't expose checked exceptions where it's actually useful. DataStreamSinkV2ExternalContext.createSink or ExternalSystemSplitDataWriter.writeRecords, for instance, is not exposing any Throwable except for UnsupportedOperationException. This implies that internal caught exception need to be either caught and transformed into a RuntimeException or handled internally. AFAIU, that's not what we want. The connector testing framework wants exceptions to be exposed. Therefore, we should improve the interfaces of the framework to allow exceptions to happen (probably depending on the usecase).

      This makes it easier for contributors implementing test cases for their connector giving them the freedom to just expose undesired exceptions instead of handling them internally. JUnit should be the actor dealing with these exceptions.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              mapohl Matthias Pohl
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: