Skip to content
Source
Sign inSign up

effect__sql__SqlClient.yaml

23 lines2.4 KB

1"@effect/sql/SqlClient#make":
2 replacement: "effect/sql/SqlClient#make"
3 note: "Moved; custom clients must supply MakeOptions.driver, rename reactiveMailbox to reactiveQueue, and may supply transactionService. Driver names conventionally omit the @effect/sql- prefix, for example pg or pglite."
4"@effect/sql/SqlClient#SafeIntegers":
5 replacement: "effect/sql/SqlClient#SafeIntegers"
6 note: "Moved and changed from a Reference subclass to a Context.Reference value; provide it as a service."
7"@effect/sql/SqlClient#SqlClient":
8 include: true
9 replacement: "effect/sql/SqlClient#SqlClient"
10 note: "Moved into core Effect. Custom service implementations must expose driver and afterCommit; SqlClient.make supplies both. driver identifies the driver independently of its SQL dialect. afterCommit registers effects to run after the outermost successful commit and connection release attempt, discarding rolled-back work. withTransaction now also defers contextual Reactivity.invalidate and mutation invalidations until that commit. Transactions bypassing makeWithTransaction, such as sqlite-do transactions, run callbacks and invalidations immediately."
11"@effect/sql/SqlClient#makeWithTransaction":
12 include: true
13 replacement: "effect/sql/SqlClient#makeWithTransaction"
14 note: "Rename transactionTag to transactionService. acquireConnection is now a function receiving restore and returning Effect<Connection, SqlError, Scope>, rather than an effect returning a scope/connection pair. Register releases in the provided scope and wrap interruptible connection waits with restore; the wrapper closes the scope on transaction completion or failed acquisition."
15"@effect/sql/SqlClient#SqlClient.MakeOptions":
16 replacement: "effect/sql/SqlClient#SqlClient.MakeOptions"
17 note: "Moved; driver is now required and conventionally names the driver package without @effect/sql-, for example pg or pglite. Rename reactiveMailbox to reactiveQueue; transactionService is optional."
18"@effect/sql/SqlClient#TransactionConnection":
19 replacement: "effect/sql/SqlClient#TransactionConnection"
20 note: "Now a factory keyed by client id, not a singleton tag. Prefer the client's transactionService; the payload type is TransactionConnection.Service."
21"@effect/sql/SqlClient#TypeId":
22 replacement: "none"
23 note: "The brand is private in v4; do not inspect or attach it, and obtain clients through SqlClient or SqlClient.make."