liveBook · Manning

Driven actor

As explained in Clean Applications with Hexagonal Architecture

An external system that an application calls or otherwise causes to act during an interaction.

A driven actor is an external system that the hexagon calls during an outbound interaction. The use case initiates the interaction through an output adapter; the external system may be a database, API, or message broker. The role belongs to the interaction, not permanently to the system. section 10.1 section 10.7

Use the interaction’s direction to identify the actor:

  • Inbound: an external system starts behavior through an input adapter and acts as a driving actor. section 10.1
  • Outbound: a use case starts behavior through an output adapter, and the external system acts as a driven actor. section 10.1

One system, different roles

A publishing platform is a driving actor when it asks WriteFlow to confirm an article’s approval. It is a driven actor when WriteFlow publishes an approval event to it. section 10.1

Table 10.1 The same boundary, seen from each direction
Direction
Who starts
Adapter on the boundary
External system’s role
Example candidate
Inbound
The external system
Input adapter
Driving actor
A partner CMS asks to send an article back for review
Outbound
A WriteFlow use case
Output adapter
Driven actor
WriteFlow saves an article and tells the publishing platform about it

Compare who starts each interaction with the adapter and actor role at the boundary. section 10.1

How Clean Applications with Hexagonal Architecture covers it

How deep it goes
Defines actor roles by interaction direction and distinguishes them from adapter roles at the boundary.
Examples
Uses article persistence, thumbnail refresh, event publication, and a publishing platform acting in both directions.
What you can do after
Evaluate an interaction’s initiator to identify the external system’s actor role and the boundary adapter.
How it connects
Connects driven actors to hexagonal architecture, output adapters, driving actors, and integration modes.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Clean Applications with Hexagonal Architecture. The section links point to the parts of the book it draws on.