store

package
v0.0.0-...-9bd2c4f Latest Latest
Warning

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

Go to latest
Published: May 15, 2018 License: BSD-3-Clause Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetMsgChan

func GetMsgChan() chan *message.CardMessageFuture

func GetRouter

func GetRouter() *mux.Router

Types

type FS

type FS struct {
	Funcs map[string]func(source *task.Collection,
		result *task.Collection,
		context *task.TaskContext) bool

	SharedJobs map[string]*JobFunc
	LocalJobs  map[string]*JobFunc
	// contains filtered or unexported fields
}

func GetInstance

func GetInstance() *FS

func (*FS) Add

func (fs *FS) Add(f func(source *task.Collection,
	result *task.Collection,
	context *task.TaskContext) bool, id ...string)

func (*FS) AddLocal

func (fs *FS) AddLocal(methods []string, jobs ...func(w http.ResponseWriter, r *http.Request, bg *task.Background))

func (*FS) AddShared

func (fs *FS) AddShared(methods []string, jobs ...func(w http.ResponseWriter, r *http.Request, bg *task.Background))

func (*FS) Call

func (fs *FS) Call(id string, source *task.Collection,
	result *task.Collection,
	context *task.TaskContext) bool

func (*FS) GetExecutor

func (fs *FS) GetExecutor(name string) (iexecutor.IExecutor, error)

func (*FS) GetJob

func (fs *FS) GetJob(id string) (*task.Job, error)

func (*FS) GetLimiter

func (fs *FS) GetLimiter(name string) (*rate.Limiter, error)

func (*FS) GetLocal

func (fs *FS) GetLocal(key string) (*JobFunc, error)

func (*FS) GetShared

func (fs *FS) GetShared(key string) (*JobFunc, error)

func (*FS) HAdd

func (fs *FS) HAdd(f func(source *task.Collection,
	result *task.Collection,
	context *task.TaskContext) bool) (hash string)

func (*FS) SetExecutor

func (fs *FS) SetExecutor(exe iexecutor.IExecutor, name string)

func (*FS) SetJob

func (fs *FS) SetJob(j *task.Job)

func (*FS) SetLimiter

func (fs *FS) SetLimiter(name string, r rate.Limit, b int)

func (*FS) SetLocal

func (fs *FS) SetLocal(key string, val *JobFunc)

func (*FS) SetMapper

func (fs *FS) SetMapper(mp imapper.IMapper, name string)

func (*FS) SetReducer

func (fs *FS) SetReducer(rd ireducer.IReducer, name string)

func (*FS) SetShared

func (fs *FS) SetShared(key string, val *JobFunc)

type JobFunc

type JobFunc struct {
	F         func(w http.ResponseWriter, r *http.Request, bg *task.Background)
	Methods   []string
	Signature string
}

Jump to

Keyboard shortcuts

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