We really should be doing this elsewhere; we should centralize the logging configuration, and we definitely don't want to do the config every time this function is called. @ritesh277coe has a pull request that's trying to do that; I'll address that and then we can use whatever solution we decide upon there.