Skip to main content

App Logic Layer

The App Logic Layer is the heart of your application's business functionality. Its primary responsibility is to orchestrate processes, handle complex business logic, and manage the flow of data between the Touchpoint Layer and the Domain Logic Layer.

A simple rule of thumb for defining what belongs in the App Logic Layer is to identify what doesn't naturally do not belong to this layer:

  • Touchpoint logic: User input validation and navigation actions.
  • Domain logic: The manipulation, retrieval, and validation of objects.

The remaining logic—the high-level business process—resides in this layer. This includes functions and rules that are not directly tied to a specific domain entity.

1. Microflow typologies in this layer

The App Logic Layer typically contains the following microflow typologies:

  • Orchestration (ORC) Microflows: These are the main entry points for your business processes. An ORC microflow receives data from a touchpoint, orchestrates calls to various unit microflows, and handles the final commit or rollback.
  • Commit (CMT) Microflows: These are the microflows that ensure that data is validated and stored in the database.
  • Validation Orchestration (VAL_ORC) Microflows: These are used to group multiple validations into a single, logical process. You might use these to run a series of validation checks before committing data. For more information, see the section about the Orchestration microflow typologies.
  • Function (FTN) and Rule (RULE) Microflows: These can exist in this layer as long as they are not directly bound to domain-specific logic. For example, a microflow that calculates a complex shipping cost based on multiple parameters might be an FTN in this layer, as the logic is not a direct domain action. For more information about functions and rules, see the section about Unit microflow typologies.

image-20251124-102854.png