Making a fix to compare sessionid on the message and the sessionid on the link filter in a case-insensitive way.#48759
Merged
yvgopal merged 3 commits intoAzure:mainfrom Apr 10, 2026
Conversation
…in a case insensite way.
Contributor
There was a problem hiding this comment.
Pull request overview
Updates Service Bus session ID matching to be case-insensitive (Service Bus session IDs are not case-sensitive) to avoid disposition/link lookup failures when the broker returns a different session ID casing than the message carries.
Changes:
- Normalize session ID keys (lowercased with
Locale.ROOT) inSessionsMessagePumpandServiceBusSessionManagerlookup maps. - Switch
ServiceBusSingleSessionManagersession ID comparisons toequalsIgnoreCase. - Add/extend tests to cover case-differing session ID scenarios for message settlement and single-session manager behavior.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| sdk/servicebus/azure-messaging-servicebus/src/main/java/com/azure/messaging/servicebus/SessionsMessagePump.java | Normalizes tracked session receiver keys and disposition lookups to be case-insensitive. |
| sdk/servicebus/azure-messaging-servicebus/src/main/java/com/azure/messaging/servicebus/ServiceBusSingleSessionManager.java | Uses case-insensitive session ID comparison for link name/disposition routing. |
| sdk/servicebus/azure-messaging-servicebus/src/main/java/com/azure/messaging/servicebus/ServiceBusSessionManager.java | Normalizes session receiver map keys and lookups for case-insensitive session ID handling. |
| sdk/servicebus/azure-messaging-servicebus/src/test/java/com/azure/messaging/servicebus/SessionsMessagePumpIsolatedTest.java | Adds a test ensuring settlement succeeds when accepted vs message session ID casing differs. |
| sdk/servicebus/azure-messaging-servicebus/src/test/java/com/azure/messaging/servicebus/ServiceBusSingleSessionManagerTest.java | Adds new unit tests for case-insensitive link name lookup and disposition update. |
...vicebus/src/test/java/com/azure/messaging/servicebus/ServiceBusSingleSessionManagerTest.java
Outdated
Show resolved
Hide resolved
...saging-servicebus/src/main/java/com/azure/messaging/servicebus/ServiceBusSessionManager.java
Outdated
Show resolved
Hide resolved
...saging-servicebus/src/main/java/com/azure/messaging/servicebus/ServiceBusSessionManager.java
Show resolved
Hide resolved
Member
Author
|
@copilot apply changes based on the comments in this thread |
anuchandy
approved these changes
Apr 10, 2026
anuchandy
approved these changes
Apr 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Service Bus sessionid is not case sensitive. We shouldn't be doing case sensitive comparison between sessionId property on the message and sessionid property on the link.