Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Welcome to pgrx v0.14.0!
This is our very first release with Windows support. How cool is that? 😎 Much thanks go to all the contributors that have been working on Windows support for so long. There's basic instructions for getting started in the project README.
Beyond that, this release officially removes support for Postgres v12. If you still need to support it, you'll need to lock your dependencies to pgrx v0.13.1.
Additionally, there's a number of bugfixes, more included Postgres headers, and some breaking code changes that'll need attention.
As always, make sure to first install
cargo-pgrx
withcargo install cargo-pgrx --version 0.14.0 --locked
and to update your extensionCargo.toml
files using ourcargo pgrx upgrade
tool.What's Changed
Windows Support
One important note for Windows Support:
This change (using
extern "C-unwind"
) is important to call out separately as it'll require any functions with#[pg_guard]
to be changed to use"C-unwind"
. This came about as a requirement for Windows, but is necessary for all supported platforms.Breaking Changes
pgrx::pg_guard
: functions marked with#[pg_guard]
must use theC-unwind
ABI, andpg_guard
macro generates an error for functions that do not use theC-unwind
ABI.pgrx::lwlock
: the parametername
ofPgLwLock::new
is required;PgLwLock::from_named
is removed; the type of the parametervalue
ofPgLwLock::attach
is changed.pgrx::atomic
: the parametername
ofPgAtomic::new
is required.pgrx::pg_sys
: ABI of all generated binding function types has been changed fromC
toC-unwind
.pgrx-tests
: on Linux, before usingcargo-pgrx
with--runas
, you must relax kernel security restrictions by runningsudo sysctl fs.protected_fifos=0
due to internal implementation details.Bug Fixes
API Changes (likely breaking)
DatumWithOid
: Addnew_from_datum(Option<Datum>, Oid)
andnull_oid(Oid)
by @the-kenny inDatumWithOid
: Addnew_from_datum(Option<Datum>, Oid)
andnull_oid(Oid)
#1999pgstat
macros by @YohDeadfall in Implemented pgstat macros #2007Display
forOid
by @YohDeadfall in ImplementedDisplay
forOid
#2029xid
by @YohDeadfall in Added mapping forxid
#2003This PR actually adds a hand-rolled representation for Postgres'
pg_sys::TransactionId
type. As such, usages ofpg_sys::TransactionId
may need adjustments. If we missed any UX for the type, please file issues (or PRs!) and we'll address them immediately. A benefit of this is that it's now possible to usepg_sys::TransactionId
as arguments or the return type of#[pg_extern]
functions.Oid::as_u32
toto_u32
by @YohDeadfall in Renamed Oid::as_u32 to to_u32 #2011New Features
PgHeapTuple::set_by_index_unchecked
by @silver-ymz in feat: addPgHeapTuple::set_by_index_unchecked
#2012More Headers
storage/buf_internals.h
by @eeeebbbbrrrr in includestorage/buf_internals.h
#2008tsearch/ts_cache.h
by @silver-ymz in includetsearch/ts_cache.h
#2010utils/spccache.h
by @usamoi in includeutils/spccache.h
#2023Code Cleanups
IntoDatum
, drop intermediate Vecs fortuples
by @vrmiguel in Dedup arrayIntoDatum
, drop intermediate Vecs fortuples
#2017A special thanks to @nyurik for this one. It was a lot of work and should make clippy users a lot happier!
Administrative/CI
rustfmt
to use--edition 2021
by @eeeebbbbrrrr in Instructrustfmt
to use--edition 2021
#2002Thank You!
I just want to send a sincere thank you to all the contributors for this release. It represents a lot of work and I'm sure they hope y'all enjoy it and can make good use of it!
New Contributors
Full Changelog: v0.13.1...v0.14.0