从SQL Azure发送电子邮件 [英] sending email from sql azure

查看:75
本文介绍了从SQL Azure发送电子邮件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,
只是有关sql azure的快速问题.我的应用程序在Windows azure上运行,数据库在sql azure上运行.一切都很好.但是,我想在用户成为会员后立即向其发送电子邮件.我不想使用

Hey all,
just quick question about sql azure. My App is running on windows azure and the database is on sql azure. Everything is working great. However, I would like to send email to a user, as soon as he\she became a member.I don't want to Use

    -第三方服务

    -通过代码发送电子邮件.
    - send email from the code.

是否可以使用触发器和存储过程来发送电子邮件?例如:在用户表每次更新后运行触发器,触发器将运行存储过程. 提前致谢 .马特

Is there any way to send email by using a trigger and stored procedure? For example: run trigger after each updated for user table and trigger will run stored procedure. Thanks in advance . Matt

推荐答案

据我所知,无法直接从SQL Azure发送电子邮件.您将必须使用网络,工作人员或VM角色来实际发送电子邮件.通常,从Azure数据中心发送电子邮件非常棘手,因为垃圾邮件过滤器将Azure IP地址标记为不安全(请参阅 https ://alinirimie.sys-con.com/node/1404827 ).为避免此问题,您必须使用第三方SMTP服务(我们使用 Amazon SES )或您自己的服务SMTP服务器.如果要通过防火墙连接到自己的SMTP服务器,则可以使用 Windows Azure Connect 建立从Azure到本地网络的安全隧道.

As far as I know, there is no way to send an email from SQL Azure directly. You will have to use a web, worker or VM role to actually send email. In general, sending email from Azure data centers is tricky because spam filters flag Azure IP addresses as unsafe (see https://alinirimie.sys-con.com/node/1404827). To avoid this problem, you must use a third party SMTP service (we use Amazon SES) or your own SMTP server. If you want to connect to your own SMTP server through a firewall, you can use Windows Azure Connect to establish a secure tunnel from Azure to your local network.

这篇关于从SQL Azure发送电子邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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