Config Type — fiber Architecture
Architecture documentation for the Config type/interface in config.go from the fiber codebase.
Entity Profile
Dependency Diagram
graph TD 35729dc5_95b4_876f_1df6_687666021447["Config"] 55aeeb49_49d2_a4eb_1402_135d36fb1292["config.go"] 35729dc5_95b4_876f_1df6_687666021447 -->|defined in| 55aeeb49_49d2_a4eb_1402_135d36fb1292 style 35729dc5_95b4_876f_1df6_687666021447 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
middleware/proxy/config.go lines 12–70
type Config struct {
// Next defines a function to skip this middleware when returned true.
//
// Optional. Default: nil
Next func(c fiber.Ctx) bool
// ModifyRequest allows you to alter the request
//
// Optional. Default: nil
ModifyRequest fiber.Handler
// ModifyResponse allows you to alter the response
//
// Optional. Default: nil
ModifyResponse fiber.Handler
// tls config for the http client.
TLSConfig *tls.Config
// Client is custom client when client config is complex.
// Note that Servers, Timeout, WriteBufferSize, ReadBufferSize, TLSConfig
// and DialDualStack will not be used if the client are set.
Client *fasthttp.LBClient
// Servers defines a list of <scheme>://<host> HTTP servers,
//
// which are used in a round-robin manner.
// i.e.: "https://foobar.com, http://www.foobar.com"
//
// Required
Servers []string
// Timeout is the request timeout used when calling the proxy client
//
// Optional. Default: 1 second
Timeout time.Duration
// Per-connection buffer size for requests' reading.
// This also limits the maximum header size.
// Increase this buffer if your clients send multi-KB RequestURIs
// and/or multi-KB headers (for example, BIG cookies).
ReadBufferSize int
// Per-connection buffer size for responses' writing.
WriteBufferSize int
// KeepConnectionHeader keeps the "Connection" header when set to true.
//
// Optional. Default: false
KeepConnectionHeader bool
// Attempt to connect to both ipv4 and ipv6 host addresses if set to true.
//
// By default client connects only to ipv4 addresses, since unfortunately ipv6
// remains broken in many networks worldwide :)
//
// Optional. Default: false
DialDualStack bool
}
Defined In
Source
Frequently Asked Questions
What is the Config type?
Config is a type/interface in the fiber codebase, defined in middleware/proxy/config.go.
Where is Config defined?
Config is defined in middleware/proxy/config.go at line 12.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free