Loading

Exploring Temporal: Features, Architecture, and Comparisons

2025-01-12T12:38:54.929Z

Ray Ray

Temporal is a robust open-source framework designed to simplify the orchestration of distributed workflows and tasks. In this blog post, we’ll delve into its features, architecture, pros and cons, and compare it to Amazon SQS.


Features

Temporal offers several key features that make it a powerful choice for workflow orchestration:

  • Centralised Workflow/Queue Orchestration: Streamlines task coordination across distributed systems.
  • Durable Execution Abstraction: Separates execution logic from application and business logic.
  • Event Sourcing: Maintains a complete history of workflow events.
  • Configurable Timeout/Retry: Provides fine-grained control over task retries and timeouts.
  • Activity Flow Visibility: Offers detailed visibility into activity flows within workflows across distributed systems.

User-Hosted Processes

User Application

  • Start or cancel workflows.

Worker

  • Poll the Temporal server for Workflow and Activity tasks.
  • Send task completion or failure information to the Temporal server.

Temporal Cluster Components

History Service

  • Manages individual workflow executions.
  • Enqueues tasks into the Matching Service.

Matching Service

  • Manages task queues being polled by workers.

Tasks in Temporal

Workflow Task

When a Workflow Task is completed, the worker sends a sequence of commands specifying the next steps required to advance the workflow.

Activity Task

Upon completion of an Activity Task (success or failure), the worker sends the task outcome back to the Temporal server.

Learn more:


Pros & Cons of Temporal

Pros

  • Durability: Resumes workflows from where they stopped without data loss.
  • Abstracted Queue Management: Eliminates the need to manage and maintain queue infrastructure.
  • Microservice Orchestration: Simplifies coordination of microservice interactions within workflows.
  • Detailed Visibility: Provides granular insight into microservice interactions, aiding troubleshooting.
  • Granular Control: Offers features like replay and retry for each activity.
  • Scalability & Disaster Recovery: Supports high scalability and potential for robust disaster recovery (DR).

Cons

  • Learning Curve: Requires time to understand and implement effectively.

Temporal vs. Amazon SQS

Feature Temporal SQS
Message Orchestration Workflow of activities Individual messages (e.g., retry)
Retry Control Per-task retry policy Retry policy per queue
Infrastructure Setup/Maintenance Abstracted, with various queue options Manual setup per queue (e.g., DLQ)
Delayed Message Setup Timer control API Delayed queue setup
Delayed Message Control Per-message control Control for the entire queue
Activity Control Pause/Resume per workflow N/A

Temporal simplifies and abstracts the complexity of workflow orchestration in distributed systems. While it has a steeper learning curve compared to simpler tools like SQS, its extensive feature set and durability make it an excellent choice for scalable and robust workflows.

Contact Us
  • Office Address

    Melbourne, Australia

  • Email Us

    info@zdgroup.com.au

  • Call Us

    +61408985566

2025 © zdgroup.com.au. All rights reserved.  ZDAU Group