me-ventures / microservice-toolkit

MIT License
3 stars 1 forks source link

Logger breaks when no logger is in config #2

Closed MaikelH closed 7 years ago

MaikelH commented 8 years ago

When there is no logger object in config it will break the logger since the instance will not be initialized. This will in turn break any attemp of logging ( which should be avoided).

IMO there are 2 different solutions:

  1. Always initialize logging. Logging is now not initialized when there is no logging object. It can initialize with default options.
  2. Log an error when logging is being used without an instance being defined.
EvaLok commented 7 years ago

should go with 1 so it's backward compatible