Skip to content

v0.17.0 — Configurable derive overloads

Choose a tag to compare

@sideeffffect sideeffffect released this 08 Jun 00:30
· 68 commits to master since this release

Highlights

The three name-bound derivations now each offer two derive overloads — pass the name explicitly, or let it be derived from the type's simple name (honouring @name):

Derivation Explicit Name-derived
ActorDefinitions derive[C](actorType: ActorType) (new) derive[C] → ActorType from the class name
ServiceInvocation derive[T](appId: AppId) derive[T] → AppId from the trait name (new)
Subscriptions derive[T](pubsubName: PubSubName) derive[T] → PubSubName from the type name (new)
// explicit
val svc = ServiceInvocation.derive[GreetingService](AppId("greeting-service"))
// name-derived — AppId("GreetingService")
val svc = ServiceInvocation.derive[GreetingService]

ActorDefinitions gains the explicit-ActorType form (it previously only derived from the class name); ServiceInvocation and Subscriptions gain the name-derived form (they previously required the name). All additions are backward compatible.

Features

  • Add name-deriving derive overloads for ActorDefinitions, ServiceInvocation and Subscriptions. Name resolution goes through a new MacroSupport.derivedTypeName, which honours @name on the type and strips a module's trailing $ so Foo.type yields Foo.

Docs

  • Mandate auto-commit/push and curated GitHub Releases in AGENTS.md.

Full Changelog: v0.16.0...v0.17.0