Community
Participate
Working Groups
Build ID: M20080911-1700 Steps To Reproduce: Our product (WebSphere Integration Developer 6.2) is based on Eclipse 3.4.1 and there is a regression issue that an exception is logged when deleting projects in workspace. For example, start WID, import the Hello World Part 2 sample (with the starter artifacts). After workspace build finishes, selects all 3 projects and deletes them (with file system content deleted as well). The following will be logged: !ENTRY org.eclipse.jdt.launching 4 4 2008-11-21 10:43:11.156 !MESSAGE HelloService does not exist !STACK 1 Java Model Exception: Java Model Status [HelloService does not exist] at org.eclipse.jdt.internal.core.JavaElement.newNotPresentException(Unknown Source) at org.eclipse.jdt.internal.core.JavaModelManager.getPerProjectInfoCheckExistence(Unknown Source) at org.eclipse.jdt.internal.core.JavaProject.getPerProjectInfo(Unknown Source) at org.eclipse.jdt.internal.core.JavaProject.getRawClasspath(Unknown Source) at org.eclipse.jdt.internal.launching.LaunchingPlugin.resourceChanged(Unknown Source) at org.eclipse.core.internal.events.NotificationManager$2.run(Unknown Source) at org.eclipse.core.runtime.SafeRunner.run(Unknown Source) at org.eclipse.core.internal.events.NotificationManager.notify(Unknown Source) at org.eclipse.core.internal.events.NotificationManager.broadcastChanges(Unknown Source) at org.eclipse.core.internal.resources.Workspace.broadcastBuildEvent(Unknown Source) at org.eclipse.core.internal.events.AutoBuildJob.doBuild(Unknown Source) at org.eclipse.core.internal.events.AutoBuildJob.run(Unknown Source) at org.eclipse.core.internal.jobs.Worker.run(Unknown Source) !SUBENTRY 1 org.eclipse.jdt.core 4 969 2008-11-21 10:43:11.156 !MESSAGE HelloService does not exist More information: Please contact us to have the dev environment for investigation.
We have made initial contact: -------------------------------------- Re: Java Model Exception: Java Model Status Jerome Lanneluc to: Darin Wright 11/21/2008 03:44 AM Darin, It looks like the LaunchingPlugin is attempting to retrieve the raw classpath of a Java project that no longer exists. Does this ring any bell? Jerome Chengbin Feng 21/11/2008 04:32 AM To Jerome Lanneluc Subject Java Model Exception: Java Model Status Hi Jerome, Your name is referred as the guru for Java model (by colleague, Olivier Thomann, here in Ottawa). The product I am working on, WebSphere Integration Developer (a.k.a. WID), encountered a regression issue lately, and we like your hint/help finding out the root cause ASAP, as our GM build will be in the next few days. Here is the scenario: - there are 50+ projects in the workspace - after the workspace build completes, all projects are selected together, and deleted (with file system content deleted as well) - intermittently (about 1 out of 4 times), the following exception is logged in .log file !ENTRY org.eclipse.jdt.launching 4 4 2008-11-19 16:48:12.718 !MESSAGE OPLibrary does not exist !STACK 1 Java Model Exception: Java Model Status [OPLibrary does not exist] at org.eclipse.jdt.internal.core.JavaElement.newNotPresentException(JavaElement.java:491) at org.eclipse.jdt.internal.core.JavaModelManager.getPerProjectInfoCheckExistence(JavaModelManager.java:1941) at org.eclipse.jdt.internal.core.JavaProject.getPerProjectInfo(JavaProject.java:1756) at org.eclipse.jdt.internal.core.JavaProject.getRawClasspath(JavaProject.java:1802) at org.eclipse.jdt.internal.launching.LaunchingPlugin.resourceChanged(LaunchingPlugin.java:780) at org.eclipse.core.internal.events.NotificationManager$2.run(NotificationManager.java:288) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.NotificationManager.notify(NotificationManager.java:282) at org.eclipse.core.internal.events.NotificationManager.broadcastChanges(NotificationManager.java:148) at org.eclipse.core.internal.resources.Workspace.broadcastBuildEvent(Workspace.java:297) at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:136) at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:238) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55) !SUBENTRY 1 org.eclipse.jdt.core 4 969 2008-11-19 16:48:12.875 !MESSAGE OPLibrary does not exist In order to provide you the actual environment to investigate, either "Remote Assistance" or NetMeeting will be used on my Thinkpad (assuming you are using Windows as well). Please let me know whether this is feasible, or you prefer other ways. Here is the version we are using: Eclipse Platform Version: 3.4.1.r341_v20080731-9I96EiDElYevwz-p1bP5z-NlAaP7vtX6Utotqsu Build id: M20080911-1700 Eclipse Java Development Tools Version: 3.4.1.r341_v20080709-0800-7o7tEAfEF_U5qyUgrb2HAp539P97 Build id: M20080709-0800 Best regards, Chengbin
When a project's classpath changes, JDT launching re-validates the classpath's referenced execution environment (J2SE-1.4, etc). If there is no installed JRE in the workspace that matches the project's referenced environment, a problem is created for the user. In this case, the project no longer exists and an exception is logged. There is no harm in the exception - it probably should not be logged. However, I do find it strange that the code even gets to the point of retrieving the classpath, since it first checks if the project exists: IJavaProject project = (IJavaProject) JavaCore.create(projectDelta.getResource()); if (project != null && project.exists()) { try { IClasspathEntry[] rawClasspath = project.getRawClasspath(); Jerome, do you know why project.exists() would pass in the case the project was deleted? I don't think the problem is critical, as this is just the side effect of the project not being present. No function is lost - just that an error is logged.
(In reply to comment #2) > However, I do find it strange that the code even gets to the point of > retrieving the classpath, since it first checks if the project exists: > > IJavaProject project = (IJavaProject) > JavaCore.create(projectDelta.getResource()); > if (project != null && project.exists()) { > try { > IClasspathEntry[] rawClasspath = project.getRawClasspath(); > > Jerome, do you know why project.exists() would pass in the case the project was > deleted? It might be a timing issue. The project still exists at the time you check for exists() and it no longer exists when getRawClasspath() is called. > I don't think the problem is critical, as this is just the side effect of the > project not being present. No function is lost - just that an error is logged. Reduced severity to normal.
Darin, are you still logging the error in this case ?
(In reply to comment #4) > Darin, are you still logging the error in this case ? No. The code that logs the error no longer exists. Bug 249932 has moved the EE processing to a compilation participant.
Closing as WORKSFORME. This no longer happens.
Verified for 3.6M5
Verified.