Initial stab at adding logging

It's not used anywhere, but it has the basic abstraction in place.