Interface JdbcConnectionPool

All Superinterfaces:
org.jvnet.hk2.config.ConfigBeanProxy, jakarta.validation.Payload, org.jvnet.hk2.config.types.PropertyBag, com.sun.enterprise.config.serverbeans.Resource, com.sun.enterprise.config.serverbeans.ResourcePool

@ResourceTypeOrder(deploymentOrder=JDBC_POOL) @UniqueResourceNameConstraint(message="{resourcename.isnot.unique}", payload=JdbcConnectionPool.class) public interface JdbcConnectionPool extends org.jvnet.hk2.config.ConfigBeanProxy, com.sun.enterprise.config.serverbeans.Resource, com.sun.enterprise.config.serverbeans.ResourcePool, org.jvnet.hk2.config.types.PropertyBag
Defines configuration used to create and manage a pool physical database connections. Pool definition is named, and can be referred to by multiple jdbc-resource elements (See <jdbc-resource>).

Each named pool definition results in a pool instantiated at server start-up.

Pool is populated when accessed for the first time. If two or more jdbc-resource elements point to the same jdbc-connection-pool element, they are using the same pool of connections, at run time.

  • Field Details

  • Method Details

    • getDatasourceClassname

      String getDatasourceClassname()
      Gets the value of the datasourceClassname property.

      Name of the vendor supplied JDBC datasource resource manager.

      An XA or global transactions capable datasource class will implement XADataSource interface. Non XA or Local transactions only datasources will implement DataSource interface.

      Returns:
      possible object is String
    • setDatasourceClassname

      void setDatasourceClassname(String datasourceClassname) throws PropertyVetoException
      Sets the value of the datasourceClassname property.
      Parameters:
      datasourceClassname - allowed object is String
      Throws:
      PropertyVetoException
    • getDriverClassname

      String getDriverClassname()
      Gets the value of the driverClassname property.

      Name of the vendor supplied JDBC driver resource manager.

      Get classnames that implement Driver.

      Returns:
      possible object is String
    • setDriverClassname

      void setDriverClassname(String driverClassname) throws PropertyVetoException
      Sets the value of the driverClassname property.
      Parameters:
      driverClassname - allowed object is String
      Throws:
      PropertyVetoException
    • getResType

      @Pattern(regexp="(java.sql.Driver|javax.sql.DataSource|javax.sql.XADataSource|javax.sql.ConnectionPoolDataSource)", message="Valid values: (java.sql.Driver|javax.sql.DataSource|javax.sql.XADataSource|javax.sql.ConnectionPoolDataSource)") @Pattern(regexp="(java.sql.Driver|javax.sql.DataSource|javax.sql.XADataSource|javax.sql.ConnectionPoolDataSource)",message="Valid values: (java.sql.Driver|javax.sql.DataSource|javax.sql.XADataSource|javax.sql.ConnectionPoolDataSource)") String getResType()
      Gets the value of the resType property.

      DataSource implementation class could implement one of DataSource, XADataSource or ConnectionPoolDataSource interfaces.

      This optional attribute must be specified to disambiguate when a Datasource class implements two or more of these interfaces. An error is produced when this attribute has a legal value and the indicated interface is not implemented by the datasource class.

      This attribute has no default value.

      Returns:
      possible object is String
    • setResType

      void setResType(String resType) throws PropertyVetoException
      Sets the value of the resType property.
      Parameters:
      resType - allowed object is String
      Throws:
      PropertyVetoException
    • getSteadyPoolSize

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getSteadyPoolSize()
      Gets the value of the steadyPoolSize property.

      Minimum and initial number of connections maintained in the pool.

      Returns:
      possible object is String
    • setSteadyPoolSize

      void setSteadyPoolSize(String poolSize) throws PropertyVetoException
      Sets the value of the steadyPoolSize property.
      Parameters:
      poolSize - allowed object is String
      Throws:
      PropertyVetoException
    • getMaxPoolSize

      @Min(1L) @Max(2147483647L) @Min(1L) @Max(2147483647L) String getMaxPoolSize()
      Gets the value of the maxPoolSize property.

      Maximum number of connections that can be created.

      Returns:
      possible object is String
    • setMaxPoolSize

      void setMaxPoolSize(String maxPoolSize) throws PropertyVetoException
      Sets the value of the maxPoolSize property.
      Parameters:
      maxPoolSize - allowed object is String
      Throws:
      PropertyVetoException
    • getMaxWaitTimeInMillis

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getMaxWaitTimeInMillis()
      Gets the value of the maxWaitTimeInMillis property.

      Amount of time the caller will wait before getting a connection timeout.

      Default is 60 sec. A value of 0 will force caller to wait indefinitely.

      Returns:
      possible object is String
    • setMaxWaitTimeInMillis

      void setMaxWaitTimeInMillis(String maxWaitTime) throws PropertyVetoException
      Sets the value of the maxWaitTimeInMillis property.
      Parameters:
      maxWaitTime - allowed object is String
      Throws:
      PropertyVetoException
    • getPoolResizeQuantity

      @Min(1L) @Max(2147483647L) @Min(1L) @Max(2147483647L) String getPoolResizeQuantity()
      Gets the value of the poolResizeQuantity property.

      Number of connections to be removed when idle-timeout-in-seconds timer expires. Connections that have idled for longer than the timeout are candidates for removal. When the pool size reaches steady-pool-size, the connection removal stops.

      Returns:
      possible object is String
    • setPoolResizeQuantity

      void setPoolResizeQuantity(String resizeQuantity) throws PropertyVetoException
      Sets the value of the poolResizeQuantity property.
      Parameters:
      resizeQuantity - allowed object is String
      Throws:
      PropertyVetoException
    • getIdleTimeoutInSeconds

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getIdleTimeoutInSeconds()
      Gets the value of the idleTimeoutInSeconds property.

      Maximum time in seconds, that a connection can remain idle in the pool. After this time, the pool implementation can close this connection. Note that this does not control connection timeouts enforced at the database server side. Administrators are advised to keep this timeout shorter than the database server side timeout (if such timeouts are configured on the specific vendor's database), to prevent accumulation of unusable connection in Application Server.

      Returns:
      possible object is String
    • setIdleTimeoutInSeconds

      void setIdleTimeoutInSeconds(String idleTimeout) throws PropertyVetoException
      Sets the value of the idleTimeoutInSeconds property.
      Parameters:
      idleTimeout - allowed object is String
      Throws:
      PropertyVetoException
    • getTransactionIsolationLevel

      @Pattern(regexp="(read-uncommitted|read-committed|repeatable-read|serializable)", message="Valid values: (read-uncommitted|read-committed|repeatable-read|serializable)") @Pattern(regexp="(read-uncommitted|read-committed|repeatable-read|serializable)",message="Valid values: (read-uncommitted|read-committed|repeatable-read|serializable)") String getTransactionIsolationLevel()
      Gets the value of the transactionIsolationLevel property.

      Specifies the Transaction Isolation Level on pooled database connections.

      Optional.

      Has no default. If left unspecified the pool operates with default isolation level provided by the JDBC Driver. A desired isolation level can be set using one of the standard transaction isolation levels, which see.

      Applications that change the Isolation level on a pooled connection programmatically, risk polluting the pool and this could lead to program errors.

      Returns:
      possible object is String
      See Also:
      • "is-isolation-level-guaranteed"
    • setTransactionIsolationLevel

      void setTransactionIsolationLevel(String isolationLevel) throws PropertyVetoException
      Sets the value of the transactionIsolationLevel property.
      Parameters:
      isolationLevel - allowed object is String
      Throws:
      PropertyVetoException
    • getIsIsolationLevelGuaranteed

      String getIsIsolationLevelGuaranteed()
      Gets the value of the isIsolationLevelGuaranteed property.

      Applicable only when a particular isolation level is specified for transaction-isolation-level.

      The default value is true. This assures that every time a connection is obtained from the pool, it is guaranteed to have the isolation set to the desired value.

      This could have some performance impact on some JDBC drivers. Can be set to false by that administrator when they are certain that the application does not change the isolation level before returning the connection.

      Returns:
      possible object is String
    • setIsIsolationLevelGuaranteed

      void setIsIsolationLevelGuaranteed(String isGuaranteed) throws PropertyVetoException
      Sets the value of the isIsolationLevelGuaranteed property.
      Parameters:
      isGuaranteed - allowed object is String
      Throws:
      PropertyVetoException
    • getIsConnectionValidationRequired

      String getIsConnectionValidationRequired()
      Gets the value of the isConnectionValidationRequired property.

      If true, connections are validated (checked to find out if they are usable) before giving out to the application.

      The default is false.

      Returns:
      possible object is String
    • setIsConnectionValidationRequired

      void setIsConnectionValidationRequired(String isValidationRequired) throws PropertyVetoException
      Sets the value of the isConnectionValidationRequired property.
      Parameters:
      isValidationRequired - allowed object is String
      Throws:
      PropertyVetoException
    • getConnectionValidationMethod

      @Pattern(regexp="(auto-commit|meta-data|custom-validation|table)", message="Valid values: (auto-commit|meta-data|custom-validation|table)") @Pattern(regexp="(auto-commit|meta-data|custom-validation|table)",message="Valid values: (auto-commit|meta-data|custom-validation|table)") String getConnectionValidationMethod()
      Gets the value of the connectionValidationMethod property.

      Specifies the type of validation to be performed when is-connection-validation-required is true. The following types of validation are supported:

      • auto-commit using connection.autoCommit()
      • meta-data using connection.getMetaData()
      • table performing a query on a user specified table(see validation-table-name)
      Returns:
      possible object is String
    • setConnectionValidationMethod

      void setConnectionValidationMethod(String validationMethod) throws PropertyVetoException
      Sets the value of the connectionValidationMethod property.
      Parameters:
      validationMethod - allowed object is String
      Throws:
      PropertyVetoException
    • getValidationTableName

      String getValidationTableName()
      Gets the value of the validationTableName property.

      Specifies the table name to be used to perform a query to validate a connection.

      This parameter is mandatory, if connection-validation-type is set to table.

      Verification by accessing a user specified table may become necessary for connection validation, particularly if database driver caches calls to setAutoCommit() and getMetaData().

      Returns:
      possible object is String
    • setValidationTableName

      void setValidationTableName(String tableName) throws PropertyVetoException
      Sets the value of the validationTableName property.
      Parameters:
      tableName - allowed object is String
      Throws:
      PropertyVetoException
    • getValidationClassname

      String getValidationClassname()
      Gets the value of the validationClassName property.

      Specifies the custom validation class name to be used to perform connection validation.

      This parameter is mandatory, if connection-validation-type is set to custom-validation.

      Returns:
      possible object is String
    • setValidationClassname

      void setValidationClassname(String classname) throws PropertyVetoException
      Sets the value of the validationClassName property.
      Parameters:
      classname - allowed object is String
      Throws:
      PropertyVetoException
    • getFailAllConnections

      String getFailAllConnections()
      Gets the value of the failAllConnections property.

      Indicates if all connections in the pool must be closed should a single validation check fail.

      The default is false.

      One attempt will be made to re-establish failed connections.

      Returns:
      possible object is String
    • setFailAllConnections

      void setFailAllConnections(String failAllConnections) throws PropertyVetoException
      Sets the value of the failAllConnections property.
      Parameters:
      failAllConnections - allowed object is String
      Throws:
      PropertyVetoException
    • getNonTransactionalConnections

      String getNonTransactionalConnections()
      Gets the value of the nonTransactionalConnections property.

      A pool with this property set to true returns non-transactional connections. This connection does not get automatically enlisted with the transaction manager.

      Returns:
      possible object is String
    • setNonTransactionalConnections

      void setNonTransactionalConnections(String nonTransactional) throws PropertyVetoException
      Sets the value of the nonTransactionalConnections property.
      Parameters:
      nonTransactional - allowed object is String
      Throws:
      PropertyVetoException
    • getAllowNonComponentCallers

      String getAllowNonComponentCallers()
      Gets the value of the allowNonComponentCallers property.

      A pool with this property set to true, can be used by non-J2EE components (i.e components other than EJBs or Servlets). The returned connection is enlisted automatically with the transaction context obtained from the transaction manager. This property is to enable the pool to be used by non-component callers such as ServletFilters, Lifecycle modules, and 3rd party persistence managers. Standard J2EE components can continue to use such pools. Connections obtained by non-component callers are not automatically cleaned at the end of a transaction by the container. They need to be explicitly closed by the caller.

      Returns:
      possible object is String
    • setAllowNonComponentCallers

      void setAllowNonComponentCallers(String allowNonComponentCallers) throws PropertyVetoException
      Sets the value of the allowNonComponentCallers property.
      Parameters:
      allowNonComponentCallers - allowed object is String
      Throws:
      PropertyVetoException
    • getValidateAtmostOncePeriodInSeconds

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getValidateAtmostOncePeriodInSeconds()
      Gets the value of the validateAtmostOncePeriodInSeconds property.

      Used to set the time-interval within which a connection is validated atmost once.

      Default is 0 which implies that it is not enabled.

      TBD: Documentation is to be corrected.

      Returns:
      possible object is String
    • setValidateAtmostOncePeriodInSeconds

      void setValidateAtmostOncePeriodInSeconds(String validatePeriod) throws PropertyVetoException
      Sets the value of the validateAtmostOncePeriodInSeconds property.
      Parameters:
      validatePeriod - allowed object is String
      Throws:
      PropertyVetoException
    • getConnectionLeakTimeoutInSeconds

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getConnectionLeakTimeoutInSeconds()
      Gets the value of the connectionLeakTimeoutInSeconds property.

      To aid user in detecting potential connection leaks by the application.

      When a connection is not returned back to the pool by the application within the specified period, it is assumed to be a potential leak and stack trace of the caller will be logged.

      Default is 0, which implies there is no leak detection, by default.

      A positive non-zero value turns on leak detection. Note however that, this attribute only detects if there is a connection leak. The connection can be reclaimed only if connection-leak-reclaim is set to true.

      Returns:
      possible object is String
    • setConnectionLeakTimeoutInSeconds

      void setConnectionLeakTimeoutInSeconds(String leakTimeout) throws PropertyVetoException
      Sets the value of the connectionLeakTimeoutInSeconds property.
      Parameters:
      leakTimeout - allowed object is String
      Throws:
      PropertyVetoException
    • getConnectionLeakReclaim

      String getConnectionLeakReclaim()
      Gets the value of the connectionLeakReclaim property.

      If enabled, connection will be reusable (put back into pool) after connection-leak-timeout-in-seconds occurs.

      Default value is false.

      Returns:
      possible object is String
    • setConnectionLeakReclaim

      void setConnectionLeakReclaim(String leakReclaim) throws PropertyVetoException
      Sets the value of the connectionLeakReclaim property.
      Parameters:
      leakReclaim - allowed object is String
      Throws:
      PropertyVetoException
    • getConnectionCreationRetryAttempts

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getConnectionCreationRetryAttempts()
      Gets the value of the connectionCreationRetryAttempts property.

      The number of attempts to create a new connection.

      Default is 0, which implies no retries.

      Returns:
      possible object is String
    • setConnectionCreationRetryAttempts

      void setConnectionCreationRetryAttempts(String creationAttempts) throws PropertyVetoException
      Sets the value of the connectionCreationRetryAttempts property.
      Parameters:
      creationAttempts - allowed object is String
      Throws:
      PropertyVetoException
    • getConnectionCreationRetryIntervalInSeconds

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getConnectionCreationRetryIntervalInSeconds()
      Gets the value of the connectionCreationRetryIntervalInSeconds property.

      The time interval between retries while attempting to create a connection

      Default is 10 seconds.

      Effective when connection-creation-retry-attempts is greater than 0.

      Returns:
      possible object is String
    • setConnectionCreationRetryIntervalInSeconds

      void setConnectionCreationRetryIntervalInSeconds(String retryInterval) throws PropertyVetoException
      Sets the value of the connectionCreationRetryIntervalInSeconds property.
      Parameters:
      retryInterval - allowed object is String
      Throws:
      PropertyVetoException
    • getStatementTimeoutInSeconds

      @Min(-1L) @Min(-1L) String getStatementTimeoutInSeconds()
      Gets the value of the statementTimeoutInSeconds property.

      Sets the timeout property of a connection to enable termination of abnormally long running queries.

      Default value of -1 implies that it is not enabled.

      Returns:
      possible object is String
    • setStatementTimeoutInSeconds

      void setStatementTimeoutInSeconds(String statementTimeout) throws PropertyVetoException
      Sets the value of the statementTimeoutInSeconds property.
      Parameters:
      statementTimeout - allowed object is String
      Throws:
      PropertyVetoException
    • getLazyConnectionEnlistment

      String getLazyConnectionEnlistment()
      Gets the value of the lazyConnectionEnlistment property.

      Enlist a resource to the transaction only when it is actually used in a method, which avoids enlistment of connections that are not used in a transaction. This also prevents unnecessary enlistment of connections cached in the calling components.

      Default value is false.

      Returns:
      possible object is String
    • setLazyConnectionEnlistment

      void setLazyConnectionEnlistment(String lazyEnlistment) throws PropertyVetoException
      Sets the value of the lazyConnectionEnlistment property.
      Parameters:
      lazyEnlistment - allowed object is String
      Throws:
      PropertyVetoException
    • getLazyConnectionAssociation

      String getLazyConnectionAssociation()
      Gets the value of the lazyConnectionAssociation property.

      Connections are lazily associated when an operation is performed on them. Also, they are disassociated when the transaction is completed and a component method ends, which helps reuse of the physical connections.

      Default value is false.

      Returns:
      possible object is String
    • setLazyConnectionAssociation

      void setLazyConnectionAssociation(String lazyAssociation) throws PropertyVetoException
      Sets the value of the lazyConnectionAssociation property.
      Parameters:
      lazyAssociation - allowed object is String
      Throws:
      PropertyVetoException
    • getAssociateWithThread

      String getAssociateWithThread()
      Gets the value of the associateWithThread property.

      Associate a connection with the thread such that when the same thread is in need of a connection, it can reuse the connection already associated with that thread, thereby not incurring the overhead of getting a connection from the pool.

      Default value is false.

      Returns:
      possible object is String
    • setAssociateWithThread

      void setAssociateWithThread(String associateWithThread) throws PropertyVetoException
      Sets the value of the associateWithThread property.
      Parameters:
      associateWithThread - allowed object is String
      Throws:
      PropertyVetoException
    • getPooling

      String getPooling()
      Gets the value of the pooling property.

      Property to disable pooling for the pool.

      Returns:
      possible object is String
    • setPooling

      void setPooling(String pooling) throws PropertyVetoException
      Sets the value of the pooling property.
      Parameters:
      pooling - allowed object is String
      Throws:
      PropertyVetoException
    • getStatementCacheSize

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getStatementCacheSize()
      Gets the value of the statementCacheSize property.

      When specified, statement caching is turned on to cache statements, prepared statements, callable statements that are repeatedly executed by applications.

      Default value is 0, which implies the feature is not enabled.

      Returns:
      possible object is String
    • setStatementCacheSize

      void setStatementCacheSize(String cacheSize) throws PropertyVetoException
      Sets the value of the statementCacheSize property.
      Parameters:
      cacheSize - allowed object is String
      Throws:
      PropertyVetoException
    • getStatementCacheType

      String getStatementCacheType()
      Gets the value of the statementCacheType property.

      When specified, statement caching type is set to cache statements, prepared statements, callable statements that are repeatedly executed by applications.

      Returns:
      possible object is String
    • setStatementCacheType

      void setStatementCacheType(String cacheType) throws PropertyVetoException
      Sets the value of the statementCacheType property.
      Parameters:
      cacheType - allowed object is String
      Throws:
      PropertyVetoException
    • getStatementLeakTimeoutInSeconds

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getStatementLeakTimeoutInSeconds()
      Returns:
      possible object is String
    • setStatementLeakTimeoutInSeconds

      void setStatementLeakTimeoutInSeconds(String leakTimeout) throws PropertyVetoException
      Sets the value of the statementLeakTimeoutInSeconds property.
      Parameters:
      leakTimeout - allowed object is String
      Throws:
      PropertyVetoException
    • getStatementLeakReclaim

      String getStatementLeakReclaim()
    • setStatementLeakReclaim

      void setStatementLeakReclaim(String leakReclaim) throws PropertyVetoException
      Sets the value of the statementLeakReclaim property.
      Parameters:
      leakReclaim - allowed object is String
      Throws:
      PropertyVetoException
    • getInitSql

      String getInitSql()
      Gets the value of the initSql property.

      Init sql is executed whenever a connection created from the pool.

      This is mostly useful when the state of a connection is to be initialized.

      Returns:
      possible object is String
    • setInitSql

      void setInitSql(String initSql) throws PropertyVetoException
      Sets the value of the initSql property.
      Parameters:
      initSql - allowed object is String
      Throws:
      PropertyVetoException
    • getMatchConnections

      String getMatchConnections()
      Gets the value of the matchConnections property.

      To switch on/off connection matching for the pool.

      It can be set to false if the administrator knows that the connections in the pool will always be homogeneous and hence a connection picked from the pool need not be matched by the resource adapter.

      Default value is false.

      Returns:
      possible object is String
    • setMatchConnections

      void setMatchConnections(String matchConnections) throws PropertyVetoException
      Sets the value of the matchConnections property.
      Parameters:
      matchConnections - allowed object is String
      Throws:
      PropertyVetoException
    • getMaxConnectionUsageCount

      @Min(0L) @Max(2147483647L) @Min(0L) @Max(2147483647L) String getMaxConnectionUsageCount()
      Gets the value of the maxConnectionUsageCount property.

      When specified, connections will be re-used by the pool for the specified number of times after which it will be closed. This is useful for instance, to avoid statement-leaks.

      Default value is 0, which implies the feature is not enabled.

      Returns:
      possible object is String
    • setMaxConnectionUsageCount

      void setMaxConnectionUsageCount(String maxUsageCount) throws PropertyVetoException
      Sets the value of the maxConnectionUsageCount property.
      Parameters:
      maxUsageCount - allowed object is String
      Throws:
      PropertyVetoException
    • getWrapJdbcObjects

      String getWrapJdbcObjects()
      Gets the value of the wrapJdbcObjects property.

      When set to true, application will get wrapped jdbc objects for Statement, PreparedStatement, CallableStatement, ResultSet, DatabaseMetaData.

      Defaults to false.

      Returns:
      possible object is String
    • setWrapJdbcObjects

      void setWrapJdbcObjects(String wrapJdbcObjects) throws PropertyVetoException
      Sets the value of the wrapJdbcObjects property.
      Parameters:
      wrapJdbcObjects - allowed object is String
      Throws:
      PropertyVetoException
    • getSqlTraceListeners

      String getSqlTraceListeners()
      Gets the value of the sqlTraceListeners property.

      Comma separated list of SQL trace listener implementations to be used to trace the SQL statements executed by the applications.

      The default logger used by the system logs the SQL statements based on a set of values stored in SQLTraceRecord object.

      Returns:
      possible object is String
    • setSqlTraceListeners

      void setSqlTraceListeners(String traceListeners) throws PropertyVetoException
      Sets the value of the sqlTraceListeners property.
      Parameters:
      traceListeners - allowed object is String
      Throws:
      PropertyVetoException
    • getDescription

      String getDescription()
      Gets the value of the description property.
      Returns:
      possible object is String
    • setDescription

      void setDescription(String description) throws PropertyVetoException
      Sets the value of the description property.
      Parameters:
      description - allowed object is String
      Throws:
      PropertyVetoException
    • getProperty

      @PropertyDesc(name="PortNumber",defaultValue="1527",dataType=org.glassfish.config.support.datatypes.Port.class,description="Port on which the database server listens for requests") @PropertyDesc(name="Password",defaultValue="APP",description="Password for connecting to the database") @PropertyDesc(name="User",defaultValue="APP",description="User name for connecting to the database") @PropertyDesc(name="serverName",defaultValue="localhost",description="Database server for this connection pool") @PropertyDesc(name="DatabaseName",defaultValue="sun-appserv-samples",description="Database for this connection pool.") @PropertyDesc(name="connectionAttributes",defaultValue=";create=true",description="connection attributes") List<org.jvnet.hk2.config.types.Property> getProperty()
      Properties.

      This list is likely incomplete as of 21 October 2008.

      Most JDBC 2.0 drivers permit use of standard property lists, to specify User, Password and other resource configuration. While these are optional properties, according to the specification, several of these properties may be necessary for most databases. See Section 5.3 of JDBC 2.0 Standard Extension API.

      The following are the names and corresponding values for these properties:

      • databaseName name of the Database
      • serverName database Server name
      • port port where a Database server is listening for requests
      • networkProtocol communication Protocol used
      • user default name of the database user with which connections will be stablished. Programmatic database authentication or default-resource-principal specified in vendor specific web and ejb deployment descriptors will take precedence, over this default. The details and caveats are described in detail in the Administrator's guide
      • password password for default database user
      • roleName the initial SQL role name
      • datasourceName used to name an underlying XADataSource, or ConnectionPoolDataSource when pooling of connections is done
      • description textual Description

      When one or more of these properties are specified, they are passed as is using set<Name>(<Value>) methods to the vendors Datasource class (specified in datasource-classname). User and Password properties are used as default principal, if Container Managed authentication is specified and a default-resource-principal is not found in application deployment descriptors.

      Specified by:
      getProperty in interface org.jvnet.hk2.config.types.PropertyBag
    • getIdentity

      default String getIdentity()
      Specified by:
      getIdentity in interface com.sun.enterprise.config.serverbeans.Resource
      Specified by:
      getIdentity in interface com.sun.enterprise.config.serverbeans.ResourcePool