Skip to content

Conversation

@DoChaoing
Copy link

@DoChaoing DoChaoing commented Feb 3, 2026

[fix][broker] Rename TopicBacklogQuotaExceededException to TopicBlockedQuotaExceededException

Fixes #25168

Motivation

Based on the code, there is a naming inconsistency between server-side and client-side exceptions:

  • When the server throws ProducerBacklogQuotaExceededError, the exception class is TopicBacklogQuotaExceededException
  • But the client receives ProducerBlockedQuotaExceededException or ProducerBlockedQuotaExceededError

This makes it difficult for developers to locate key information from the server-side code when debugging quota-related issues.

Modifications

Renamed TopicBacklogQuotaExceededException to TopicBlockedQuotaExceededException in the following files:

  • BrokerServiceException.java: Class definition and constructor
  • ServerCnx.java: Exception type check and casting
  • PersistentTopic.java: Import statement and exception throwing

Verifying this change

This change is already covered by existing tests, such as:

  • BacklogQuotaManagerTest - Tests backlog quota enforcement
  • PersistentTopicTest - Tests topic behavior with quota exceeded

Does this pull request potentially affect one of the following parts:

  • Dependencies (add or upgrade a dependency)
  • The public API
  • The schema
  • The default values of configurations
  • The threading model
  • The binary protocol
  • The REST endpoints
  • The admin CLI options
  • The metrics
  • Anything that affects deployment

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

Matching PR in forked repository

PR in forked repository: https://github.com/DoChaoing/pulsar/pull/1

@github-actions
Copy link

github-actions bot commented Feb 3, 2026

@DoChaoing Please add the following content to your PR description and select a checkbox:

- [ ] `doc` <!-- Your PR contains doc changes -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
- [ ] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->

@DoChaoing DoChaoing closed this Feb 3, 2026
@DoChaoing DoChaoing reopened this Feb 3, 2026
@github-actions github-actions bot added doc-not-needed Your PR changes do not impact docs and removed doc-label-missing labels Feb 3, 2026
@DoChaoing DoChaoing closed this Feb 3, 2026
@DoChaoing DoChaoing reopened this Feb 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-not-needed Your PR changes do not impact docs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change broker exception from TopicBacklogQuotaExceededException to TopicBlockQuotaExceededException

1 participant