model

package
v0.0.0-...-fc7dab2 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateTables

func CreateTables()

func DropTables

func DropTables()

func NewConfigurator

func NewConfigurator() *cfg

Types

type BalancerConfig

type BalancerConfig struct {
	model.Model
	Port          int                     `gorm:"default:12001"`
	Address       string                  `gorm:"default:localhost"`
	DefaultAlgo   int                     `gorm:"default:0"` // Random
	PreferredAlgo []BalancerPreferredAlgo `gorm:"constraint:OnUpdate:CASCADE,OnDelete:SET NULL;"`
}

type BalancerPreferredAlgo

type BalancerPreferredAlgo struct {
	model.Model
	ServiceName      string `gorm:"not null"`
	Algo             int    `gorm:"default:0"` // Random
	BalancerConfigID uint
}

type HubConfigurator

type HubConfigurator interface {
	service.ServiceConfigurator
	Secret() string
}

Jump to

Keyboard shortcuts

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