lib

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StatusOnline     int8 = iota
	StatusOffline         = 2
	StatusNoNewSyncs      = 3
)

Variables

View Source
var VERSION string

Functions

This section is empty.

Types

type Config

type Config struct {
	Debug string

	Database struct {
		Type       string
		Connection string
	}

	Server struct {
		BindIP string
		Port   string

		Prefork                 bool
		ServerHeader            string
		StrictRouting           bool
		CaseSensitive           bool
		ETag                    bool
		Concurrency             int
		ProxyHeader             string
		EnableTrustedProxyCheck bool
		TrustedProxies          []string
		DisableStartupMessage   bool
		AppName                 string
		ReduceMemoryUsage       bool
		Network                 string
		EnablePrintRoutes       bool
	}

	Service struct {
		Location    string
		Status      ServiceStatus
		Message     string
		MaxSyncSize int
	}

	Limiter struct {
		Max        int
		Expiration time.Duration
	}
}

func Cfg

func Cfg() (Config, error)

func ParseDatabaseURL

func ParseDatabaseURL(config *Config) *Config

type ServiceStatus added in v0.1.1

type ServiceStatus int8

type XBSContext

type XBSContext struct {
	Config    *Config
	EntClient *ent.Client
	Logger    *zap.Logger
}

Jump to

Keyboard shortcuts

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