Registry / utility / mailgun-ttlmap

mailgun-ttlmap

JSON →
library0.0.0-20170619185759-c1c17f74874fgogounverified

Package ttlmap implements a map with time-to-live expiration for keys.

go get github.com/mailgun/ttlmap
INSTALL
IMPORT
SIG · MAILGUN-TTLMAP
M
mailgun-ttlmap
utilitygov0.0.0-20170619185759-c1c17f74874f
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

ttlmap
github.com/mailgun/ttlmap

Creates a TTL map, sets a key with expiration, and retrieves it.

package main import ( "fmt" "time" "github.com/mailgun/ttlmap" ) func main() { m, _ := ttlmap.New(100) m.Set("key", "value", 1*time.Second) val, ok := m.Get("key") fmt.Println(val, ok) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.0.0-20170619185759-c1c17f74874flatest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
mailgun-ttlmap — go get mailgun-ttlmap · libregistry