Moved execution into main method and updated some logging