more architecture improvements
added more logging