collect

package
v0.0.0-...-bd03ed3 Latest Latest
Warning

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

Go to latest
Published: May 7, 2016 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package collect implements fan-in from local plugin programs.

Index

Constants

View Source
const (
	// MaxQueue limits the number of points queued in a Pool.
	MaxQueue = 10000

	// MaxProc limits the number of processes running in parallel.
	MaxProc = 128
)

Variables

View Source
var Debug *log.Logger

Functions

This section is empty.

Types

type Pool

type Pool struct {
	C tsdb.Chan
	// contains filtered or unexported fields
}

Pool represents a pool of plugin processes.

func NewPool

func NewPool(path string) *Pool

NewPool creates a pool of plugin processes corresponding to programs held in the given directory. Pool automatically starts/terminates processes in response to directory events.

The pool has bounded process count, see MaxProc. An attempt to create additional process is logged and ignored.

func (*Pool) Kill

func (pool *Pool) Kill()

Kill terminates the process pool. If returns after the last running process is reaped.

Jump to

Keyboard shortcuts

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