dispatcher

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2020 License: GPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dispatcher

type Dispatcher struct {
	// contains filtered or unexported fields
}

Dispatcher represents a dns query dispatcher

func Init

func Init(c *config.Config) (*Dispatcher, error)

Init inits a dispatcher from configuration

func (*Dispatcher) Dispatch

func (d *Dispatcher) Dispatch(ctx context.Context, qCtx *handler.Context) error

Dispatch sends q to entries and return first valid result.

func (*Dispatcher) ServeDNS

func (d *Dispatcher) ServeDNS(ctx context.Context, qCtx *handler.Context, w server.ResponseWriter)

func (*Dispatcher) StartServer

func (d *Dispatcher) StartServer() error

StartServer starts mosdns. Will always return a non-nil err.

Directories

Path Synopsis
logger for the whole dispatcher package
logger for the whole dispatcher package
matcher

Jump to

Keyboard shortcuts

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