Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to create an ant task to compile JSPs. Here are the excerpts from the build.xml related to the task:

....

<fileset dir="${java.home}/lib">
  <include name="tools.jar"/>
</fileset>

<java classname="weblogic.jspc" fork="yes">
  <classpath refid="weblogic.jsp.classpath" />

  <sysproperty key="weblogic.jsp.windows.caseSensitive" value="false"/>

  <arg line="-forceGeneration -keepgenerated -compileAll -webapp ${jsp.src.dir} -d ${jsp.generated.src.dir}"/>
</java>

When I try to run wl.jsp.generate task, I get:

wl.jsp.generate:

 [java] [jspc] warning: expected file /WEB-INF/web.xml  not found, tag

libraries cannot be resolved.

 [java] [jspc] Overriding  default descriptor option 'keepgenerated' with

value specified on command-line 'true'

 [java] Exception encountered while compiling

C:\workspace\smcmw\smcmw_browser\jsp\smcesearchprogress.jsp [java] java.lang.NoSuchMethodError: javax.servlet.jsp.tagext.TagAttributeInfo.(Ljava/lang/String;ZLjava/lang/String;ZZLjava/lang/String;ZZLjava/lang/String;Ljava/lang/String;)V

 [java]  at weblogic.jsp.internal.jsp.tag.TagAttrInfoEx.<init>(TagAttrInfoEx.java:64)
 [java]  at weblogic.jsp.internal.jsp.tag.TagAttrInfoEx.<init>(TagAttrInfoEx.java:57)
 [java]  at weblogic.jsp.internal.jsp.tag.TagAttrInfoEx.<init>(TagAttrInfoEx.java:41)
 [java]  at weblogic.jsp.internal.jsp.tag.TagAttrInfoEx.read(TagAttrInfoEx.java:86)

Looks like it fails because it can't find WEB-INF/web.xml file and tag libraries. How can I fix this?

share|improve this question
1  
This question would probably have more success on SO –  emills Oct 31 '09 at 14:02

1 Answer 1

This might be helpful...

http://www.coderanch.com/t/66927/BEA-Weblogic/Precompile-JSPs-using-Ant

hope it helps!

I would also ask you to consider why you would want to pre-compile your jsp pages anyway. The only cost is in the performance of the very first person who hits your jsp pages and that should probably be your Dev team for sanity testing after a deployment. Eric

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.