Some refactoring + pagerduty