Skip to content

Enhance error reporting on startup #415

@pierre

Description

@pierre

https://github.com/killbill/killbill-admin-ui/blob/master/app/helpers/kaui/exception_helper.rb#L5 doesn't always propagate the exception to the user.

For instance, specifying KAUI_CONFIG_DAO_URL=jdbc:mariadb://db:3306/kaui, it throws:

RuntimeError (#<ActiveRecord::StatementInvalid: ActiveRecord::JDBCError: Didn't get a connection. Wrong URL?>):
  
kaui (3.0.4) app/controllers/kaui/sessions_controller.rb:15:in `block in SessionsController'
org/jruby/RubyBasicObject.java:2620:in `instance_exec'
activesupport (7.0.8.5) lib/active_support/rescuable.rb:116:in `block in handler_for_rescue'
activesupport (7.0.8.5) lib/active_support/rescuable.rb:92:in `rescue_with_handler'
activesupport (7.0.8.5) lib/active_support/rescuable.rb:165:in `rescue_with_handler'
actionpack (7.0.8.5) lib/action_controller/metal/rescue.rb:26:in `process_action'
actionpack (7.0.8.5) lib/action_controller/metal/instrumentation.rb:67:in `block in process_action'
activesupport (7.0.8.5) lib/active_support/notifications.rb:206:in `block in instrument'
activesupport (7.0.8.5) lib/active_support/notifications/instrumenter.rb:24:in `instrument'
activesupport (7.0.8.5) lib/active_support/notifications.rb:206:in `instrument'
actionpack (7.0.8.5) lib/action_controller/metal/instrumentation.rb:66:in `process_action'
actionpack (7.0.8.5) lib/action_controller/metal/params_wrapper.rb:259:in `process_action'
activerecord (7.0.8.5) lib/active_record/railties/controller_runtime.rb:27:in `process_action'
actionpack (7.0.8.5) lib/abstract_controller/base.rb:151:in `process'
actionview (7.0.8.5) lib/action_view/rendering.rb:39:in `process'

but the UI doesn't show anything useful.

  • Fix handling of that specific error above
  • Regardless of the error, always log the full error in the logs for ease of debugging

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions