Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release pgrx 0.12.0-alpha.1 #1598

Conversation

workingjubilee
Copy link
Member

@workingjubilee workingjubilee commented Mar 1, 2024

Welcome to pgrx 0.12.0-alpha.1!

Say the magic words with me!

cargo install cargo-pgrx --locked --version 0.12.0-alpha.1

Breaking Changes

No more dlopen!

Perhaps the most exciting change this round is @usamoi's contribution in #1468 which means that we no longer perform a dlopen in order to generate the schema. The cost, such as it is, is that your pgrx extensions now require a src/bin/pgrx_embed.rs, which will be used to generate the schema. This has much less cross-platform issues and will enable supporting things like cargo binstall down the line.

It may be a bit touchy on first-time setup for transitioning older repos. If necessary, you may have to directly add a src/bin/pgrx_embed.rs and add the following code (which should be the only code in the file, though you can add comments if you like?):

::pgrx::pgrx_embed!();

Your Cargo.toml will also want to update its crate-type key for the library:

[lib]
crate-type = ["cdylib", "lib"]

Library Code

What's New

We have quite a lot of useful additions to our API:

Result<composite_type!("..."), E> support

Significantly expanded docs

Thanks to @rjuju, @NotGyro, and @workingjubilee, we now have significantly expanded docs for cargo-pgrx and pgrx in general. Some of these are in the API docs on https://docs.rs or the READMEs, but there's also a guide, now! It's not currently published, but is available as an mdbook in the repo.

Some diagnostic information that is also arguably documentation, like comments and the suggestion to cargo install, have also been improved, thanks to @workingjubilee in

#[pg_cast]

An experimental macro for a CREATE CAST was contributed by @xwkuang5 in #1445!

Legal Stuff

Thanks to @the-kenny in #1490 and @workingjubilee in #1504, it was brought to our attention that some dependencies had unusual legal requirements. So we fixed this with CI! We now check our code included into pgrx-using binaries is MIT/Apache 2.0 licensed, as is common across crates.io, using cargo deny!. The build tools will have more flexible legal requirements (partly due to the use of Mozilla Public License code in rustls).

Internal Changes

Many internal cleanups were done thanks to

In particular:

Soundness Fixes

We had a number of soundness issues uncovered or have added more tests to catch them.

Less Deps

Part of the cleanup by @workingjubilee was reducing the number of deps we compile:

Hopefully it will reduce compile time and disk usage!

New Contributors

Full Changelog: v0.12.0-alpha.0...v0.12.0-alpha.1

@workingjubilee workingjubilee merged commit db7b09d into pgcentralfoundation:develop Mar 1, 2024
11 checks passed
@workingjubilee workingjubilee deleted the prepare-v0.12.0-alpha.1 branch March 1, 2024 05:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant