Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DefaultALookup is the lookup resolver for DNS A records. // You can override it for caching or testing. DefaultALookup = net.LookupHost )
Functions ¶
func NewDynamic ¶
func NewDynamic() *dynamic
NewDynamic creates a new dynamic router that can be have its routes updated.
func NewStaticAddresser ¶
Types ¶
type Addresser ¶
type Addresser interface { // Address decides the ip:port to send the request to, if any. Errors may be returned if permission is denied. // The returned string must contain contain both ip and port separated by colon. Address(r *http.Request) (string, error) }
Addresser implements logic that decides what "ad-hoc" ip:port to dial for a backend, if any.
Adhoc rules are a way of forwarding requests to services that fall outside of pre-defined Routes and Backends.
Click to show internal directories.
Click to hide internal directories.