-
Notifications
You must be signed in to change notification settings - Fork 54
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
connector-init: start listening on tcp port before check_protocol #1127
Conversation
b29ee73
to
1d214fc
Compare
crates/flowctl/src/connector.rs
Outdated
"--publish", &format!("0.0.0.0:{}:{}/tcp", port, CONNECTOR_INIT_PORT), | ||
"--entrypoint", | ||
target_connector_init, | ||
"--mount", &format!("type=bind,source={host_inspect_str},target={target_inspect}"), | ||
image, | ||
&format!("--image-inspect-json-path={target_inspect}"), | ||
&format!("--port={CONNECTOR_INIT_PORT}"), | ||
], args].concat()) |
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.
Updated the arguments here to match the ones in container.go
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.
rust fmt? perhaps sort --flags ?
Also remove LOG_LEVEL=trace ? that's going to be very verbose.
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 % comments
crates/flowctl/src/connector.rs
Outdated
"--publish", &format!("0.0.0.0:{}:{}/tcp", port, CONNECTOR_INIT_PORT), | ||
"--entrypoint", | ||
target_connector_init, | ||
"--mount", &format!("type=bind,source={host_inspect_str},target={target_inspect}"), | ||
image, | ||
&format!("--image-inspect-json-path={target_inspect}"), | ||
&format!("--port={CONNECTOR_INIT_PORT}"), | ||
], args].concat()) |
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.
rust fmt? perhaps sort --flags ?
Also remove LOG_LEVEL=trace ? that's going to be very verbose.
4509740
to
3d54630
Compare
Description:
connector-init
as soon as possible, but we don't process the requests while we check the protocol. After we have checked the protocol, we use the incoming stream to serve requests.flowctl
'sdocker_run
not being able to clearly distinguish between a port that it can connect to, and a port that is ready for data to be written to it here. It's still a mystery to me how the go implementation of the same connection works fine and waits until the grpc server actually starts processing before it considers the connection as ready. The relevant go code is here and Tonic seems to conceptually check for readiness here, however it seems it has a different formulation of readiness.I still don’t love this, because I would like to understand why the tonic client considers the connection ready and the go client doesn’t, and ideally we would have the tonic client behave similar to the go client…
Workflow steps:
(How does one use this feature, and how has it changed)
Documentation links affected:
(list any documentation links that you created, or existing ones that you've identified as needing updates, along with a brief description)
Notes for reviewers:
(anything that might help someone review this PR)
This change is