Skip to the content.

SocialMediaPosts.Kafka

This repository demonstrates handling social media posts via Event Driven Architecture, Kafka and .NET6.

Event Sourcing With Kafka


‘Topics’ covered:

CQRS

Event Sourcing

How to Create Microservices in C# with .NET

Creating DDD-Oriented Microservices

Using Apache Kafka as a Message Bus

Creating an Event Store with MongoDB

Optimistic Concurrency Control

Event Versioning

Using Microsoft SQL to Implement the Read Database

Replay the Event Store and Recreate the State of the Aggregate

Replay the Event Store and Recreate the Entire Read Database

Replay the Event Store and Recreate the Read Database in a Different Database Type - PostgreSQL

Implementing the Database-Per-Service Pattern

Entity Framework Core (MS SQL and PostgreSQL)

Dependency Injection

Docker


Learnings:

Handle commands and raise events.

Use the mediator pattern to implement command and query dispatchers.

Create and change the state of an aggregate with event messages.

Implement an event store / write database in MongoDB.

Create a read database in MS SQL.

Apply event versioning.

Implement optimistic concurrency control.

Produce events to Apache Kafka.

Consume events from Apache Kafka to populate and alter records in the read database.

Replay the event store and recreate the state of the aggregate.

Separate read and write concerns.

Structure your code using Domain-Driven-Design best practices.

Replay the event store to recreate the entire read database.

Replay the event store to recreate the entire read database into a different database type - PostgreSQL.

Courtesy:

https://www.udemy.com/

Sean Campbell