Get the FREE Ultimate OpenClaw Setup Guide →

messaging

npx machina-cli add skill Fujigo-Software/f5-framework-claude/messaging --openclaw
Files (1)
SKILL.md
3.8 KB

Messaging Skills

Overview

Asynchronous communication patterns for building scalable, decoupled distributed systems. Messaging enables services to communicate without direct coupling, improving reliability and scalability.

Messaging Types

TypeDescriptionUse CaseExamples
Point-to-PointOne sender, one receiverTask distributionRabbitMQ, SQS
Pub/SubOne sender, many receiversEvent broadcastingKafka, Redis Pub/Sub
Request/ReplySynchronous over asyncRPC-style callsRabbitMQ RPC
Event StreamingOrdered, replayable logEvent sourcingKafka, Kinesis

Delivery Guarantees

GuaranteeDescriptionTrade-off
At-most-onceFire and forgetMay lose messages
At-least-onceRetry until acknowledgedMay have duplicates
Exactly-onceDeduplicated deliveryComplex, higher latency

When to Use Messaging

Use Messaging For

  • Decoupling services
  • Async task processing
  • Event-driven architectures
  • Load leveling and buffering
  • Cross-service communication

Avoid Messaging When

  • Simple request/response is sufficient
  • Strong consistency is required
  • Real-time response is critical
  • System complexity isn't justified

Categories

Fundamentals

Core messaging concepts:

  • Messaging Patterns - Common communication patterns
  • Sync vs Async - When to use each approach
  • Message Types - Commands, events, and queries

Queues

Message queue implementations:

  • RabbitMQ - Feature-rich message broker
  • Redis Queues - Simple Redis-based queues
  • AWS SQS - Managed queue service
  • BullMQ - Node.js job queue

Events

Event-driven patterns:

  • Event-Driven Architecture - EDA fundamentals
  • Apache Kafka - Event streaming platform
  • Event Sourcing - State as event log
  • Pub/Sub - Publish-subscribe patterns

Patterns

Distributed system patterns:

  • Saga Pattern - Distributed transactions
  • Outbox Pattern - Reliable event publishing
  • Retry Strategies - Handling failures
  • Dead Letter Queue - Failed message handling

Reliability

Ensuring message delivery:

  • Delivery Guarantees - At-most/least/exactly-once
  • Idempotency - Safe message reprocessing
  • Message Ordering - Maintaining sequence

Best Practices

Production considerations:

  • Message Design - Schema and versioning
  • Error Handling - Failure management
  • Monitoring - Observability and alerting

Quick Reference

Message Broker Comparison

FeatureRabbitMQKafkaSQSRedis
ModelQueueLogQueueQueue/Pub-Sub
OrderingPer-queuePer-partitionFIFO optionPer-queue
PersistenceDurableAlwaysAlwaysOptional
ReplayNoYesNoNo
ThroughputHighVery HighHighVery High
LatencyLowLowMediumVery Low

Common Patterns

Producer → Queue → Consumer (Point-to-Point)
Producer → Exchange → Queue → Consumer (RabbitMQ)
Producer → Topic → Partition → Consumer Group (Kafka)
Publisher → Channel → Subscribers (Pub/Sub)

Integration with F5

# In f5-config.yaml
messaging:
  broker: rabbitmq
  queues:
    - name: orders
      durable: true
      dlq: orders-dlq
  events:
    - topic: order.placed
      retention: 7d

Related Skills

Source

git clone https://github.com/Fujigo-Software/f5-framework-claude/blob/main/plugins/f5-core/skills/messaging/SKILL.mdView on GitHub

Overview

Messaging enables services to communicate asynchronously, decoupling components to improve reliability and scalability. It covers point-to-point queues, pub/sub, request/reply, and event streaming to handle different workloads and guarantees.

How This Skill Works

Producers publish messages to brokers, which route to consumers via queues, topics, or channels. Delivery guarantees such as at-most-once, at-least-once, and exactly-once govern re-delivery and deduplication, while patterns like the Outbox and retry strategies help manage failures across distributed components.

When to Use It

  • Decoupling services for resilience and scalability
  • Async task processing and background jobs
  • Event-driven architectures and real-time event broadcasting
  • Load leveling and buffering between services
  • Cross-service communication with loose coupling

Quick Start

  1. Step 1: Identify message types (commands, events, queries) and business events
  2. Step 2: Choose a messaging model (Point-to-Point, Pub/Sub, or RPC-like) and determine delivery guarantees
  3. Step 3: Prototype with a broker (e.g., RabbitMQ, Kafka, SQS), define queues/topics, and implement producers/consumers

Best Practices

  • Design messages with stable schemas and careful versioning
  • Implement robust error handling, retries, and dead-letter queues
  • Monitor latency, throughput, and failure modes with observability
  • Ensure idempotent consumers to safely reprocess messages
  • Choose delivery guarantees and ordering based on use case and complexity

Example Use Cases

  • RabbitMQ-based task queues for background processing
  • Kafka-based event streaming for event sourcing
  • Redis Pub/Sub for simple broadcast patterns
  • AWS SQS for managed queuing in cloud apps
  • Outbox pattern to guarantee reliable event publishing

Frequently Asked Questions

Add this skill to your agents

Related Skills

Sponsor this space

Reach thousands of developers