census

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RenewDuration                = time.Second * 30
	ScanEvictDuration            = time.Second * 60
	SelfProtectedThreshold       = 0.8
	InstanceEvictExpiredDuration = time.Second * 90
	InstanceMaxExpiredDuration   = time.Second * 3600
	ResetRenewNeedCountDuration  = time.Second * 900
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Census

type Census struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

census

func (*Census) DecrNeedCount

func (c *Census) DecrNeedCount()

decrement need renew count

func (*Census) IncrCount

func (c *Census) IncrCount()

increment renew count

func (*Census) IncrNeedCount

func (c *Census) IncrNeedCount()

increment need renew count

func (*Census) ProtectedStatus

func (c *Census) ProtectedStatus() bool

check protected status

func (*Census) ResetCount

func (c *Census) ResetCount()

reset renew count

func (*Census) SeekNeedCount

func (c *Census) SeekNeedCount(count int64)

seek need renew count

Jump to

Keyboard shortcuts

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