Class AbstractRegistry<E,C>
java.lang.Object
io.github.resilience4j.core.registry.AbstractRegistry<E,C>
- All Implemented Interfaces:
Registry<E,C>
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface Registry
Registry.EventPublisher<E> -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected final ConcurrentMap<String, C> protected static final Stringprotected static final Stringprotected final RegistryStore<E> private final AbstractRegistry<E,C>.RegistryEventProcessor private static final Stringprivate static final StringGlobal tags which must be added to each instance created by this registry.protected static final Stringprotected static final String -
Constructor Summary
ConstructorsConstructorDescriptionAbstractRegistry(C defaultConfig) AbstractRegistry(C defaultConfig, RegistryEventConsumer<E> registryEventConsumer) AbstractRegistry(C defaultConfig, RegistryEventConsumer<E> registryEventConsumer, Map<String, String> tags) AbstractRegistry(C defaultConfig, List<RegistryEventConsumer<E>> registryEventConsumers) AbstractRegistry(C defaultConfig, List<RegistryEventConsumer<E>> registryEventConsumers, Map<String, String> tags) AbstractRegistry(C defaultConfig, List<RegistryEventConsumer<E>> registryEventConsumers, Map<String, String> tags, RegistryStore<E> registryStore) AbstractRegistry(C defaultConfig, Map<String, String> registryTags) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddConfiguration(String configName, C configuration) Adds a configuration to the registryprotected EcomputeIfAbsent(String name, Supplier<E> supplier) Find a named entry in the RegistrygetAllTags(Map<String, String> tags) Creates map with all tags (registry and instance).getConfiguration(String configName) Get a configuration by nameGet the default configurationReturns an EventPublisher which can be used to register event consumers.getTags()Remove an entry from the RegistryReplace an existing entry in the Registry by a new one.
-
Field Details
-
DEFAULT_CONFIG
- See Also:
-
CONFIG_MUST_NOT_BE_NULL
- See Also:
-
CONSUMER_MUST_NOT_BE_NULL
- See Also:
-
SUPPLIER_MUST_NOT_BE_NULL
- See Also:
-
TAGS_MUST_NOT_BE_NULL
- See Also:
-
NAME_MUST_NOT_BE_NULL
- See Also:
-
REGISTRY_STORE_MUST_NOT_BE_NULL
- See Also:
-
entryMap
-
configurations
-
registryTags
-
eventProcessor
-
-
Constructor Details
-
AbstractRegistry
-
AbstractRegistry
-
AbstractRegistry
-
AbstractRegistry
-
AbstractRegistry
-
AbstractRegistry
-
AbstractRegistry
public AbstractRegistry(C defaultConfig, List<RegistryEventConsumer<E>> registryEventConsumers, Map<String, String> tags, RegistryStore<E> registryStore)
-
-
Method Details
-
computeIfAbsent
-
find
-
remove
-
replace
-
addConfiguration
-
getConfiguration
-
getDefaultConfig
-
getTags
-
getEventPublisher
Description copied from interface:RegistryReturns an EventPublisher which can be used to register event consumers.- Specified by:
getEventPublisherin interfaceRegistry<E,C> - Returns:
- an EventPublisher
-
getAllTags
-