Open AndyM1H opened 1 year ago
@AndyM1H thank you for reporting the issue! This must be related to this change: https://github.com/Azure/azure-sdk-for-js/pull/24509. After the PR, when we need to open a new link, a new replyTo
guid is generated.
Does the issue happen every time you call scheduleMessages()
? Could you please share you code snippets that reproduced the problem?
@jeremymeng I have an update for you. Messages were scheduled as expected, but there is the exception in the timer trigger after that messages were scheduled. So, Service Bus Queue receives scheduled messages at the time.
Code snippet
await Promise.all(
users
.map((user) =>
({
body: {
userId: user.id,
},
})
)
.map((message, index) =>
sender.scheduleMessages(
message,
new Date(
syncStartTimestamp +
index * syncPeriod +
OFFSET_IN_MILLISECONDS
)
)
)
);
If we add catch
statement to scheduleMessages()
, then we get the next error object per each message in the catch
:
{
name: "ServiceBusError",
retryable: false,
info: null,
code: "ServiceCommunicationProblem",
message: "The response link 'd7a6486c-5cf7-bd4a-93e0-9225e1299ffa' was not found in the entity management node $management."
}
Any updates on this? I am getting this error in the Azure Portal when I try to Peek the message queue. The queue won't populate at all in the Portal.
EDIT: The error occurs when I attempt to Peek the messages in the queue via the Azure Portal when the Queue State is ReceiveDisabled.
@AndyM1H the original issue may have been addressed by PR #25297. Could you please give version 7.9.0 or later a try?
@David-Nash-0 Do you have the stack trace? Also for Azure Portal scenarios you may want to open a support ticket so we can investigate both the Portal and the SDK.
@jeremymeng When I click the "Peek from start" button in Service Bus Explorer, I get a notification: Failed to peek messages ServiceBusError: The response link '{guid}' was not found in the entity management node $management.
@David-Nash-0 Thanks I can see the same error in portal too and will investigate this further.
@David-Nash-0 when you set Queue to ReceiveDisabled
you will not be able to receive messages from it. This looks to include peeking as well.
Regarding the eerror: our JS SDK receives this error first from the service
Messaging entity 'sb://yu-servicebus.servicebus.windows.net/qjs25258/$management' is currently disabled.
But due to the current architecture of the internal management client, we only log a warning for this error and are unable to surface this error to the caller of peekMessages()
. So our code continues until we got another error from the service, which is the one you are seeing. I will investigate further on how to correctly report the first error.
@jeremymeng Thank you so much for investigating. Service Bus really should allow peeking messages in the disabled states. There are operational reasons people will want to analyze the contents of the queue before releasing it for processing.
Service Bus really should allow peeking messages in the disabled states. There are operational reasons people will want to analyze the contents of the queue before releasing it for processing.
@David-Nash-0 This is a good feedback! I will communicate it to the service team.
Describe the bug When I try to schedule a message to the service bus queue from my timer trigger function using the .scheduleMessages() method, I encounter an exception. This exception is only encountered on versions of the package that are greater than v7.8.0. or equal.
Exception's stack
To Reproduce Steps to reproduce the behavior:
Expected behavior Messages are successfully scheduled to the service bus queue.