tracer

package
v0.0.0-...-22e6a58 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2015 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadIdsFromDb

func LoadIdsFromDb(dbName string) []uint64

func StartServer

func StartServer(params ServerParameters)

Types

type DbLogger

type DbLogger struct {
	IdsCache *TerminalIdsCache
	// contains filtered or unexported fields
}

func NewDbLogger

func NewDbLogger(dbName string) (DbLogger, error)

func (DbLogger) AddNewEntry

func (handler DbLogger) AddNewEntry(res http.ResponseWriter,
	req *http.Request)

func (DbLogger) GetLogs

func (handler DbLogger) GetLogs(res http.ResponseWriter, req *http.Request)

func (DbLogger) PrepareDB

func (handler DbLogger) PrepareDB()

func (DbLogger) ServeHTTP

func (handler DbLogger) ServeHTTP(res http.ResponseWriter, req *http.Request)

type IdLister

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

func NewIdLister

func NewIdLister(cache *TerminalIdsCache) IdLister

func (IdLister) ServeHTTP

func (handler IdLister) ServeHTTP(res http.ResponseWriter, req *http.Request)

type LogEntry

type LogEntry struct {
	Id         uint64
	TerminalId uint64 `sql:"not null"`
	Timestamp  string `sql:"not null"`
	Message    string `sql:"not null"`
}

type ServerParameters

type ServerParameters struct {
	Host     string
	Port     string
	DbName   string
	SiteRoot string
}

type TerminalIdsCache

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

func NewTerminalIdsCache

func NewTerminalIdsCache() TerminalIdsCache

func (*TerminalIdsCache) AppendId

func (cache *TerminalIdsCache) AppendId(id uint64)

func (*TerminalIdsCache) AppendIds

func (cache *TerminalIdsCache) AppendIds(ids []uint64)

func (*TerminalIdsCache) GetIds

func (cache *TerminalIdsCache) GetIds() []uint64

type Uint64Slice

type Uint64Slice []uint64

func (Uint64Slice) Len

func (s Uint64Slice) Len() int

func (Uint64Slice) Less

func (s Uint64Slice) Less(i, j int) bool

func (Uint64Slice) Swap

func (s Uint64Slice) Swap(i, j int)

Jump to

Keyboard shortcuts

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