Notifications Rewrite

Asynchronous notifications with improved support for message customization (subject and body, multi-lingual).

Still to do:
- [x] subscription system based on relationships
- [x] update a plugin as example of how to use API
- [x] more unit tests
- [x] coding standard updates
- [x] inject dependencies
- [x] use internal vars rather than $CONFIG 
- [ ] look into using a separate table for the queue