nori

package module
v0.0.0-...-b05cad6 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2016 License: MIT Imports: 12 Imported by: 0

README

nori

A Celery-compatible distributed task queue library for Golang

Build Status

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Name      string
	Transport transport.Driver
}

type JSONSerializer

type JSONSerializer struct {
}

func (JSONSerializer) ContentType

func (JSONSerializer) ContentType() string

func (JSONSerializer) Name

func (JSONSerializer) Name() string

type Serializer

type Serializer interface {
	Name() string
	ContentType() string
}

type Server

type Server struct {
	context.Context
	Tasks map[string]*Task
	// contains filtered or unexported fields
}

func NewServer

func NewServer(ctx context.Context, config *Configuration) (*Server, error)

func (*Server) RegisterTask

func (s *Server) RegisterTask(t *Task)

func (*Server) Run

func (s *Server) Run() error

func (*Server) RunManagementServer

func (s *Server) RunManagementServer(addr string)

func (*Server) Stop

func (s *Server) Stop()

func (*Server) Wait

func (s *Server) Wait() error

type Task

type Task struct {
	Name     string
	Handler  TaskHandlerFunc
	Request  interface{}
	Response interface{}
}

type TaskHandlerFunc

type TaskHandlerFunc func(*message.Request) (message.Response, error)

Directories

Path Synopsis
_examples

Jump to

Keyboard shortcuts

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