|
| 1 | +Galleon Layers |
| 2 | +========= |
| 3 | + |
| 4 | +* `db2-datasource`: Provision the `DB2DS` non xa datasource. Depends on `db2-driver` layer. |
| 5 | +* `db2-driver`: Provision the `db2` driver. This layer installs the JBoss Modules module `com.ibm.db2`. |
| 6 | + |
| 7 | +Build time configuration |
| 8 | +=============== |
| 9 | + |
| 10 | +Configuration to provide when provisioning the Galleon feature-pack. |
| 11 | + |
| 12 | +Required configuration |
| 13 | +-------------------------------- |
| 14 | + |
| 15 | +* `DB2_DRIVER_VERSION` |
| 16 | + |
| 17 | + * Description: The version of the `com.ibm.db2:jcc` Maven artifact. |
| 18 | + * No default value. |
| 19 | + * Required: True |
| 20 | + * System Property: `org.jboss.eap.datasources.db2.driver.version` |
| 21 | + |
| 22 | +Runtime Configuration |
| 23 | +============== |
| 24 | + |
| 25 | +The following set of environment variables and corresponding Java system properties can be used to configure the datasource. |
| 26 | + |
| 27 | +Required configuration |
| 28 | +-------------------------------- |
| 29 | + |
| 30 | +* `DB2_DATABASE` |
| 31 | + |
| 32 | + * Description: Defines the database name to be used in the datasource’s `connection-url` property. |
| 33 | + * No default value. |
| 34 | + * Required: True if `DB2_URL` is not set. |
| 35 | + * System Property: `org.jboss.eap.datasources.db2.database` |
| 36 | + |
| 37 | +* `DB2_PASSWORD` |
| 38 | + |
| 39 | + * Description: Defines the password for the datasource. |
| 40 | + * No default value. |
| 41 | + * Required: True |
| 42 | + * System Property: `org.jboss.eap.datasources.db2.password` |
| 43 | + |
| 44 | +* `DB2_URL` |
| 45 | + |
| 46 | + * Description: Defines the connection URL for the datasource. |
| 47 | + * Default Value: `jdbc:db2://${DB2_HOST}:${DB2_PORT}/${DB2_DATABASE}` |
| 48 | + * Required: True if `DB2_PORT/HOST/DATABASE` are not set. |
| 49 | + * System Property: `org.jboss.eap.datasources.db2.connection-url` |
| 50 | + |
| 51 | +* `DB2_USER` |
| 52 | + |
| 53 | + * Description: Defines the username for the datasource. |
| 54 | + * No default value. |
| 55 | + * Required: True |
| 56 | + * System Property: `org.jboss.eap.datasources.db2.user-name` |
| 57 | + |
| 58 | +Optional configuration |
| 59 | +============== |
| 60 | + |
| 61 | +* `DB2_BACKGROUND_VALIDATION` |
| 62 | + |
| 63 | + * Description: When set to true database connections are validated periodically in a background thread prior to use. Defaults to false, meaning the `validate-on-match` method is enabled by default instead. |
| 64 | + * Default Value: `false` |
| 65 | + * System Property: `org.jboss.eap.datasources.db2.background-validation` |
| 66 | + |
| 67 | +* `DB2_BACKGROUND_VALIDATION_MILLIS` |
| 68 | + |
| 69 | + * Description: Specifies frequency of the validation, in milliseconds, when the `background-validation` database connection validation mechanism is enabled. |
| 70 | + * Default Value: `10000` |
| 71 | + * System Property: `org.jboss.eap.datasources.db2.background-validation-millis` |
| 72 | + |
| 73 | +* `DB2_CONNECTION_CHECKER` |
| 74 | + |
| 75 | + * Description: Specifies a connection checker class that is used to validate connections. Valid value: `org.jboss.jca.adapters.jdbc.extensions.db2.DB2ValidConnectionChecker` |
| 76 | + * Default Value: `org.jboss.jca.adapters.jdbc.extensions.db2.DB2ValidConnectionChecker` |
| 77 | + * System Property: `org.jboss.eap.datasources.db2.valid-connection-checker-class-name` |
| 78 | + |
| 79 | +* `DB2_DATASOURCE` |
| 80 | + |
| 81 | + * Description: Datasource name used in the `jndi-name`. |
| 82 | + * Default Value: `DB2DS` |
| 83 | + * System Property: `org.jboss.eap.datasources.db2.datasource` |
| 84 | + |
| 85 | +* `DB2_ENABLED` |
| 86 | + |
| 87 | + * Description: Set to false to disable the datasource. |
| 88 | + * Default Value: `true` |
| 89 | + * System Property: `org.jboss.eap.datasources.db2.enabled` |
| 90 | + |
| 91 | +* `DB2_EXCEPTION_SORTER` |
| 92 | + |
| 93 | + * Description: Specifies the exception sorter class that is used to properly detect and clean up after fatal database connection exceptions. Valid value: `org.jboss.jca.adapters.jdbc.extensions.db2.DB2ExceptionSorter` |
| 94 | + * Default Value: `org.jboss.jca.adapters.jdbc.extensions.db2.DB2ExceptionSorter` |
| 95 | + * System Property: `org.jboss.eap.datasources.db2.exception-sorter-class-name` |
| 96 | + |
| 97 | +* `DB2_FLUSH_STRATEGY` |
| 98 | + |
| 99 | + * Description: Specifies how the datasource should be flushed in case of an error. |
| 100 | + * Default Value: `FailingConnectionOnly` |
| 101 | + * System Property: `org.jboss.eap.datasources.db2.flush-strategy` |
| 102 | + |
| 103 | +* `DB2_HOST` (or `DB2_SERVICE_HOST`) |
| 104 | + |
| 105 | + * Description: Defines the database server’s host name or IP address to be used in the datasource’s `connection-url` property. |
| 106 | + * Default Value: `localhost` |
| 107 | + * Required: True if `DB2_URL` is not set. |
| 108 | + * System Property: `org.jboss.eap.datasources.db2.host` |
| 109 | + |
| 110 | +* `DB2_IDLE_TIMEOUT_MINUTES` |
| 111 | + |
| 112 | + * Description: Specifies the maximum time, in minutes, a connection may be idle before being closed. |
| 113 | + * Default Value:`30` |
| 114 | + * System Property: `org.jboss.eap.datasources.db2.idle-timeout-minutes` |
| 115 | + |
| 116 | +* `DB2_JNDI` |
| 117 | + |
| 118 | + * Description: Defines the JNDI name for the datasource. |
| 119 | + * Default Value:` java:jboss/datasources/${DB2_DATASOURCE}` |
| 120 | + * System Property: `org.jboss.eap.datasources.db2.jndi-name` |
| 121 | + |
| 122 | +* `DB2_JTA` |
| 123 | + |
| 124 | + * Description: Defines Java Transaction API (JTA) option for the non-XA datasource. |
| 125 | + * Default Value: `true` |
| 126 | + * System Property: `org.jboss.eap.datasources.db2.jta` |
| 127 | + |
| 128 | +* `DB2_MAX_POOL_SIZE` |
| 129 | + |
| 130 | + * Description: Defines the maximum pool size option for the datasource. |
| 131 | + * Default Value: `20` |
| 132 | + * System Property: `org.jboss.eap.datasources.db2.max-pool-size` |
| 133 | + |
| 134 | +* `DB2_MIN_POOL_SIZE` |
| 135 | + |
| 136 | + * Description: Defines the minimum pool size option for the datasource. |
| 137 | + * Default Value: `0` |
| 138 | + * System Property: `org.jboss.eap.datasources.db2.min-pool-size` |
| 139 | + |
| 140 | +* `DB2_PORT` (or `DB2_SERVICE_PORT`) |
| 141 | + |
| 142 | + * Description: Defines the database server’s port to be used in the datasource’s `connection-url` property. |
| 143 | + * Default Value: `50000` |
| 144 | + * Required: True if `DB2_URL` is not set. |
| 145 | + * System Property: `org.jboss.eap.datasources.db2.port` |
| 146 | + |
| 147 | +* `DB2_STALE_CONNECTION_CHECKER` |
| 148 | + |
| 149 | + * Description: Specifies a connection checker class that is used to check stale connections. Valid value: `org.jboss.jca.adapters.jdbc.extensions.db2.DB2StaleConnectionChecker` |
| 150 | + * Default Value: `org.jboss.jca.adapters.jdbc.extensions.novendor.NullStaleConnectionChecker` |
| 151 | + * System Property: `org.jboss.eap.datasources.db2.stale-connection-checker-class-name` |
| 152 | + |
| 153 | +* `DB2_TX_ISOLATION` |
| 154 | + |
| 155 | + * Description: Defines the `java.sql.Connection` transaction isolation level for the datasource. |
| 156 | + * Default Value: `TRANSACTION_READ_COMMITTED` |
| 157 | + * System Property: `org.jboss.eap.datasources.db2.transaction-isolation` |
| 158 | + |
| 159 | +* `DB2_VALIDATE_ON_MATCH` |
| 160 | + |
| 161 | + * Description: Indicates whether or not connection level validation should be done when a connection factory attempts to match a managed connection for a given set. This is typically exclusive to the use of background validation. |
| 162 | + * Default Value: `true` |
| 163 | + * System Property: `org.jboss.eap.datasources.db2.validate-on-match` |
| 164 | + |
0 commit comments