Azure网站上的MSMQ [英] MSMQ on Azure Website

查看:104
本文介绍了Azure网站上的MSMQ的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个现有的ASP.NET Web服务(asmx),我正尝试将其移至Azure. Web服务的日志记录组件将消息记录到MSMQ中,并且有一个Windows服务可以读取消息并更新数据库.

I have an existing ASP.NET Web Service (asmx), which I am trying to move into Azure. The logging component of the web service logs the messages in to MSMQ and there is a windows service which reads the message and update the database.

使用Azure Web APP(网站)是否可能? Web服务代码能否在运行时创建消息队列并将消息推送到其中?

Is this possible using Azure Web APP (Websites) ? Will the web service code be able to create message queues at run time and could push messages into it?

推荐答案

MSMQ不能作为Azure服务使用,并且不能使用App Service创建Windows服务.您可以做的是使用存储队列而不是MSMQ,对您的Web服务代码的影响最小.将Windows服务替换为将新消息发送到队列时将触发的Web作业.您必须进行一些重构,但这应该没那么糟.

MSMQ isn't available as an Azure service and you can't create a Windows service with App Service. What you can do is use a storage queue instead of MSMQ with minimal impact on your Web service code. Replace you Windows service with a Web Job that will be triggered when a new message is sent to the queue. You'll have to do a little refactoring but it shouldn't be that bad.

以下是可帮助您入门的链接: https://azure.microsoft.com/zh-CN/documentation/articles/websites-dotnet-webjobs-sdk-get-started/

Here's a link to get you started: https://azure.microsoft.com/en-us/documentation/articles/websites-dotnet-webjobs-sdk-get-started/

这篇关于Azure网站上的MSMQ的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆