designing with com+ and MS Queue
Messages   Related Types
This message was discovered on ASPFriends.com 'ngfx-messaging' list.


David Winslow
Hey,

I want to write and application that can do the following:

Tools avaible :
MessageQueue
MS components server (com+)
Dotnet

Scenario:

Message1 is added to a MS queue
A instance of appgetmessage (app1) is created
App1 gets the message in the queue

Message1 is added to a MS queue (while app1 is still busy)
A instance of appgetmessage (app2) is created
App2 gets the message in the queue

Message3 is added to a MS queue (while app2 is still busy)
Now app1 is ready and handles this message

Questions:

1. Can I use com+ to achieve this?
2. Is there a better way of doing load balancing for this scenario?
3. Can Com+ subscribe to and event like "messagequeue file added"?

Thank you for reading this!

I would really appricate any feedback, thought etc on this subject.

Thank you

David
Reply to this message...
 
    
Matthew Arnheiter
I would try to build the solution differently. I would create one thread
for retrieving messages off of the message queue and then pass the message
along to worker threads to do the work with those messages. You can then
use a thread pool to manage the worker threads and use which ever thread is
currently not doing any work. Your scenarios would look more like:

The Listen thread receives message1 from the queue and asks the thread pool
for a thread. The pool returns thread1 and thread1 processes message1.
The Listen thread receives message2 from the queue and asks the thread pool
for a thread. The pool knows that thread1 is still busy so it returns
thread2 and thread2 processes message2.
etc.

Matthew Arnheiter
Chief Software Architect
GoAmerica Communications Corp.
-----Original Message-----
From: David Winslow [mailto:Click here to reveal e-mail address]
Sent: Saturday, December 29, 2001 3:02 PM

I want to write and application that can do the following:

Scenario:

Message1 is added to a MS queue
A instance of appgetmessage (app1) is created
App1 gets the message in the queue

Message1 is added to a MS queue (while app1 is still busy)
A instance of appgetmessage (app2) is created
App2 gets the message in the queue

Message3 is added to a MS queue (while app2 is still busy)
Now app1 is ready and handles this message

Questions:

1. Can I use com+ to achieve this?
2. Is there a better way of doing load balancing for this scenario?
3. Can Com+ subscribe to and event like "messagequeue file added"?
Reply to this message...
 
 
System.Messaging.MessageQueue




Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com