services

package
v0.0.0-...-06c19a4 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2014 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrFactoryPanic = errors.New("Transport factory panicked")
)

Functions

This section is empty.

Types

type ErrMissingConfig

type ErrMissingConfig struct {
	Where string
	What  string
}

func (*ErrMissingConfig) Error

func (err *ErrMissingConfig) Error() string

type ErrTerminated

type ErrTerminated struct {
	What string
}

func (*ErrTerminated) Error

func (err *ErrTerminated) Error() string

type Transport

type Transport interface {
	// Close shall terminate the transport, possibly in a clean way, and close
	// the channel returned by Closed().
	Close() error

	// Closed returns a channel that is closed once the transport is terminated.
	// The channel should be closed when a fatal internal transport error occurs
	// or after Close() is called and the transport object is terminated.
	//
	// Possible internal error can be checked by using Wait method once this
	// channel is closed.
	Closed() <-chan struct{}

	// Wait shall block until the transport is terminated. Wait returning a
	// non-nil error means that the transport failed in a non-recoverable way.
	Wait() error
}

Transport interface in this package defines what all service transports should implement and it is inherited by all the service transports, which, naturally, add much more on top of these basic methods.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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