Logging

Add basic support for logging