registry

package
v0.0.0-...-42086f8 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2024 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetMetadataInfo

func GetMetadataInfo(instance registry.ServiceInstance, revision string) (*common.MetadataInfo, error)

GetMetadataInfo get metadata info when MetadataStorageTypePropertyName is null

func NewDubboSDNotifyListener

func NewDubboSDNotifyListener(services *gxset.HashSet) registry.ServiceInstancesChangedListener

Types

type DubboSDNotifyListener

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

DubboSDNotifyListener The Service Discovery Changed Event Listener

func (*DubboSDNotifyListener) Accept

func (lstn *DubboSDNotifyListener) Accept(e observer.Event) bool

Accept return true if the name is the same

func (*DubboSDNotifyListener) AddListenerAndNotify

func (lstn *DubboSDNotifyListener) AddListenerAndNotify(serviceKey string, notify registry.NotifyListener)

AddListenerAndNotify add notify listener and notify to listen service event

func (*DubboSDNotifyListener) GetEventType

func (lstn *DubboSDNotifyListener) GetEventType() reflect.Type

GetEventType returns ServiceInstancesChangedEvent

func (*DubboSDNotifyListener) GetPriority

func (lstn *DubboSDNotifyListener) GetPriority() int

GetPriority returns -1, it will be the first invoked listener

func (*DubboSDNotifyListener) GetServiceNames

func (lstn *DubboSDNotifyListener) GetServiceNames() *gxset.HashSet

GetServiceNames return all listener service names

func (*DubboSDNotifyListener) OnEvent

func (lstn *DubboSDNotifyListener) OnEvent(e observer.Event) error

OnEvent on ServiceInstancesChangedEvent the service instances change event

func (*DubboSDNotifyListener) RemoveListener

func (lstn *DubboSDNotifyListener) RemoveListener(serviceKey string)

RemoveListener remove notify listener

type MetadataInstance

type MetadataInstance struct {
	registry.ServiceInstance
}

func ConvertToMetadataInstance

func ConvertToMetadataInstance(serviceInstance registry.ServiceInstance) *MetadataInstance

func (*MetadataInstance) GetServiceName

func (m *MetadataInstance) GetServiceName() string

type NotifyListener

type NotifyListener struct {
	manager.ResourceManager
	// contains filtered or unexported fields
}

func NewNotifyListener

func NewNotifyListener(
	manager manager.ResourceManager,
	cache *sync.Map,
	discovery dubboRegistry.ServiceDiscovery,
	writer events.Emitter,
) *NotifyListener

func (*NotifyListener) Notify

func (l *NotifyListener) Notify(event *dubboRegistry.ServiceEvent)

func (*NotifyListener) NotifyAll

func (l *NotifyListener) NotifyAll(events []*dubboRegistry.ServiceEvent, f func())

type Registry

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

func NewRegistry

func NewRegistry(delegate dubboRegistry.Registry, sdDelegate dubboRegistry.ServiceDiscovery) *Registry

func (*Registry) Delegate

func (r *Registry) Delegate() dubboRegistry.Registry

func (*Registry) Destroy

func (r *Registry) Destroy() error

func (*Registry) Subscribe

func (r *Registry) Subscribe(
	metadataReport report.MetadataReport,
	resourceManager core_manager.ResourceManager,
	cache *sync.Map,
	discovery dubboRegistry.ServiceDiscovery,
	out events.Emitter,
	systemNamespace string,
) error

type ServiceMappingChangedListenerImpl

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

func NewMappingListener

func NewMappingListener(
	interfaceKey string,
	oldServiceNames *gxset.HashSet,
	listener registry.NotifyListener,
	writer events.Emitter,
	systemNamespace string,
	delSDRegistry registry.ServiceDiscovery,
) *ServiceMappingChangedListenerImpl

func (*ServiceMappingChangedListenerImpl) OnEvent

OnEvent on ServiceMappingChangedEvent the service mapping change event

func (*ServiceMappingChangedListenerImpl) Stop

func (lstn *ServiceMappingChangedListenerImpl) Stop()

Stop on ServiceMappingChangedEvent the service mapping change event

Jump to

Keyboard shortcuts

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