Tidied up the syntax somewhat
Added configuration switches for disabling MongoDB and/or the Notifications API