Closed woutslabbinck closed 2 years ago
@woutslabbinck @ddvlanck Is it an idea to merge the functionalities of https://github.com/TREEcg/event-stream-client/pull/55/files#diff-2bef2fd99182122dea7001da7d9811efdcafb74c68bfa40d0bece04613aa5554 and https://github.com/TREEcg/types/blob/main/lib/utils/Logger.ts (the Logger utility inside treecg/types)? This way the treecg/types logger could be used everywhere.
@woutslabbinck @ddvlanck Is it an idea to merge the functionalities of https://github.com/TREEcg/event-stream-client/pull/55/files#diff-2bef2fd99182122dea7001da7d9811efdcafb74c68bfa40d0bece04613aa5554 and https://github.com/TREEcg/types/blob/main/lib/utils/Logger.ts (the Logger utility inside treecg/types)? This way the treecg/types logger could be used everywhere.
That would make sense. That way, the LDES event stream client would not need its own logger file
@brechtvdv Is it okay to merge for you?
Why is a logger provided inside @treecg/types and not in a separate repo?
This is stale → what’s the progress on this?
This branch made the logging functionality of the LDES client configurable. Therefore, it uses the logger from @treecg/types. Brecht asked why this is implemented there and not a separate repository. I just used the logger that was already available in @treecg/types (created by Dwight and modified by myself). I can make a new repository just for the logging functionality within @treecg, but I don't think it would make that much difference (might even be worse as some projects, like bucketizer, were already using that logger)
It is now possible with option
loggingLevel error
to only print error messages an not print the info messages by the default. The format has also changed a tiny bit, but if necessary it can be reverted.Current format:
New format:
where the info is green