app

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2026 License: AGPL-3.0 Imports: 27 Imported by: 0

Documentation

Overview

Package app owns Starport production composition and lifecycle.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrConfigRequired reports an absent application configuration.
	ErrConfigRequired = errors.New("application config is required")
	// ErrStorageRequired reports a storage factory that returned no adapter.
	ErrStorageRequired = errors.New("storage factory returned no storage")
	// ErrCatalogRequired reports a catalog factory that returned no control plane.
	ErrCatalogRequired = errors.New("catalog factory returned no catalog")
	// ErrCredentialsRequired reports an absent provider-credential master key.
	ErrCredentialsRequired = errors.New("provider credential master key is required")
	// ErrIdentityRequired reports empty gateway identity storage.
	ErrIdentityRequired = errors.New("gateway identity is required; run \"starport init\"")
)
View Source
var (
	// ErrProvidersRequired reports an empty production provider set.
	ErrProvidersRequired = errors.New("at least one production provider is required")
)

Functions

This section is empty.

Types

type App

type App struct {
	// contains filtered or unexported fields
}

App owns all constructed runtime dependencies.

func New

func New(cfg *config.Config, options ...Option) (*App, error)

New creates the complete production runtime without starting background work.

func (*App) Close

func (a *App) Close(ctx context.Context) error

Close stops owned dependencies in reverse construction order.

func (*App) Run

func (a *App) Run(ctx context.Context) error

Run starts explicit runtime work and closes all dependencies on exit.

type Option

type Option func(*buildOptions)

Option changes runtime factories for explicit test composition.

Jump to

Keyboard shortcuts

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