libcentrifugo

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 23, 2015 License: MIT Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AuthTokenKey   = "token"
	AuthTokenValue = "authorized"
)
View Source
const (
	VERSION = "0.1.0"
)

Variables

View Source
var (
	ErrInvalidClientMessage  = errors.New("invalid client message")
	ErrInvalidApiMessage     = errors.New("invalid API message")
	ErrInvalidControlMessage = errors.New("invalid control message")
	ErrInvalidAdminMessage   = errors.New("invalid admin message")
	ErrInvalidToken          = errors.New("invalid token")
	ErrUnauthorized          = errors.New("unauthorized")
	ErrMethodNotFound        = errors.New("method not found")
	ErrPermissionDenied      = errors.New("permission denied")
	ErrProjectNotFound       = errors.New("project not found")
	ErrNamespaceNotFound     = errors.New("namespace not found")
	ErrInternalServerError   = errors.New("internal server error")
	ErrLimitExceeded         = errors.New("limit exceeded")
	ErrNotAvailable          = errors.New("not available")
	ErrConnectionExpired     = errors.New("connection expired")
)

Functions

func Main

func Main()

Types

type ChannelOptions

type ChannelOptions struct {
	// Watch determines if message published into channel will be sent into admin channel
	Watch bool `json:"watch"`

	// Publish determines if client can publish messages into channel directly
	Publish bool `json:"publish"`

	// Anonymous determines is anonymous access (with empty user ID) allowed or not
	Anonymous bool `json:"anonymous"`

	// Presence turns on(off) presence information for channels
	Presence bool `json:"presence"`

	// HistorySize determines max amount of history messages for channel, 0 means no history for channel
	HistorySize int64 `mapstructure:"history_size" json:"history_size"`

	// HistoryLifetime determines time in seconds until expiration for history messages
	HistoryLifetime int64 `mapstructure:"history_lifetime" json:"history_lifetime"`

	// JoinLeave turns on(off) join/leave messages for channels
	JoinLeave bool `mapstructure:"join_leave" json:"join_leave"`
}

ChannelOptions represent channel specific configuration for namespace or project in a whole

Directories

Path Synopsis
This is an adapted code from Steve Francia's jWalterWeatherman library - see https://github.com/spf13/jWalterWeatherman
This is an adapted code from Steve Francia's jWalterWeatherman library - see https://github.com/spf13/jWalterWeatherman

Jump to

Keyboard shortcuts

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