{"id":"6b08bd3280884893657cc942","slug":"event-driven-architecture","title":"Architektura sterowana zdarzeniami: kto publikuje, kto słucha i co może pójść nie tak","summary":"Event-driven architecture w praktyce: cztery znaczenia „zdarzeń” według Fowlera, choreografia i orkiestracja, gwarancje dostarczenia, outbox, idempotentni konsumenci, kolejność i kontrakty. Kod w C#, TypeScript, Javie, Go i Pythonie.","servedLang":"pl","availableLangs":["pl","en"],"topics":["event-driven-architecture","microservices","event-sourcing"],"techs":["dotnet","java","typescript","go","python"],"tags":["architecture","events","kafka","outbox","idempotency","sagas","messaging"],"level":"advanced","kind":"article","access":"members","status":"published","cover":null,"author":{"id":"6b08bd2e80884893657cc8cf","name":"Redakcja Art of Devs","avatar":null,"handle":"redakcja","community":false},"readingMinutes":12,"stats":{"views":1,"likes":0,"bookmarks":0,"comments":0},"publishedAt":"2026-11-26T23:13:54.773Z","updatedAt":"2026-11-27T10:04:44.825Z","requestedLang":"pl","theme":{"hero":"classic","heroMedia":null,"accent":"teal","background":"dots","weaveResources":true,"toc":"right"},"seoDescription":"Architektura sterowana zdarzeniami (EDA): event notification, event-carried state transfer, broker i mediator, choreografia i orkiestracja sag, at-least-once, transactional outbox, inbox i idempotencja, Kafka, przykłady w 5 językach.","wordCount":2242,"doc":{"type":"doc","content":[{"type":"paragraph","content":[{"type":"text","text":"Gdy w pierogarni Haliny ktoś składa zamówienie, dzieje się kilka rzeczy: kuchnia dostaje bon, program lojalnościowy nalicza punkty, analityka aktualizuje wykresy, a klient dostaje SMS. W pierwszej wersji "},{"type":"text","text":"OrderService","marks":[{"type":"code"}]},{"type":"text","text":" wołał po kolei cztery serwisy – i gdy padała bramka SMS, nie dało się złożyć zamówienia. W "},{"type":"text","text":"architekturze sterowanej zdarzeniami","marks":[{"type":"bold"}]},{"type":"text","text":" (ang. "},{"type":"text","text":"event-driven architecture","marks":[{"type":"italic"}]},{"type":"text","text":", EDA) zamówienia tylko ogłaszają fakt „zamówienie złożone”, a reszta reaguje we własnym tempie."}]},{"type":"callout","attrs":{"variant":"tip","title":"W skrócie"},"content":[{"type":"bulletList","content":[{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Komponenty komunikują się "},{"type":"text","text":"zdarzeniami","marks":[{"type":"bold"}]},{"type":"text","text":" – faktami z przeszłości – publikowanymi do brokera; nadawca nie wie, kto słucha."}]}]},{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Zyskujesz luźne sprzężenie i odporność na awarie, płacisz "},{"type":"text","text":"spójnością ostateczną","marks":[{"type":"bold"}]},{"type":"text","text":" i trudniejszym śledzeniem przepływu."}]}]},{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Fundamenty produkcyjne to: "},{"type":"text","text":"outbox","marks":[{"type":"bold"}]},{"type":"text","text":" po stronie nadawcy, "},{"type":"text","text":"idempotentni konsumenci","marks":[{"type":"bold"}]},{"type":"text","text":", klucze partycji dla kolejności i wersjonowane kontrakty."}]}]}]}]},{"type":"stats","attrs":{"items":[{"value":"4","label":"znaczenia „event-driven”","hint":"według Martina Fowlera (2017)"},{"value":"≥1","label":"dostarczenie każdej wiadomości","hint":"typowa gwarancja: at-least-once, więc duplikaty się zdarzają"},{"value":"2011","label":"Kafka jako open source","hint":"LinkedIn udostępnia platformę strumieniowania zdarzeń"}]}},{"type":"heading","attrs":{"level":2,"id":"kontekst-i-sily"},"content":[{"type":"text","text":"Kontekst i siły"}]},{"type":"bulletList","content":[{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Wielu odbiorców jednego faktu","marks":[{"type":"bold"}]},{"type":"text","text":" – kuchnia, lojalność, analityka i powiadomienia; jutro dojdzie piąty."}]}]},{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Niezależność zespołów i wdrożeń","marks":[{"type":"bold"}]},{"type":"text","text":" – dodanie odbiorcy nie powinno wymagać zmiany w zamówieniach."}]}]},{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Odporność","marks":[{"type":"bold"}]},{"type":"text","text":" – awaria SMS-ów nie może blokować składania zamówień."}]}]},{"type":"listItem","content":[{"type":"paragraph","content":[{"type":"text","text":"Szczyty ruchu","marks":[{"type":"bold"}]},{"type":"text","text":" – w piątek o 18:00 kolejka wyrównuje obciążenie, zamiast przewracać kuchnię."}]}]}]},{"type":"heading","attrs":{"level":2,"id":"cztery-rzeczy-ktore-ludzie-nazywaja-event-driven"},"content":[{"type":"text","text":"Cztery rzeczy, które ludzie nazywają „event-driven”"}]},{"type":"paragraph","content":[{"type":"text","text":"Martin Fowler w tekście "},{"type":"text","text":"What do you mean by \"Event-Driven\"?","marks":[{"type":"italic"}]},{"type":"text","text":" (2017) zwrócił uwagę, że pod tym hasłem kryją się różne wzorce:"}]},{"type":"table","content":[{"type":"tableRow","content":[{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Wzorzec"}]}]},{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Na czym polega"}]}]},{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Przykład w pierogarni"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Event Notification"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Zdarzenie tylko informuje; odbiorca w razie potrzeby dopyta nadawcę o szczegóły"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"OrderPlaced(orderId)","marks":[{"type":"code"}]},{"type":"text","text":" – kuchnia pobiera szczegóły przez API"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Event-Carried State Transfer"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Zdarzenie niesie dane, odbiorca trzyma lokalną kopię i nie musi pytać"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"OrderPlaced","marks":[{"type":"code"}]},{"type":"text","text":" z pozycjami i telefonem – Delivery nie woła Orders"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Event Sourcing"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Zdarzenia są źródłem prawdy o stanie"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"strumień konta lojalnościowego"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"CQRS"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Osobne modele zapisu i odczytu, często zasilane zdarzeniami"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"tablica kuchni jako projekcja"}]}]}]}]},{"type":"paragraph","content":[{"type":"text","text":"Ten artykuł skupia się na dwóch pierwszych – komunikacji między komponentami. O pozostałych piszemy w artykułach "},{"type":"text","text":"Event sourcing","marks":[{"type":"link","attrs":{"href":"/pl/articles/event-sourcing"}}]},{"type":"text","text":" i "},{"type":"text","text":"CQRS","marks":[{"type":"link","attrs":{"href":"/pl/articles/cqrs"}}]},{"type":"text","text":"."}]},{"type":"heading","attrs":{"level":2,"id":"struktura"},"content":[{"type":"text","text":"Struktura"}]},{"type":"diagram","attrs":{"kind":"mermaid","code":"flowchart LR\n  orders[\"Orders<br/>(producent)\"] -- \"orders.order-placed.v1\" --> broker[[\"Broker: Kafka / RabbitMQ / Service Bus\"]]\n  kitchen[\"Kitchen\"] -- \"kitchen.order-ready.v1\" --> broker\n  broker --> k[\"Kitchen<br/>grupa: kitchen\"]\n  broker --> l[\"Loyalty<br/>grupa: loyalty\"]\n  broker --> a[\"Analytics<br/>grupa: analytics\"]\n  broker --> n[\"Notifications<br/>grupa: notifications\"]\n  broker --> o[\"Orders<br/>grupa: orders\"]\n  broker -. \"po N nieudanych próbach\" .-> dlq[(\"Dead letter topic\")]","caption":"Topologia z brokerem: nadawca nie zna odbiorców"}},{"type":"paragraph","content":[{"type":"text","text":"Choreografia czy orkiestracja?","marks":[{"type":"bold"}]},{"type":"text","text":" W choreografii każdy komponent reaguje na zdarzenia i publikuje własne – nie ma centralnego dyrygenta (jak na diagramie). W orkiestracji jeden komponent (orkiestrator, menedżer procesu, saga) wysyła komendy i czeka na odpowiedzi. Choreografia jest prostsza dla krótkich reakcji („nalicz punkty”), orkiestracja – czytelniejsza dla wieloetapowych procesów z kompensacją, np. catering z zaliczką: rezerwacja terminu → płatność → potwierdzenie, a przy odmowie płatności zwolnienie terminu."}]},{"type":"heading","attrs":{"level":2,"id":"gwarancje-dostarczenia"},"content":[{"type":"text","text":"Gwarancje dostarczenia"}]},{"type":"table","content":[{"type":"tableRow","content":[{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Gwarancja"}]}]},{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Co oznacza"}]}]},{"type":"tableHeader","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Konsekwencja"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"At-most-once"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Wiadomość może zginąć, nigdy się nie powtórzy"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"dobre dla metryk, złe dla punktów lojalnościowych"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"At-least-once"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Wiadomość nie zginie, ale może przyjść więcej niż raz"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"standard; konsumenci muszą być idempotentni"}]}]}]},{"type":"tableRow","content":[{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"Exactly-once"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"W praktyce: skutecznie dokładnie raz dzięki deduplikacji lub transakcjom brokera"}]}]},{"type":"tableCell","attrs":{"colspan":1,"rowspan":1},"content":[{"type":"paragraph","content":[{"type":"text","text":"działa w obrębie jednego systemu (np. Kafka Streams), nie end-to-end z dowolną bazą"}]}]}]}]},{"type":"heading","attrs":{"level":2,"id":"jak-to-wyglada-w-kodzie"},"content":[{"type":"text","text":"Jak to wygląda w kodzie"}]},{"type":"paragraph","content":[{"type":"text","text":"Problem podwójnego zapisu","marks":[{"type":"bold"}]},{"type":"text","text":": jeśli zapiszesz zamówienie w bazie, a potem wyślesz zdarzenie do brokera, awaria pomiędzy tymi krokami zgubi zdarzenie (albo, w odwrotnej kolejności, wyśle zdarzenie o zamówieniu, którego nie ma). Rozwiązaniem jest "},{"type":"text","text":"transactional outbox","marks":[{"type":"bold"}]},{"type":"text","text":": zdarzenie trafia do tabeli w tej samej transakcji co zamówienie, a osobny proces (relay lub CDC, np. Debezium) przekazuje je do brokera."}]},{"type":"codeGroup","attrs":{"title":"Producent z outboxem"},"content":[{"type":"codeBlock","attrs":{"language":"csharp","filename":"PlaceOrderWithOutbox.cs"},"content":[{"type":"text","text":"// The order and the event are saved in ONE transaction. A relay publishes the outbox later.\npublic async Task<Guid> Handle(PlaceOrder cmd, CancellationToken ct)\n{\n    var order = Order.Place(cmd.Phone, cmd.Lines);\n    db.Orders.Add(order);\n    db.Outbox.Add(new OutboxMessage\n    {\n        Id = Guid.NewGuid(),                                     // becomes the message id (for dedup)\n        Type = \"orders.order-placed.v1\",\n        Key = order.Id.ToString(),                               // partition key: per-order ordering\n        Payload = JsonSerializer.Serialize(new OrderPlacedV1(order.Id, order.Phone, order.Total)),\n        OccurredAt = clock.GetUtcNow()\n    });\n    await db.SaveChangesAsync(ct);                               // both rows or neither\n    return order.Id;\n}\n\n// Relay (BackgroundService): SELECT TOP 100 ... WHERE PublishedAt IS NULL ORDER BY OccurredAt,\n// produce to Kafka, then UPDATE PublishedAt. Crashes cause re-sends, never losses -> at-least-once."}]},{"type":"codeBlock","attrs":{"language":"typescript","filename":"place-order.outbox.ts"},"content":[{"type":"text","text":"// The order and the event are saved in ONE transaction. A relay publishes the outbox later.\nexport async function placeOrder(cmd: PlaceOrder): Promise<string> {\n  return prisma.$transaction(async (tx) => {\n    const order = await tx.order.create({ data: toOrderRow(cmd) });\n    await tx.outboxMessage.create({\n      data: {\n        id: crypto.randomUUID(), // becomes the message id (for dedup)\n        type: \"orders.order-placed.v1\",\n        key: order.id, // partition key: per-order ordering\n        payload: { orderId: order.id, phone: order.phone, total: order.total },\n      },\n    });\n    return order.id;\n  });\n}\n\n// Relay: every second read unpublished rows in order, send them with\n// producer.send({ topic, messages: [{ key, value, headers: { \"message-id\": id } }] }),\n// then mark them as published. A crash means a re-send, never a loss."}]},{"type":"codeBlock","attrs":{"language":"java","filename":"PlaceOrderWithOutbox.java"},"content":[{"type":"text","text":"@Service\nclass PlaceOrderHandler {\n    private final OrderRepository orders;\n    private final OutboxRepository outbox;\n    private final ObjectMapper json;\n\n    PlaceOrderHandler(OrderRepository orders, OutboxRepository outbox, ObjectMapper json) {\n        this.orders = orders; this.outbox = outbox; this.json = json;\n    }\n\n    // The order and the event are saved in ONE transaction. A relay publishes the outbox later.\n    @Transactional\n    public UUID handle(PlaceOrder cmd) throws JsonProcessingException {\n        var order = orders.save(Order.place(cmd.phone(), cmd.lines()));\n        outbox.save(new OutboxMessage(\n            UUID.randomUUID(),                                   // message id for dedup\n            \"orders.order-placed.v1\",\n            order.id().toString(),                               // partition key\n            json.writeValueAsString(new OrderPlacedV1(order.id(), order.phone(), order.total())),\n            Instant.now()));\n        return order.id();\n    }\n}\n// Relay: a @Scheduled job (or Debezium reading the outbox table via CDC) publishes and marks rows."}]},{"type":"codeBlock","attrs":{"language":"go","filename":"orders/outbox.go"},"content":[{"type":"text","text":"// PlaceOrder saves the order and the event in ONE transaction; a relay publishes the outbox later.\nfunc (s Service) PlaceOrder(ctx context.Context, cmd PlaceOrder) (string, error) {\n\ttx, err := s.DB.BeginTx(ctx, nil)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\tdefer tx.Rollback()\n\n\torderID := uuid.NewString()\n\tif _, err := tx.ExecContext(ctx,\n\t\t`INSERT INTO orders (id, phone, total) VALUES ($1, $2, $3)`, orderID, cmd.Phone, cmd.Total()); err != nil {\n\t\treturn \"\", err\n\t}\n\tpayload, _ := json.Marshal(OrderPlacedV1{OrderID: orderID, Phone: cmd.Phone, Total: cmd.Total()})\n\tif _, err := tx.ExecContext(ctx,\n\t\t`INSERT INTO outbox (id, type, key, payload) VALUES ($1, 'orders.order-placed.v1', $2, $3)`,\n\t\tuuid.NewString(), orderID, payload); err != nil {\n\t\treturn \"\", err\n\t}\n\treturn orderID, tx.Commit()\n}\n\n// Relay goroutine: SELECT ... FOR UPDATE SKIP LOCKED LIMIT 100, publish, UPDATE published_at."}]},{"type":"codeBlock","attrs":{"language":"python","filename":"orders/outbox.py"},"content":[{"type":"text","text":"import json\nimport uuid\n\nfrom sqlalchemy.orm import Session\n\n\ndef place_order(session: Session, cmd: \"PlaceOrder\") -> str:\n    \"\"\"The order and the event are saved in ONE transaction; a relay publishes the outbox later.\"\"\"\n    order = Order.place(cmd.phone, cmd.lines)\n    session.add(order)\n    session.flush()  # assigns order.id\n    session.add(OutboxMessage(\n        id=str(uuid.uuid4()),          # message id for dedup on the consumer side\n        type=\"orders.order-placed.v1\",\n        key=str(order.id),             # partition key: per-order ordering\n        payload=json.dumps({\"order_id\": str(order.id), \"phone\": order.phone, \"total\": str(order.total)}),\n    ))\n    session.commit()                   # both rows or neither\n    return str(order.id)\n\n# Relay: a loop (or a Celery beat task) reads unpublished rows, produces them with\n# confluent_kafka.Producer.produce(topic, key=..., value=..., headers=...), then marks them published."}]}]}]},"toc":[{"id":"kontekst-i-sily","text":"Kontekst i siły","level":2,"locked":false},{"id":"cztery-rzeczy-ktore-ludzie-nazywaja-event-driven","text":"Cztery rzeczy, które ludzie nazywają „event-driven”","level":2,"locked":false},{"id":"struktura","text":"Struktura","level":2,"locked":false},{"id":"gwarancje-dostarczenia","text":"Gwarancje dostarczenia","level":2,"locked":false},{"id":"jak-to-wyglada-w-kodzie","text":"Jak to wygląda w kodzie","level":2,"locked":false},{"id":"kolejnosc-kontrakty-i-obserwowalnosc","text":"Kolejność, kontrakty i obserwowalność","level":2,"locked":true},{"id":"kompromisy","text":"Kompromisy","level":2,"locked":true},{"id":"sciezka-wdrozenia","text":"Ścieżka wdrożenia","level":2,"locked":true},{"id":"w-praktyce","text":"W praktyce","level":2,"locked":true},{"id":"antywzorce","text":"Antywzorce","level":2,"locked":true},{"id":"powiazane-tematy","text":"Powiązane tematy","level":2,"locked":true},{"id":"sprawdz-sie","text":"Sprawdź się","level":2,"locked":true}],"locked":true,"paywall":null,"previewRatio":0.3,"totalBlocks":39,"visibleBlocks":17,"resources":[{"id":"6b0857be3c96f2d34d0b4235","type":"article","provider":"web","url":"https://learn.microsoft.com/en-us/azure/architecture/guide/architecture-styles/event-driven","embedUrl":null,"title":"Event-Driven Architecture Style","description":"Explore the benefits, challenges, and best practices for event-driven architectures on Azure.","author":"Microsoft Azure Architecture Center","thumbnailUrl":"https://learn.microsoft.com/en-us/media/open-graph-image.png","durationSec":null,"lang":"en","topics":["event-driven-architecture"],"techs":["general"],"tags":["azure","cloud","software-architecture"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"manual","publishedAt":null,"popularity":70,"verifiedAt":"2026-11-26T11:07:30.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:00:59.965Z","updatedAt":"2026-11-26T16:00:59.965Z"},{"id":"6b0857be3c96f2d34d0b4214","type":"article","provider":"web","url":"https://www.enterpriseintegrationpatterns.com/patterns/messaging","embedUrl":null,"title":"Messaging Patterns Overview - Enterprise Integration Patterns","description":"This pattern catalog includes 65 integration patterns that we collected from integration projects and updated over two decades. They provide technology-independent design guidance for developers and architects to develop and document robust integration solutions. The 65 messaging patterns are…","author":"Gregor Hohpe","thumbnailUrl":"https://www.enterpriseintegrationpatterns.com/img/eip1_patterns_wide.png","durationSec":null,"lang":"en","topics":["event-driven-architecture"],"techs":["general"],"tags":["software-architecture"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"manual","publishedAt":null,"popularity":75,"verifiedAt":"2026-11-26T11:26:15.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:00:59.965Z","updatedAt":"2026-11-26T16:00:59.965Z"},{"id":"6b0857bf3c96f2d34d0b4281","type":"article","provider":"web","url":"https://microservices.io/patterns/data/transactional-outbox.html","embedUrl":null,"title":"Microservices Pattern: Pattern: Transactional outbox","description":"First, write the message/event to a database OUTBOX table as part of the transaction that updates business objects, and then publish it to a message broker.","author":"Chris Richardson (microservices.io)","thumbnailUrl":null,"durationSec":null,"lang":"en","topics":["event-driven-architecture","microservices"],"techs":["general"],"tags":["databases","messaging","software-architecture"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"manual","publishedAt":null,"popularity":65,"verifiedAt":"2026-11-26T11:25:55.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:01:02.417Z","updatedAt":"2026-11-26T16:01:02.417Z"},{"id":"6b0857c53c96f2d34d0b480e","type":"video","provider":"youtube","url":"https://www.youtube.com/watch?v=A_mstzRGfIE","embedUrl":"https://www.youtube-nocookie.com/embed/A_mstzRGfIE","title":"Event-Driven Architectures Done Right, Apache Kafka • Tim Berglund • Devoxx Poland 2021","description":"Subscribe to our channel: https://youtube.pl/c/DevoxxPoland?sub_confirmation=1 Far from a controversial choice, Kafka is now a technology developers and architects are adopting with enthusiasm. And it’s often not just a good choice, but a technology enabling meaningful improvements in complex…","author":"Devoxx Poland","thumbnailUrl":"https://i.ytimg.com/vi/A_mstzRGfIE/hqdefault.jpg","durationSec":null,"lang":"en","topics":["event-driven-architecture"],"techs":["general"],"tags":["messaging","software-architecture"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"youtube-rss","publishedAt":"2022-05-26T14:00:33.000Z","popularity":80,"verifiedAt":"2026-11-26T11:14:49.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:01:07.480Z","updatedAt":"2026-11-26T16:01:07.480Z"},{"id":"6b0857bf3c96f2d34d0b423c","type":"article","provider":"web","url":"https://microservices.io/patterns/data/saga.html","embedUrl":null,"title":"Microservices Pattern: Pattern: Saga","description":"Implement transactions using a saga, which is a reliably coordinated sequence of local transactions","author":"Chris Richardson (microservices.io)","thumbnailUrl":null,"durationSec":null,"lang":"en","topics":["event-driven-architecture","microservices"],"techs":["general"],"tags":["software-architecture"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"manual","publishedAt":null,"popularity":70,"verifiedAt":"2026-11-26T11:25:54.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:01:02.417Z","updatedAt":"2026-11-26T16:01:02.417Z"},{"id":"6b0857c53c96f2d34d0b47fc","type":"video","provider":"youtube","url":"https://www.youtube.com/watch?v=7fkS-18KBlw","embedUrl":"https://www.youtube-nocookie.com/embed/7fkS-18KBlw","title":"Event-Driven Architecture(EDA) vs. Request/Response (RR): System Design Explained","description":"Are you deciding between an Event-Driven Architecture (EDA) and a traditional Request/Response model for your system? This video breaks down the critical differences to help you make the right choice. We'll compare these two architectural patterns across six key factors: reactivity, coupling…","author":"Confluent, an IBM Company","thumbnailUrl":"https://i.ytimg.com/vi/7fkS-18KBlw/hqdefault.jpg","durationSec":null,"lang":"en","topics":["event-driven-architecture"],"techs":["general"],"tags":["software-architecture","system-design","messaging"],"price":"free","featured":false,"featuredOrder":0,"packageName":null,"source":"youtube-rss","publishedAt":"2024-04-18T12:59:48.000Z","popularity":82,"verifiedAt":"2026-11-26T10:57:28.000Z","curated":false,"addedBy":"6b0857a15a2625e44ecaabe6","createdAt":"2026-11-26T16:01:07.480Z","updatedAt":"2026-11-26T16:01:07.480Z"}],"challenges":[{"id":"6b093dc291bd8fbaf2a0c8d8","slug":"payment-circuit-breaker","title":"Bezpiecznik przed bramką płatności","summary":"Circuit breaker ze stanami zamknięty, otwarty i półotwarty, wstrzykiwanym zegarem, progiem prób testowych i filtrem błędów biznesowych – żeby awaria bramki płatności nie położyła całego sklepu.","servedLang":"pl","availableLangs":["pl","en"],"kind":"code","category":"architecture","status":"published","difficulty":"hard","topics":["circuit-breaker","microservices"],"techs":["typescript","javascript","python","dotnet","java","go"],"tags":["circuit-breaker","resilience","fault-tolerance","state-machine","payments"],"languages":["typescript","javascript","python","csharp","java","go"],"questionCount":null,"xp":40,"stats":{"attempts":0,"solves":0,"solutions":0,"comments":0},"solveRate":null,"publishedAt":"2026-11-27T08:22:26.251Z"},{"id":"6b093dc191bd8fbaf2a0c8d0","slug":"inventory-cqrs","title":"Magazyn z CQRS – osobny model zapisu i odczytu","summary":"Komendy magazynowe walidowane na własnym modelu zapisu, zdarzenia na szynie i projekcja budująca model odczytu z raportem niskich stanów. Model odczytu da się odtworzyć z samych zdarzeń.","servedLang":"pl","availableLangs":["pl","en"],"kind":"code","category":"architecture","status":"published","difficulty":"medium","topics":["cqrs","event-driven-architecture"],"techs":["typescript","javascript","python","dotnet","java","go"],"tags":["cqrs","read-model","projection","events","inventory"],"languages":["typescript","javascript","python","csharp","java","go"],"questionCount":null,"xp":20,"stats":{"attempts":0,"solves":0,"solutions":0,"comments":0},"solveRate":null,"publishedAt":"2026-11-27T08:22:25.519Z"},{"id":"6b093dc091bd8fbaf2a0c8c0","slug":"event-sourced-account","title":"Konto bankowe w event sourcingu","summary":"Agregat konta, którego stan powstaje wyłącznie z odtwarzania zdarzeń, magazyn zdarzeń z optymistyczną współbieżnością i repozytorium zapisujące tylko nowe fakty. Zapytania o stan z przeszłości w gratisie.","servedLang":"pl","availableLangs":["pl","en"],"kind":"code","category":"architecture","status":"published","difficulty":"hard","topics":["event-sourcing","cqrs"],"techs":["typescript","javascript","python","dotnet","java","go"],"tags":["event-sourcing","aggregate","event-store","optimistic-concurrency","ddd"],"languages":["typescript","javascript","python","csharp","java","go"],"questionCount":null,"xp":40,"stats":{"attempts":0,"solves":0,"solutions":0,"comments":0},"solveRate":null,"publishedAt":"2026-11-27T08:22:24.935Z"}],"attachments":[],"hasCode":true,"repoUrl":null,"series":[{"slug":"architecture-path","title":"Od monolitu do mikroserwisów","items":[{"slug":"monolith","title":"Monolit: jedna aplikacja, jedno wdrożenie i dlaczego to często dobry start","current":false},{"slug":"modular-monolith","title":"Modularny monolit: twarde granice bez kosztów sieci","current":false},{"slug":"layered-architecture","title":"Architektura warstwowa: prezentacja, logika, dane – i gdzie to się psuje","current":false},{"slug":"hexagonal-architecture","title":"Pierogi w Heksagonie","current":false},{"slug":"clean-architecture","title":"Czysta architektura: reguła zależności i przypadki użycia w centrum","current":false},{"slug":"onion-architecture","title":"Architektura cebulowa: model domeny w środku, infrastruktura na zewnątrz","current":false},{"slug":"vertical-slice-architecture","title":"Architektura pionowych wycinków: kod według funkcji, nie według warstw","current":false},{"slug":"cqrs","title":"CQRS: osobny model do zmieniania, osobny do czytania","current":false},{"slug":"event-sourcing","title":"Event sourcing: zapisuj fakty, a nie tylko ostatni stan","current":false},{"slug":"event-driven-architecture","title":"Architektura sterowana zdarzeniami: kto publikuje, kto słucha i co może pójść nie tak","current":true},{"slug":"microservices","title":"Mikroserwisy: niezależne wdrożenia, prawdziwe koszty i kiedy to się opłaca","current":false},{"slug":"ddd-strategic-design","title":"DDD – projektowanie strategiczne: poddomeny, konteksty ograniczone i mapy kontekstów","current":false}]}],"prev":{"slug":"event-sourcing","title":"Event sourcing: zapisuj fakty, a nie tylko ostatni stan"},"next":{"slug":"microservices","title":"Mikroserwisy: niezależne wdrożenia, prawdziwe koszty i kiedy to się opłaca"},"featured":false,"authorCard":{"id":"6b08bd2e80884893657cc8cf","name":"Redakcja Art of Devs","avatar":null,"handle":"redakcja","headline":"Wzorce projektowe · Architektura · AI i LLM","community":false,"reputation":{"points":3900,"level":{"key":"mentor","label":"Mentor"}},"articles":68,"skills":[{"key":"typescript","title":"TypeScript","level":5,"levelLabel":"Autorytet","articles":63},{"key":"dotnet","title":".NET","level":5,"levelLabel":"Autorytet","articles":53},{"key":"python","title":"Python","level":5,"levelLabel":"Autorytet","articles":52},{"key":"java","title":"Java","level":5,"levelLabel":"Autorytet","articles":38}]}}