implemented dependancy injection via xml,
introduced logging in main