Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 342120

Summary: Unable to start Eclipse: BundleException on startup (error while loading IProxyService)
Product: [Eclipse Project] Platform Reporter: Julien HENRY <julien.henry>
Component: TeamAssignee: Platform Team Inbox <platform-team-inbox>
Status: CLOSED WONTFIX QA Contact:
Severity: major    
Priority: P3 CC: dak2009, pwebster, remy.suen
Version: 3.7   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard: stalebug
Attachments:
Description Flags
Error stack
none
Eclipse log that show both error during shutdown and error during next start none

Description Julien HENRY CLA 2011-04-07 05:02:42 EDT
Build Identifier: 3.7.0.v20110110

I have installed several plugins on a fresh Eclipse 3.7 M6. Eclipse used to ask for master password in the middle of splash screen progress bar. 
Last thing I remember to do is installing several m2eclipse connectors from m2e marketplace. Then I have restarted Eclipse and everything seemed ok. Then I tried to access Eclipse marketplace. A prompt asked for my proxy login/password (I am in a corporate environnement), then the marketplace appeared and tried to retrieve list of plugins. At that point Eclipse was stuck. I was not able to cancel Marketplace loading process nor close it so I killed Eclipse.
Now every time I start Eclipse I have an error in the log. Eclipse GUI appears but is not usable because the splash screen is still present and modal.
I noticed that Eclipse didn't asked for master password during startup.

Reproducible: Always
Comment 1 Julien HENRY CLA 2011-04-07 05:03:24 EDT
Created attachment 192706 [details]
Error stack
Comment 2 Julien HENRY CLA 2011-04-07 05:21:17 EDT
Deleting the workspace .metadata folder fixed the issue (but of course all my settings are lost). I kept the old folder so tell me if you need it.
Comment 3 Julien HENRY CLA 2011-04-07 07:55:57 EDT
For some reason, Eclipse crashed again and I was forced to kill it. As a result my workspace is broken again and I have a very similar stack (IProxyChangeListener instead of IProxyService):

!SESSION 2011-04-07 13:48:39.137 -----------------------------------------------
eclipse.buildId=I20110310-1119
java.version=1.6.0_24
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=fr_FR
Framework arguments:  -product org.eclipse.epp.package.jee.product
Command-line arguments:  -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.jee.product

!ENTRY org.eclipse.core.resources 2 10035 2011-04-07 13:48:56.196
!MESSAGE The workspace exited with unsaved changes in the previous session; refreshing workspace to recover changes.

!ENTRY org.eclipse.osgi 2 0 2011-04-07 13:49:04.615
!MESSAGE While loading class "org.eclipse.core.net.proxy.IProxyChangeListener", thread "Thread[main,6,main]" timed out waiting (5005ms) for thread "Thread[Worker-0,5,main]" to finish starting bundle "org.eclipse.core.net_1.2.100.I20110208-0800 [78]". To avoid deadlock, thread "Thread[main,6,main]" is proceeding but "org.eclipse.core.net.proxy.IProxyChangeListener" may not be fully initialized.
!STACK 0
org.osgi.framework.BundleException: State change in progress for bundle "reference:file:plugins/org.eclipse.core.net_1.2.100.I20110208-0800.jar" by thread "Worker-0".
	at org.eclipse.osgi.framework.internal.core.AbstractBundle.beginStateChange(AbstractBundle.java:1087)
	at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:297)
...
Comment 4 Remy Suen CLA 2011-04-07 07:58:22 EDT
(In reply to comment #3)
> For some reason, Eclipse crashed again and I was forced to kill it.

If it crashed already why do you need to kill its process? Did you mean it got into a frozen state?
Comment 5 Julien HENRY CLA 2011-04-07 08:15:40 EDT
Yes, sorry. I mean UI was frozen. I was playing with screen configuration on Linux when it happened so this is probably not an Eclipse issue. I killed it with > killall java

I don't blame Eclipse for the UI freeze, but I blame it for breaking the workspace in a way that prevent to start it again.
Comment 6 Julien HENRY CLA 2011-04-07 11:06:44 EDT
It happened again. This time it was not the consequence of killing Eclipse, but simply a normal restart after installing a new m2e connector... I'm good to start with a new workspace again.

I will attach the log as there was an error during shutdown, and maybe this is what caused the issue during next startup.

(snip)
!ENTRY org.eclipse.wst.server.core 4 0 2011-04-07 17:00:14.744
!MESSAGE Error during shutdown
!STACK 0
org.eclipse.core.runtime.AssertionFailedException: null argument:
	at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:85)
	at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:73)
	at org.eclipse.core.internal.events.ResourceChangeListenerList.remove(ResourceChangeListenerList.java:146)
Comment 7 Julien HENRY CLA 2011-04-07 11:07:56 EDT
Created attachment 192753 [details]
Eclipse log that show both error during shutdown and error during next start
Comment 8 Remy Suen CLA 2011-04-07 11:10:52 EDT
(In reply to comment #6)
> !ENTRY org.eclipse.wst.server.core 4 0 2011-04-07 17:00:14.744
> !MESSAGE Error during shutdown
> !STACK 0
> org.eclipse.core.runtime.AssertionFailedException: null argument:
>     at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:85)
>     at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:73)
>     at
> org.eclipse.core.internal.events.ResourceChangeListenerList.remove(ResourceChangeListenerList.java:146)

Other people have encountered this before. See bug 333775.
Comment 9 Julien HENRY CLA 2011-07-25 11:22:26 EDT
I still face this bug. Nearly each time after Eclipse crash, I can't restart it. I spend time to compare a clean workspace with the old one to finally found that the problem come from .metadata/.plugins/org.eclipse.core.resources/.snap file. Removing this file allow to start Eclipse again, but all projects are removed from the workspace (I have to import them).
The only difference with starting with a fresh new workspace is I don't loose my settings.

What is the purpose of the .snap file? I saw a lot of bug reports concerning similar issues (for example Bug 345553 that was closed but not fixed).
Comment 10 Lars Vogel CLA 2019-11-14 03:16:26 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.