215 Commits

Author SHA1 Message Date
Joey de Waal
e8384f2a00
fix spelling (#4069) 2025-10-28 05:18:47 -07:00
Austin Bonander
946b6d4d16 fix: break dev-dependency cycle because of rust-lang/cargo#15622 2025-10-14 19:08:15 -07:00
Austin Bonander
388c424f48
fix(macros): smarter .env loading, caching, and invalidation (#4053)
* fix(macros): smarter `.env` loading, caching, and invalidation

* feat(mysql): test `.env` loading in CI

* feat(postgres): test `.env` loading in CI

* feat(macros): allow `DATABASE_URL` to be empty

* fix(examples/postgres): make `cargo-sqlx` executable

* fix(examples/postgres): `cargo sqlx` invocation

* feat(examples/postgres): check offline prepare on more examples

* fix(examples/postgres): the name of this step

* fix(cli): don't suppress error from `dotenv()`

* fix(ci/examples/postgres): don't use heredoc in this step

* fix(ci/examples/postgres): multi-tenant

* fix(ci/examples/sqlite): test `.env` loading

* chore: add CHANGELOG entry
2025-10-14 17:31:12 -07:00
iamjpotts
81526898d4
refactor(core): Remove lifetime parameter from Arguments trait (#3960)
* refactor(core): Remove lifetime parameter from Arguments trait

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(core): Also relax lifetime of argument passed to Query::bind and Query::try_bind

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

---------

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>
2025-09-13 21:47:45 -07:00
iamjpotts
54a0492ee2
refactor(any): Remove lifetime parameter from AnyArguments (#3958)
Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>
2025-09-12 16:11:39 -07:00
Alejandro González
1f4b5f28f3
feat(sqlite): no_tx migration support (#4015)
* chore(sqlx-postgres): fix typo in `migrate.rs` comment

* feat(sqlite): support `no_tx` migrations

SQLite includes several SQL statements that are useful during migrations but
must be executed outside of a transaction to take effect, such as `PRAGMA
foreign_keys = ON|OFF` or `VACUUM`. Additionally, advanced migrations may want
more precise control over how statements are grouped into transactions or
savepoints to achieve the desired atomicity for different parts of the
migration.

While SQLx already supports marking migrations to run outside explicit
transactions through a `-- no-transaction` comment, this feature is currently
only available for `PgConnection`'s `Migrate` implementation, leaving SQLite and
MySQL without this capability. Although it's possible to work around this
limitation by implementing custom migration logic instead of executing
`Migrator#run`, this comes at a cost of significantly reduced developer
ergonomics: code that relies on the default migration logic, such as
`#[sqlx::test]` or `cargo sqlx database setup`, won't support these migrations.

These changes extend `SqliteConnection`'s `Migrate` implementation to support
`no_tx` migrations in the same way as PostgreSQL, addressing this feature gap. I
also considered implementing the same functionality for MySQL, but since I
haven't found a practical use case for it yet, and every
non-transaction-friendly statement I could think about in MySQL triggers
implicit commits anyway, I determined it wasn't necessary at this time and could
be considered an overreach.

* test(sqlite): add test for `no_tx` migrations

* chore(sqlx-sqlite): bring back useful comment

* chore(sqlx-sqlite): unify SQL dialect in annotation comments
2025-09-08 14:55:58 -07:00
Thom Wright
482c9427a9
PostgreSQL SASL – run SHA256 in a blocking executor (#4006)
* Yield while salting password for PG SASL

To prevent spenting too much time doing synchronous work on the
event loop, we yield every few iterations of the hmac-sha256.

* Remove unused bench
2025-09-05 18:02:39 -07:00
jerryq
c01f51330a
Rename PgLTree::from to from_labels and add From<Vec<PgLTreeLabel>> implementation (#3949) 2025-08-21 22:11:35 -07:00
iamjpotts
ff93aa017a
refactor(sqlite): do not borrow bound values, delete lifetime on SqliteArguments (#3957)
* bug(sqlite): query macro argument lifetime use inconsistent with other db platforms

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(sqlite): Improve support for references as query macro bind arguments by removing lifetime parameter from SqliteArguments

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(sqlite): Introduce SqliteArgumentsBuffer type

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(sqlite): Improve cloning of SqliteArgumentValue, SqliteArguments, and SqliteArgumentsBuffer

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(any): Simplify AnyArguments::convert_to to convert_into

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

---------

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>
2025-08-19 13:59:37 -07:00
iamjpotts
e77f32ea5e
chore: Fix warnings for custom postgres_## cfg flags (#3950)
* chore: Fix warnings for custom postgres_## cfg flags

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* pr feedback - reorder cfg allowance; enable test_pg_copy_chunked test

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(postgres): Remove two more deprecated cfg flag uses (from docstrings)

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

* refactor(ci): Use separate job for postgres ssl auth tests

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>

---------

Signed-off-by: Joshua Potts <8704475+iamjpotts@users.noreply.github.com>
2025-08-18 16:17:45 -07:00
Niclas Klugmann
129e3351ae
fix documentation for rustls native root certificates (#3975) 2025-08-15 14:32:08 -07:00
Joey de Waal
24317d5eab
Fix logger regression (#3938) 2025-07-17 14:58:36 -07:00
Duncan
01d5443f15
feat(postgres): remove lifetime from PgAdvisoryLockGuard (#3495)
Unlike with CPU synchronization primitives, there is no semantic requirement
that the guard borrows the lock object.

We preserve the optimization of memoizing the release query by wrapping it in
an Arc. This way all instances of `PgAdvisoryLockGuard` that originate from the
same lock will share a single instance of the release query.

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2025-07-17 02:32:05 -07:00
Joey de Waal
469f22788e
breaking: add SqlStr (#3723)
* refactor: introduce `SqlSafeStr` API

* rebase main

* Add SqlStr + remove Statement lifetime

* Update the definition of Executor and AnyConnectionBackend + update Postgres driver

* Update MySql driver

* Update Sqlite driver

* remove debug clone count

* Reduce the amount of SqlStr clones

* improve QueryBuilder error message

* cargo fmt

* fix clippy warnings

* fix doc test

* Avoid panic in `QueryBuilder::reset`

* Use `QueryBuilder` when removing all test db's

* Add comment to `SqlStr`

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* Update sqlx-core/src/query_builder.rs

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* Add `Clone` as supertrait to `Statement`

* Move `Connection`, `AnyConnectionBackend` and `TransactionManager` to `SqlStr`

* Replace `sql_cloned` with `sql` in `Statement`

* Update `Executor` trait

* Update unit tests + QueryBuilder changes

* Remove code in comments

* Update comment in `QueryBuilder`

* Fix clippy warnings

* Update `Migrate` comment

* Small changes

* Move `Migration` to `SqlStr`

---------

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2025-07-07 00:35:54 -07:00
David Cornu
2702b9851a
feat: Unify Debug implementations across PgRow, MySqlRow and SqliteRow (#3890)
* Introduce `debug_row` function

* Use `debug_row` to implement `Debug` for `SqliteRow`

* Use `debug_row` in `PgRow`'s `Debug` implementation

* Match `MySqlRow`'s `Debug` implementation
2025-07-06 19:24:07 -07:00
Joey de Waal
9f28837bca
feat(Postgres): support nested domain types (#3641)
* feat(Postgres): support nested domain types

* chore: clippy

* fix(postgres): Recurse when looking for type info.
2025-07-06 18:37:56 -07:00
Tyler Hawkes
97de03482c
Add PgBindIter for encoding and use it as the implementation encoding &[T] (#3651)
* Add PgBindIter for encoding and use it as the implementation encoding &[T]

* Implement suggestions from review

* Add docs to PgBindIter and test to ensure it works for owned and borrowed types

* Use extension trait for iterators to allow code to flow better. Make struct private. Don't reference unneeded generic T. Make doc tests compile.

* Fix doc function

* Fix doc test to actually compile

* Use Cell<Option<I>> instead of Clone bound
2025-07-04 17:59:38 -07:00
Joey de Waal
60f67dbc39
feat: implement Encode, Decode, Type for Arc<str> and Arc<[u8]> (and Rc equivalents) (#3675)
* implement Encode, Decode, Type for Arc<str> and Arc<[u8]> (and Rc equivalents)

* sqlx-sqlite: Remove clone in Encode impl

* sqlx-sqlite: Remove unnecessary impls
2025-07-04 17:58:33 -07:00
Joey de Waal
0f891a3c56
Remove unnecessary boxfutures (#3525)
* Remove `BoxFuture`'s from `Connection` and `ConnectOptions`

* Remove `BoxFuture`'s for `MigrateDatabase`

* Remove `BoxFuture`'s for `TransactionManager`

* Remove `BoxFuture`'s for `TestSupport`

* Remove `BoxFuture`'s from `PgPoolCopyExt`

* Clippy fixes

* Box timeout future in debug mode
2025-07-04 17:53:46 -07:00
Ole Martin Ruud
a0c7769d85
Feature: Add exclusion violation error kind (#3918)
* feat: add exclusion violation error kind

* chore: add test for exclusion error kind
2025-07-04 16:52:58 -07:00
Nicolás Hatcher
9de593a0e5
fix[sqlx-postgres]: do a checked_mul to prevent panic when casting from db (#3919) 2025-07-04 16:51:43 -07:00
miniduikboot
2fd3dabf38
Bump etcetera to 0.10.0 (#3867)
This bumps the underlying version of windows-sys used by this crate.

I've only compile tested this by crosscompiling from Linux.
2025-06-30 17:23:12 -07:00
Joey de Waal
8602d94c4d
Implement Decode, Encode and Type for Box, Arc, Cow and Rc (#3674)
* feat: implement Decode,Encode,Type for Box,Arc,Cow

* feat implement Encode,Type for Rc

* feat: implement Decode for Rc

* chore: make tests more concise

* chore: use macro's

* chore: remove conflicting impls

* chore: more macro's

* Relax Sized bound for Decode, Encode

* update unit tests

* fixes after review

* add comment in `Decode` impl

* add comment about `ToOwned` trait bound

* add comment explaining why decoding to `Cow::Owned` was chosen

* Remove unnecessary Decode impls
2025-06-30 17:03:48 -07:00
V02460
1341b396bb
Escape PostgreSQL options (#3800)
* Escape PostgreSQL options

* Use raw string literals in test case

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* Document escaping behavior for options

* Remove heap allocations for options formatting

* Use an actual config option for the test case

---------

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2025-06-30 16:40:44 -07:00
Austin Bonander
25cbeedab4
feat: create sqlx.toml format (#3383)
* feat: create `sqlx.toml` format

* feat: add support for ignored_chars config to sqlx_core::migrate

* chore: test ignored_chars with `U+FEFF` (ZWNBSP/BOM)

https://en.wikipedia.org/wiki/Byte_order_mark

* refactor: make `Config` always compiled

simplifies usage while still making parsing optional for less generated code

* refactor: add origin information to `Column`

* feat(macros): implement `type_override` and `column_override` from `sqlx.toml`

* refactor(sqlx.toml): make all keys kebab-case, create `macros.preferred-crates`

* feat: make macros aware of `macros.preferred-crates`

* feat: make `sqlx-cli` aware of `database-url-var`

* feat: teach macros about `migrate.table-name`, `migrations-dir`

* feat: teach macros about `migrate.ignored-chars`

* chore: delete unused source file `sqlx-cli/src/migration.rs`

* feat: teach `sqlx-cli` about `migrate.defaults`

* feat: teach `sqlx-cli` about `migrate.migrations-dir`

* feat: teach `sqlx-cli` about `migrate.table-name`

* feat: introduce `migrate.create-schemas`

* WIP feat: create multi-tenant database example

* fix(postgres): don't fetch `ColumnOrigin` for transparently-prepared statements

* feat: progress on axum-multi-tenant example

* feat(config): better errors for mislabeled fields

* WIP feat: filling out axum-multi-tenant example

* feat: multi-tenant example

No longer Axum-based because filling out the request routes would have distracted from the purpose of the example.

* chore(ci): test multi-tenant example

* fixup after merge

* fix(ci): enable `sqlx-toml` in CLI build for examples

* fix: CI, README for `multi-tenant`

* fix: clippy warnings

* fix: multi-tenant README

* fix: sequential versioning inference for migrations

* fix: migration versioning with explicit overrides

* fix: only warn on ambiguous crates if the invocation relies on it

* fix: remove unused imports

* fix: doctest

* fix: `sqlx mig add` behavior and tests

* fix: restore original type-checking order

* fix: deprecation warning in `tests/postgres/macros.rs`

* feat: create postgres/multi-database example

* fix: examples/postgres/multi-database

* fix: cargo fmt

* chore: add tests for config `migrate.defaults`

* fix: sqlx-cli/tests/add.rs

* feat(cli): add `--config` override to all relevant commands

* chore: run `sqlx mig add` test with `RUST_BACKTRACE=1`

* fix: properly canonicalize config path for `sqlx mig add` test

* fix: get `sqlx mig add` test passing

* fix(cli): test `migrate.ignored-chars`, fix bugs

* feat: create `macros.preferred-crates` example

* fix(examples): use workspace `sqlx`

* fix: examples

* fix(sqlite): unexpected feature flags in `type_checking.rs`

* fix: run `cargo fmt`

* fix: more example fixes

* fix(ci): preferred-crates setup

* fix(examples): enable default-features for workspace `sqlx`

* fix(examples): issues in `preferred-crates`

* chore: adjust error message for missing param type in `query!()`

* doc: mention new `sqlx.toml` configuration

* chore: add `CHANGELOG` entry

Normally I generate these when cutting the release, but I wanted to take time to editorialize this one.

* doc: fix new example titles

* refactor: make `sqlx-toml` feature non-default, improve errors

* refactor: eliminate panics in `Config` read path

* chore: remove unused `axum` dependency from new examples

* fix(config): restore fallback to default config for macros

* chore(config): remove use of `once_cell` (to match `main`)
2025-06-30 16:34:46 -07:00
Paolo Barbolini
764ae2f702
chore: replace once_cell OnceCell/Lazy with std OnceLock/LazyLock (#3709) 2025-06-17 16:38:02 -07:00
Austin Bonander
90797200ee
groundwork for 0.9.0-alpha.1 (#3821)
* chore: bump version to `0.9.0-alpha.1`

* chore: delete unused `sqlx-bench` package

* chore: set `rust-version` to 1.85 for all crates

* fix: lots of new Clippy warnings

* fix: lots more Clippy warnings

* fix(cli): add `_sqlite` feature

* fix: lots, *lots* more Clippy warnings

* fix(core): warning in `tls_rustls`

* breaking: delete runtime+TLS combination features

* chore: don't re-export unstable `TransactionManager` trait

* chore: 0.9.0-alplha.1 CHANGELOG

* chore: increase MSRV further to 1.86

* fix: more clippy warnings
2025-06-01 21:09:55 -07:00
Thom Wright
d335f782cf
Use unnamed statement in pg when not persistent (#3863)
This will automatically close the prepared statement when
another query is run, avoiding a memory leak.
2025-05-19 14:58:40 -07:00
Austin Bonander
f9084035d7
0.8.4 release (#3819)
* chore: prepare 0.8.4 release

* fix(postgres): send `limit: 0` for all `Execute` messages

fixes #3673

* fix: let `CertificateInput::from` infer any PEM-encoded document

https://github.com/launchbadge/sqlx/pull/3809#issuecomment-2800293813

* doc: improve documentation of `PgConnectOptions`

fixes #3740

* chore: update CHANGELOG from PR
2025-04-13 21:55:14 -07:00
Markus Schirp
154878547e
fix: PgConnectOptions docs (#3809) 2025-04-13 17:21:15 -07:00
TeCHiScy
082aed5c2b
Fix error message typo in PgPoint::from_str (#3811) 2025-04-01 00:41:28 -07:00
Beau Gieskens
1c9cbe939a
feat: add ipnet support (#3710)
* feat: add ipnet support

* fix: ipnet not decoding IP address strings

* fix: prefer ipnetwork to ipnet for compatibility

* fix: unnecessary cfg
2025-03-23 17:19:05 -07:00
Austin Bonander
393b731d5e
Merge of #3427 (by @mpyw) and #3614 (by @bonsairobo) (#3765)
* feat: Implement `get_transaction_depth` for drivers

* test: Verify `get_transaction_depth()` on postgres

* Refactor: `TransactionManager` delegation without BC

SQLite implementation is currently WIP

* Fix: Avoid breaking changes on `AnyConnectionBackend`

* Refactor: Remove verbose `SqliteConnection` typing

* Feat: Implementation for SQLite

I have included `AtomicUsize` in `WorkerSharedState`. Ideally, it is not desirable to execute `load` and `fetch_add` in two separate steps, but we decided to allow it here since there is only one thread writing. To prevent writing from other threads, the field itself was made private, and a getter method was provided with `pub(crate)`.

* Refactor: Same approach for `cached_statements_size`

ref: a66787d36d62876b55475ef2326d17bade817aed

* Fix: Add missing `is_in_transaction` for backend

* Doc: Remove verbose "synchronously" word

* Fix: Remove useless `mut` qualifier

* feat: add Connection::begin_with

This patch completes the plumbing of an optional statement from these methods to
`TransactionManager::begin` without any validation of the provided statement.

There is a new `Error::InvalidSavePoint` which is triggered by any attempt to
call `Connection::begin_with` when we are already inside of a transaction.

* feat: add Pool::begin_with and Pool::try_begin_with

* feat: add Error::BeginFailed and validate that custom "begin" statements are successful

* chore: add tests of Error::BeginFailed

* chore: add tests of Error::InvalidSavePointStatement

* chore: test begin_with works for all SQLite "BEGIN" statements

* chore: improve comment on Connection::begin_with

* feat: add default impl of `Connection::begin_with`

This makes the new method a non-breaking change.

* refactor: combine if statement + unwrap_or_else into one match

* feat: use in-memory SQLite DB to avoid conflicts across tests run in parallel

* feedback: remove public wrapper for sqlite3_txn_state

Move the wrapper directly into the test that uses it instead.

* fix: cache Status on MySqlConnection

* fix: compilation errors

* fix: format

* fix: postgres test

* refactor: delete `Connection::get_transaction_depth`

* fix: tests

---------

Co-authored-by: mpyw <ryosuke_i_628@yahoo.co.jp>
Co-authored-by: Duncan Fairbanks <duncanfairbanks6@gmail.com>
2025-03-10 14:29:46 -07:00
James H.
2f10c29dfd
feat(postgres): add geometry circle (#3773)
* feat: circle

* docs: comments
2025-03-09 15:01:30 -07:00
James H.
ca3a509036
feat(postgres): add geometry polygon (#3769)
* feat: add polygon

* test: paths for pgpoints in polygon test

* fix: import typo

* chore(Sqlite): remove ci.db from repo (#3768)

* fix: CI

* Fix breakage from Rustup 1.28 <https://blog.rust-lang.org/2025/03/02/Rustup-1.28.0.html>
* Let `Swatinem/rust-cache` generate cache keys

* fix(ci): upgrade Ubuntu image to 24.04

For some reason the `cargo +beta clippy` step is failing because `libsqlite3-sys` starts requiring Glibc >= 2.39 but I don't have time to figure out why and I can't reproduce it in a clean environment.

---------

Co-authored-by: joeydewaal <99046430+joeydewaal@users.noreply.github.com>
Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2025-03-07 01:25:45 -08:00
Chitoku
a92626d6cc postgres: Use current tracing span when dropping PgListener 2025-03-05 01:30:38 -08:00
James H.
5c573e15eb
feat(postgres): add geometry path (#3716)
* feat: add geometry path

* fix: paths to pg point

* test: remove array tests for path

* Fix readme: uuid feature is gating for all repos (#3720)

The readme previously stated that the uuid feature is only for postres but it actually also gates the functionality in mysql and sqlite.

* Replace some futures_util APIs with std variants (#3721)

* feat(sqlx-cli): Add flag to disable automatic loading of .env files (#3724)

* Add flag to disable automatic loading of .env files

* Update sqlx-cli/src/opt.rs

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

---------

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>

* chore: expose bstr feature (#3714)

* chore: replace rustls-pemfile with rustls-pki-types (#3725)

* QueryBuilder: add `debug_assert` when `push_values` is passed an empty set of tuples (#3734)

* throw a warning in tracing so that the empty tuples would be noticed

* use debug assertion to throw a panic in debug mode

* fix: merge conflicts

* chore(cli): remove unused async-trait crate from dependencies (#3754)

* Update pull_request_template.md

* Fix example calculation (#3741)

* Avoid privilege requirements by using an advisory lock in test setup (postgres). (#3753)

* feat(sqlx-postgres): use advisory lock to avoid setup race condition

* fix(sqlx-postgres): numeric hex constants not supported before postgres 16

* Small doc correction. (#3755)

When sqlx-core/src/from_row.rs was updated to implement FromRow for tuples of up to 16 values, a comment was left stating that it was implemented up to tuples of 9 values.

* Update FAQ.md

* refactor(cli): replace promptly with dialoguer (#3669)

* docs(pool): recommend actix-web ThinData over Data to avoid two Arcs (#3762)

Both actix_web::web::Data and sqlx::PgPool internally wrap an Arc. Thus,
using Data<PgPool> as an extractor in an actix-web route handler results
in two Arcs wrapping the data of interest, which isn't ideal.

Actix-web 4.9.0 introduced a new web::ThinData extractor for cases like
this, where the data is already wrapped in an `Arc` (or is otherwise
similarly cheap and sensible to simply clone), which doesn't wrap the
inner value in a (second) Arc.

Since the new extractor is better suited to the task, suggest it in
place of web::Data when giving an example on how to share a pool.

* fix: merge conflicts

* fix: use types mod from main

* fix: merge conflicts

* fix: merge conflicts

* fix: merge conflicts

* fix: ordering of types mod

* fix: path import

* test: no array test for path

---------

Co-authored-by: Jon Thacker <thacker.jon@gmail.com>
Co-authored-by: Paolo Barbolini <paolo.barbolini@m4ss.net>
Co-authored-by: Ben Wilber <benwilber@users.noreply.github.com>
Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
Co-authored-by: joeydewaal <99046430+joeydewaal@users.noreply.github.com>
Co-authored-by: tottoto <tottotodev@gmail.com>
Co-authored-by: Ethan Wang <mailme@ethanavania.org>
Co-authored-by: Stefan Schindler <dns2utf8@users.noreply.github.com>
Co-authored-by: kildrens <5198060+kildrens@users.noreply.github.com>
Co-authored-by: Marti Serra <marti.serra+github@protonmail.com>
Co-authored-by: Jonas Malaco <jonas@protocubo.io>
2025-03-02 14:29:53 -08:00
kildrens
a9dfb4f2c1
Avoid privilege requirements by using an advisory lock in test setup (postgres). (#3753)
* feat(sqlx-postgres): use advisory lock to avoid setup race condition

* fix(sqlx-postgres): numeric hex constants not supported before postgres 16
2025-02-20 18:13:56 -08:00
Sam Lyon
8cdad44366
docs: add some missing backticks (#3749)
* add ending backticks to starting backticks that were missing them

* fix table alignment
2025-02-19 15:23:45 -08:00
Paolo Barbolini
65229f7ff9
Replace some futures_util APIs with std variants (#3721) 2025-02-01 16:01:56 -08:00
James H.
97cada3e16
feat(postgres): add geometry box (#3711)
* feat: add geometry box

* test: cannot compare box arrays

* test: regular equals check for boxes

* test: try box array test
2025-01-29 14:59:50 -08:00
Nicolas Séverin
6ca52fe80c
Added missing special casing for encoding embedded arrays of custom types (#3603)
* Added missing special casing for encoding arrays of custom types

* Added the matching test

* Formatting
2025-01-27 17:30:02 -08:00
joeydewaal
6fa0458ff3
fix(Postgres) chunk pg_copy data (#3703)
* fix(postgres) chunk pg_copy data

* fix: cleanup after review
2025-01-25 14:23:50 -08:00
James H.
74da542bf3
feat: add postres geometry line segment (#3690)
* feat: add postres geometry line segment

* fix: add doc alias
2025-01-24 22:34:40 -08:00
Rémy SAISSY
ad1d7a8aa5
Derive clone and debug for postgresql arguments (#3687) 2025-01-24 14:41:06 -08:00
joeydewaal
a408c490fd
fix(postgres) use signed int for length prefix in PgCopyIn (#3701) 2025-01-24 14:30:02 -08:00
Andreas Liljeqvist
a83395a360
Fix: nextest cleanup race condition (#3334)
* remove unused trait fn `cleanup_test_dbs`

* *wip* solve test cleanup race condition

* check for exactly 63 chars in database name

* move base64 dependency

* change

* Use url_safe base64 encoding

* Assert quoting for database name

* refactor

* add mysql support?

* borrow

* fix borrows

* ensure quoting

* re-add trait cleanup_test_dbs

* fix mysql insert

* cargo lock

* use actual field

* cleanup converted path in sqlite

* replace dashes with underscore in db name

* refactor: remove redundant path conversion in cleanup_test and add db_name method

---------

Co-authored-by: Austin Bonander <austin.bonander@gmail.com>
2025-01-23 17:36:55 -08:00
tison
838a239a2c
docs: add example for postgres enums with type TEXT (#3655)
* docs: add example for postgres enums with type TEXT

Signed-off-by: tison <wander4096@gmail.com>

* revert GitHub naming

Signed-off-by: tison <wander4096@gmail.com>

* add note

Signed-off-by: tison <wander4096@gmail.com>

---------

Signed-off-by: tison <wander4096@gmail.com>
2025-01-15 08:41:57 -08:00
joeydewaal
dfd0ac5974
feat: add Transaction type aliases (#3658) 2025-01-03 00:26:09 -08:00
Rinat Shigapov
4590b9c3ee
close listener connection on TimedOut and BrokenPipe errors (#3648)
* close listener connection on TimedOut and BrokerPipe errors

* use matches macro to generate jump table instead of chain of conditions
2024-12-24 17:00:40 -08:00