Community
Participate
Working Groups
org.eclipse.virgo.kernel.core.StartupTracker has a private Runnable class StartupTrackingRunnable. In turn, this has a private method logEvent(...) which throws exceptions sometimes because the context (this.context in the Runnable instance) becomes invalid (in the process of shutting down for example). There is no sure-fire cure for this (except to somehow guarantee early logging first before we shutdown), but this bug is to make this code tolerate the errors rather than barfing all over the console.
I'm looking at this one already.
Made changes to startupTracker to isolate the running thread from changes, and to make the Runnable a static inner class. Rather than getting the eventAdmin and eventLogger every time, the services are obtained early and only ungot when the startupTracker stops. This might fail, but is guarded to ignore failures which might occur during clean-up. One of the startupTracker tests is re-enabled because the wait-time is not fixed at one hour (as the @Ignore comment claims) and the test passes easily in the new incarnation. This bugzilla will be closed when the fix is reviewed.
Done.