You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/guides/01-deployment-guide/02-data-management-&-storage.md
+95-21Lines changed: 95 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,33 +82,107 @@ The file transfer service Score is compatible with any S3 storage provider; for
82
82
83
83
## Running Kafka
84
84
85
-
1. **Run Kafka:** Use the following command to pull and run the Kafka docker container
85
+
Kafka serves as a distributed streaming platform, enabling high-throughput, fault-tolerant, and scalable messaging between Song and Maestro.
86
+
87
+
:::info Why Kafka?
88
+
Kafka serves as a message broker between Song and Maestro, enabling asynchronous communication between services. Kafka provides reliable message delivery and persistence, handling message queuing and processing at scale. This ensures fault tolerance when processing multiple indexing requests between Song and Maestro.
89
+
:::
90
+
91
+
The following configuration creates a single-node Kafka broker for development use:
92
+
93
+
1. **Create an env file:** Create a file named `.env.kafka` with the following content:
Kafka serves as a distributed streaming platform, enabling high-throughput, fault-tolerant, and scalable messaging between Song and Maestro. Kafka acts as the backbone messaging system for Song and Maestro, facilitating asynchronous communication ensuring efficient and reliable job execution, queuing, and processing.
134
+
<details>
135
+
<summary><b>Click here for a detailed breakdown</b></summary>
136
+
137
+
#### Core Kafka Configuration
138
+
- `KAFKA_PROCESS_ROLES`: Defines the roles this broker will fulfill (broker and controller)
139
+
- `KAFKA_NODE_ID`: Unique identifier forthis brokerin the cluster
140
+
- `KAFKA_ADVERTISED_LISTENERS`: External connection points other clients will use to connect
141
+
- `KAFKA_LISTENERS`: Internal connection points for broker communication
142
+
- `KAFKA_LISTENER_SECURITY_PROTOCOL_MAP`: Maps listener names to security protocols
143
+
- `KAFKA_INTER_BROKER_LISTENER_NAME`: Listener used for inter-broker communication
144
+
- `KAFKA_CONTROLLER_QUORUM_VOTERS`: List of controller nodes in the cluster
145
+
- `KAFKA_CONTROLLER_LISTENER_NAMES`: Names of listeners used for controller connections
146
+
147
+
#### Storage Configuration
148
+
- `KAFKA_LOG_DIRS`: Directory where Kafka stores its log files
149
+
- `KAFKA_LOG_RETENTION_HOURS`: How long to keep messages (7 days)
150
+
- `KAFKA_LOG_RETENTION_BYTES`: Maximum size of the log before deletion (-1 means unlimited)
151
+
152
+
#### Topic Configuration
153
+
- `KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR`: Replication factor for the offsets topic
154
+
- `KAFKA_AUTO_CREATE_TOPICS_ENABLE`: Whether to allow automatic topic creation
155
+
- `KAFKA_NUM_PARTITIONS`: Default number of partitions for new topics
156
+
- `KAFKA_DEFAULT_REPLICATION_FACTOR`: Default replication factor for new topics
157
+
- `KAFKA_MIN_INSYNC_REPLICAS`: Minimum number of replicas that must acknowledge writes
158
+
159
+
#### Performance Tuning
160
+
- `KAFKA_MESSAGE_MAX_BYTES`: Maximum message size (5MB)
161
+
- `KAFKA_REPLICA_FETCH_MAX_BYTES`: Maximum size of messages that can be fetched
162
+
163
+
#### Logging Configuration
164
+
- `KAFKA_LOG4J_LOGGERS`: Specific logger levels for Kafka components
165
+
- `KAFKA_LOG4J_ROOT_LOGLEVEL`: Default logging level for all components
166
+
167
+
</details>
168
+
169
+
:::tip For more detailed information about Kafka refer to:
For more detailed information on Kafka configurations, please refer to the [official Confluent Kafka documentation](https://docs.confluent.io/platform/current/installation/docker/config-reference.html#confluent-ak-configuration).
175
+
2. **Run Kafka:** Use the docker run command with your `.env.kafka` file:
0 commit comments