unifrost: github.com/unifrost/unifrost/drivers Index | Files | Directories

package drivers

import "github.com/unifrost/unifrost/drivers"

Package drivers contains all the drivers required to connect to different brokers, under a single easy to use interface.

Index

Package Files

common.go doc.go

Variables

var (
    // ErrInvalidDriver error
    ErrInvalidDriver = errors.New("driver: Invalid driver specified")
    // ErrInvalidConfigSignature error
    ErrInvalidConfigSignature = errors.New("driver: Invalid config signature for specifie driver")
)

type SubscriberClient Uses

type SubscriberClient interface {
    // Subscribe method subscribes to the specified topic
    // and returns the gocloud pubsub Subscription
    Subscribe(context.Context, string) (*pubsub.Subscription, error)

    Close(context.Context) error
}

SubscriberClient connects to the specific pubsub broker using specific drivers, it also hides the specific driver implementation for subscribing to topics And gives a single interface for all driver types.

Directories

PathSynopsis
gcpdriver
kafkadriver
memdriver
natsdriver
rabbitdriver
sqsdriver

Package drivers imports 3 packages (graph) and is imported by 3 packages. Updated 2020-01-31. Refresh now. Tools for package owners.