Uploaded image for project: 'Pivot'
  1. Pivot
  2. PIVOT-916

Replace DesktopApplicationContext.displayException calls with ApplicationContext.handleUncaughtException

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments


    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0.4, 2.1, 2.0.5
    • Component/s: None
    • Labels:


      There should be consistent way to handle uncaught exceptions in Pivot applications.

      However uncaught exceptions thrown in DesktopApplicationContext class (for example in application.startup ) are handled using private static method displayException, which displays dialog and its logic cannot be overriden.

      May be ApplicationContext.handleUncaughtException could be made protected and calls to DesktopApplicationContext.displayException could be replaced by ApplicationContext.handleUncaughtException. And possibly Application.Adapter could implement UncaughtExceptionHandler - so current DesktopApplicationContext.displayException logic could be moved to new Application.Adapter.uncaughtExceptionThrown method.

      This should enable to override uncaught exception handling globally in pivot applications.


      We deploy Pivot app using Java Web Start. Users have by default disabled Java Console (and they are not familiar with it). We want to display custom dialog to handle uncaught exceptions displaying full stack trace and with possiblity to report exception to help desk.
      I think, in current implementation it is not possible to override handling of uncaught exceptions thrown during application init and other specific situations.


        1. 916.diff
          2 kB
          Roger Lee Whitcomb
        2. app_exception.patch
          4 kB
          Roger Lee Whitcomb
        3. ScriptApplication.java.patch
          1 kB
          Sandro Martini
        4. trunk_wtk.patch
          6 kB
          Karel Hübl
        5. wtk_test.zip
          7 kB
          Karel Hübl



            • Assignee:
              rwhitcomb Roger Lee Whitcomb
              kaja78 Karel Hübl


              • Created:

                Issue deployment