entrypoint

package
v0.0.0-...-6da63fb Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2026 License: AGPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModeSelfHosted = internalserver.ModeSelfHosted
	ModeCloud      = internalserver.ModeCloud
)

Variables

This section is empty.

Functions

func ConnectMigrationDatabase

func ConnectMigrationDatabase(cfg MigrationConfig) (*bun.DB, error)

func InitializeProcessingWithFactory

func InitializeProcessingWithFactory(cfg *config.Config, nodeCfg sharedprocessing.NodeConfig, logger *zap.Logger, runtimeFactory sharedprocessing.RuntimeFactory) (*bootstrap.Services, error)

func InitializeProcessingWithFactoryAndHooks

func InitializeProcessingWithFactoryAndHooks(cfg *config.Config, nodeCfg sharedprocessing.NodeConfig, logger *zap.Logger, runtimeFactory sharedprocessing.RuntimeFactory, hooks sharedprocessing.NodeHooks) (*bootstrap.Services, error)

func NewProcessingHandlerForTests

func NewProcessingHandlerForTests(args []string, nodeCfg sharedprocessing.NodeConfig, runtimeFactory sharedprocessing.RuntimeFactory, hooks sharedprocessing.NodeHooks) (http.Handler, func() error, error)

func Run

func Run(embedFS fs.FS, mode Mode)

func RunAutoMigration

func RunAutoMigration(db *bun.DB, databaseURL string, forceAutoMigrate bool, logger *zap.Logger) (bool, error)

func RunCloudWithFactories

func RunCloudWithFactories(embedFS fs.FS, factories management.CloudFactories)

func RunCloudWithFactoriesAndArgs

func RunCloudWithFactoriesAndArgs(embedFS fs.FS, args []string, factories management.CloudFactories)

func RunCloudWorkerWithFactoriesAndArgs

func RunCloudWorkerWithFactoriesAndArgs(args []string, factories management.CloudFactories, runner management.CloudWorkerRunner)

func RunMigrations

func RunMigrations(db *bun.DB, databaseURL, command string, logger *zap.Logger) error

func RunProcessingWithBuilder

func RunProcessingWithBuilder(embedFS fs.FS, build func(cfg *config.Config, logger *zap.Logger) (*bootstrap.Services, error))

func RunProcessingWithBuilderAndArgs

func RunProcessingWithBuilderAndArgs(embedFS fs.FS, args []string, build func(cfg *config.Config, logger *zap.Logger) (*bootstrap.Services, error))

func RunProcessingWithFactory

func RunProcessingWithFactory(embedFS fs.FS, nodeCfg sharedprocessing.NodeConfig, runtimeFactory sharedprocessing.RuntimeFactory)

func RunProcessingWithFactoryAndArgs

func RunProcessingWithFactoryAndArgs(embedFS fs.FS, args []string, nodeCfg sharedprocessing.NodeConfig, runtimeFactory sharedprocessing.RuntimeFactory)

func RunProcessingWithFactoryAndArgsAndHooks

func RunProcessingWithFactoryAndArgsAndHooks(embedFS fs.FS, args []string, nodeCfg sharedprocessing.NodeConfig, runtimeFactory sharedprocessing.RuntimeFactory, hooks sharedprocessing.NodeHooks)

Types

type MigrationConfig

type MigrationConfig struct {
	DatabaseURL             string
	ForceAutoMigrate        bool
	MigrateCommand          string
	PostgresMaxOpenConns    int
	PostgresMaxIdleConns    int
	PostgresConnMaxLifetime time.Duration
	PostgresConnMaxIdleTime time.Duration
}

func LoadMigrationConfig

func LoadMigrationConfig(args []string) (MigrationConfig, error)

type Mode

type Mode = internalserver.Mode

Jump to

Keyboard shortcuts

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