logging and error handling enhancements

 - added logger and debug log consistently on put and get
 - check for wrongly formatted data (no prefix type indicator) and throw
   error accordingly