lib/mb/application.rb in motherbrain-1.2.0 vs lib/mb/application.rb in motherbrain-1.2.1
- old
+ new
@@ -61,9 +61,13 @@
# Run the application asynchronously (terminate after execution)
#
# @param [MB::Config] config
def run!(config)
Celluloid.boot
+ Celluloid.exception_handler do |ex|
+ log.fatal { "Application received unhandled exception: #{ex.class} - #{ex.message}" }
+ log.fatal { ex.backtrace.join("\n\t") }
+ end
log.info { "motherbrain starting..." }
setup
@instance = Application::SupervisionGroup.new(config)
end