Example: full app with SQLite store (single binary, zero deps) #27

Closed
opened 2026-02-19 22:28:39 +00:00 by ash · 2 comments
Owner

What

Complete working example app using SQLite store. The simplest possible deployment — one Go binary, one SQLite file.

Must Demonstrate

  • All 3 event modeling patterns (state change, state view, automation)
  • CommandBus with single writer (in-process)
  • EventSubscription with guaranteed delivery
  • SQLiteNotifier for real-time updates
  • Projections → read models
  • Automations with TodoList pattern
  • GDPR forget flow
  • Schema evolution (v1 → v2 event)
  • HTTP API (Chi router)
  • SSE live updates via Datastar + Templ
  • go run main.go and it works

Stack

Go + Templ + Datastar + Open Props + SQLite + Chi

Why

This is the "getting started" example. If someone can't get this running in 30 seconds, we've failed.

## What Complete working example app using SQLite store. The simplest possible deployment — one Go binary, one SQLite file. ## Must Demonstrate - All 3 event modeling patterns (state change, state view, automation) - CommandBus with single writer (in-process) - EventSubscription with guaranteed delivery - SQLiteNotifier for real-time updates - Projections → read models - Automations with TodoList pattern - GDPR forget flow - Schema evolution (v1 → v2 event) - HTTP API (Chi router) - SSE live updates via Datastar + Templ - `go run main.go` and it works ## Stack Go + Templ + Datastar + Open Props + SQLite + Chi ## Why This is the "getting started" example. If someone can't get this running in 30 seconds, we've failed.
Author
Owner

Implemented in commit 0b50908. Full working examples with end-to-end flow tested (HTTP → CommandBus → Decider → Store → Subscription → Projection → HTTP query).

Also fixed library gap: added subscription.StoreAdapter and pgstore.SubscriptionAdapter to bridge the type mismatch between store Event[E] and subscription GlobalEvent[E].

Implemented in commit 0b50908. Full working examples with end-to-end flow tested (HTTP → CommandBus → Decider → Store → Subscription → Projection → HTTP query). Also fixed library gap: added subscription.StoreAdapter and pgstore.SubscriptionAdapter to bridge the type mismatch between store Event[E] and subscription GlobalEvent[E].
ash closed this issue 2026-02-20 08:15:34 +00:00
Author
Owner

Implemented. Full end-to-end flow tested.

Implemented. Full end-to-end flow tested.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ash/eskit#27
No description provided.