来自网络的电子邮件,不绑网页 [英] Email from web without tying up webpage

查看:204
本文介绍了来自网络的电子邮件,不绑网页的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个处理工作请求的Web应用程序。它会向用户介绍新的,已更改的和已完成的请求。问题是,当它发送电子邮件时,需要一段时间才能加载页面。没有电子邮件过程,它工作正常。我正在使用CDO直接从代码隐藏发送消息。有没有更好的方法不会绑定网页?



我认为在更改请求后,可能会独立运行exe。有没有办法shell脚本来处理电子邮件,但是继续使用网页加载,以便shell脚本独立于页面代码运行?

解决方案

您可能会考虑将电子邮件排入数据库表或由专用服务读取的文本文件。



编写电子邮件到数据库或文本文件将很快,服务只需要检查每几分钟的更改。



问题是你不能通知用户电子邮件没有发送,尽管您将遇到同样的问题,试图执行另一个程序。


I have a web app that handles work requests. It emails the users involved on new, changed, and completed requests. The problem is, when it sends the email it takes a while for the page to load. Without the email process, it works fine. I'm using CDO to send messages now directly from the code-behind. Is there a better way that won't tie up the webpage?

I've considered possibly running an exe independently after a request is changed. Is there a way to shell a script that will handle the email, but continue forwad with the webpage load so the shelled script runs independently from the code-behind of the page?

解决方案

You might consider queuing the emails in a database table or a text file that is read by a dedicated service.

Writing the email to the database or text file will be quick, and the service only needs to check for changes every few minutes.

Problem would be you can't notify the user that the email didn't send, though you would have the same problem trying to shell execute another program.

这篇关于来自网络的电子邮件,不绑网页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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