到MSMQ或不MSMQ? (或SQL表作为队列) [英] to MSMQ or not to MSMQ? (or SQL Table as the Queue)
问题描述
我有一个分布式系统,其中将有1 SQL Server中,1-N处理服务器和1-N的数据供应商(在网络硬件设备)。所提供的数据需要处理进入关系数据库结构之前 - 通过处理服务器进行(如Windows服务 - .NET code解析数据,处理它,并将其插入到关系结构)< BR>
为了处理潜在的负载,不会减慢数据供应商,我想实现一个队列,但我不知道我要到一个MSMQ服务器的复杂性加进来。是否有一个很好的替代MSMQ,如使用DB(平面表)作为队列?是否.NET提供了出位的现成的任何的DB队列支持,还是有另一种选择可靠的排队?
谢谢
I've got a distributed system where there will be 1 SQL Server, 1-n processing servers, and 1-n data suppliers (hardware devices across the network). The data being supplied will require processing prior to going into the relational DB structure - performed by the processing servers (as windows services - .net code to parse the data, process it, and insert it into the relational structure.)
To handle the potential load and not slow down the data suppliers, I want to implement a queue, but I'm not sure I want to add the complexity of an MSMQ server to the mix. Is there a good alternative to MSMQ, such as using the DB (a flat table) as the queue? Does .NET provide any out-of-the-box support for DB queues, or is there another option for reliable queueing?
Thanks
编辑:(11月29日,11时30分)
听起来像SQL服务代理(SSB)可能会做的伎俩。
<一href="http://www.netframeworkdev.com/windows-communication-foundation/service-broker-vs-msmq-as-reliable-queueing-mechanism-63981.shtml">http://www.netframeworkdev.com/windows-communication-foundation/service-broker-vs-msmq-as-reliable-queueing-mechanism-63981.shtml
(29 Nov, 11:30pm)
sounds like SQL Service Broker (SSB) might do the trick.
http://www.netframeworkdev.com/windows-communication-foundation/service-broker-vs-msmq-as-reliable-queueing-mechanism-63981.shtml
编辑:(11月30日上午07点45分)
发现关于这个问题的另一个非常有用的链接:
<一href="http://social.msdn.microsoft.com/Forums/en-US/sqlservicebroker/thread/52687510-0852-44f3-bfcd-83610d1c1b9a">http://social.msdn.microsoft.com/Forums/en-US/sqlservicebroker/thread/52687510-0852-44f3-bfcd-83610d1c1b9a
我也期待到将要提供的数据的最大/最小尺寸。他们头顶的,没有人知道通过MSMQ和/或SSB容纳的最大尺寸?
MSMQ:4MB邮件大小
国家统计局:2GB邮件大小
(30 Nov, 7:45am)
Found another very useful link on this subject:
http://social.msdn.microsoft.com/Forums/en-US/sqlservicebroker/thread/52687510-0852-44f3-bfcd-83610d1c1b9a
I'm also looking into the max/min size of the data that will be supplied. Of the top of their head, does anyone know the max size accommodated by MSMQ and/or SSB?
MSMQ: 4MB message size
SSB: 2GB message size
编辑:(11月30日,8; 15AM)
MSMQ和放大器之间比较大; SSB在这里:
良策消息队列?
(30 nov, 8;15am)
Great comparison between MSMQ & SSB here:
Good Strategy for Message Queuing?
推荐答案
我会用MSMQ,它不添加太多的复杂性,这是很容易备份的消息,因此即使在系统重新启动可以继续处理。你可以使用类似SSB。
I would use MSMQ, it doesnt add that much complexity, and it is so easy to backup the messages, so processing can continue even after a system restart. You could use something like SSB.
这篇关于到MSMQ或不MSMQ? (或SQL表作为队列)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!