Community
Participate
Working Groups
From an email: There seems to be a race between AJDT and m2eclipse at startup which is causing a deadlock on the splash screen. See attached thread dump. This happens when I have some entities from a roo project open which has AJDT and m2eclipse support enabled and restart.
Created attachment 137685 [details] Thread dump of deadlock
Eyeballing that part of the AJDT code right now, it seems that this problem occurs only when JDT weaving is disabled. It's a bunch of code that I've always wanted to get rid of, but can't in order to make sure that AJDT still functions reasonably well with JDT weaving disabled. I'm trying right now to see if I can avoid this race condition.
Not able to reproduce this. However, I notice that the log you sent shows that the deadlock occurs when both AJDT and m2eclipse are in their startup methods. I could put some logic in AJDT's start method that it should wait for m2eclispe to start first (if it is present in the workspace).
It is straight forward to ensure that the m2eclipse bundle is started before AJDT bundle is. However, perhaps this should go in a separate thread because OSGi will throw a BundleException if a BundleActivator's time to start is too long. I don't want AJDT's time to start depending on m2eclipse's time to start.
OK...made a change to AspectJUIPlugin so that now AJCompilationUnitManager.INSTANCE.initCompilationUnits(AspectJPlugin.getWorkspace()); is called in a separate job. Also, before this is called, the job ensures that m2eclipse has finished its starting (if it exists). Going to wait to hear back from the reporter of this bug before closing.
Not reproducible after changes have been made.