-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[QUERY] In Microsoft.Azure.ServiceBus how do we perform OnMessageAsync and OnCloseSessionAsync #11061
Comments
I See that we can use RegisterSessionHandler for OnMessageAsync. But I didn't find an equivalent of OnCloseSessionAsync OnCloseSessionAsync we have a use case that we notify the Listeners of the queue . And after notifying them they are suppose to take some action. |
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @jfggdl. |
@pvreddy37, Thanks for raising the issue. @jsquire @JoshLove-msft , FYI. |
There is no easy way to work around this. One hack you could try is poll on the session object for |
Hi @pvreddy37, can you elaborate on the action that the queue listener needs to take once the session is closed? Is the intent to track the number of sessions processed or is it a time-sensitive action that needs to happen precisely when we have stopped processing messages from a particular session? |
Hi @JoshLove-msft : It is a time sensitive action that we need to take when we have stopped processing messages from a particular session. . Basically we configure MessageWaitTimeout = 3 minutes in SessionHandlerOptions() and if there is no message for 3 minutes we notify other users to take action. |
This appears to have been resolved; the forthcoming |
hi People. Just need your help and assistance on the below questions.
Earlier we are using session queues with Microsoft.ServiceBus.Messaging with below approach
Current Appracoh:
creating a queue client and we are registering to RegisterSessionHandlerFactory( with a call back and Session handler)
We are inherting IMessageSessionAsyncHandler and overriding OnMessageAsync,OnCloseSessionAsync to handle messages and closing functionality of sessions.
we mainly depend on these member functions (OnMessageAsync,OnCloseSessionAsync ) to write our logic.
Current Problem : we are planning to migrate to use Microsoft.Azure.ServiceBus. and we didn't find an equivalent class or interface with which we can implement and override (OnMessageAsync,OnCloseSessionAsync ) and write our functionality
Note: We have implemented above mentioned current approach in continuous Web job. where we have callback which creates a factory method on each webjob instance
Is there any solution for this . or any other alternative. Thanks in advance
The text was updated successfully, but these errors were encountered: