PoCAT Documentation Get Started

Microservices Integration Patterns

Services connect by messagebus bindings. A Servit does not call the next service by class name.

Last updated: 2026-10-20 Section: Architecture

The next service is the outbound binding. Business state travels in the payload and the parameters. A Servit publishes a channel name and does not name the next class.

PatternBest fitCore implementationCaveats
Channel handoffNext business stepOutbound channel to the next inbound bindingSender must not name the next Servit class
Business resultDecline, mismatch, anomalyNormal message on a rejected channelDo not throw for an expected outcome
Dead letterStep cannot finishServitException and <dead-letter-channel>Routing params must still expand
Shared resourceStore or client used by the stepref-name in service.xml, type in deploy.xmlMissing resource fails init

Message contract

messagebus://endpoint1/com/kiosk/${param:kiosk_id}/payment/${param:payment_id}/requested

ServitMessage
  messageId
  headers
  parameters: kiosk_id, payment_id, order_id
  payload: byte[]

Wire a step

  1. Declare the Servit, its source channel, and init-param defaults in service.xml.
  2. Bind that channel to a messagebus URI in deploy.xml.
  3. Publish with ServitMessageChannel.publish. Carry routing parameters on the message.
  4. Point unhandled errors at messagebus://error/.../deadletter/${ctx:service_id}.