Quickstart

Get started

Generate an api + service pair, build a deployable monolith, and start attaching policies. Under ten minutes on a machine with Node, Make and Maven.

What you’ll need

  • Node — the generator uses Mustache (downloaded automatically).
  • GNU/UNIX make — to build the generator the first time.
  • Maven (mvn) — to build the generated service.
  • A shell — bash or PowerShell.

1 · Set up the generator

mkdir code && cd code
git clone https://github.com/rajakolluru/chenile-gen.git
cd chenile-gen/app-gen
make                       # compiles the generator into ./bin, downloads Mustache
export PATH=$PATH:$(pwd)/bin

2 · Create your local config

cd            # run gen.sh from a stable folder such as $HOME
gen.sh        # choose "create a local config"

This creates a config/ folder containing setenv.sh. Edit it to set your company and org (product) names — these drive the Java package structure of the code you generate.

3 · Generate a service and a deployable

cd
gen.sh        # choose "create a normal service and monolith"
# service name:   stringdemo
# monolith name:  stringdemodeploy
# accept the defaults for version and output folder (./output)

You now have two folders:

  • stringdemo/ — the service, split into stringdemo-api (definition) and stringdemo-service (implementation).
  • stringdemodeploy/ — a deployable monolith that hosts the service.

4 · Build

cd output/stringdemo       && make build   # builds the api + service libraries
cd ../stringdemodeploy     && make build   # builds the runnable deployable

5 · Where to go next

🧩

Understand the split

See exactly what lives in the api vs service module and why consumers only ever depend on the api.

Definition vs. implementation →

🛡️

Attach a policy

Add a cross-cutting concern as an interceptor and choose whether it runs at the gateway, the last mile, or both.

How Chenile helps →

📚

Full documentation

Tutorials, developer guides and release notes for every module.

cheniledocs →

▶️

Watch the series

Prefer video? The same story, in short episodes with live demos.

The Chenile video series →

Note
Command names and repository paths above follow the current Chenile tutorial. If your generated layout differs, check the documentation for your version.