ViewStoreAutoConfiguration

@ConditionalOnClass(value = [CommandHandler::class])
@EnableConfigurationProperties(value = [ViewStoreProperties::class])
class ViewStoreAutoConfiguration

Puts the view store into a Wow service: the View, ViewPreferences and DatasetWording aggregates come with the domain on the classpath (Wow routes them like the host's own, under /view-store); this adds what they need around them. Every bean is named for the view store and touches only the view store's aggregates and paths, so the host's own aggregates, routes and queries are left as they were.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
object Companion
Link copied to clipboard
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(name = ["me.ahoo.wow.kafka.CommandTopicConverter"])
class ViewStoreKafkaConfiguration

The view store's own Kafka topic prefix, when ViewStoreKafkaProperties.TOPIC_PREFIX is set to text (a blank prefix is no prefix). Its beans are static, so that Spring creates the BeanPostProcessor before, and without, this class.

Link copied to clipboard
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(name = ["org.springdoc.core.customizers.OpenApiCustomizer"])
class ViewStoreOpenApiConfiguration

Documents the view store's own routes when Wow's OpenAPI document is served (as Wow's springdoc customizer). The customizer is created eagerly, even under spring.main.lazy-initialization, so their schemas are generated at startup and never on a request thread. The routes the view store closes are taken out of the document by an OpenApiDocumentFilter, which Wow's customizer applies after merging them.

Link copied to clipboard
@Configuration(proxyBeanMethods = false)
@ConditionalOnClass(name = ["me.ahoo.wow.kafka.KafkaCommandBus"])
class ViewStoreSharedTopicsConfiguration

Warns at startup when the view store's Kafka topics are Wow's default ones, which every other deployment of the view store left at its defaults shares (viewStoreSharedTopicsWarning).

Functions

Link copied to clipboard
@Bean
@ConditionalOnMissingBean
fun sharedBoardReferences(beanFactory: BeanFactory): SharedBoardReferences
Link copied to clipboard
@Bean
@ConditionalOnMissingBean
fun storedSystemViewSource(snapshotQueryBackendFactories: ObjectProvider<SnapshotQueryBackendFactory>, beanFactory: BeanFactory): StoredSystemViewSource

The system views stored under (platform)/(system), from the view snapshots, when the host has a snapshot query backend for views; otherwise none (Wow's fallback backend answers every query with an error, which would take the configured system views down with it), with one warning.

Link copied to clipboard
@Bean
@ConditionalOnMissingBean
fun systemViewProvider(viewStoreProperties: ViewStoreProperties): SystemViewProvider
Link copied to clipboard

Opens state.config.kind and the panel references of state.config to snapshot queries.