datastax / cassandra-quarkus

An Apache Cassandra(R) extension for Quarkus
Apache License 2.0
39 stars 28 forks source link

Adapt to Quarkus 3 #222

Closed adutra closed 1 year ago

adutra commented 1 year ago

This PR aims to make the extension compatible with Quarkus 3.

The main pain point was the change in Mutiny: they moved away from the Reactive Streams API in favor of Java's Flow API.

Obviously, there was also the expected javax/jakarta fun.

Other than that, I tried to follow the upgrade principles outlined here.

I tested locally including native mode, all tests pass (using GraalVM 22.3.1 + java 11).

Here is what I would suggest:

Regarding the version number: the changes in this PR are NOT backwards compatible because 1) Quarkus 3 is not backwards compatible with Quarkus 2 and 2) The Mutiny changes are not backwards compatible either. This should warrant a major version bump, BUT: for most users the upgrade should be a no-brainer. With that in mind, I decided that a minor bump instead was "good enough", so I bumped to 1.2.0-alpha1-SNAPSHOT (we did the same when we switched from Quarkus 1 to Quarkus 2). But I'm happy to change this to a major bump instead.

\cc @ppalaga

ppalaga commented 1 year ago

Thanks a lot @adutra! I tested Camel Quarkus against this PR and it works well.

Regarding the version number: the changes in this PR are NOT backwards compatible because 1) Quarkus 3 is not backwards compatible with Quarkus 2 and 2) The Mutiny changes are not backwards compatible either. This should warrant a major version bump, BUT: for most users the upgrade should be a no-brainer. With that in mind, I decided that a minor bump instead was "good enough", so I bumped to 1.2.0-alpha1-SNAPSHOT (we did the same when we switched from Quarkus 1 to Quarkus 2). But I'm happy to change this to a major bump instead.

I'd vote for bumping the major, because other projects in the ecosystem do it like that. It might be easier for end users to see which versions of cassandra-quarkus are compatible with which Quarkus major versions. My 2 cents. I'll be also fine with 1.2.0-alpha1.

adutra commented 1 year ago

Thanks for the feedback @ppalaga !

@absurdfarce or @msmygit could somebody please take a look at this and release an alpha version soon-ish? I'll let you decide whether this should be 1.2.0 or 2.0.0 :-)

Thanks 🙏

gsmet commented 1 year ago

Hey there, Quarkus 3 is coming very soon and if we don't get a Cassandra Quarkus version compatible with it soon, we will have to drop it from the Quarkus Platform, which is also a problem for Camel Quarkus.

Our schedule is the following:

Ideally, we would need a Cassandra Quarkus version compatible and built with Quarkus 3.0.0.Final between April 13th and April 25th.

Maybe it would be a good idea to merge this PR and then upgrade to the Final and release the artifacts after April 12th?

Thanks.

msmygit commented 1 year ago

Since the Beta1 was released a couple days ago, I submitted a PR here, https://github.com/adutra/cassandra-quarkus/pull/1 to get it upgraded to that along with this.

adutra commented 1 year ago

Since the Beta1 was released a couple days ago, I submitted a PR here, adutra#1 to get it upgraded to that along with this.

Merged, thanks! Do you have an ETA for when this PR is going to be merged?

absurdfarce commented 1 year ago

Hey @adutra , many thanks for the PR! I'm gonna try to get this guy merged (and ideally get 1.2.0-alpha1 artifacts released) today.

ppalaga commented 1 year ago

Thanks for merging @absurdfarce! When may we expect a release?

absurdfarce commented 1 year ago

Hey @ppalaga, thanks for checking in!

I'm doing the release on an ARM platform and unfortunately it looks like some of the integration tests don't behave nicely on that platform. In the short-term we're working on getting that resolved so that the build (which happens as part of the deployment) can complete successfully. That work is taking place in this PR; once that's merged (which I expect will happen soon) we should be ready to resume the release process.

ppalaga commented 1 year ago

@absurdfarce Interesting! Thanks for the information.

absurdfarce commented 1 year ago

You're quite welcome @ppalaga!

There will probably be other notifications elsewhere but I'll mention it here since it's directly relevant: the release was finished up last night. 1.2.0-alpha1 should now be available via Maven Central. If you have any problems with it let me know!

@adutra you might be interested in the above as well. :)

adutra commented 1 year ago

Thanks @absurdfarce, we already integrated it in our quarkus3 branch :-)

ppalaga commented 1 year ago

Thanks @absurdfarce! The tests in Camel Quarkus are passing.

absurdfarce commented 1 year ago

Hey @gsmet, regarding your question about Cassandra Quarkus and the Quarkus Platform... I think the schedule you outline will work for us. 1.2.0-alpha1 is now out on Maven and we've got another PR up for CR1. I suspect we should be able to get a final 1.2.0 release out between the release of 3.0 final on ~4/12 and the platform announcement on ~4/26.