using shared pointers allowed us to get rid of this wasteful mutex. The old code used this mutex to prevent trying to shut down processing while in the middle of the process loop. That was problematic because it could result in deadlock. Now we don't need this because we're doing proper ref counting via shared pointers, and so we don't need this mutex, and the chance of deadlock is eliminated.