Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8845721
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T11:48:09+00:00 2026-06-14T11:48:09+00:00

I have an NServiceBus endpoint hosted in an azure worker role using AzureMessageQueue as

  • 0

I have an NServiceBus endpoint hosted in an azure worker role using AzureMessageQueue as the transport. I am pretty sure that i will be running the worker role with more than one instance configured in azure. I also have a few messages where order is important.

Here is my question. Is there a way to control the order with this type of setup (azure worker role scaled out)?

Should i be looking at a saga? Techniques like the one described below (using the bus.send(object[] messages) overload) will work in this model, i am guessing, but this is only ideal if there are a few messages due to the size limit on an azure queue.

http://mikaelkoskinen.net/post/NServiceBus-In-order-message-processing.aspx

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T11:48:10+00:00Added an answer on June 14, 2026 at 11:48 am

    Bus.Send in batch will help and so will configuring the read batch size from the message queue if messages are small enough, you can definitly control the order of messages this way. Batch send will put multiple message instances in the same physical queue message, while batch read will pull multiple physical messages from the queue in one go and process them in order on the node.

    Another option is to synchronize the reads in the message handlers, using leases on blobs. See the code of the nsb timeoutmanager on how to use these for synchronization or have a look at steve marx’s blog post on the topic. http://blog.smarx.com/posts/managing-concurrency-in-windows-azure-with-leases

    But please do note that azure messages queues DO NOT GUARANTEE ORDER themselves, it’s a best effort. If you want to guarantee order at the transport level, you need to use Azure Servicebus Queues with message ordering enabled.

    Kind regards,
    Yves

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an experimental NServiceBus project running which has: MyProject.Core - message publisher using
I have a feature I'm attempting to implement using NServiceBus but not sure the
I have an NServiceBus 3.0 endpoint set up to use FluentNHibernate as my ORM
I have a basic nServicebus 3.2.0 setup with a web application endpoint and a
We have an NServiceBus 3.0 publisher running under the production profile. When a subscriber
I have a client-server application that utilises MSMQ and NServiceBus for messaging. During some
I have an existing NServiceBus 2.6 application that I want to start moving to
I have an application using NServiceBus to process messages, and while debugging I'm finding
I am concerned with my NServiceBus solution. I have a MessageHub that publishes some
While debugging my NServiceBus enabled application, I have certain messages that are reported in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.