In our Spring boot Java app flow, we were not able to send message using ASB sdk to a topic.
We also did not see any retries while publishing the message.
Here is the stack trace
Caused by: java.lang.IllegalStateException: Cannot perform operation 'sendMessage' on a disposed sender.
at com.azure.messaging.servicebus.ServiceBusSenderAsyncClient.sendInternal(ServiceBusSenderAsyncClient.java:798)
at com.azure.messaging.servicebus.ServiceBusSenderAsyncClient.sendMessage(ServiceBusSenderAsyncClient.java:237)
at com.azure.messaging.servicebus.ServiceBusSenderClient.sendMessage(ServiceBusSenderClient.java:183)
at
com.fmr.prdc.postprice.recon.infrastructure.adapter.IncompleteTransactionEventPublisherAdapter.publishIncompleteTransactionEvent(IncompleteTransactionEventPublisherAdapter.java:61)
at com.fmr.prdc.postprice.recon.core.facade.BaseReconEventHandler.notifyIncompleteTransactionProcessor(BaseReconEventHandler.java:545)
at com.fmr.prdc.postprice.recon.core.facade.ContributionActivityDefaultReconHandler.handleReconSummaryEvent(ContributionActivityDefaultReconHandler.java:84)
at com.fmr.prdc.postprice.recon.core.facade.LoanRepaymentsDefaultReconHandler.handleReconSummaryEvent(LoanRepaymentsDefaultReconHandler.java:61)
at com.fmr.prdc.postprice.recon.application.consumer.ReconSetupListener.processMessage(ReconSetupListener.java:95)
at com.fmr.prdc.postprice.recon.application.consumer.ReconSetupListener.handleReconEvent(ReconSetupListener.java:59)
at jdk.internal.reflect.GeneratedMethodAccessor226.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.springframework.messaging.handler.invocation.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:169)
at org.springframework.messaging.handler.invocation.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:119)
at org.springframework.jms.listener.adapter.MessagingMessageListenerAdapter.invokeHandler(MessagingMessageListenerAdapter.java:114)
... 10 common frames omitted
Hi @anshul733 , thanks for reaching out. This repository has been deprecated and migrated to https://github.com/Azure/azure-sdk-for-java. So I will close this one and create another there to track your issue.
In our Spring boot Java app flow, we were not able to send message using ASB sdk to a topic. We also did not see any retries while publishing the message.
Here is the stack trace
Here is the SDK version we use
JDK version - 11
Spring boot version - 2.6.6
Here is the code snippet we use to publsh the message