For the complete documentation index, see llms.txt. This page is also available as Markdown.

webservice

Generate a Webservice microservice (an HTTP front door onto the Rumi engine).

Syntax

rumi quickstart webservice [options]

Options

Option
Short
Description
Default

--app-root

-r

Application root directory

rumi-quickstart

--clustered

-c

Create the microservice clustered

false

Example

rumi quickstart webservice --app-root my-app

What Gets Generated

The webservice is stateful and clusterable, and embeds an HTTP server that hands requests to the engine and waits for the reply. The generated module contains:

File
Purpose

Main.java

The microservice, carrying its @AppHAPolicy

HttpServer.java

The embedded HTTP server

AepEngineProvider.java

Supplies the engine to the web layer

resources/WebMain.java

The HTTP resource, where you add endpoints

models/api.xml

API operations

models/messages/messages.xml

Message model

models/state/state.xml

State model

The HTTP port is wired into the system configuration and defaults to 8080:

Like the processor, driver, and connector quickstart microservices, the generated code is scaffolding: WebMain is where you add your endpoints, and the handlers that service them go in Main.

Clustering

The webservice is clusterable, so it always carries an HA model. It is generated non-clustered by default, which keeps the quickstart to a single container per microservice while you are learning. Pass --clustered to generate it as a clustered microservice with a hot standby, the same shape the processor uses.

See Also

  • app - Generate a complete application

  • processor - Generate a Processor microservice

  • driver - Generate a Driver microservice

  • connector - Generate a Connector microservice

Last updated