fixed some issue regarding htttp and logging