-
Notifications
You must be signed in to change notification settings - Fork 97
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
Make dora cli connect to remote coordinator #513
Conversation
54169dd
to
af2798f
Compare
1fab2bc
to
b758570
Compare
Signed-off-by: Gege-Wang <[email protected]> fix: localhost to control_socket_addr()
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! Looks good to me overall, just one small suggestion.
@XxChang Thanks for reviewing!
8993a92
to
c759282
Compare
Before merging, can we add some CI test so that we know that this features works. Something in the likes of adding a bash script within https://github.com/dora-rs/dora/blob/ea47a556a77f6c64f29ab07939d747edc8573671/.github/workflows/ci.yml with something like: export IP="$(curl ipinfo.io/ip)"
dora coordinator --addr $IP
dora list --coordinator-addr $IP
# ... Thanks! |
Also, there is some Clippy warnings worth checking: https://github.com/dora-rs/dora/pull/513/files |
ok, I will add it! |
Could we try to find what need to be changed for the CI to work with external IP? |
How about creating a docker image for testing coordinator services? |
I think that before trying docker, we need to be able to run with the same machine, same environment, just with the external IP instead of localhost. We can have docker container testing as a follow up PR. Does it work on your local machine? You can try with a docker container but it's probably not going to work. |
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.
Looks good to me, thanks a lot for your work!
Could we try to find what need to be changed for the CI to work with external IP?
@haixuanTao You mean substituting the 127.0.0.1
in the CI job with the external IP of the runner? We might be able to do that using the third-party haythem/public-ip
action.
If i try: export IP="0.0.0.0:6013" (base) ✘ 130 remotes/gege/multiple
dora coordinator --addr $IP &
dora list --coordinator-addr $IP I'm having this warning issue: 2024-05-29T14:20:56.596707Z WARN dora_coordinator::listener: failed to deserialize node message
Caused by:
invalid type: string "List", expected struct Timestamped at line 1 column 6
Location:
/home/peter/Documents/work/dora/binaries/coordinator/src/listener.rs:38:48
at binaries/coordinator/src/listener.rs:41 |
The public IP is probably not reachable this way because of firewalls, NATs, etc. So we decided to postpone the creation of a proper CI test for now. |
|
I see. So, basically the port is not configurable yet. In that case, can we only specify IP address in the cli configuration. To avoid people using the PORT and realising it can´t be used. |
I have tried in EC2 as the following:
and local
now, the control_socket_addr() is still 127.0.0.1:6012, but we can still connect to remote coordinator. I cannot understand, but it works, I think it should be 0.0.0.0:6012, but not.
@XxChang , yes, there are also some problem about
|
ok, I have done this in ce2b02f |
Yes, exactly. The coordinator listens on two different ports:
|
Yes, the coordinator should listen on |
Thanks! Great work! |
I implemented this in #520, among some other improvements. |
To make CLI coordinator connection configurable, such as
dora start dataflow.yaml --coordinator-addr IP
Allow users to pass a parameter when dora up, dora start, and dora list --coordinator-address to specify the address or the default address control_socket_addr().
To test this PR:
now, there are no CLI CI test to test it.