-
Notifications
You must be signed in to change notification settings - Fork 598
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
refactor(jni): remove jni_core's dependency on storage #17193
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -26,17 +26,15 @@ public class Binding { | |||
} | |||
} | |||
|
|||
static void ensureInitialized() {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the purpose of this function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The native method iteratorNewHummock
is moved to the HummockIterator
class. We should ensure that this Binding
class has been initialized before we use the HummockIterator
class. This method is called in the static block of HummockIterator
to ensure that the Binding
class is loaded and initialized, and otherwise the shared library won't be loaded when we use HummockIterator
and causes error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. The build graph looks much better now
@xxchan Need an approval for cargo.lock. Can you approve on it? |
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
Resolve #17177
Previously, we need to support hummock java binding in the
risingwave_jni_core
crate, which depends onrisingwave_storage
. However, the connector node, which is the current main usage ofrisingwave_jni_core
, does not need this feature. Therefore, in this PR, we remove the hummock related feature to therisingwave_java_binding
crate, which is a dynamic library that is not used by connector node, but used by hummock java binding.The macro is refactored accordingly.
Checklist
./risedev check
(or alias,./risedev c
)Documentation
Release note
If this PR includes changes that directly affect users or other significant modifications relevant to the community, kindly draft a release note to provide a concise summary of these changes. Please prioritize highlighting the impact these changes will have on users.