Fix Akka shutdown for non OSGi system.