limiter

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2017 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fixed

type Fixed chan struct{}

Fixed is a simple channel based concurrency limiter. It uses a fixed size channel to limit callers from proceeding until there is a value avalable in the channel. If all are in-use, the caller blocks until one is freed.

func NewFixed

func NewFixed(limit int) Fixed

func (Fixed) Release

func (t Fixed) Release()

func (Fixed) Take

func (t Fixed) Take()

Jump to

Keyboard shortcuts

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