This project is read-only.

Cloud Mail User Guide


  1. Download the latest release from and unzip the file
  2. Locate and run CloudMail.msi

Usage Instructions (Client Dll's)

  1. Add references to both CloudMail.dll and CloudMailShared.dll in your Azure project making sure that 'copy local' is set to true (you can find them in the c:\Program Files\StLR\CloudMail\ClientDlls\ folder).
  2. To send mail follow the example below where testmailqueue is the name of the queue and blob container to use and CloudMailStorageConnectionString is the storage account connection string. Make sure that these values match the settings in the relay configuration file.*
          using CloudMailShared;
          using Microsoft.WindowsAzure.ServiceRuntime;

          CloudMailClient cmc = new CloudMailClient(
          SerializableMailMessage msg = new SerializableMailMessage("",""){
                          Subject = "CloudMail Test",
                          Body = "This is a mail body",
                          IsBodyHtml = true };


Installation Instructions (Cloud Email Relay)

  1. Open a command prompt and enter the following
    1. cd "C:\Program Files\StLR\CloudMail\CloudMailRelay"
    2. "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe" CloudEmailRelay.exe
    3. notepad CloudEmailRelay.exe.config
  2. Edit and save the configuration file (see the next section)
  3. Back in the command prompt type the following
    1. services.msc
  4. In the Service Manager
    1. Find the 'Cloud Email Relay' service, right click and select Properties
    2. Change the Startup type to automatic and then select the 'Log On' tab and configure the appropriate credentials for your network
    3. Press the Ok button
  5. In the service manager Right click on the service and select start

Configuration Settings

Setting Name Description
AzureStorageUrl The connection string to the Azure storage account that you want to use
MailQueueName The name of the Azure Queue and Blob Container
PollIntervalSeconds How often the relay checks for new mail on the queue
SmtpServer Your SMPT server
SmtpPort The SMTP port (default 25)
SmtpEnableSsl Use SSL
SmtpUsername Leave blank to use default credentials
SmptPassword Ignored if SmtpUsername is blank
UseDevFabric If this is set to true the AzureStorageUrl is ignored and the Development Fabric is used
GenerateDebugMessages This should be False unless you have a problem with the service. Set to True for additional diagnostics in the Windows Event Log.


  1. Where are the log files?
    1. All messages are written to the Windows Event Log
  2. My service starts ok but never sends any mail, any ideas why?
    1. Make sure you have set up the proxy config properly as the call into the Azure SDK seems to hang if it can't get to the service.
  3. Can I see generated emails?
    1. Sure. Try a tool like
  4. Do I need to create the blob and queue containers?
    1. No. The client or the relay will create them for you (it doesn't matter which one starts first).

Build Instructions

  • Before you start you will need the - Visual Studio 2010 RC and the Azure Platform SDK
  • Download the source
  • Open the CloudEmailRelay solution

Last edited Mar 29, 2010 at 5:09 PM by StLuisRey, version 19


No comments yet.