Skip to content

Commit b06ea7c

Browse files
authored
Add JDBC sample and samples index page (#607)
* JIRA WDT-411 Add JDBC sample and samples index page, link to top level README * JIRA WDT-411 Revise JDBC sample * JIRA WDT-411 Revise JDBC sample from document review * Issue #143 - Changes from review * Issue #143 - Combine to a single sample
1 parent 5a05098 commit b06ea7c

File tree

3 files changed

+45
-0
lines changed

3 files changed

+45
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ Many organizations are using WebLogic Server, with or without other Oracle Fusio
2727
- [ODL Configuration](site/odl_configuration.md)
2828
- [Configuring Oracle WebLogic Server Kubernetes Operator](site/kubernetes.md)
2929
- [Variable Injection](site/variable_injection.md)
30+
- [Model Samples](site/samples/samples.md)
3031
- [Model Filters](site/tool_filters.md)
3132
- [The Archive File](site/archive.md)
3233
- [Downloading and Installing](#downloading-and-installing-the-software)

site/samples/jdbc.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
## JDBC Sample
2+
3+
This WDT domain model sample section has a typical configuration for a JDBC data source, including targeting information, connection pool parameters, and other details.
4+
5+
```yaml
6+
resources:
7+
JDBCSystemResource:
8+
'datasource-1':
9+
Target: 'AdminServer,cluster-1'
10+
JdbcResource:
11+
DatasourceType: GENERIC
12+
JDBCConnectionPoolParams:
13+
ConnectionReserveTimeoutSeconds: 10
14+
InitialCapacity: 0
15+
MaxCapacity: 5
16+
MinCapacity: 0
17+
TestConnectionsOnReserve: true
18+
TestTableName: SQL ISVALID
19+
JDBCDriverParams:
20+
DriverName: oracle.jdbc.OracleDriver
21+
PasswordEncrypted: '@@PROP:jdbc.password@@'
22+
URL: 'jdbc:oracle:thin:@//localhost:1521/myDB'
23+
Properties:
24+
user:
25+
Value: scott
26+
```
27+
There are additional sub-folders and attributes available for more configuration options. These can be determined using the [Model Help Tool](../model_help.md). For example, this command will list the attributes and sub-folders for the `JDBCSystemResource/JdbcResource` folder:
28+
```yaml
29+
${WDT_HOME}/bin/modelHelp.sh -oracle_home /tmp/oracle resources:/JDBCSystemResource/JdbcResource
30+
```
31+
32+
For this sample, the target cluster `cluster-1` should be defined elsewhere within this model, or should already exist in a domain that is being updated.
33+
34+
It is recommended that credential fields, such as `PasswordEncrypted`, should not be stored as clear text in the model. Those values can be referenced in a separate variables file or in Kubernetes secrets, or the model can be encrypted using the [Encrypt Model Tool](../encrypt.md).

site/samples/samples.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Model Samples
2+
3+
These sample WDT domain models are provided as a starting point for creating your own working models. They include the most commonly used sub-folders and attributes.
4+
5+
You can use the [Model Help Tool](../model_help.md) to determine the complete list of sub-folders and attributes that can be used in a specific model location. For example, this command will list the attributes and sub-folders for the `JDBCSystemResource/JdbcResource` folder:
6+
```yaml
7+
${WDT_HOME}/bin/modelHelp.sh -oracle_home /tmp/oracle resources:/JDBCSystemResource/JdbcResource
8+
```
9+
## Contents
10+
- [JDBC Sample](jdbc.md)

0 commit comments

Comments
 (0)