Added logging to sample application