Extra logging/debugging in place to solve threading issues