server

package
v0.0.0-...-7bf8d03 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	*http.Server
}

Server wraps the http.Server type for extending functionality.

func New

func New(cfg *config.App, sessionManager *scs.SessionManager, userService *user.Service) *Server

New creates a new http.Server type, configures the routes, and adds middleware.

func (*Server) Start

func (s *Server) Start(ctx context.Context) error

Start starts the HTTP server in a separate goroutine and listens for the context cancellation signal to shut down the server gracefully.

Jump to

Keyboard shortcuts

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