added email log and metrics email rake task