added logging
better log messages