Updated logging channel to use a wrapper for later early-filter optimizations. Various bug fixes and optimizations.