Reviewing implementation details in infrastructure
In the last section, we focused slightly on the infrastructure provisioning of Kafka, although there is far more to setting up Kafka than simply running a script. To understand the producer and consumer examples, we made some assumptions about how to interact with Kafka and, specifically, a topic.
Topics
Topics are not unique to Kafka but are a construct that producer-consumer patterns leverage to store and retrieve messages relevant to a specific domain or grouping of events within a domain. Normally, topics are scoped to a specific subset of data. For example, with the domain model of the MTAEDA application, you m expect to find a topic for equipment, stations, and scheduling, among others.
Events and messages (known as records in Kafka) are written in an append-only fashion. This means that each record is immutable upon being written to a topic. Any changes that are required have to be appended to the end of the topic....