Fixed Monitoring bugs and slight refactor.