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

feat: Upgrade to jni-rs 0.21 #50

Merged
merged 2 commits into from
Feb 20, 2024
Merged

feat: Upgrade to jni-rs 0.21 #50

merged 2 commits into from
Feb 20, 2024

Conversation

sunchao
Copy link
Member

@sunchao sunchao commented Feb 20, 2024

Which issue does this PR close?

Closes #49.

Rationale for this change

Comet currently use jni-rs 0.19 which is a bit out-dated. The latest version 0.21.x provides more improvements including updated safety, better JVM handling, less data copying, etc. On the other hand, it also introduced many API changes. In the long term, we should update to 0.21+ to get continuous improvements from jni-rs.

What changes are included in this PR?

This PR upgrades jni-rs from 0.19 to 0.21. There are many API changes between the two versions and hence many places need to be updated as well in the repo.

Most notably, many method calls in jni-rs now requires a &mut JNIEnv as parameter, while it used to be &JNIEnv.

How are these changes tested?

Existing tests.

This PR upgrades `jni-rs` from 0.19 to 0.21. There are many API changes between the two versions and hence many places need to be updated as well in the repo.

Most notably, many method calls in `jni-rs` now requires a `&mut JNIEnv` as parameter, while it used to be `&JNIEnv`.
Copy link
Member

@viirya viirya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was reviewed already internally.

@sunchao sunchao merged commit 7018225 into apache:main Feb 20, 2024
6 checks passed
@sunchao
Copy link
Member Author

sunchao commented Feb 20, 2024

Thanks, merged

@sunchao sunchao deleted the jni-21 branch February 20, 2024 18:30
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.

Upgrade jni-rs to 0.21
2 participants