Class CosIdAutoConfiguration
java.lang.Object
me.ahoo.cosid.spring.autoconfigure.CosIdAutoConfiguration
@AutoConfiguration(afterName="org.springframework.cloud.commons.util.UtilAutoConfiguration")
@ConditionalOnProperty(prefix="cosid",
name="enabled",
havingValue="true",
matchIfMissing=true)
@EnableConfigurationProperties(CosIdProperties.class)
@ImportRuntimeHints(CosIdRuntimeHints.class)
public class CosIdAutoConfiguration
extends Object
Starts the
CosIdRuntime (07-runtime-and-spring.md ยง4.2): the spec from cosid.* and the
RuntimeSpecCustomizers (CosIdGeneratorRegistrar), the StoreProvider beans, the clients of the
context (DataSource, Lettuce or RedisConnectionFactory, MongoClient, CuratorFramework),
the GeneratorListener beans and a HostResolver bean if any (Spring Cloud's InetUtils gives one,
the first non-loopback address, as in 4.x). The runtime is fixed once started (D17);
the context closes it after the beans that use its generators, and before the clients it uses.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic org.springframework.core.convert.converter.GenericConverterBinds theCosIdPropertiesbean asCosIdSpecs.bind(java.lang.Iterable<org.springframework.boot.context.properties.source.ConfigurationPropertySource>, org.springframework.boot.context.properties.bind.PlaceholdersResolver)does:- friendly: {}is its defaults.me.ahoo.cosid.accessor.IdFillercosIdFiller(me.ahoo.cosid.runtime.CosIdRuntime runtime) static CosIdGeneratorRegistrarme.ahoo.cosid.runtime.CosIdRuntimecosIdRuntime(me.ahoo.cosid.runtime.RuntimeSpec spec, CosIdProperties properties, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.store.StoreProvider> storeProviders, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.observe.GeneratorListener> listeners, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.runtime.HostResolver> hostResolver, org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory, org.springframework.core.env.Environment environment) me.ahoo.cosid.runtime.RuntimeSpeccosIdRuntimeSpec(CosIdGeneratorRegistrar registrar)
-
Constructor Details
-
CosIdAutoConfiguration
public CosIdAutoConfiguration()
-
-
Method Details
-
cosIdGeneratorRegistrar
-
cosIdEmptyItems
@Bean @ConfigurationPropertiesBinding public static org.springframework.core.convert.converter.GenericConverter cosIdEmptyItems()Binds theCosIdPropertiesbean asCosIdSpecs.bind(java.lang.Iterable<org.springframework.boot.context.properties.source.ConfigurationPropertySource>, org.springframework.boot.context.properties.bind.PlaceholdersResolver)does:- friendly: {}is its defaults. -
cosIdRuntimeSpec
@Bean("cosIdRuntimeSpec") public me.ahoo.cosid.runtime.RuntimeSpec cosIdRuntimeSpec(CosIdGeneratorRegistrar registrar) -
cosIdRuntime
@Bean(name="cosIdRuntime", destroyMethod="close") public me.ahoo.cosid.runtime.CosIdRuntime cosIdRuntime(@Qualifier("cosIdRuntimeSpec") me.ahoo.cosid.runtime.RuntimeSpec spec, CosIdProperties properties, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.store.StoreProvider> storeProviders, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.observe.GeneratorListener> listeners, org.springframework.beans.factory.ObjectProvider<me.ahoo.cosid.runtime.HostResolver> hostResolver, org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory, org.springframework.core.env.Environment environment) -
cosIdFiller
@Bean public me.ahoo.cosid.accessor.IdFiller cosIdFiller(me.ahoo.cosid.runtime.CosIdRuntime runtime)
-