DEVIDM-81

Fixed bean injection issue.
Fixed wierd logging.
Added logging configuration.
Moved some things around to make more sense.
Fixed error handling and other random and less random fixes.