1
votes

For my Azure app I have a variety of scenarios for needing both scheduled and triggers jobs. Having researched both Azure WebJobs and Scheduler it appears I can accomplish this, but not in the best way possible.

My use cases will go something like:

  1. Weekly email blast (seems right up the alley for Scheduler)
  2. Event invites, dynamically timed based on event's time (I could have a job check every hour to see if any need to be sent? or at the event's creation create a Scheduled Job at the specific time, but what happens if the event changes?)
  3. Reminders based on #2 above (same issues/questions)
  4. Welcome emails (two versions, one if they complete a walkthrough and another if they don't: how to manage the timing of this?)

So basically I see how I can use Azure Scheduler to accomplish all of this, but not in the most efficient way. I would like to see if there's a way to manage Azure Scheduler along with some sort of triggered Jobs based on various criteria, controller by code. Does something like this exist?

Update

To add a bit more information to this,

I'm using Mandrill as these are transactional emails. The things that makes my use case not appropriate for Mailchimp or some automation platform is I have repeat templates I will be sending out (5ish) which are triggered dynamically based on my user's events and various configurations.

Examples:

1) New user registers. If they complete an on-boarding walkthrough they receive one type of welcome email, if they don't complete the on-boarding walkthrough within x minutes they receive an other type of welcome email.

2) An event is created by an admin. At that moment code will comb through all users to see who should be invited based on user's preferences, then send out personalized invites to each user.

2
so have you manage to solve this by using azure schedular?Learning-Overthinker-Confused

2 Answers

2
votes

Consider using the WebJobs SDK for some of this. For example, you could use an Azure Storage Queue to invoke your web job as event invites are created or modified in your application. You may want to have different queues that different web jobs are triggered from too. For example, one for invites, another for reminders, and one for welcome emails.

The weekly email blast may be a separate scheduled web job in your scenario.

2
votes

Putting my business cap on, it sounds like you have a need of something that will handle your email marketing/automation. Consider looking at 3rd party products that specialize in this, instead of hand-coding it. Mailchimp @ http://mailchimp.com comes to mind. They have a feature called Goal completion more info at: http://blog.mailchimp.com/new-trigger-emails-from-website-traffic/

Alternatively, a monitoring and automation service that my company provides (CloudMonix @ http://cloudmonix.com ) allows for automatically kicking off tasks based on some very custom criteria. CloudMonix knows nothing about email marketing, but it can kick-off a Web job or an Azure automation job if some SQL record appeared in the database or a metric published somewhere.