[Sorry to crosspost against Struts --- I think the problem could be fixed by
either Struts or Tomcat audience]

I am using Tomcat 3.2.2 and Struts 1.0 for translating the jsp pages.

When I compile a jsp pages containing reference to struts cutom tag library,
I get the following error message:

2001-06-25 04:35:08 - Package name is: jsp
2001-06-25 04:35:08 - Class file name is:
D:\web-test\Ems2.0\win\WEB-INF\classes\JspServ_pre\jsp\_0002fjsp_0002findex_
0002ejspindex.class
2001-06-25 04:35:08 - Java file name is:
D:\web-test\Ems2.0\win\WEB-INF\classes\JspServ_pre\jsp\index.java
2001-06-25 04:35:08 - Class name is: index
2001-06-25 04:35:08 - 
Handling Directive: page        {language=java}
2001-06-25 04:35:08 - Accepted org.apache.jasper.compiler.Parser$Directive
at D:\web-test\Ems2.0\win\jsp\index.jsp(0,0)
2001-06-25 04:35:08 - 
Handling Directive: taglib      {uri=/WEB-INF/struts-bean.tld, prefix=bean}

BUILD FAILED

D:\web-test\dev.xml:1141: java.lang.LinkageError: loader constraints
violated when linking org/xml/sax/EntityResolver class
--- Nested Exception ---
java.lang.LinkageError: loader constraints violated when linking
org/xml/sax/EntityResolver class
        at
org.apache.jasper.compiler.JspUtil.parseXMLDocJaxp(JspUtil.java:161)
        at org.apache.jasper.compiler.JspUtil.parseXMLDoc(JspUtil.java:138)
        at
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java
:170)
        at
org.apache.jasper.compiler.JspParseEventListener.handleDirective(JspParseEve
ntListener.java:706)
        at
org.apache.jasper.compiler.DelegatingListener.handleDirective(DelegatingList
ener.java:116)
        at
org.apache.jasper.compiler.Parser$Directive.accept(Parser.java:215)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1077)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1042)
        at org.apache.jasper.compiler.Parser.parse(Parser.java:1038)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:209)
        at org.apache.jasper.JspC.parseFile(JspC.java:376)
        at org.apache.jasper.JspC.parseFiles(JspC.java:641)
        at org.apache.jasper.JspC.main(JspC.java:689)
        at java.lang.reflect.Method.invoke(Native Method)
        at
org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:127)
        at org.apache.tools.ant.taskdefs.Java.run(Java.java:260)
        at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:123)
        at org.apache.tools.ant.taskdefs.Java.execute(Java.java:87)
        at org.apache.tools.ant.Target.execute(Target.java:153)
        at org.apache.tools.ant.Project.runTarget(Project.java:898)
        at org.apache.tools.ant.Project.executeTarget(Project.java:536)
        at org.apache.tools.ant.Project.executeTargets(Project.java:510)
        at org.apache.tools.ant.Main.runBuild(Main.java:421)
        at org.apache.tools.ant.Main.main(Main.java:149)

I made sure I have the tld files in the WEB-INF dir. Here is the snippet of
jsp that is producing the error:
index.jsp:
<%@ page language="java" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>

<html:html locale="true">
<head>
<title><bean:message key="logon.title" arg0="2.0"/></title>
<html:base/>
</head>
<body bgcolor="white">

<html:errors/>

<html:form action="/logon" focus="username">
<table border="0" width="100%">

  <tr>
    <th align="right">
      <bean:message key="prompt.username"/>
    </th>
    <td align="left">
      <html:text property="username" size="16" maxlength="16"/>
    </td>
  </tr>

  <tr>
    <th align="right">
      <bean:message key="prompt.password"/>
    </th>
    <td align="left">
      <html:password property="password" size="16" maxlength="16"
                    redisplay="false"/>
    </td>
  </tr>

  <tr>
    <td align="right">
      <html:submit property="submit" value="Submit"/>
    </td>
    <td align="left">
      <html:reset/>
    </td>
  </tr>

</table>

</html:form>

</body>

Those jsps without struts custom tag library reference gets precompiled
properly. I have the jasper.jar, struts.jar, jaxp.jar, parser.jar and
webserver.jar from Tomcat 3.2.2 and Struts 1.0 in the class path of
org.apache.jasper.JspC.

Any suggestion to fix the problem of pre-compilation would be appreciated.



Sibon Barman
SS8 Networks, Inc.
Suite 500
495 March Road, Kanata, 
Ontario K2K 3G1

*: (613)592-2100 ext:3281
*: [EMAIL PROTECTED]


winmail.dat

Reply via email to