messaging

package
v0.0.0-...-ec2ce48 Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2016 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Overview

Toto-build, the stupid Go continuous build server.

Toto-build is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

Toto-build is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Toto-build, the stupid Go continuous build server.

Toto-build is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

Toto-build is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Toto-build, the stupid Go continuous build server.

Toto-build is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

Toto-build is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

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

messaging api handler

func NewHandler

func NewHandler(buffer chan message.ToWork) *Handler

create one new Handler using the given buffer

func (*Handler) HandleMessage

func (h *Handler) HandleMessage(mes *nsq.Message) error

Handle the incoming message. If inccorect or if buffer is full, return one error

type Listener

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

func NewListener

func NewListener(conf *ListenerConfig) *Listener

initialize new listener

func (*Listener) Start

func (l *Listener) Start() chan message.ToWork

start listening for incoming ToWork

func (*Listener) Stop

func (l *Listener) Stop()

will attempt to do a gracefull shutdown of the listener

type ListenerConfig

type ListenerConfig struct {
	LookupAddr []string
	Topic      string
	Channel    string
	BuffSize   int
}

func NewListenerConfig

func NewListenerConfig() *ListenerConfig

initialize new config for listener

type Producer

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

func NewProducer

func NewProducer(conf *ProducerConfig) *Producer

func (*Producer) Start

func (producer *Producer) Start(reportChan chan message.Report)

start waiting for report to send back to toto scheduler

type ProducerConfig

type ProducerConfig struct {
	NsqAddr string
	Topic   string
}

func NewProducerConfig

func NewProducerConfig() *ProducerConfig

Jump to

Keyboard shortcuts

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