thor

package module
v0.0.0-...-4146708 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2023 License: MIT Imports: 9 Imported by: 0

README

thor

项目命令

  • 单元测试:make test
  • 代码检查: make lint
  • 提交检查执行:make pre_commit
  • 提交检查安装:make pre_commit_install
  • 提交检查卸载:make pre_commit_uninstall

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

type Application interface {
	ID() string
	Name() string
	Version() string
	Namespace() string
	Run() error
}

func New

func New(options ...Option) Application

New a server bootstrap

type Option

type Option func(ops *Options)

Option setter

func WithLog

func WithLog(l logger.Logger) Option

WithLog with service id.

func WithServer

func WithServer(boxes ...server.Server) Option

WithServer set servers

func WithShutdownTimeout

func WithShutdownTimeout(timeout int) Option

WithShutdownTimeout app shutdown timeout

func WithStartupTimeout

func WithStartupTimeout(timeout int) Option

WithStartupTimeout app startup timeout

type Options

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

Options new server options

Directories

Path Synopsis
Package build contains application build information ```sh go run -ldflags="-X 'github.com/go-thor/thor/build.Namespace={Namespace}' -X 'github.com/go-thor/thor/build.Name={Name}' -X 'github.com/go-thor/thor/build.Version={Version}' -X 'github.com/go-thor/thor/build.Instance={Instance}' -X 'github.com/go-thor/thor/build.BuildId={BuildId}' -X 'github.com/go-thor/thor/build.BuildTime={BuildTime}'" .
Package build contains application build information ```sh go run -ldflags="-X 'github.com/go-thor/thor/build.Namespace={Namespace}' -X 'github.com/go-thor/thor/build.Name={Name}' -X 'github.com/go-thor/thor/build.Version={Version}' -X 'github.com/go-thor/thor/build.Instance={Instance}' -X 'github.com/go-thor/thor/build.BuildId={BuildId}' -X 'github.com/go-thor/thor/build.BuildTime={BuildTime}'" .
Package codec handles data encoding
Package codec handles data encoding
xml
Package config is an interface for dynamic configuration.
Package config is an interface for dynamic configuration.
reader
Package reader parses change sets and provides config values
Package reader parses change sets and provides config values
source
Package source is the interface for sources
Package source is the interface for sources
source/file
Package file is a file source.
Package file is a file source.

Jump to

Keyboard shortcuts

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