configs

package
v4.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2022 License: MIT Imports: 6 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Database *gorm.DB

Functions

This section is empty.

Types

type Db

type Db struct {
	Host     string `json:"host" yaml:"host"`
	Port     int    `json:"port" yaml:"port"`
	User     string `json:"user" yaml:"user"`
	Password string `json:"password" yaml:"password"`
	Name     string `json:"name" yaml:"name"`
	Driver   string `json:"driver" yaml:"driver"`
}

type Env

type Env struct {
	Debug         bool   `json:"debug" yaml:"debug"`
	Name          string `json:"name" yaml:"name"`
	Secret        string `json:"secret" yaml:"secret"`
	HttpPort      int    `json:"http_port" yaml:"http_port"`
	RpcPort       int    `json:"rpc_port" yaml:"rpc_port"`
	Service       string `json:"service" yaml:"service"`
	Db            Db     `json:"database" yaml:"database"`
	CacheLifetime int    `json:"cache_lifetime" yaml:"cache_lifetime"`
	User          string
}

type Server

type Server interface {
	Register(server *grpc.Server)
	Handle(context context.Context, server *runtime.ServeMux, client *grpc.ClientConn) error
	Migrate(db *gorm.DB)
	Consume(messenger *messengers.Messenger)
	Sync(client *elastic.Client)
}

Jump to

Keyboard shortcuts

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