Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-6015

Testing JDBC connection is causing it to be created

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 10.0.0.Final
    • 10.0.0.CR5
    • Web Console
    • None
    • Hide

      1 - Create a new datasource through web admin console
      2 - When in final step, click to test the connection
      3 - Even it being a test it seems that it tries to add the datasource, so if you try to test again you'll get:

      Unexpected HTTP response: 500

      Request
      {
          "name" => "MySqlDS",
          "use-ccm" => false,
          "pool-name" => "MySqlDS_Pool",
          "connection-url" => "jdbc:mariadb://192.168.0.119:3306",
          "jta" => false,
          "driver-class" => "org.mariadb.jdbc.Driver",
          "driver-name" => "mariadb-java-client-1.3.4.jar",
          "valid-connection-checker-class-name" => "org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLValidConnectionChecker",
          "background-validation" => true,
          "exception-sorter-class-name" => "org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLExceptionSorter",
          "jndi-name" => "java:/MySqlDS",
          "user-name" => "root",
          "password" => "123",
          "enabled" => true,
          "operation" => "add",
          "address" => [
              ("subsystem" => "datasources"),
              ("data-source" => "MySqlDS")
          ]
      }
      
      Response
      
      Internal Server Error
      {
          "outcome" => "failed",
          "failure-description" => "WFLYCTL0158: Operation handler failed: org.jboss.msc.service.DuplicateServiceException: Service org.wildfly.data-source.MySqlDS is already registered",
          "rolled-back" => true,
          "response-headers" => {"process-state" => "reload-required"}
      }
      
      01:52:14,722 ERROR [org.jboss.as.controller.management-operation] (XNIO-3 task-10) WFLYCTL0013: Operation ("add") failed - address: ([
          ("subsystem" => "datasources"),
          ("data-source" => "MySqlDS")
      ]): org.jboss.msc.service.DuplicateServiceException: Service org.wildfly.data-source.MySqlDS is already registered
      
      Show
      1 - Create a new datasource through web admin console 2 - When in final step, click to test the connection 3 - Even it being a test it seems that it tries to add the datasource, so if you try to test again you'll get: Unexpected HTTP response: 500 Request { "name" => "MySqlDS" , "use-ccm" => false , "pool-name" => "MySqlDS_Pool" , "connection-url" => "jdbc:mariadb: //192.168.0.119:3306" , "jta" => false , "driver-class" => "org.mariadb.jdbc.Driver" , "driver-name" => "mariadb-java-client-1.3.4.jar" , "valid-connection-checker-class-name" => "org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLValidConnectionChecker" , "background-validation" => true , "exception-sorter-class-name" => "org.jboss.jca.adapters.jdbc.extensions.mysql.MySQLExceptionSorter" , "jndi-name" => "java:/MySqlDS" , "user-name" => "root" , "password" => "123" , "enabled" => true , "operation" => "add" , "address" => [ ( "subsystem" => "datasources" ), ( "data-source" => "MySqlDS" ) ] } Response Internal Server Error { "outcome" => "failed" , "failure-description" => "WFLYCTL0158: Operation handler failed: org.jboss.msc.service.DuplicateServiceException: Service org.wildfly.data-source.MySqlDS is already registered" , "rolled-back" => true , "response-headers" => { "process-state" => "reload-required" } } 01:52:14,722 ERROR [org.jboss.as.controller.management-operation] (XNIO-3 task-10) WFLYCTL0013: Operation ( "add" ) failed - address: ([ ( "subsystem" => "datasources" ), ( "data-source" => "MySqlDS" ) ]): org.jboss.msc.service.DuplicateServiceException: Service org.wildfly.data-source.MySqlDS is already registered

      Testing JDBC connection is causing it to be created.

              hpehl@redhat.com Harald Pehl
              darkness.renann@gmail.com Renann Prado (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: