-
Notifications
You must be signed in to change notification settings - Fork 590
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(connector): init embedded connector node #12122
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.
Rest LGTM
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.
license-eye has totally checked 4080 files.
Valid | Invalid | Ignored | Fixed |
---|---|---|---|
1800 | 1 | 2279 | 0 |
Click to see the invalid file list
- java/java-binding/src/main/java/com/risingwave/java/binding/CdcJniChannel.java
java/java-binding/src/main/java/com/risingwave/java/binding/CdcJniChannel.java
Outdated
Show resolved
Hide resolved
…cJniChannel.java Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
cc @arkbriar In this PR, we introduce
|
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.
Rest LGTM!
...onnector-service/src/main/java/com/risingwave/connector/source/core/JniDbzSourceHandler.java
Show resolved
Hide resolved
Sounds great! Two questions:
|
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!
I got what you mean. We can set
If we don't set it explicitly, it would use 10% of total memory by default. I think a value between 10%-20% looks good to me. As for the minimum requirement, I think 256m is enough. |
# Set default connector libs path | ||
ENV CONNECTOR_LIBS_PATH /risingwave/bin/connector-node/libs |
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.
Add default CONNECTOR_LIBS_PATH to the Dockerfile.
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.
Do I miss any other Dockerfiles? cc @fuyufjh @BugenZhao
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.
AFAIK this is the only one
# Set default connector libs path | ||
ENV CONNECTOR_LIBS_PATH /risingwave/bin/connector-node/libs |
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.
Add default CONNECTOR_LIBS_PATH to the Dockerfile.
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.
IIRC, opandal also uses jni to start a jvm when supporting hdfs access. May need to test whether it will conflict with the embedded connector node. cc @wcy-fdu
@@ -151,24 +151,33 @@ where | |||
|
|||
let channel_ptr = Box::into_raw(tx) as i64; |
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.
For current code, we don't even need wrapping the channel with box, since the tx
variable is dropped after the method is called. We can pass channel_ptr
as &tx as *const Sender as i64
.
Co-authored-by: Eric Fu <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
CONNECTOR_LIBS_PATH
needs to be specified to tell the JVM where to load connector libs.GetEventStream
is replaced with JNI. See more details in the codes.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.