remote

package
v4.3.1 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2023 License: Apache-2.0 Imports: 13 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AbsApolloConfig

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

AbsApolloConfig 抽象 apollo 配置

func (*AbsApolloConfig) SyncWithNamespace

func (a *AbsApolloConfig) SyncWithNamespace(namespace string, appConfigFunc func() config.AppConfig) *config.ApolloConfig

type ApolloConfig

type ApolloConfig interface {
	// GetNotifyURLSuffix 获取异步更新路径
	GetNotifyURLSuffix(notifications string, config config.AppConfig) string
	// GetSyncURI 获取同步路径
	GetSyncURI(config config.AppConfig, namespaceName string) string
	// Sync 同步获取 Apollo 配置
	Sync(appConfigFunc func() config.AppConfig) []*config.ApolloConfig
	// CallBack 根据 namespace 获取 callback 方法
	CallBack(namespace string) http.CallBack
	// SyncWithNamespace 通过 namespace 同步 apollo 配置
	SyncWithNamespace(namespace string, appConfigFunc func() config.AppConfig) *config.ApolloConfig
}

ApolloConfig apollo 配置

func CreateAsyncApolloConfig

func CreateAsyncApolloConfig() ApolloConfig

CreateAsyncApolloConfig 创建异步 apollo 配置

func CreateSyncApolloConfig

func CreateSyncApolloConfig() ApolloConfig

CreateSyncApolloConfig 创建同步获取 Apollo 配置

Jump to

Keyboard shortcuts

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