Added gzip support. Added logging to console