treemanager

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultTreeManagerListen is the default listen address for the TreeManager.
	DefaultTreeManagerListen = ":8080"
	// DefaultTreeManagerUnix is the default unix socket for the TreeManager.
	DefaultTreeManagerUnix = ""
	// DefaultTreeManagerDebug is the default debug flag for the TreeManager.
	DefaultTreeManagerDebug = false
	// DefaultTreeManagerShutdownTimeout is the default shutdown timeout for the TreeManager.
	DefaultTreeManagerShutdownTimeout = 5 * time.Second
)

Variables

View Source
var DefaultTreeManagerNotifier = noop.NewNotifier()

DefaultTreeManagerNotifier is the default notifier for the TreeManager.

Functions

func NewServer

func NewServer(
	logger *zap.Logger,
	db *sql.DB,
	opts ...Option,
) *common.Server

Types

type Option added in v0.0.6

type Option func(*treeManagerConfig)

func WithAuditMiddleware added in v0.0.10

func WithAuditMiddleware(auditMiddleware *ginaudit.Middleware) Option

func WithAuthConfig added in v0.0.10

func WithAuthConfig(config *ginjwt.AuthConfig) Option

WithAuthConfig sets the jwt auth config.

func WithDebug added in v0.0.6

func WithDebug(debug bool) Option

WithDebug sets the debug flag for the server.

func WithListen added in v0.0.6

func WithListen(listen string) Option

WithListen sets the listen address for the server.

func WithNotifier added in v0.0.6

func WithNotifier(n notifier.Notifier) Option

WithNotifier sets the notifier for the server.

func WithShutdownTimeout added in v0.0.6

func WithShutdownTimeout(t time.Duration) Option

WithShutdownTimeout sets the shutdown timeout for the server.

func WithStorageDriver added in v0.0.6

func WithStorageDriver(d storage.DirectoryAdmin) Option

WithStorageDriver sets the storage driver for the server.

func WithUnix added in v0.0.6

func WithUnix(unix string) Option

WithUnix sets the unix socket for the server. If set, the server will listen on the unix socket instead of the listen address.

Jump to

Keyboard shortcuts

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