added proper signal handling for email service
Merge branch 'test'