Uploaded image for project: 'CMS'
  1. CMS
  2. CMS-6625

The SQL connection checker does not report an error

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 4.0 alpha
    • None
    • None
    • None

      The SQL connection checker does not report an error whereas the declared server doesn't exist (I'm trying to validate the default values):

      Driver: com.mysql.jdbc.Driver
      Url: jdbc:mysql://servername/basename
      User: username
      No password.

      I get an error in the logs but the parameter are reported valid (green check).

      org.ametys.core.parameter.checker.ParameterCheckerTestFailureException: Communications link failure
      
      Last packet sent to the server was 0 ms ago.
          at org.ametys.plugins.core.impl.checker.SqlConnectionChecker.check(SqlConnectionChecker.java:78)
          at org.ametys.runtime.plugins.admin.configuration.ParameterCheckerAction.act(ParameterCheckerAction.java:131)
          [...]
          
      Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
      
      Last packet sent to the server was 0 ms ago.
          at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
          [...]
          at java.sql.DriverManager.getConnection(DriverManager.java:247)
          at org.ametys.plugins.core.impl.checker.SqlConnectionChecker.check(SqlConnectionChecker.java:70)
          ... 54 more
      Caused by: java.net.UnknownHostException: servername: unknown error
          at java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method)
          [...]
          at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2026)
          ... 66 more
      

            quentin Quentin Glinel-Mortreuil (Inactive)
            ngavalda Nicolas Gavalda (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: