services

package
v0.0.0-...-98c0197 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2016 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPServer

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

HTTPServer Represents an instance of the HTTP protocol server.

func NewHTTPServer

func NewHTTPServer(store storage.Store) *HTTPServer

NewHTTPServer Returns a new HTTPServer instance.

func (*HTTPServer) IsStarted

func (server *HTTPServer) IsStarted() bool

IsStarted Returns whether the HTTP protocol server is started.

func (*HTTPServer) ListenAndServe

func (server *HTTPServer) ListenAndServe(address string)

ListenAndServe Starts the HTTP protocol server.

type MySQLReplicator

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

MySQLReplicator Represents an instance of a MySQL replication client.

func NewMySQLReplicator

func NewMySQLReplicator(serviceHost *ServiceHost, host string, port uint16, username string, password string, serverID uint32, store storage.Store, jsVirtualMachine *otto.Otto) *MySQLReplicator

NewMySQLReplicator Returns a new instance of NewMySQLReplicator.

func (*MySQLReplicator) IsStarted

func (replicator *MySQLReplicator) IsStarted() bool

IsStarted Returns whether the MySQL replication service is started.

func (*MySQLReplicator) SaveBinlogPosition

func (replicator *MySQLReplicator) SaveBinlogPosition()

SaveBinlogPosition Saves the current MySQL binlog filename and position.

type RedisServer

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

RedisServer Represents an instance of a redis protocol server.

func NewRedisServer

func NewRedisServer(store storage.Store) *RedisServer

NewRedisServer Returns a new RedisServer instance.

func (*RedisServer) IsStarted

func (server *RedisServer) IsStarted() bool

IsStarted Returns whether the Redis protocol server is started.

func (*RedisServer) ListenAndServe

func (server *RedisServer) ListenAndServe(address string)

ListenAndServe Starts the Redis protocol server.

type ServiceHost

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

ServiceHost ServiceHost represents a service instance.

func (*ServiceHost) Increment

func (serviceHost *ServiceHost) Increment(amount int64)

Increment Increments the write operations counter by the specified amount.

func (*ServiceHost) IsStarted

func (serviceHost *ServiceHost) IsStarted() bool

IsStarted Returns whether all services have been started.

func (*ServiceHost) ListenAndServe

func (serviceHost *ServiceHost) ListenAndServe(localDatabaseFilename string, store string, httpListenAddress string, redisListenAddress string, mysqlHost string, mysqlPort uint16, mysqlUsername string, mysqlPassword string, mysqlServerID uint32) error

ListenAndServe Starts the service.

func (*ServiceHost) Rate

func (serviceHost *ServiceHost) Rate() int64

Rate Returns the rate of throughput per second.

func (*ServiceHost) StartTicker

func (serviceHost *ServiceHost) StartTicker()

StartTicker Starts the per second ticker.

Jump to

Keyboard shortcuts

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