Video series · Episode 4 · 10–12 min

Your first Chenile service (live demo)

Hands-on: generate an api + service pair and a deployable mini-monolith with jgen, build it, and call it. The definition/implementation split, made real.

← All episodes

Episode goal: convert theory into muscle memory. Viewer watches a service go from nothing to a running endpoint with jgen, and sees the two-module structure appear.

Cold open
On camera: “Enough theory. Let’s generate a real Chenile service with jgen, build it, and call it — and watch the definition/implementation split appear on disk.”
Prereqs
On screen checklist: Java 17+, Maven, git, a shell. “jgen is pure Java — no Node needed. If you have these, you’re ten minutes from a running service.” (Note on screen: the old app-gen/gen.sh is deprecated.)
Demo — install jgen
Terminal: git clone …/chenile-gen, cd chenile-gen, make clean all, then source setpath.sh. Narrate: “make all builds jgen and the CLI; setpath.sh puts jgen and stm-cli on the PATH. One-time setup.”
Demo — generate the service
Run jgen → pick the chenile-service blueprint. Service name orders; accept version/output defaults; jpa: y. “Answer a few prompts and jgen expands the blueprint.”
Payoff
Expand output/orders/: point at orders-api and orders-service. “There it is — the exact split from last episode, generated for you.”
Demo — the deployable
Run jgen again → minimonolith blueprint; name ordersdeploy; add orders under dependencies. “A service is a library; the mini-monolith hosts it.”
Demo — build
cd output/orders && make build, then cd ../ordersdeploy && make build. Narrate the api and service libraries building, then the deployable.
Demo — run & call
Start the mini-monolith (make run); hit the generated endpoint with a curl script from scripts/. Show the response, then the health endpoint. “Business logic, a health probe, and an HTTP binding — and we wrote none of the plumbing.”
Point
Voiceover: “Look at the impl again — still just business logic. Everything else came from the framework. Next, we start adding the horizontal behavior as policies.”
Recap card
“Generated an api + service pair and a deployable monolith, built and called it — no plumbing written by hand.”

Companion reading: Get started · Definition vs. implementation