Skip to content

Commit

Permalink
Add doc to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
guizmaii committed Nov 14, 2024
1 parent f7f47c0 commit 413551d
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ Yet another database client for Scala. No dependencies, high productivity.
* [Splicing Literal Values into Frags](#splicing-literal-values-into-frags)
* [Postgres Module](#postgres-module)
* [Logging](#logging-sql-queries)
* [Integrations](#integrations)
* [ZIO](#zio)
* [Motivation](#motivation)
* [Feature List And Database Support](#feature-list)
* [Talks and Blogs](#talks-and-blogs)
Expand Down Expand Up @@ -538,6 +540,23 @@ Setting to TRACE will log SQL queries and their parameters.

You can log slow queries by using the `Transactor` class in conjunction with `SqlLogger.logSlowQueries(FiniteDuration)`. See [Customizing Transactions](#customizing-transactions) for an example. You can also implement your own SqlLogger subclass as desired.

## Integrations

### ZIO

Magnum provides a fine layer of integration with ZIO.
The `magnum-zio` module provides an implementation of the `connect` and `transact` utils that return a ZIO effect.

To use the ZIO integration, add the following dependency:
```scala
"com.augustnagro" %% "magnum-zio" % "x.x.x"
```

and import these utils in your code with:
```scala
import com.augustnagro.magnum.zio_integration.*
```

## Motivation

Historically, database clients on the JVM fall into three categories.
Expand Down

0 comments on commit 413551d

Please sign in to comment.