adding some logging statements