This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 12744 - Sax Exception attempting to Execute a JSP, followed by crash.
Summary: Sax Exception attempting to Execute a JSP, followed by crash.
Status: CLOSED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: Other Windows 95/98
: P3 blocker (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-06-11 14:51 UTC by cbarham
Modified: 2003-07-02 08:30 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description cbarham 2001-06-11 14:51:00 UTC
DESCRIPTION
-----------
Sax Exception attempting to Execute a JSP:
"org.xml.sax.SAXParseException: The entity name must immediately follow the '&' 
in the entity reference."
Which is immediatly followed by complete shutdown of NetBeans.

STEPS TO REPRODUCE
------------------
Execute the following JSP within netbeans:

<%@page contentType="text/html"%>
<html>
<head>
<basefont face="Arial">
<title>JSP Page</title></head>
<body>

<table border="1" cellspacing="5" cellpadding="5">
<tr>
<th>Variable</td>
<th>Value</td>
</tr>

<tr>
<td>Request protocol</td>
<td>
<%
// protocol
out.println(request.getProtocol());
%>
</td>
</tr>

<tr>
<td>Hostname</td>
<td>
<%
// server name
out.println(request.getServerName());
%>
</td>
</tr>

<tr>
<td>Port</td>
<td>
<%
// server port
out.println(request.getServerPort());
%>
</td>
</tr>

<tr>
<td>Remote username</td>
<td>
<%
// username if using HTTP authentication
// null if no authentication
out.println(request.getRemoteUser());
%>
</td>
</tr>

<tr>
<td>Remote address</td>
<td>
<%
// get IP address of client
out.println(request.getRemoteAddr());
%>
</td>
</tr>

<tr>
<td>Client browser</td>
<td>
<%
// client browser identification
out.println(request.getHeader("User-Agent"));
%>
</td>
</tr>

<tr>
<td>Server Software</td>
<td>
<%
// server software
out.println(getServletContext().getServerInfo() );
%>
</td>
</tr>

</table>
</body>
</html>

Expected results
----------------
Web page describing the client request/server environment

Other platforms
---------------
Error does not occur in Forte 2 Community Edition, (i.e. correct behaviour 
observed in that environment.)

LOG entries/Stack Trace
-----------------------
The System Log contains the following entries and Stack Trace:


-------------------------------------------------------------------------------
>Log Session: 11 June 2001 14:18:17 o'clock BST
>System Info: 
  Product Version       = NetBeans IDE 3.2 (Build 39)
  IDE Versioning        = IDE/1 spec=1.2.1 impl=39
  Operating System      = Windows 98 version 4.10 running on x86
  Java; VM; Vendor      = 1.3.0_02; Java HotSpot(TM) Client VM 1.3.0_02; Sun 
Microsystems Inc.
  Java Home             = C:\JDK1.3\JRE
  System Locale         = en_GB
  Home Dir; Current Dir = C:\WINDOWS; C:\netbeans\bin
  IDE Install; User Dir = C:\NETBEANS; G:\Application Services\DBA, Notes & Int-
net\Java2\Projects
  CLASSPATH             = G:\Application Services\DBA, Notes & Int-net\Java2
\Projects\lib\ext\logger.jar;C:\NETBEANS\lib\patches\openide-
compat.jar;C:\NETBEANS\lib\core.jar;C:\NETBEANS\lib\openide-
fs.jar;C:\NETBEANS\lib\openide-nodes.jar;C:\NETBEANS\lib\openide-
util.jar;C:\NETBEANS\lib\openide.jar;C:\NETBEANS\lib\ext\jaxp.jar;C:\NETBEANS\li
b\ext\jh.jar;C:\NETBEANS\lib\ext\jpython.jar;C:\NETBEANS\lib\ext\parser.jar;C:\N
ETBEANS\lib\ext\regexp.jar;C:\NETBEANS\lib\ext\rmi-
ext.jar;C:\NETBEANS\lib\ext\sax2.jar;C:\NETBEANS\lib\ext\servlet.jar;C:\NETBEANS
\lib\ext\xerces.jar;C:\jdk1.3\lib\dt.jar;C:\jdk1.3\lib\tools.jar
-------------------------------------------------------------------------------
[INFO] Loaded modules: org.netbeans.core/1 (1.0/unspec); 
org.apache.tools.ant.module/2 (2.2.1/39); org.netbeans.modules.autoupdate/1 
(1.6.1/39); org.netbeans.modules.clazz/1 (1.6.1/39); 
org.netbeans.modules.debugger.core/2 (2.0.1/39); org.netbeans.modules.applet/1 
(1.6.1/39); org.netbeans.modules.debugger.debug/1 (1.8.1/39); 
org.netbeans.modules.debugger.jpda/1 (1.8.1/39); org.netbeans.modules.editor/1 
(1.7.1/39); org.netbeans.modules.html/1 (1.7.1/39); 
org.netbeans.modules.httpserver/1 (1.6.1/39); org.netbeans.modules.extbrowser/1 
(0.2.1/39); org.netbeans.modules.icebrowser/1 (1.6.1/39); 
org.netbeans.modules.image/1 (1.6.1/39); org.netbeans.modules.jarpackager/2 
(1.6.1/39); org.netbeans.modules.java/1 (1.6.1/39); 
org.netbeans.modules.beans/1 (1.6.1/39); org.netbeans.modules.form/2 
(1.6.1/39); org.netbeans.modules.javadoc/1 (1.6.1/39); 
org.netbeans.modules.jndi/1 (1.4/39); org.netbeans.modules.objectbrowser/1 
(1.6.1/39); org.netbeans.modules.projects/1 (1.6.1/39); 
org.netbeans.modules.properties/1 (1.6.1/39); org.netbeans.modules.i18n/1 
(1.7/39); org.netbeans.modules.i18n.form/2 (1.7/39); 
org.netbeans.modules.properties.syntax/1 (1.6.1/39); 
org.netbeans.modules.text/1 (1.6.1/39); org.netbeans.modules.usersguide/1 
(1.7.1/39); org.netbeans.modules.web.core/1 (1.2.1/39); 
org.netbeans.modules.web.core.syntax/1 (1.2.1/39); org.openidex.util/1 
(1.7.1/39); org.netbeans.modules.scripting/1 (1.3.1/39); 
org.netbeans.modules.utilities/1 (1.6.1/39); 
org.netbeans.modules.apisupport.lite/1 (0.1.1/39); org.netbeans.modules.rmi/1 
(1.3.1/39); org.netbeans.modules.vcscore/1 (1.4.1/39); 
org.netbeans.modules.cvsclient/1 (1.3.1/39); 
org.netbeans.modules.vcs.advanced/1 (1.4.1/39); 
org.netbeans.modules.vcs.cmdline/1 (1.7.1/39); org.netbeans.modules.junit/2 
(2.2/8); org.netbeans.modules.logger/1 (1.0/22-dec-00); 
org.netbeans.modules.makefile/1 (1.3/for-michael-juergens-26-feb-01)
path="" :jsp: init
WARNING: C:\JDK1.3\JRE\classes cannot be opened
org.openide.filesystems.FSException: Root C:\JDK1.3\JRE\classes does not exist.
[IDE-Exec] Executing:
0 .= C:\JDK1.3\JRE\bin\java
1 .= -cp
2 .= G:\Application Services\DBA, Notes & Int-net\Java2
\Projects\system;C:\NETBEANS\system;C:\netbeans\beans\TimerBean.jar;G:\Applicati
on Services\DBA, Notes & Int-net\Java2\Projects\sampledir;C:\jdk1.3\junit3.7
\junit.jar;C:\j2sdkee1.3\lib\j2ee.jar;G:\Application Services\DBA, Notes & Int-
net\Java2\toolbox\Gif89aencoder\lib\classes.jar;G:\Application Services\DBA, 
Notes & Int-net\Java2\toolbox\JFreeChart\jfreechart.jar;G:\Application 
Services\DBA, Notes & Int-net\Java2
\toolbox\PngGraphicsLibrary\png.jar;G:\Application Services\DBA, Notes & Int-
net\Java2\JdbcDrivers\classes12.zip;G:\Application Services\DBA, Notes & Int-
net\Java2\JdbcDrivers\mm.mysql-2.0.4-
bin.jar;C:\notes\JdbcSql\Lib\JdbcDomino.jar;C:\apps;G:\Application 
Services\DBA, Notes & Int-net\Java2
\Projects\temp\jspwork\3dfeb12a;C:\netbeans\modules\ext\AbsoluteLayout.jar;C:\ne
tbeans\modules\ext\jasper.jar;C:\netbeans\lib\ext\servlet.jar;C:\netbeans\module
s\ext\webserver.jar;C:\netbeans\lib\ext\xerces.jar;G:\Application Services\DBA, 
Notes & Int-net\Java2
\Projects\lib\ext\logger.jar;C:\NETBEANS\lib\core.jar;C:\NETBEANS\lib\openide-
fs.jar;C:\NETBEANS\lib\openide-nodes.jar;C:\NETBEANS\lib\openide-
util.jar;C:\NETBEANS\lib\openide.jar;C:\NETBEANS\lib\ext\jaxp.jar;C:\NETBEANS\li
b\ext\jh.jar;C:\NETBEANS\lib\ext\jpython.jar;C:\NETBEANS\lib\ext\parser.jar;C:\N
ETBEANS\lib\ext\regexp.jar;C:\NETBEANS\lib\ext\rmi-
ext.jar;C:\NETBEANS\lib\ext\sax2.jar;C:\NETBEANS\lib\ext\servlet.jar;C:\NETBEANS
\lib\ext\xerces.jar;C:\jdk1.3\lib\dt.jar;C:\jdk1.3
\lib\tools.jar;C:\NETBEANS\modules\ant.jar;C:\NETBEANS\modules\docs\ant-
manual.zip;C:\NETBEANS\modules\ext\ant-
optional.jar;C:\NETBEANS\modules\ext\ant.jar;C:\NETBEANS\modules\autoupdate.jar;
C:\NETBEANS\modules\clazz.jar;C:\NETBEANS\modules\debuggerCore.jar;C:\NETBEANS\m
odules\applet.jar;C:\NETBEANS\modules\toolsDebugger.jar;C:\NETBEANS\modules\jpda
Debugger.jar;C:\NETBEANS\modules\editor.jar;C:\NETBEANS\modules\ext\nb-
editor.jar;C:\NETBEANS\modules\html.jar;C:\NETBEANS\modules\httpserver.jar;C:\NE
TBEANS\modules\ext\webserver.jar;C:\NETBEANS\modules\extbrowser.jar;C:\NETBEANS\
modules\icebrowser.jar;C:\NETBEANS\modules\ext\icebrowserlitebean.jar;C:\NETBEAN
S\modules\image.jar;C:\NETBEANS\modules\jarpackager.jar;C:\NETBEANS\modules\java
.jar;C:\NETBEANS\modules\ext\java-
gj.jar;C:\NETBEANS\modules\ext\javac.jar;C:\NETBEANS\modules\beans.jar;C:\NETBEA
NS\modules\form.jar;C:\NETBEANS\modules\ext\AbsoluteLayout.jar;C:\NETBEANS\modul
es\javadoc.jar;C:\NETBEANS\modules\jndi.jar;C:\NETBEANS\modules\browser.jar;C:\N
ETBEANS\modules\ext\infobus.jar;C:\NETBEANS\modules\projects.jar;C:\NETBEANS\mod
ules\properties.jar;C:\NETBEANS\modules\i18n.jar;C:\NETBEANS\modules\i18n-
form.jar;C:\NETBEANS\modules\properties-
syntax.jar;C:\NETBEANS\modules\text.jar;C:\NETBEANS\modules\usersguide.jar;C:\NE
TBEANS\modules\jsp.jar;C:\NETBEANS\modules\ext\jasper.jar;C:\NETBEANS\modules\js
p-
syntax.jar;C:\NETBEANS\modules\openidex.jar;C:\NETBEANS\modules\scripting.jar;C:
\NETBEANS\modules\ext\djava.jar;C:\NETBEANS\modules\ext\bsh-
1.01.jar;C:\NETBEANS\modules\utilities.jar;C:\NETBEANS\modules\apisupport-
lite.jar;C:\NETBEANS\modules\rmi.jar;C:\NETBEANS\modules\vcscore.jar;C:\NETBEANS
\modules\javacvs.jar;C:\NETBEANS\modules\ext\cvslib.jar;C:\NETBEANS\modules\vcsg
en.jar;C:\NETBEANS\modules\cvs.jar;G:\Application Services\DBA, Notes & Int-
net\Java2\Projects\modules\junit.jar;G:\Application Services\DBA, Notes & Int-
net\Java2\Projects\modules\loggerModule.jar;G:\Application Services\DBA, Notes 
& Int-net\Java2\Projects\modules\makefile.jar
3 .= org.netbeans.modules.web.core.execution.WebAppMain
4 .= G:\Application Services\DBA, Notes & Int-net\Java2
\Projects\temp\tomcat\server.xml
5 .= G:\Application Services\DBA, Notes & Int-net\Java2\Projects\temp\tomcat

org.xml.sax.SAXParseException: The entity name must immediately follow the '&' 
in the entity reference.
	at org.apache.xerces.framework.XMLParser.reportError
(XMLParser.java:1060)
	at org.apache.xerces.framework.XMLDocumentScanner.reportFatalXMLError
(XMLDocumentScanner.java:626)
	at org.apache.xerces.framework.XMLDocumentScanner.scanAttValue
(XMLDocumentScanner.java:513)
	at org.apache.xerces.framework.XMLDocumentScanner.scanElement
(XMLDocumentScanner.java:1821)
	at 
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch
(XMLDocumentScanner.java:1234)
	at org.apache.xerces.framework.XMLDocumentScanner.parseSome
(XMLDocumentScanner.java:381)
	at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:952)
	at org.xml.sax.helpers.XMLReaderAdapter.parse(XMLReaderAdapter.java:223)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:290)
	at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:214)
	at org.apache.tomcat.startup.Tomcat.stopTomcat(Tomcat.java:258)
	at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:174)
	at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
	at org.netbeans.modules.web.core.execution.WebAppStop.main
(WebAppStop.java:35)
	at org.netbeans.modules.web.core.execution.ServerProcess.destroy
(ServerProcess.java:61)
	at org.openide.execution.ProcessExecutor$ExternalExecutorTask.stop
(ProcessExecutor.java:516)
	at org.openide.execution.ProcessExecutor$ExternalExecutorTask.result
(ProcessExecutor.java:524)
	at org.openide.execution.ProcessExecutor$2.run(ProcessExecutor.java:504)
org.xml.sax.SAXParseException: The entity name must immediately follow the '&' 
in the entity reference.
	at org.apache.xerces.framework.XMLParser.reportError
(XMLParser.java:1060)
	at org.apache.xerces.framework.XMLDocumentScanner.reportFatalXMLError
(XMLDocumentScanner.java:626)
	at org.apache.xerces.framework.XMLDocumentScanner.scanAttValue
(XMLDocumentScanner.java:513)
	at org.apache.xerces.framework.XMLDocumentScanner.scanElement
(XMLDocumentScanner.java:1821)
	at 
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch
(XMLDocumentScanner.java:1234)
	at org.apache.xerces.framework.XMLDocumentScanner.parseSome
(XMLDocumentScanner.java:381)
	at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:952)
	at org.xml.sax.helpers.XMLReaderAdapter.parse(XMLReaderAdapter.java:223)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:290)
	at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:214)
	at org.apache.tomcat.startup.Tomcat.stopTomcat(Tomcat.java:258)
	at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:174)
	at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
	at org.netbeans.modules.web.core.execution.WebAppStop.main
(WebAppStop.java:35)
	at org.netbeans.modules.web.core.execution.ServerProcess.destroy
(ServerProcess.java:61)
	at org.openide.execution.ProcessExecutor$ExternalExecutorTask.stop
(ProcessExecutor.java:516)
	at org.openide.execution.ProcessExecutor$ExternalExecutorTask.result
(ProcessExecutor.java:524)
	at org.netbeans.modules.web.core.WebExecSupport$1.run
(WebExecSupport.java:178)
Comment 1 Damian Frach 2001-06-12 09:29:21 UTC
Probably similiar ot the #12749.
Comment 2 Milan Kuchtiak 2001-06-19 16:23:07 UTC
This was caused by the incorrect configuration of server.xml file. Changes in 
configuratuin were running in a standalone thread and it happened sometimes, 
that in time when tomcat was looking at the server.xml file - this was 
corrupted at that moment.

Configuration of server.xml file runs not in standalone thread now
Comment 3 Marek Fukala 2001-07-16 13:36:49 UTC
Verified in 010714 -the bug is probably duplicat of #12749.
Comment 4 Quality Engineering 2003-07-02 08:30:06 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.