Skip to content
This repository has been archived by the owner on Jun 4, 2021. It is now read-only.

Add Kafka Sink #682

Closed
aslom opened this issue Oct 28, 2019 · 9 comments
Closed

Add Kafka Sink #682

aslom opened this issue Oct 28, 2019 · 9 comments
Assignees
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.

Comments

@aslom
Copy link
Member

aslom commented Oct 28, 2019

Expected Behavior

Allow Knative sink to send events to Kafka - symmetrical to Kafka source

Actual Behavior

Not possible with code in Knative eventing

Steps to Reproduce the Problem

  1. Use event-display as sink to print events

Additional Info

Based on comments @jamesward

@jamesward
Copy link

Thanks! Sorry I didn't file this.

@aslom
Copy link
Member Author

aslom commented Oct 28, 2019

/good-first-issue

@knative-prow-robot knative-prow-robot added good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. labels Oct 28, 2019
@n3wscott
Copy link
Contributor

n3wscott commented Nov 5, 2019

There is nothing special about a sink aside from being addressable.

For example, in google/knative-gcp, it models pubsub. I created a PullSubscription backed by a deployment, and also created a Topic backed by a ksvc. A channel combines both into do what we think of the thing we want channels to do. But the components are independently useful.

PullSubscription adheres to the Source contract, and Topic adheres to the Addressable contract.

This is not a good first issue as it is open ended and unclear what should be produced.

/remove-good-first-issue

@n3wscott
Copy link
Contributor

n3wscott commented Nov 5, 2019

My advice would be to make the same kind of object for Kafka to model the outbound Topic as I have for Topic for Pub/Sub.

@knative-prow-robot knative-prow-robot removed the good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. label Nov 5, 2019
@aslom
Copy link
Member Author

aslom commented Nov 6, 2019

@n3wscott interesting - can I deploy only Topic component as a knative sink for gcp pubsub? Where can I find an example of it? My thinking for good first issue was that functionality is very simple could be run just with command line arguments without need to use CR.

@aslom
Copy link
Member Author

aslom commented Jun 23, 2020

I wrote my own in Python as I needed it for testing - maybe I add and we refactor it as needed? I think there is real need for it - there are external Kafka brokers where you want your events to go ...

@aslom
Copy link
Member Author

aslom commented Jun 23, 2020

/assign

@aslom
Copy link
Member Author

aslom commented Jul 24, 2020

First version is in PR #1406

It is fully working Kafka Sink that can be deployed in k8s cluster.

Next steps are to add security, unit tests (not sure how to mock sending to Kafka topic?), create KafkaSink CR and add controller reconciliation support for it

@slinkydeveloper
Copy link
Contributor

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.
Projects
None yet
Development

No branches or pull requests

5 participants