discover

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2022 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 2 more Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetClient

func SetClient(factory Factory)

SetClient set the iam discover client.

Types

type Factory

type Factory interface {
	Register() ServiceRegister
	Discover() ServiceDiscover

	Info() InfoStore
	// PolicyAudits() PolicyAuditStore
	Close() error
}

Factory defines the iam platform storage interface.

func Client

func Client() Factory

Client return the discover client instance.

type InfoStore

type InfoStore interface {
	Put(ctx context.Context, key, value string) error
	Get(ctx context.Context, key string) ([]byte, error)
	Close() error
}

InfoStore information store interface.

type ServiceDiscover

type ServiceDiscover interface {
	DiscoverStart(ctx context.Context, prefix string) error

	GetService() []string

	GetHttpsService() []string

	RestartSession() error
	Close() error
}

ServiceDiscover service discover interface.

type ServiceRegister

type ServiceRegister interface {
	NewServiceRegister(ctx context.Context, cluster, proto, key, value string) error
	RecoveryServiceRegister(ctx context.Context) error

	RestartSession() error
	Close() error
}

ServiceRegister service register interface.

Directories

Path Synopsis
Package etcd implements `github.com/marmotedu/iam/internal/apiserver/discover.Store` interface.
Package etcd implements `github.com/marmotedu/iam/internal/apiserver/discover.Store` interface.

Jump to

Keyboard shortcuts

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