From a8ea50d8f09873418d03dd56fc4ffd0d891761c9 Mon Sep 17 00:00:00 2001 From: Paolo Salvatori Date: Tue, 13 Oct 2026 05:10:56 +0200 Subject: [PATCH] Declare a Service Bus queue Azure accepts in the Java Terraform sample The Terraform variant of the servicebus/java sample created a queue that is partitioned, express and duplicate-detecting, which Azure refuses ("Both DelayedPersistence and RequiresDuplicateDetection property can't be enabled together", Service Bus Resource Manager exceptions), and that requires sessions, while the Spring Boot app sends and receives without a session ID ("When you enable sessions on a queue or a subscription, client applications can no longer send or receive regular messages", Message sessions). The queue now defaults to express and sessions off, like the Azure CLI and Bicep variants of the sample. Co-Authored-By: Claude Opus 5.5 --- samples/servicebus/java/terraform/variables.tf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/servicebus/java/terraform/variables.tf b/samples/servicebus/java/terraform/variables.tf index f52b32a3..157fc28c 100644 --- a/samples/servicebus/java/terraform/variables.tf +++ b/samples/servicebus/java/terraform/variables.tf @@ -118,7 +118,7 @@ variable "servicebus_queue_requires_duplicate_detection" { variable "servicebus_queue_requires_session" { description = "(Optional) Specifies whether the queue requires sessions for ordered handling of unbounded sequences of related messages. Changing this forces a new resource to be created. Defaults to false." type = bool - default = true + default = false } variable "servicebus_queue_default_message_ttl" { @@ -172,7 +172,7 @@ variable "servicebus_queue_partitioning_enabled" { variable "servicebus_queue_express_enabled" { description = "(Optional) Specifies whether Express Entities are enabled. An express queue holds a message in memory temporarily before writing it to persistent storage. Defaults to false." type = bool - default = true + default = false } variable "servicebus_queue_forward_to" {