powered by
XX:YY
https://asq.click/

Design Patterns for Process-centric
APIs

Cesare Pautasso

http://www.pautasso.org/
@pautasso@scholar.social

7.12.23, HPI, Potsdam, Germany

Contents

  • APIs
  • Process-Centric APIs
  • Task Execution
  • Task Coordination

Abstract

Just like every software component has an interface, every open software architecture has an Application programming interface (API) which delimits its boundary, keeping it separate from other systems, while making it possible to connect and interact with them. Process-centric APIs are designed so that processes can flow through them. They are the main entry points for delegating execution, exchanging data, and transferring control back and forth across composable software systems. In this talk we illustrate a small collection of API design patterns derived from assigning the responsibility for determining "who does what when" to different parties, gradually deconstructing what it means to execute a process in a decentralized way.

Olaf Zimmerman, Mirko Stocker, Daniel Lübke, Uwe Zdun, Cesare Pautasso Patterns for API Design
Simplifying Integration with Loosely Coupled Message Exchanges
December 2022, ISBN: 978-0-13767010-9

44 Patterns for API Design

Client/Server

Storage vs. Computation

Processing Resource

Information Holder

Process-centric APIs

Who does What When?

Who does What When?

  • Who should perform a task?
  • Who initiates task execution?

Who does What When?

  • What has to be done?
  • Which task(s) can be done?

Who does What When?

  • When should a task be started?
  • When should a task be completed?

Process/Task

Imperative Task Execution

Voluntary Task Execution

Self Paced Task Execution

Deadline-Driven Task Execution

Self Imposed Task Execution

Spontaneous Task Execution

Loosely Coupled Task Execution

Independent Task Execution

Optional Task Execution

Elective Task Execution

Lock-Stepped Task Execution

Autonomous Task Execution

Passive Task Execution

Active Task Execution

Punctual Task Execution

Prioritized Task Execution

Arbitrary Task Execution

Facultative Task Execution

Process/Task
APIs

Why?

  • What is the purpose of a task?
  • What causes a task to be executed?

Process/Task API

Multi Tasking

Coordination

What to do next?

Coordination

Centralized Coordination

Decentralized Coordination?

Decentralized Coordination

(with Autonomous Task Execution)

Coordination

Collaboration

Decentralized Collaboration

Conclusions

  • Different Process-centric APIs patterns determine where decisions on task execution (who does what when, and why?) and task coordination (what to do next) are taken.
  • Classical workflow architectures centralized all these decisions in the engine.
  • It does not have to be that way.

Design Patterns for Process-centric APIs

Cesare Pautasso

7.12.23, HPI, Potsdam, Germany

http://www.pautasso.org/

c.pautasso@ieee.org

References