Class DbConnectionConfig

java.lang.Object
com.oracle.database.selectai.model.DbConnectionConfig

public final class DbConnectionConfig extends Object
Immutable configuration for creating an SDK-owned Oracle JDBC connection.

Use this configuration with SelectAI.create(DbConnectionConfig) or DatabaseAdmin.create(DbConnectionConfig) when the SDK should open and own one JDBC connection. For pooled or multi-threaded applications, prefer the DataSource-based factory methods.

Password fields are retained in memory as String values so they can be passed to Oracle JDBC. Do not log, persist, or expose this configuration in diagnostics.

  • Method Details

    • getDbUser

      public String getDbUser()
      Returns the database username.
      Returns:
      configured database username
    • getDbPassword

      Returns the database password.

      This value is sensitive. Do not log, persist, or expose it in diagnostics.

      Returns:
      configured database password
    • getWalletPassword

      Returns the password for a password-protected wallet.

      This value is sensitive. Do not log, persist, or expose it in diagnostics.

      Returns:
      configured wallet password, or null when the wallet is not password-protected
    • getJdbcUrl

      public String getJdbcUrl()
      Returns the JDBC URL.
      Returns:
      configured JDBC URL
    • getJdbcProperties

      Returns additional JDBC connection properties.

      The returned Properties object is a defensive copy. Changes to it do not affect this connection configuration. Property values may contain sensitive data, so callers should not log or expose the returned object.

      Returns:
      configured JDBC properties; never null
    • builder

      Creates a builder for database connection configuration.

      The builder does not provide default credentials, wallet locations, or database names. Callers must supply connection values explicitly.

      Returns:
      new builder with no connection values populated