move monitor to it's own module