add a send so `apply` can be called.  Fixes #13510

THIS IS A HUGE HACK.  Thor does not allow us to define public methods
without turning them in to "thor tasks".  That means we cannot subclass
the `apply` method and make it public, so we have to make the method
private and call `send` on it.
adding connection parameter to check_pending for migrations
adding missed change