websocket

package
v0.6.1-hr Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2018 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Time allowed to write a message to the peer.
	WriteWait = 3 * time.Second

	// Time allowed to read the next pong message from the peer.
	PongWait = 30 * time.Second

	// Send pings to peer with this period. Must be less than pongWait.
	PingPeriod = (PongWait * 9) / 10
)

Variables

View Source
var Upgrader = socket.Upgrader{

	CheckOrigin:     func(r *http.Request) bool { return true },
	ReadBufferSize:  1024,
	WriteBufferSize: 1024,
}

Functions

func FilterHeader

func FilterHeader(header http.Header) http.Header

FilterHeader filters the headers for upgrading the HTTP server connection to the WebSocket protocol.

Types

This section is empty.

Jump to

Keyboard shortcuts

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