
Microservices Architect
FreeDesign and implement robust microservices architectures.
Free · Opens the source repo
What Microservices Architect does
The Microservices Architect skill provides a structured approach to designing and implementing distributed systems using microservices principles. It emphasizes domain-driven design (DDD) to identify bounded contexts and service boundaries, ensuring that each service is independently deployable and owns its data. This skill is particularly valuable for architects and developers who are tasked with transitioning from monolithic architectures to microservices, as it offers a systematic methodology to guide the decomposition process.
The core workflow consists of several key phases, including communication design, data strategy, resilience patterns, observability, and deployment strategies. Each phase includes validation checkpoints to ensure that the architecture adheres to best practices, such as using asynchronous communication for long-running operations and implementing circuit breakers for external service calls. This skill also provides reference guides for deeper insights into specific topics, allowing users to load detailed information based on their current context.
In addition to theoretical guidance, the Microservices Architect skill includes practical implementation examples in popular programming languages like Node.js and Python. These examples illustrate how to implement essential patterns such as correlation IDs for tracing requests and circuit breakers for managing failures. By following these patterns, teams can enhance the reliability and maintainability of their services, ultimately leading to a more resilient architecture.
This skill is designed for software architects, developers, and DevOps engineers who are involved in the design and implementation of microservices architectures. It is particularly useful in environments where scalability, resilience, and operational excellence are critical to the success of the system.
When to use it
Use this skill when transitioning from a monolithic architecture to microservices, or when designing new distributed systems.
When not to use it
This skill may not be suitable for small applications where a monolithic architecture is sufficient or for teams unfamiliar with microservices concepts.
What you can build with it
Transitioning to Microservices
When a team is moving from a monolithic architecture to microservices, this skill provides the necessary guidelines to ensure a smooth transition.
Designing New Distributed Systems
For teams starting fresh with a distributed system, this skill offers foundational principles and patterns to follow from the outset.
Implementing Resilience Strategies
In systems where uptime and reliability are critical, this skill helps in designing resilience patterns to handle failures gracefully.
How to install Microservices Architect
View source1. Install with the skills CLI
npx skills add jeffallan/claude-skills/microservices-architect --agent claude-code2. Or install it manually
Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.
Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs
Inside SKILL.md
Written by jeffallanMicroservices Architect
Senior distributed systems architect specializing in cloud-native microservices architectures, resilience patterns, and operational excellence.
Core Workflow
- Domain Analysis — Apply DDD to identify bounded contexts and service boundaries.
- Validation checkpoint: Each candidate service owns its data exclusively, has a clear public API contract, and can be deployed independently.
- Communication Design — Choose sync/async patterns and protocols (REST, gRPC, events).
- Validation checkpoint: Long-running or cross-aggregate operations use async messaging; only query/command pairs with sub-100 ms SLA use synchronous calls.
- Data Strategy — Database per service, event sourcing, eventual consistency.
- Validation checkpoint: No shared database schema exists between services; consistency boundaries align with bounded contexts.
- Resilience — Circuit breakers, retries, timeouts, bulkheads, fallbacks.
- Validation checkpoint: Every external call has an explicit timeout, retry budget, and graceful degradation path.
- Observability — Distributed tracing, correlation IDs, centralized logging.
- Validation checkpoint: A single request can be traced end-to-end using its correlation ID across all services.
- Deployment — Container orchestration, service mesh, progressive delivery.
- Validation checkpoint: Health and readiness probes are defined; canary or blue-green rollout strategy is documented.
Reference Guide
Load detailed guidance based on context:
| Topic | Reference | Load When |
|---|---|---|
| Service Boundaries | references/decomposition.md | Monolith decomposition, bounded contexts, DDD |
| Communication | references/communication.md | REST vs gRPC, async messaging, event-driven |
| Resilience Patterns | references/patterns.md | Circuit breakers, saga, bulkhead, retry strategies |
| Data Management | references/data.md | Database per service, event sourcing, CQRS |
| Observability | references/observability.md | Distributed tracing, correlation IDs, metrics |
Implementation Examples
Correlation ID Middleware (Node.js / Express)
const { v4: uuidv4 } = require('uuid');
function correlationMiddleware(req, res, next) {
req.correlationId = req.headers['x-correlation-id'] || uuidv4();
res.setHeader('x-correlation-id', req.correlationId);
// Attach to logger context so every log line includes the ID
req.log = logger.child({ correlationId: req.correlationId });
next();
}
Propagate x-correlation-id in every outbound HTTP call and Kafka message header.
Circuit Breaker (Python / pybreaker)
import pybreaker
# Opens after 5 failures; resets after 30 s in half-open state
breaker = pybreaker.CircuitBreaker(fail_max=5, reset_timeout=30)
@breaker
def call_inventory_service(order_id: str):
response = requests.get(f"{INVENTORY_URL}/stock/{order_id}", timeout=2)
response.raise_for_status()
return response.json()
def get_inventory(order_id: str):
try:
return call_inventory_service(order_id)
except pybreaker.CircuitBreakerError:
return {"status": "unavailable", "fallback": True}
Saga Orchestration Skeleton (TypeScript)
// Each step defines execute() and compensate() so rollback is automatic.
interface SagaStep<T> {
execute(ctx: T): Promise<T>;
compensate(ctx: T): Promise<void>;
}
async function runSaga<T>(steps: SagaStep<T>[], initialCtx: T): Promise<T> {
const completed: SagaStep<T>[] = [];
let ctx = initialCtx;
for (const step of steps) {
try {
ctx = await step.execute(ctx);
completed.push(step);
} catch (err) {
for (const done of completed.reverse()) {
await done.compensate(ctx).catch(console.error);
}
throw err;
}
}
return ctx;
}
// Usage: order creation saga
const orderSaga = [reserveInventoryStep, chargePaymentStep, scheduleShipmentStep];
await runSaga(orderSaga, { orderId, customerId, items });
Health & Readiness Probe (Kubernetes)
livenessProbe:
httpGet:
path: /health/live
port: 8080
initialDelaySeconds: 10
periodSeconds: 15
readinessProbe:
httpGet:
path: /health/ready
port: 8080
initialDelaySeconds: 5
periodSeconds: 10
/health/live — returns 200 if the process is running.
/health/ready — returns 200 only when the service can serve traffic (DB connected, caches warm).
Constraints
MUST DO
- Apply domain-driven design for service boundaries
- Use database per service pattern
- Implement circuit breakers for external calls
- Add correlation IDs to all requests
- Use async communication for cross-aggregate operations
- Design for failure and graceful degradation
- Implement health checks and readiness probes
- Use API versioning strategies
MUST NOT DO
- Create distributed monoliths
- Share databases between services
- Use synchronous calls for long-running operations
- Skip distributed tracing implementation
- Ignore network latency and partial failures
- Create chatty service interfaces
- Store shared state without proper patterns
- Deploy without observability
Output Templates
When designing microservices architecture, provide:
- Service boundary diagram with bounded contexts
- Communication patterns (sync/async, protocols)
- Data ownership and consistency model
- Resilience patterns for each integration point
- Deployment and infrastructure requirements
Knowledge Reference
Domain-driven design, bounded contexts, event storming, REST/gRPC, message queues (Kafka, RabbitMQ), service mesh (Istio, Linkerd), Kubernetes, circuit breakers, saga patterns, event sourcing, CQRS, distributed tracing (Jaeger, Zipkin), API gateways, eventual consistency, CAP theorem
Frequently asked questions about Microservices Architect
Similar skills
Python PyPI Package Builder
Streamline the process of creating and publishing Python packages.
Minecraft Plugin Development
Streamline your Minecraft server plugin creation.
MCP Server Builder
Easily build .NET MCP servers with the latest standards.
CommunityToolkit.Mvvm Messenger
Decoupled communication for ViewModels in .NET applications.
MVVM Toolkit DI
Streamline ViewModel integration with Dependency Injection in .NET.
MCP Apps Builder
Essential guidelines for MCP server development.
