phancox
Posts: 17
Joined: Sat Jun 24, 2006 11:03 am

Startup failure check and DefaultUncaughtExceptionHandler

I am having a problem with setDefaultUncaughtExceptionHandler(...) not working when the Java application is launched from AdvancedInstaller.

When the java application is launched from the command line, uncaught exceptions are caught and handled by the application's UncaughtExceptionHandler. When the application is launched by AdvancedInstaller the applications UncaughtExceptionHandler is not invoked even though tracing through the program shows it is set by Thread.setDefaultUncaughtExceptionHandler(...)

If I enable AdvancedInstaller's "Startup failure check" then the AdvancedInstaller dialogue box is displayed with the details of the uncaught exception.

It would seem that perhaps AdvancedInstaller is disabling or in some way preventing an existing DefaultUncaughtExceptionHandler but will insert its own if "Startup failure check" is enabled?

I'm not sure whether this behaviour has changed from previous versions? I thought our uncaught exception processing used to work but can't be sure as it always works in our eclipse development environment since we don't launch from AdvancedInstaller there.
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hello,

I'm not sure why you are encountering this behavior. Can you please send us a sample .jar file (included in an .AIP project) which reproduces the behavior to support at advancedinstaller dot com so we can investigate them?

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
phancox
Posts: 17
Joined: Sat Jun 24, 2006 11:03 am

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hi Daniel,

As requested, I have sent you a link where you can download the AI installation package and attached the associated .aip file.

REGARDS
Peter
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hello Peter,

Please give us some time to investigate them and we'll get back to you as soon as we have a conclusive answer.

Thank you for your patience and understanding.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
phancox
Posts: 17
Joined: Sat Jun 24, 2006 11:03 am

Re: Startup failure check and DefaultUncaughtExceptionHandle

Any news yet on what might be causing this?

THANKS
Peter
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hello Peter,

It seems this was caused by an Advanced Installer issue. I've sent you an email containing an implemented fix.

Let us know if this helped.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
phancox
Posts: 17
Joined: Sat Jun 24, 2006 11:03 am

Re: Startup failure check and DefaultUncaughtExceptionHandle

Thanks Daniel,

That appears to be OK but can't be sure as, in order to test the patch, I've had to partially rework a fix that we'd already implemented as a work-around. So everything is working for us but can't be sure whether it's entirely your patch that fixed it.

Presume the patch to the stubs will be part of all future releases?

REGARDS
Peter
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hello Peter,
Presume the patch to the stubs will be part of all future releases?
Yes, a fix will be included in next version of Advanced Installer.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Startup failure check and DefaultUncaughtExceptionHandle

Hello,

This was fixed in version 9.8 of Advanced Installer released on December 20, 2012.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”