http

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Subscriber

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

func NewSubscriber

func NewSubscriber(addr string, unmarshalMessageFunc UnmarshalMessageFunc, logger watermill.LoggerAdapter) (*Subscriber, error)

func (*Subscriber) Close

func (s *Subscriber) Close() error

func (*Subscriber) StartHTTPServer

func (s *Subscriber) StartHTTPServer() error

StartHTTPServer starts http server. StartHTTPServer must be called after all subscribe function are called.

func (*Subscriber) Subscribe

func (s *Subscriber) Subscribe(topic string) (chan *message.Message, error)

type UnmarshalMessageFunc

type UnmarshalMessageFunc func(topic string, request *http.Request) (*message.Message, error)

Jump to

Keyboard shortcuts

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