-
Notifications
You must be signed in to change notification settings - Fork 126
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
Connectors Implementation #1077
Conversation
89b779c
to
093ff41
Compare
51d7a6e
to
2885548
Compare
A question to the std_stream connector, I noticed that the user needs to specify what type of std_stream it is which in my mind breaks the connector concept a bit since instead of a bidirectional connection it is now a unidirectional connection that the user specifies the direction to. Would it make sense to turn the std_stream into a connector that allows reading/writing to? behaving more like This would require connectors to be aware when their input (sink) and output (source) ports are connected to dynamically shut down / start the corresponding subsystems but it would feel a bit more intuitive than having to write: connector:
- id: stdin
type: std_stream
config:
stream: stdin
- id: stdout
type: std_stream
config:
stream: stdout
- id: stderr
type: std_stream
config:
stream: stderr Same goes for Kafka, so kafka should it be a consumer/producer connector? that works bidirectional depending on how things are connected? Or at least follow the same model: Either each direction has their own connector, or there is one connector with multiple directions based on configuration? For other connectors like http-server and http-client (TCP, UDP too) the separation makes sense ( since both are bidirectional) but I think we got to be a bit careful on naming them to keep it consistent. Perhaps we should retrofit the RFC to spell out the notions of where we split out client /server connectors, where we combine http-client, where we specify by configuration (currently stdio) or by connector (currently kafka) that we get a more generalized and pattern driven approach? |
8bc5a2b
to
0ec38c4
Compare
Once this branch goes green it would be worth merging the |
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.
🚀 also fixes #587
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
To wait a bit so the outfile can be written. Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
… 100ms Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Matthias Wahl <[email protected]>
… test Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
…oss pipelines. Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Matthias Wahl <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Signed-off-by: Heinz N. Gies <[email protected]>
Pull request
Description
Connectors are successors to onramps/offramps, sinks/sources. A connector can be a source of events and events can be sent to a connector. Not all connectors necessarily support all both the sink and source nature/trait.
This PR introduces a new config artefact
and tries to remodel the current onramp/offramp handling to move as much boilerplate and common logic from the connector implementation to the runtime (or where not possible to reasonable utilities), so that writing new connectors is getting easier, while maintaining all invariants enforced by the runtime.
Additional connector features:
TODOs
tests
folder)out
,err
in
--register-debug-connectors
or similar)Test expectations and conditions
Tier 1 and Tier 2 connectors should have container tests in
/tests
contributed with the new connector testharness ( this helps greatly with code coverage ) and integration tests in
/tremor-cli/tests/integration
thatdemonstrate canonical and simple use and validation of the connector in all its configuration modes ( client or server, secure and insecure etc.. ). For Tier 3, container and integration tests are preferable.
Related
Checklist
Performance