MailBee.NET Queue  

Introduction

About MailBee.NET Queue

MailBee.NET Queue is a background Windows service which allows you to improve performance and responsiveness of your applications which send large volumes of e-mails. Shipped with the source code making it possible to fine-tune it for your needs.

When needed

Usually, in order to send an e-mail, the application needs to make a connection to the mail server and then submit the e-mail to this server using SMTP protocol. This may take significant time. Also, many mail servers limit the maximum number of e-mails which can be accepted from a single IP address per second, hour and so on. If you have a large number of e-mails to be sent, you need to distribute the load over time in order to not violate the restrictions implied by the server.

For instance, if the server allows you to submit only 100 e-mails per hour and you have 1000 e-mails waiting, you cannot send them faster than in 10 hours.

With MailBee.NET Queue, your application can quickly write all the outgoing e-mails as .EML files in MailBee.NET Queue pickup folder, and proceed to other tasks or simply exit if it has no more work to do ("fire and forget" approach).

MailBee.NET Queue service which operates in the background monitors this folder and sends all the e-mails which appear there as .EML files. The entire process is not limited in time so that you can deliver very large volumes of e-mails even if your mail server is slow or too restrictive in terms of the allowed throughput.

You can also examine MailBee.NET Queue source code as a real-world example of using MailBee.NET Objects.

How to send e-mails to MailBee.NET Queue

You can use virtually any tool capable of producing MIME .EML files in order to feed MailBee.NET Queue. For instance, MailBee.NET Objects and MailBee Objects components provide extra methods to submit e-mails to MailBee.NET Queue rather than to an SMTP server (see Submitting e-mails to MailBee.NET Queue topic for details). You can even create .EML files manually or with your own scripts because MIME format is very simple if your e-mails are also simple (no attachments, just text).

Getting Started

Once installed, MailBee.NET Queue requires just a few things to be configured. First of all, you need a trial or permanent license key. MailBee.NET Queue uses MailBee.NET SMTP component for its work. In fact, the required license key is MailBee.NET SMTP license key. If you already have a license key for MailBee.NET SMTP component or for the entire MailBee.NET Objects bundle, you do not need any additional key for MailBee.NET Queue.

If you don't have a key, you can get a trial key during downloading MailBee.NET Queue. Or you can use "Get a Trial Key" tool in MailBee.NET Queue Start Menu. The second method may, however, not always work due to permission issues or (see Troubleshooting for details).

Also, MailBee.NET Queue needs to know which folder on the filesystem it will monitor and use as input (the pickup folder). Your applications will write .EML files to that folder.

Finally, you need to tell MailBee.NET Queue which SMTP relay server to use (and, optionally, SMTP username/password because most mail servers do not allow unauthenticated users to relay mail to external domains).

You can also enable logging all the activities into a log file - this can be of much help when troubleshooting.

How to configure

You can directly edit the XML config file (more flexible, more features available) or use MailBee.NET Queue Control Panel application (only basic features are supported but easy to use). You can combine both methods together because the Control Panel app does nothing but reads and writes the config file. For instance, use Control Panel app for basic configuration and edit the config file if you need to fine-tune something.

How to setup multiple configuration sets

If you need to have more than one active configuration (for instance, high-priority queue for urgent e-mails and low-priority queue for the rest), you can set up multiple MailBee.NET Queue services.

How to run

Once configured, you can start using MailBee.NET Queue. To start or stop the service, you can use MailBee.NET Queue Control Panel application, click Start/Stop/Restart buttons in MailBee.NET Queue Start Menu, run .bat files in the folder where

If getting "The service could not be started. Cannot start service MailBee.NET Queue on computer '.'. The service did not respond to the start or control request in a timely fashion." error, you may increase the timeout of starting MailBee.NET Queue Windows service to 60 seconds (from the default value of 30 seconds). Read more at A service does not start, and events 7000 and 7011 are logged in the Windows event log.

How to extend

MailBee.NET Queue ships with the source code (Visual Studio 2008 project, can be opened in modern Visual Studio versions as well). You can extend or modify it in any way to get even more advanced or specific functionality. For instance, you can setup delivery notification e-mails (DSNs), use events of underlying Smtp object to track progress of all operations, and much more.

You are allowed to redistribute the modified versions of MailBee.NET Queue, including rebranding. The only requirement: the license key must not be visible to end users or any other 3rd parties. To achieve this, you can hard-code the key in the application if you don't ship the source code, or save the key in the registry if you do.


Send feedback to AfterLogic

Copyright © 2011-2023 AfterLogic Corporation. All rights reserved.