Closed choulepoka closed 3 months ago
Hi @choulepoka, thank you for bringing this to our attention. If I recall correctly, you are using the LaunchDarkly iOS SDK and not just the event-source. @keelerm84 recently updated the logging implementation in the iOS SDK to use os_log which has better filtering capabilities. Would us bringing this change into the swift-eventsource meet your needs? We will have to investigate to see if that will work well with pure swift consumers of this event-source.
I have logged a story for tracking this: SC-245493
@tanderson-ld If you are using OSLog
, we would need an exposeed public setter so that we can set the value of the OSLog to .disabled
. That would would probably work if both framework actually expose something like that.
@choulepoka, we have released version swift-eventsource 3.3.0 which supports setting LDEventSource.Config.logger. We are in the process of updating the iOS SDK to pass it's logger in to the event source when it is created so that one logger is used for both. That PR is here. Leaving this issue open since I think you are looking for this change in the iOS SDK and not just in this swift-eventsource repo.
We're still working to get the iOS SDK update out that includes the fix for the iOS SDK itself.
This is now resolved in the iOS Client SDK v9.8.1
Is your feature request related to a problem? Please describe.
Yes. The logging of the LaunchDarkly iOS Client is verbose. When debugging, it is not uncommon to get hundreds of debugging statement in the console, with no easy to disable them.
Describe the solution you'd like
Create a way to disable logging, and optionally have the LaunchDarkly iOS Client configure it to match. Ideally somethings like:
Logs.logger = .disabled
Describe alternatives you've considered
Logs
class, but since it is not an objective-c class, it cannot be swizzledAdditional context
Not that I can see.