confgov2

package
Version: v0.4.5 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2021 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DiffDefaultScene = 1 //默认最近2版本对比
	DiffSpecifyScene = 2 //指定版本与最新版本对比
)
View Source
const (
	ExpiredLockTime = 6
)

Variables

This section is empty.

Functions

func CheckSyntax

func CheckSyntax(format model.ConfigFormat, content string) error

func ClusterPublishConfigInfo

func ClusterPublishConfigInfo(clusterName string) (configurationRes view.ClusterConfigInfo, err error)

ClusterPublishConfigInfo ..

func Create

func Create(c echo.Context, param view.ReqCreateConfig) (resp view.RespDetailConfig, err error)

Create ..

func Delete

func Delete(c echo.Context, id uint) (err error)

Delete ..

func Detail

func Detail(param view.ReqDetailConfig) (resp view.RespDetailConfig, err error)

func Diff

func Diff(configID, historyID uint, scene int) (resp view.RespDiffConfig, err error)

Diff ..

func DiffReleaseConfig

func DiffReleaseConfig(param view.ReqDiffReleaseConfig) (resp view.RespDiffReleaseConfig, err error)

DiffReleaseConfig ..

func DiffReleaseConfigByFile

func DiffReleaseConfigByFile(param view.ReqDiffReleaseConfig) (resp view.RespDiffReleaseConfig, err error)

DiffReleaseConfigByFile ..

func DiffVersion

func DiffVersion(param view.ReqDiffConfig) (resp view.RespDiffConfig, err error)

DiffVersion ..

func GetAllConfigByEnv

func GetAllConfigByEnv(env string) (resp map[uint]struct{}, err error)

func GetAllConfigText

func GetAllConfigText() (list []db.Configuration, err error)

func History

func History(param view.ReqHistoryConfig, uid int) (resp view.RespHistoryConfig, err error)

History 发布历史分页列表,Page从0开始

func Init

func Init(d *gorm.DB)

Init ..

func Instances

func Instances(param view.ReqConfigInstanceList) (resp view.RespConfigInstanceList, err error)

Instances ..

func List

func List(param view.ReqListConfig) (resp view.RespListConfig, err error)

func Publish

func Publish(param view.ReqPublishConfig, c echo.Context) (err error)

Publish ..

func ReadInstanceConfig

func ReadInstanceConfig(param view.ReqReadInstanceConfig) (configContentList []view.RespReadInstanceConfigItem, err error)

func StatisticsCommit

func StatisticsCommit(start, end int64) (cmcCnt []view.CmcCnt, total int, err error)

func StatisticsEnv

func StatisticsEnv() (res []view.EnvStatic, total int, err error)

func TryLock

func TryLock(uid, configId uint) (err error)

func Unlock

func Unlock(uid, configId uint) (err error)

func Update

func Update(c echo.Context, param view.ReqUpdateConfig) (err error)

Update ..

Types

type SyntaxError

type SyntaxError struct {
	LineNumber int
	Message    string
}

func (SyntaxError) Error

func (s SyntaxError) Error() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto