Registry / messaging / onsdigital-dp-kafka

onsdigital-dp-kafka

JSON →
library1.1.7gogounverified

A Go library for producing and consuming Kafka messages, part of the ONS Digital Publishing platform.

go get github.com/ONSdigital/dp-kafka
INSTALL
IMPORT
SIG · ONSDIGITAL-DP-KAFK
O
onsdigital-dp-kafka
messaginggov1.1.7
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

kafka
github.com/ONSdigital/dp-kafka

Creates a Kafka producer and sends a message.

package main import ( "context" "log" "github.com/ONSdigital/dp-kafka" ) func main() { ctx := context.Background() producer, err := kafka.NewProducer(ctx, []string{"localhost:9092"}, "my-topic") if err != nil { log.Fatal(err) } defer producer.Close(ctx) producer.Send(ctx, []byte("hello")) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
1.1.7latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
12 hits · last 30 days
node
10
Amazon
1
OpenAI (training)
1
Resources
onsdigital-dp-kafka — go get onsdigital-dp-kafka · libregistry