Added configuration to enable or disable logging