-
Notifications
You must be signed in to change notification settings - Fork 1.7k
LoggingAPI
pion-WebRTC currently uses fmt.Println
sprinkled through out the code base. For the most grievous errors we always print them, for warnings we usually comment them out (and then developers re-enable them locally)
This is a frustrating way to work for developers, and doesn't work at all for users. Developers just add fmt.Println
messages throughout the code base. Users have it even worse, when they have an issue they don't know where to go next to debug their issue. We also have bug reports where a user just sees a message, but not sure what is happening. It turns out the message is informational and we debug.
- Give pion-WebRTC maintainers a quicker way to debug/trace, without having to edit existing code
- Allow pion-WebRTC embedders to capture logs, and store them in format that matches existing system (JSON etc...)
- Allow logging on different levels/components (Trace+ICE) (Warning+SDP)
I am hesitant to import an existing logging solution. It would be nice if we didn't import any non-Pion libraries, I would like to allow embedders to choose anything they want, and not steer them in a certain way.
Also it is nice that we aren't dependent on other people making changes we don't agree with/having to track other projects development. It seems like a lot of Open Source projects that just use a bunch of libraries fall into a trap of having to just follow everyone's release schedule.
Sign up for the Golang Slack and join the #pion channel for discussions and support
If you need commercial support/don't want to use public methods you can contact us at [email protected]