kafka

package
v1.5.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 28, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Kind is the kind of Kafka
	Kind = "Kafka"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Dynamic

type Dynamic struct {
	Header string `yaml:"header" jsonschema:"omitempty"`
}

Dynamic defines dynamic ways to get Kafka topic from http request

type Kafka

type Kafka struct {
	// contains filtered or unexported fields
}

Kafka is kafka backend for MQTT proxy

func (*Kafka) Close

func (k *Kafka) Close()

Close close Kafka

func (*Kafka) DefaultSpec

func (k *Kafka) DefaultSpec() interface{}

DefaultSpec return default spec of Kafka

func (*Kafka) Description

func (k *Kafka) Description() string

Description return description of Kafka

func (*Kafka) Handle

func (k *Kafka) Handle(ctx context.HTTPContext) (result string)

Handle handles HTTPContext.

func (*Kafka) Inherit

func (k *Kafka) Inherit(filterSpec *httppipeline.FilterSpec, previousGeneration httppipeline.Filter)

Inherit init Kafka based on previous generation

func (*Kafka) Init

func (k *Kafka) Init(filterSpec *httppipeline.FilterSpec)

Init init Kafka

func (*Kafka) Kind

func (k *Kafka) Kind() string

Kind return kind of Kafka

func (*Kafka) Results

func (k *Kafka) Results() []string

Results return possible results of Kafka

func (*Kafka) Status

func (k *Kafka) Status() interface{}

Status return status of Kafka

type Spec

type Spec struct {
	Backend []string `yaml:"backend" jsonschema:"required,uniqueItems=true"`
	Topic   *Topic   `yaml:"topic" jsonschema:"required"`
}

Spec is spec of Kafka

type Topic

type Topic struct {
	Default string   `yaml:"default" jsonschema:"required"`
	Dynamic *Dynamic `yaml:"dynamic" jsonschema:"omitempty"`
}

Topic defined ways to get Kafka topic

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL