Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-3741

CaptureChangeMySQL should show actual IOException detail when it failed to connect

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.2.0
    • 1.2.0
    • Extensions
    • None

    Description

      When I setup a flow using CaptureChangeMySQL processor, I forgot to enable bin-log, and grant appropriate privileges at MySQL side, then CaptureChangeMySQL failed to connect the MySQL instance.

      However, it wan't easy for me to find what configuration I had missed. The error message that I got was "Could not connect binlog client to any of the specified hosts" without information of actual IOException. By debugging the source code, I finally recalled that extra configuration was needed for bin-log.

      CaptureChangeMySQL.connect() does not log the Exception message and it may be difficult for users to diagnose what went wrong.

      It would be more user friendly if we add the message of the last thrown exception if it failed to connect to any. For instance, IOException message contains details like "com.github.shyiko.mysql.binlog.network.ServerException: Host '192.168.99.1' is not allowed to connect to this MySQL serve".

      Attachments

        Issue Links

          Activity

            People

              mattyb149 Matt Burgess
              ijokarumawak Koji Kawamura
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: