---
id: bookworm.{env}.rating.feedback-delete
name: Feedback Deleted Channel
version: 1.0.0
type: topic
summary: |
  Kafka topic owned by the contributor team carrying Rating API feedback-deleted
  events consumed by Catalog API to update book rating summaries.
owners:
  - catalog-experience-team
badges:
  - content: Kafka
    backgroundColor: blue
    textColor: blue
  - content: Topic
    backgroundColor: teal
    textColor: teal
address: bookworm.{env}.rating.feedback-delete
parameters:
  env:
    enum:
      - development
      - staging
      - production
    default: development
    examples:
      - development
      - staging
      - production
    description: BookWorm deployment environment.
deliveryGuarantee: at-least-once
protocols:
  - kafka
deadLetterChannel:
  id: bookworm.{env}.catalog.dead-letter-queue
  version: 1.0.0
---

## Purpose & Scope

This topic transports feedback-deleted events published by [[service|rating-api]] within the Reviews bounded context when a customer removes feedback. [[service|catalog-api]] consumes these events to subtract the removed rating from the book's displayed summary. If the book no longer exists in Catalog, the event is treated as a safe no-op without compensation.

## Channel Specification

| Property                               | Value                                                                           |
| :------------------------------------- | :------------------------------------------------------------------------------ |
| **Bounded Context / Owner**            | [[domain\|reviews]] / [[team\|catalog-experience-team]]                         |
| **Channel Type**                       | Topic                                                                           |
| **Address Pattern**                    | `bookworm.{env}.rating.feedback-delete`                                         |
| **Parameters**                         | `env` (`development`, `staging`, `production`; default: `development`)          |
| **Protocol & Envelope Format**         | Kafka + CloudEvents JSON (`application/json`)                                   |
| **Partition Key & Ordering Guarantee** | Keyed by `bookId`; preserves per-book rating update ordering within a partition |
| **Delivery Semantics**                 | At-least-once                                                                   |
| **Dead-Letter Channel**                | [[channel\|bookworm.&#123;env&#125;.catalog.dead-letter-queue]]                 |

## Messages & Participants

| Message                                    | Type  | Producer                | Consumer(s)              | Consumer Group           |
| :----------------------------------------- | :---- | :---------------------- | :----------------------- | :----------------------- |
| [[event\|FeedbackDeletedIntegrationEvent]] | Event | [[service\|rating-api]] | [[service\|catalog-api]] | Catalog service consumer |

## Ordering, Retries & Failure Handling

- **Partition-key ordering:** Keying by `bookId` preserves per-book ordering alongside feedback creation events.
- **Transient retries:** [[service|catalog-api]] applies bounded retries with backoff for transient database or concurrency errors.
- **Immediate DLQ routing:** Malformed payloads, deserialization errors, or exhausted retries route to [[channel|bookworm.&#123;env&#125;.catalog.dead-letter-queue]].
- **Consumer idempotency:** Deletions for missing books or already-removed feedback entries are handled as safe no-ops.

## Channel Details & Visualization

<ChannelInformation />

<NodeGraph />

## Related Documentation

- [[channel|bookworm.&#123;env&#125;.catalog.dead-letter-queue]] — Consumer dead-letter queue
- [[channel|bookworm.&#123;env&#125;.rating.feedback-create]] — Paired feedback creation topic
- [[service|rating-api]] — Feedback producer
- [[service|catalog-api]] — Rating projection consumer
- [[flow|feedback-publication]] — End-to-end feedback publication flow
- [[doc|arc42/08-crosscutting-concepts/002-contracts-and-messaging]] — Messaging standards and idempotency rules
