IBM / go-sdk-core

The go-sdk-core repository contains core functionality required by Go code generated by the IBM OpenAPI SDK Generator.
Apache License 2.0
30 stars 24 forks source link

Minor improvement to logging implementation #90

Closed mkistler closed 3 years ago

mkistler commented 3 years ago

This PR makes a small improvement to the SetLoggingLevel method to only completely replace the current logger in the (unlikely) situation where the logger is a "custom" implementation of the Logger class, and not an SDKLoggerImpl. The prior behavior of replacing the logger just to set the logging level is not what most users would expect from a "Set" method.

In the next major release, we should add SetLogLevel to the Logger interface to make the behavior of SetLoggingLevel consistent for custom Logger implementations.

padamstx commented 3 years ago

Closing this PR as it was superceded by https://github.com/IBM/go-sdk-core/pull/91