Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: aliok The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
aliok
force-pushed
the
2026-09-18-kafka-sidecar
branch
from
September 29, 2026 13:33
a58200c to
6fddd33
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
function declares
run.kafka. The function stays a plain CloudEvents-over-HTTPserver; the sidecar consumes Kafka and delivers each record to the function over
localhost (
http://127.0.0.1:8080/), committing the offset on a2xxresponse.This replaces the retired in-process path (
FUNC_TRANSPORT=kafkaon the functioncontainer).
validateKafka: because the sidecar owns all Kafkahandling,
run.kafkanow works for any runtime (it still requiresinvoke: cloudevent).container only; TLS certs and SASL credentials mount into the runtime, never into
the function container.
run.kafkaon the knative (Serving) deployer. The sidecar is onlyinjected by the k8s and keda deployers, and the in-process path is gone, so a Kafka
function deployed on knative would come up healthy yet never receive a record. Fail
fast with an error pointing at the keda deployer. (Injecting the sidecar into the
Knative Service is left to a follow-up.)
Why this is WIP
https://github.com/aliok/func-kafka-adapter, currently under a personal GitHub
account rather than a Knative / knative-extensions org. Its permanent home is TBD.
ghcr.io/aliok/func-kafka-adapter:latest, which is not an official, versioned,published image, and there is no release/pinning story yet. It is overridable via
FUNC_KAFKA_RUNTIME_IMAGE.only by the CloudEvents-over-HTTP wire contract plus a set of
KAFKA_*/FUNCTION_TARGETenv vars — there is no Go module dependency — so nothing here pinsor verifies the runtime version.
func-gostill ships the in-processkafkapackage and the CloudEvents scaffolding still imports it. That code must beremoved (dropping Sarama from every Go function's dependency tree) before this is
complete.
CloudEvents receiver-wedge fix (fix(cloudevents): stop receiver stalling under concurrent request cancel knative-extensions/func-go#190, upstream
fix(http): stop receiver stalling under concurrent request cancellation cloudevents/sdk-go#1333), which is not yet merged/released.
runtimes are expected to work over the same HTTP contract but are untested.
consumer-lag scaling work (
scale.keda), which is not yet inmain; those commitsappear in this diff and will drop out once that lands.
record blocks its partition) and the local
func runsub-process topology are onthe roadmap but not built.
/kind enhancement
Relates to SRVOCF-976
Release Note
Docs