When to use this pattern
When you have an existing service you want to use from iii without rewriting it, and you want callers to address it the way they address every other worker (by function ID, not by HTTP or library-specific call shapes).Structure
A thin iii worker that:- Connects to the engine.
- Registers one function per operation you want to expose.
- Inside each handler, calls the existing service and returns the result as the function’s response.
- For each kind of event the service produces (a webhook, a change feed, a notification), registers a function whose handler returns the event, and calls that function each time the event happens. Other workers observe it like any other function. See Observable functions.