server

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package server provides the HTTP server for google-group-sync.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGroupsHandler

func NewGroupsHandler(logger *slog.Logger, res resolver.GroupResolver, c *cache.Cache) fiber.Handler

NewGroupsHandler creates a fiber handler for POST /groups.

func Run

func Run(ctx context.Context, logger *slog.Logger, cfg Config, res resolver.GroupResolver, groupCache *cache.Cache) error

Run starts the HTTP server and blocks until the context is canceled.

Types

type Config

type Config struct {
	Port       int
	HealthPort int
}

Config holds server configuration.

type Problem

type Problem struct {
	Type   string `json:"type"`
	Title  string `json:"title"`
	Status int    `json:"status"`
	Detail string `json:"detail,omitempty"`
}

Problem represents an RFC 9457 Problem Details response.

Jump to

Keyboard shortcuts

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