Skip to content

Commit

Permalink
Update README with read only example
Browse files Browse the repository at this point in the history
  • Loading branch information
rbygrave committed May 22, 2024
1 parent 40e2530 commit 9d41e9d
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,18 @@ DataSourcePool pool = DataSourcePool.builder()
.url("jdbc:h2:mem:test")
.username("sa")
.password("")
// .readOnly(true)
// .autoCommit(true)
.build();
```

```java
DataSourcePool readOnlyPool = DataSourcePool.builder()
.name("mypool")
.url("jdbc:h2:mem:test")
.username("sa")
.password("")
.readOnly(true)
.autoCommit(true)
.build();
```

Use like any java.sql.DataSource obtaining pooled connections
Expand Down

0 comments on commit 9d41e9d

Please sign in to comment.