Bug 149915

Summary: Eclipse fails to open XML files
Product: [Fedora] Fedora Reporter: Ziga Mahkovec <ziga.mahkovec>
Component: eclipseAssignee: eclipse-bugs
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Fixed In Version: 3.1.0_fc-0.M6.15 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-05-12 18:06:01 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Description Flags
Sample XML file
Stack trace none

Description Ziga Mahkovec 2005-02-28 19:54:31 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/20050224 Firefox/1.0.1 Fedora/1.0.1-1.3.1

Description of problem:
When opening XML files with a DOCTYPE (e.g. the attached web application descriptor), an exception is thrown by Eclipse.

Version-Release number of selected component (if applicable):
eclipse-platform-3.1.0_fc-0.M5.6, libgcj4-4.0.0-0.27

How reproducible:

Steps to Reproduce:
1. Add the attached web.xml to a project
2. Try to open the file.

Actual Results:  An error is shown: Error retrieving content description for resource: /project/web.xml
I'm also attaching the stack trace.

Expected Results:  The file should be opened for editing.

Additional info:

It works fine if I remove the gnu.gcj.precompiled.db.path
argument (in /usr/bin/eclipse), so this might be an ahead-of-time compilation issue.

Comment 1 Ziga Mahkovec 2005-02-28 19:56:49 UTC
Created attachment 111494 [details]
Sample XML file

Comment 2 Ziga Mahkovec 2005-02-28 19:57:26 UTC
Created attachment 111495 [details]
Stack trace

Comment 3 Phil Muldoon 2005-04-05 19:48:33 UTC
We see something similar with {plugin|build|feature}.xml as in 151919. It
actually will open the file on successive attempts after the first failure. Is
this the same thing you see on web.xml?

Comment 4 Ziga Mahkovec 2005-04-06 09:32:41 UTC
Interestingly, I do get the same exception as in bug 151919 when opening the
file for the first time.  But I can't get it to open on successive attempts, I
just get the following error:

"Error retrieving content description for resource .../web.xml"
(and the attached stack trace gets logged to <workspace>/.metadata/.log)

So I'm not sure if these errors are related.  The only workaround I found in
this case was to actually edit the XML file and remove the doctype (note that
the {plugin,feature}.xml files don't contain doctypes).  From the stack trace it
looks like Eclipse is trying to get the content type of the document.  This
results in parsing the XML file, which (when run in native mode) fails when
resolving the doctype entity.

I was thinking it would be useful if one could somehow disable the use of
specific native classes/packages in runtime.  A similar technique is often used
to debug JIT problems in IBM's JVM (the JITC_COMPILEOPT=SKIP option as described
in [1]).  E.g., by trying different variations of:


it would then be possible to isolate the class or package that's failing in
native mode.

[1] http://www-128.ibm.com/developerworks/eserver/library/es-JITDiag.html

Comment 5 Ziga Mahkovec 2005-04-20 23:46:18 UTC
Still seeing this with eclipse-jdt-3.1.0_fc-0.M6.7 / libgcj-4.0.0-0.42.  Both
the MalformedURLException for web.xml files and the ClassCastException for
plugin.xml files.

Which is strange, because this worked in eclipse-3.1.0_fc-0.M6.1 (which Andrew
posted on the fedora-devel-java list).

Comment 6 Andrew Overholt 2005-05-09 18:07:22 UTC
I can open the xml file now (gcc* >= 4.0.0-4).  Let me look further into 151919.

Comment 7 Andrew Overholt 2005-05-12 17:39:49 UTC
Can we close this now, Ziga?  151919 is a larger issue and unrelated.

Comment 8 Ziga Mahkovec 2005-05-12 18:06:01 UTC
Works fine now with: