Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.1.16
-
None
-
None
Description
If an installhook fails in the prepare phase, the processor internally changes the phase and then re-executes. it would be cleaner if the package installer controls the phases. this also avoids a cast to an impl:
try { hook.getHook().execute(context); } catch (PackageException e) { // abort processing only for prepare phase if (context.getPhase() == InstallContext.Phase.PREPARE) { log.warn("Hook " + hook.name +" threw package exception. Prepare aborted.", e); 153: ((InstallContextImpl) context).setPhase(InstallContext.Phase.PREPARE_FAILED); execute(context); return false; } log.warn("Hook " + hook.name +" threw package exception. Ignored", e); } catch (Throwable e) {