Remove the MessageLoop::DestructionObserver from mojo bindings.

Mojo connection error handlers running during browser shutdown have been
a cause of several crashes due to the error handlers running after their
dependency (e.g. a KeyedService or a RenderProcessHost) has shut down.
From a brief survey of users of StrongBinding, none appear to perform
any tear-down that is necessary during process shutdown. Further, the
vast majority of threads (and thread pools) run for close to the life of
the process, so any these connection error handlers will generally only
be triggered during shutdown. Thus, in production this causes slower,
less-stable browser shutdowns without any real benefit.

Additionally, SequencedTaskRunner does not have a MessageLoop and is not
expected to support a similar destruction observer. Thus, to improve
compatibility with future support for running mojo bindings on
SequencedTaskRunners, this removes MessageLoop::DestructionObserver from
mojo bindings.

BUG=678155
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2633053002
Cr-Commit-Position: refs/heads/master@{#447085}


CrOS-Libchrome-Original-Commit: 14e09ca425d1ee9572f69d29cdd00cff1a1b2bfc
6 files changed
tree: e17ce010105e3719fc42b14da478204ea7fd6472
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/