postgresql-monitor: another refactor, see comment. additional stats