glassfish
  1. glassfish
  2. GLASSFISH-17143

Get validation class names fail to return appropriate values in GUI

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0
    • Fix Version/s: 3.1.2_b02, 4.0
    • Component/s: jdbc
    • Labels:
      None

      Description

      When connection validation method is set to custom-validation, admin console calls the Connector Runtime API getValidationClassNames to get a list of custom validation class names available for the particular database vendor. This API needs to change to take in a datasource classname or a driver classname.

      As of now, this does not work because the advanced tab in GUI has settings to turn on the connection validation to one of the types. After a pool is created, when the user navigates to the advanced tab, the value of the database vendor is lost and as a result, the getValidationClassNames API cannot be invoked.

      This needs to be fixed for displaying the validation class names in GUI.

        Activity

        Hide
        Shalini added a comment -

        Fixed the issue in trunk. Admin GUI can pass the datasource/driver classname to the getValidationClassNames API to retrieve the list of custom validation class names. A new properties file that maps the database vendor to the custom validation class name is introduced. With the classname passed to the API, the database vendor name is got from the existing mappings between the classname and vendor. Additionally, a JDBC40 connection validation mechanism is returned if the classname passed implements the isWrapperFor method.

        Sending appserver/common/amx-core/src/main/java/org/glassfish/admin/amx/base/ConnectorRuntimeAPIProvider.java
        Sending appserver/common/amx-ext-impl/src/main/java/org/glassfish/admin/amx/impl/ext/ConnectorRuntimeAPIProviderImpl.java
        Sending appserver/connectors/connectors-internal-api/src/main/java/com/sun/appserv/connectors/internal/api/ConnectorRuntime.java
        Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/ConnectorRuntime.java
        Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/service/JdbcAdminServiceImpl.java
        Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/util/DriverLoader.java
        Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/resource/pool/monitor/ConnectorConnPoolStatsProvider.java
        Sending appserver/connectors/connectors-runtime/src/main/resources/com/sun/logging/enterprise/resource/resourceadapter/LogStrings.properties
        Sending appserver/jdbc/admin/src/main/java/org/glassfish/jdbc/admin/cli/internal/GetValidationClassNames.java
        Adding appserver/jdbc/templates/src/main/resources/glassfish/lib/install/databases/dbvendormapping/validationclassnames.properties
        Transmitting file data ..........
        Committed revision 48563.

        Show
        Shalini added a comment - Fixed the issue in trunk. Admin GUI can pass the datasource/driver classname to the getValidationClassNames API to retrieve the list of custom validation class names. A new properties file that maps the database vendor to the custom validation class name is introduced. With the classname passed to the API, the database vendor name is got from the existing mappings between the classname and vendor. Additionally, a JDBC40 connection validation mechanism is returned if the classname passed implements the isWrapperFor method. Sending appserver/common/amx-core/src/main/java/org/glassfish/admin/amx/base/ConnectorRuntimeAPIProvider.java Sending appserver/common/amx-ext-impl/src/main/java/org/glassfish/admin/amx/impl/ext/ConnectorRuntimeAPIProviderImpl.java Sending appserver/connectors/connectors-internal-api/src/main/java/com/sun/appserv/connectors/internal/api/ConnectorRuntime.java Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/ConnectorRuntime.java Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/service/JdbcAdminServiceImpl.java Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/util/DriverLoader.java Sending appserver/connectors/connectors-runtime/src/main/java/com/sun/enterprise/resource/pool/monitor/ConnectorConnPoolStatsProvider.java Sending appserver/connectors/connectors-runtime/src/main/resources/com/sun/logging/enterprise/resource/resourceadapter/LogStrings.properties Sending appserver/jdbc/admin/src/main/java/org/glassfish/jdbc/admin/cli/internal/GetValidationClassNames.java Adding appserver/jdbc/templates/src/main/resources/glassfish/lib/install/databases/dbvendormapping/validationclassnames.properties Transmitting file data .......... Committed revision 48563.
        Hide
        Shalini added a comment -

        Fixed this issue in 3.1.2 branch.

        Sending common/amx-core/src/main/java/org/glassfish/admin/amx/base/ConnectorRuntimeAPIProvider.java
        Sending common/amx-ext-impl/src/main/java/org/glassfish/admin/amx/impl/ext/ConnectorRuntimeAPIProviderImpl.java
        Sending connectors/connectors-internal-api/src/main/java/com/sun/appserv/connectors/internal/api/ConnectorRuntime.java
        Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/ConnectorRuntime.java
        Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/service/JdbcAdminServiceImpl.java
        Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/util/DriverLoader.java
        Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/resource/pool/monitor/ConnectorConnPoolStatsProvider.java
        Sending connectors/connectors-runtime/src/main/resources/com/sun/logging/enterprise/resource/resourceadapter/LogStrings.properties
        Sending jdbc/admin/src/main/java/org/glassfish/jdbc/admin/cli/internal/GetValidationClassNames.java
        Adding jdbc/templates/src/main/resources/glassfish/lib/install/databases/dbvendormapping/validationclassnames.properties
        Transmitting file data ..........
        Committed revision 48635.

        Show
        Shalini added a comment - Fixed this issue in 3.1.2 branch. Sending common/amx-core/src/main/java/org/glassfish/admin/amx/base/ConnectorRuntimeAPIProvider.java Sending common/amx-ext-impl/src/main/java/org/glassfish/admin/amx/impl/ext/ConnectorRuntimeAPIProviderImpl.java Sending connectors/connectors-internal-api/src/main/java/com/sun/appserv/connectors/internal/api/ConnectorRuntime.java Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/ConnectorRuntime.java Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/service/JdbcAdminServiceImpl.java Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/connectors/util/DriverLoader.java Sending connectors/connectors-runtime/src/main/java/com/sun/enterprise/resource/pool/monitor/ConnectorConnPoolStatsProvider.java Sending connectors/connectors-runtime/src/main/resources/com/sun/logging/enterprise/resource/resourceadapter/LogStrings.properties Sending jdbc/admin/src/main/java/org/glassfish/jdbc/admin/cli/internal/GetValidationClassNames.java Adding jdbc/templates/src/main/resources/glassfish/lib/install/databases/dbvendormapping/validationclassnames.properties Transmitting file data .......... Committed revision 48635.

          People

          • Assignee:
            Shalini
            Reporter:
            Shalini
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: