WowExtension

abstract class WowExtension

The wow { } block of a module that applies me.ahoo.wow, or me.ahoo.wow.service, which builds its own sources as a domain module does: its models and contract.

wow {
context = "shop"
service = "shop-service"
schemaOverrides.put("sample.Money", """{"type":"string"}""")
}

Inheritors

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
abstract val context: Property<String>

The bounded context this module's aggregates and subscriptions belong to (the KSP option wow.context). Unset, the module's one @BoundedContext names it.

Link copied to clipboard
abstract val schemaOverrides: MapProperty<String, String>

JSON Schemas (2020-12, as JSON text) that replace the introspected schema of a class, by its JVM binary name. Introspection follows Jackson's annotations, naming and Kotlin module, but cannot see inside a custom serializer: a type written by one declares its schema here.

Link copied to clipboard
abstract val service: Property<String>

The service that hosts the module's contexts, as it names itself (spring.application.name): the module's contract names it, so a peer that depends on the api module finds the service by this name, and the service refuses to start under another. The service module merging the contexts takes its name from the contracts (its own included), which must agree; unset everywhere, the contract names no service, a peer reaches it at wow.peers.<context>.url alone, and the service is named after the project path of its module.