-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reimplement session-processor to remove the pattern using merge operator #33706
Comments
Any resolution ETA? Customer end-user quality of service is strongly impacted due to the performance impact. |
Behavior seems to have been fixed in the release azure-messaging-servicebus_7.15.0-beta.3. To update, please override the transitive package version ( <dependency>
<groupId>com.azure</groupId>
<artifactId>azure-messaging-servicebus</artifactId>
<version>7.15.0-beta.4</version>
</dependency> |
Hello Clemence, thanks for following up. You’re right the beta.4 addresses this ordering issue. The steps to use the new session implementation is – Add 7.15.0-beta.4 dependency<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-messaging-servicebus</artifactId>
<version>7.15.0-beta.4</version>
</dependency> Opt-in for new session (V2) functionalityprivate static final String V2_SESSION_PROCESSOR_CONFIGURATION_KEY = "com.azure.messaging.servicebus.session.processor.asyncReceive.v2";
ServiceBusProcessorClient processor = new ServiceBusClientBuilder()
.fullyQualifiedNamespace(Config.FULLY_QUALIFIED_NAMESPACE)
.credential(Config.CREDENTIAL)
.configuration(new com.azure.core.util.ConfigurationBuilder()
.putProperty(V2_SESSION_PROCESSOR_CONFIGURATION_KEY, "true") // 'false' by default, so opt-in to enable V2.
.build())
.sessionProcessor()
.topicName(Config.TOPIC)
.subscriptionName(Config.SUBSCRIPTION)
.disableAutoComplete()
.processMessage(processMessage)
.processError(processError)
.maxAutoLockRenewDuration(Duration.ofMinutes(5))
.receiveMode(ServiceBusReceiveMode.PEEK_LOCK)
.subQueue(SubQueue.NONE)
.maxConcurrentSessions(2)
.maxConcurrentCalls(1)
.prefetchCount(0)
.sessionIdleTimeout(Duration.ofMinutes(1))
.buildProcessorClient(); Also, make sure the app developer understands concurrency and capacity aspects, to avoid stalling/hang/interruption. Refer this comment. |
Hello @anuchandy Edit: it works by settings an environment variable " |
Hi @brunomace, Opt-in can be also done using env-var (as you found) or via system property when Configuration route is not accessible. JFYI, 7.15.0 can be used instead of beta, opt-in is still needed. Also, please have a look at this comment regarding the session concurrency. |
Resolving this. Refer https://learn.microsoft.com/en-us/azure/developer/java/sdk/troubleshooting-messaging-service-bus-overview#upgrade-to-715x for details about version 7.15.x and how to opting-in new session rework. |
Rework session-processor to -
Related issue: #33232
The text was updated successfully, but these errors were encountered: