Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions sdk/spring/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,14 @@ This section includes changes in `spring-cloud-azure-docker-compose` module.

- Upgrade to Jackson 3 to align with Spring Boot 4 ([#49538](https://github.com/Azure/azure-sdk-for-java/issues/49538)).

### Spring Cloud Azure Stream Binder Service Bus

This section includes changes in `spring-cloud-azure-stream-binder-servicebus` module.

#### Bugs Fixed

- Fixed a regression where dead-letter reason and error description were not transmitted because a no-arg `deadLetter()` call settled the message before `deadLetter(options)` was invoked ([#41883](https://github.com/Azure/azure-sdk-for-java/issues/41883)).

## 6.4.0 (2026-06-01)
- This release is compatible with Spring Boot 3.5.0-3.5.14. (Note: 3.5.x (x>14) should be supported, but they aren't tested with this release.)
- This release is compatible with Spring Cloud 2025.0.0-2025.0.2. (Note: 2025.0.x (x>2) should be supported, but they aren't tested with this release.)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,6 @@ public <T> void deadLetter(String destination,
.getHeaders()
.get(ServiceBusMessageHeaders.RECEIVED_MESSAGE_CONTEXT);
if (messageContext != null) {
messageContext.deadLetter();
DeadLetterOptions options = new DeadLetterOptions();
options.setDeadLetterReason(deadLetterReason);
options.setDeadLetterErrorDescription(deadLetterErrorDescription);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@
import static org.assertj.core.api.Assertions.assertThat;
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.never;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
import static org.mockito.Mockito.when;

class ServiceBusMessageChannelBinderTest {
Expand Down Expand Up @@ -104,9 +106,11 @@ void testDeadLetterCalledForError() {
String description = "testDescription";
ErrorMessage msg = new ErrorMessage(new RuntimeException(description), originalMessage);
handler.handleMessage(msg);
verify(messageContext, never()).deadLetter();
verify(messageContext).deadLetter(captor.capture());
assertEquals("exception-message", captor.getValue().getDeadLetterReason());
assertEquals(description, captor.getValue().getDeadLetterErrorDescription());
verifyNoMoreInteractions(messageContext);
}

@Test
Expand Down
Loading