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: develop-docs/backend/application-domains/kafka.mdx
+28-7Lines changed: 28 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,15 +3,36 @@ title: Kafka consumers
3
3
sidebar_order: 60
4
4
---
5
5
6
-
## Creating a new consumer in Sentry
6
+
## Create a new Kafka topic
7
7
8
-
WIP! This is currently just a checklist.
8
+
1. Add the topic to the `KAFKA_TOPIC_TO_CLUSTER` in [src/sentry/conf/server.py](https://github.com/getsentry/sentry/blob/master/src/sentry/conf/server.py):
9
+
* e.g. `subscription-results-eap-items`
10
+
2. Add the topic to `Topic` in [src/sentry/conf/types/kafka_definition.py](https://github.com/getsentry/sentry/blob/master/src/sentry/conf/types/kafka_definition.py)
11
+
12
+
## Define or re-use a processing strategy
13
+
14
+
In most cases a [Streaming Factory](https://getsentry.github.io/arroyo/getstarted.html#create-a-streaming-consumer) is what you want to when defining a consumer (see next section). You can find examples of it in [Sentry's code base](https://github.com/search?q=repo%3Agetsentry%2Fsentry+%28ProcessingStrategyFactory&type=code).
15
+
16
+
## Define a new Kafka consumer
9
17
10
18
1. Add a new entry in the `KAFKA_CONSUMERS` key in
2. You may need optional properties (e.g. `click_options`, you will need to research them by looking at [ConsumerDefinition](https://github.com/getsentry/sentry/blob/master/src/sentry/conf/types/kafka_definition.py)'s code.
3. In the [Sentry Consumers metrics dashboard](https://www.notion.so/sentry/Kafka-e8b4f93595684c97b01fe831fbceb0dc?pvs=4#1fa8b10e4b5d8044859ecaf559463cb0), add a new saved view for your consumer.
0 commit comments