Search
Lessons (40)
- Event-Driven Architecture
Build systems where components react to events instead of calling each other. Broker vs mediator topologies, the four …
- CQRS & Event Sourcing
… save state every N events, then replay only newer events Event schemas change over time Versioned events, upcasters …
- Real-Time, Pub/Sub, Webhooks and CDC
… event ID catches repeats, version number catches out-of-order arrivals. </details --- Going deeper ![Event patterns: an event …
- Kafka for Backend Services
… async ({ message }) = { const event = JSON.parse(message.value!.toString()); if (event.eventType !== "OrderPlaced") return; // ignore event types we …
- AWS Messaging: Queues, Topics and Events
Use SQS to hold work, SNS to fan out notifications, and EventBridge to route events without tightly coupling …
- Kafka vs RabbitMQ & the Kafka Ecosystem
… What is the difference between Kafka and RabbitMQ? "Kafka is built for distributed event streaming. It stores events …
- Event-Driven Patterns, Step Functions and Reliable Lambdas
… make handlers idempotent , so running twice gives the same result as running once. text handler(event): validate(event …
- Batch vs Stream and Data Modeling
… For fast checks, stream, but plan for duplicates and late events ✅ For fraud checks: - Give every event a …
- What Is Apache Kafka?
Kafka is a distributed, durable log of events that many systems can write to and read from at …
- Service Communication: Sync vs Async
Should services call each other directly or talk through events? Compare request/response with messaging, orchestration with choreography …
- JavaScript Essentials: Event Loop, Closures & this
… Visual explanations of the event loop, microtasks, closures, and how 'this' is decided. Part 1: The event loop …
- Serverless Architecture
… create a thumbnail export const handler = async (event: S3Event) = { for (const record of event.Records) { const image = await …
- Data in Microservices: Sagas & the Outbox Pattern
… Design compensations as business actions . Choreography saga (events) Each service listens for events and reacts. No central coordinator …
- Domain-Driven Design: Tactical Patterns
… DomainEvent[] { const e = this.events; this.events = []; return e; } private assertDraft() { if (this.status !== "DRAFT") throw new DomainError …
- Big Data: ETL, Warehouses and Streaming
Turn millions of raw events into reports people can trust: keep the raw data, clean it in clear …
- Finding Service Boundaries with DDD
… 6. Event storming: put business experts and developers in a room with sticky notes for every domain event …
- Choosing an Architecture
… vertical slices (mostly CRUD)"] c1[search slice] c2[update price slice] end Ord -.- OrderPlaced, in-process event Bill …
- Message Delivery: Queues, Kafka, Ordering and DLQs
… order placed text Order database + outbox row (one transaction) - event stream: OrderPlaced(order id, version, event id) - inventory …
- Concurrency, Resilience & Distributed Workflows
… Preserve the original event for audit and put permanently invalid events in a dead-letter queue. Outbox, eventual …
- Async JavaScript: Promises, async/await and Node's Event Loop
… what runs in which order Node's event loop (built on libuv ) runs in phases . Between every callback …
- Behavioral Patterns I: Observer, Strategy, Command, State
… class EventEmitter { listeners = new Map(); on(event, listener) { if (!this. listeners.has(event)) this. listeners.set(event, new …
- Serverless: Lambda and API Gateway
Run small event-driven code without managing servers, expose it through an HTTP API, and handle retries safely …
- Architecture Patterns at Scale
Pick between one big app, many small services, serverless functions, events or peer-to-peer based on who …
- Cross-Service Data: How to Join Without a Database JOIN
… This is eventual consistency : a profile update commits in User Service first, and the Order Service projection catches …
- Domain-Driven Design: Strategic Design
… Domains and subdomains, ubiquitous language, bounded contexts, all the context-mapping patterns, and event storming to discover them …
- The Hot SKU Alert Problem
… The row is locked for minutes. ✅ Right: commit price + outbox event in milliseconds. A publisher sends the event …
- Troubleshooting Playbook
… read Events] C -- D[kubectl logs: what did the app say?] D -- E[Check Service, endpoints, DNS, policies …
- Design a Logging and Monitoring Platform
… detailed event lines. Metrics: numbers over time (requests per second). Traces: the path of one request through many …
- Pods: Where Your App Actually Runs
… status, explanation/events, application error, then recent cluster events. Remember this - A pod usually runs one app container …
- Storage, Search and Location Queries
… listing active" event must not bring back listing 88, which is now version 5 (deleted). The index only …
- Delivery Guarantees: At-Most, At-Least & Exactly Once
… remember processed event IDs (same transaction as the business change) await db.transaction(async (tx) = { const inserted = await …
- Vertical Slice Architecture & the Modular Monolith
… OrderRepository; events: EventBus }, cmd: PlaceOrderCommand) { const order = Order.create(cmd.customerId, cmd.lines); // business rules in the domain …
- C4 Architecture Diagrams: Context, Container, Component and Code
… publishes event StripePaymentGateway .. PaymentGateway : implements PostgresOrderRepository .. OrderRepository : implements This diagram is not a full copy of the source …
- Time, Consistency and Distributed Transactions
… It does not prove that event A caused or came before event B on a different machine. Logical …
- AWS Data Pipelines in Plain Language
… Does it represent an order created, a payment captured, or an item shipped? Those are different events, and …
- Topics, Partitions & Offsets
… A topic is a named stream of related events: orders , payments , page-views , user-signups . bash kafka-topics …
- Kafka Producers
… order.totalCents }), headers: { eventType: "OrderPlaced", eventId: crypto.randomUUID(), schemaVersion: "1" }, }, ], }); } process.on("SIGTERM", async () = { await producer.disconnect(); // flush …
- Observability: Logs, Metrics & Traces
… The car's black box records every event ( logs ). And if you tracked one trip across the city …
- Your Practical Kubernetes Workflow
… Do not delete or restart things until you understand the event or error. Minimum safety rules - Use a …
- Design a Reliable Notification System
… 1. The business event: an order changes. The order service saves the order and an "outbox" event in …