Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
Port string // Port on which the server listens
ReadTimeout time.Duration // Maximum duration for reading the entire request
WriteTimeout time.Duration // Maximum duration before timing out writes
IdleTimeout time.Duration // Maximum time to wait for the next request
}
Config contains configuration settings for an server.
func (*Config) WithIdleTimeout ¶
WithIdleTimeout sets the IdleTimeout field and returns the updated Config.
func (*Config) WithReadTimeout ¶
WithReadTimeout sets the ReadTimeout field and returns the updated Config.
Click to show internal directories.
Click to hide internal directories.