rrcache

package module
v0.0.0-...-4221b5e Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2021 License: MIT Imports: 4 Imported by: 0

README

rrcache

RR cache lib for https://github.com/miekg/dns

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNeg

func IsNeg(rrs []dns.RR) bool

IsNeg detects is response negative (need to put in NS section)

func NewRRCache

func NewRRCache(evictInt time.Duration) *rrStorage

NewRRCache create new cache instance with given evict interval

Types

type Cacher

type Cacher interface {
	Get(*dns.Question) ([]dns.RR, *dns.Question)
	Put([]dns.RR)
	PutNeg(*dns.Question, []dns.RR)
	Len() int
}

Cacher is a cache interface

Jump to

Keyboard shortcuts

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