DatabaseModuleBase
Template implementing the commodity methods for a Db module.
Attributes
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
Members list
Type members
Types
Value members
Abstract methods
Creates a Database Layer which requires an existing ConnectionSource.
Creates a Database Layer which requires an existing ConnectionSource.
Attributes
Concrete methods
Provides that ZIO with a Connection. All DB action in the ZIO will be auto-committed. Failures in the initial ZIO will be wrapped in a Right in the error case of the resulting ZIO, with connection errors resulting in a failure with the exception wrapped in a Left.
Provides that ZIO with a Connection. All DB action in the ZIO will be auto-committed. Failures in the initial ZIO will be wrapped in a Right in the error case of the resulting ZIO, with connection errors resulting in a failure with the exception wrapped in a Left.
This method should be implemented by subclasses, to provide the connection.
Attributes
- Definition Classes
As autoCommit
, for ZStream instances instead of ZIO instances.
As autoCommit
, for ZStream instances instead of ZIO instances.
This method should be implemented by subclasses, to provide the connection.
Attributes
- Definition Classes
Commodity method: creates a Database Layer which includes its own ConnectionSource based on a DataSource. Most connection pool implementations should be able to provide you a DataSource.
Commodity method: creates a Database Layer which includes its own ConnectionSource based on a DataSource. Most connection pool implementations should be able to provide you a DataSource.
When no implicit ErrorStrategies is available, the default ErrorStrategies will be used.
Attributes
As fromDatasource
, but provides a default ErrorStrategiesRef. When a method is called with no available implicit ErrorStrategiesRef, the ErrorStrategiesRef in argument will be used.
As fromDatasource
, but provides a default ErrorStrategiesRef. When a method is called with no available implicit ErrorStrategiesRef, the ErrorStrategiesRef in argument will be used.
Attributes
As fromDatasource(ErrorStrategiesRef)
, but an ErrorStrategies
is provided through a layer instead of as a parameter.
As fromDatasource(ErrorStrategiesRef)
, but an ErrorStrategies
is provided through a layer instead of as a parameter.
Attributes
Provides that ZIO with a Connection. A transaction will be opened before any actions in the ZIO, and closed after. It will commit only if the ZIO succeeds, and rollback otherwise. Failures in the initial ZIO will be wrapped in a Right in the error case of the resulting ZIO, with connection errors resulting in a failure with the exception wrapped in a Left.
Provides that ZIO with a Connection. A transaction will be opened before any actions in the ZIO, and closed after. It will commit only if the ZIO succeeds, and rollback otherwise. Failures in the initial ZIO will be wrapped in a Right in the error case of the resulting ZIO, with connection errors resulting in a failure with the exception wrapped in a Left.
This method should be implemented by subclasses, to provide the connection.
Attributes
- Definition Classes
As transactionOrDie
, for ZStream instances instead of ZIO instances.
As transactionOrDie
, for ZStream instances instead of ZIO instances.
Attributes
- Definition Classes
Inherited methods
As autoCommit
, but errors when handling the connections are treated as defects instead of failures.
As autoCommit
, but errors when handling the connections are treated as defects instead of failures.
Attributes
- Inherited from:
- DatabaseOps
As autoCommitOrDie
, for ZStream instances instead of ZIO instances.
As autoCommitOrDie
, for ZStream instances instead of ZIO instances.
Attributes
- Inherited from:
- DatabaseOps
As autoCommit
, but exceptions are simply widened to a common failure type. The resulting failure type is a superclass of both DbException and the error type of the inital ZIO.
As autoCommit
, but exceptions are simply widened to a common failure type. The resulting failure type is a superclass of both DbException and the error type of the inital ZIO.
Attributes
- Inherited from:
- DatabaseOps
As autoCommitOrWiden
, for ZStream instances instead of ZIO instances.
As autoCommitOrWiden
, for ZStream instances instead of ZIO instances.
Attributes
- Inherited from:
- DatabaseOps
As transaction
, but errors when handling the connections are treated as defects instead of failures.
As transaction
, but errors when handling the connections are treated as defects instead of failures.
Attributes
- Inherited from:
- DatabaseOps
As transaction
, but exceptions are simply widened to a common failure type. The resulting failure type is a superclass of both DbException and the error type of the inital ZIO.
As transaction
, but exceptions are simply widened to a common failure type. The resulting failure type is a superclass of both DbException and the error type of the inital ZIO.
Attributes
- Inherited from:
- DatabaseOps
Deprecated and Inherited methods
Attributes
- Deprecated
-
[Since version 4.0.0]
- Inherited from:
- DatabaseOps
Attributes
- Deprecated
-
[Since version 4.0.0]
- Inherited from:
- DatabaseOps
Attributes
- Deprecated
-
[Since version 4.0.0]
- Inherited from:
- DatabaseOps
Attributes
- Deprecated
-
[Since version 4.0.0]
- Inherited from:
- DatabaseOps
Attributes
- Deprecated
-
[Since version 4.0.0]
- Inherited from:
- DatabaseOps
Attributes
- Deprecated
-
[Since version 0.4.0]
- Inherited from:
- DatabaseOps