concurrency

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2019 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	ConcurrentCount *counter.Counter
	ConcurrencySem  *semaphore.Semaphore
	// contains filtered or unexported fields
}

func New

func New(concurrencyLimit uint64) *Manager

func (*Manager) AcquireConcurrencySlot

func (m *Manager) AcquireConcurrencySlot()

func (*Manager) AddConcurrent

func (m *Manager) AddConcurrent()

func (*Manager) DecConcurrent

func (m *Manager) DecConcurrent()

func (*Manager) IsConcurrencyUnlimited

func (m *Manager) IsConcurrencyUnlimited() bool

func (*Manager) ReleaseConcurrencySlot

func (m *Manager) ReleaseConcurrencySlot()

Jump to

Keyboard shortcuts

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