You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by peter lin <pe...@labs.gte.com> on 2002/10/02 14:14:05 UTC

4.1.12 JSPC question

I'm trying to get JSPC to work correctly and compile my webapp, but I am
having a bit of difficulty. jspc with tomcat 4.0.3 worked fine, but
4.1.12 is having trouble resolving the included files and is therefore
throwing NPE.  I've gone through every tomcat 4 doc on the site and I've
read through the javadoc, but it's still unclear to me which jspc
options are required and which are not.

I've managed to compile single jsp files, but not a webapp.  Here is an
example of the command I am using.

C:\tomcat\bin>jspc -webapp c:\project\myapp -d
c:\tomcat\work\Standalone\localhost\_ -uriroot c:\project\myapp -uribase
c:\project\myapp

I'm hoping it's just stupid user error on my part. One thing is my pages
use JSTL <c:import> as well as other JSTL tags.

peter

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: 4.1.12 JSPC question

Posted by peter lin <pe...@labs.gte.com>.
Hey Rick,


thanks for the response. Yeah, I run into the problem of command line
too long. I'll check out the manager app how-to.

peter

Rick Fincher wrote:
> 
> Hi Peter,
> 
> The docs are not very good on this.  There is good news and bad news.  The
> bad news is that even using JSPC all you get is a bunch of uncompiled
> servlets.  You still have the slowdown at runtime with the first compile
> into class files.  You can go in and compile the servlets but getting the
> classpaths correct is difficult and in many cases the command line is too
> long to be processed.
> 
> The good new is that there are ant scripts for doing all of this for you in
> 4.1.12. Check the Manager App How-To in the docs for details.
> 
> Rick
> 
> ----- Original Message -----
> From: "peter lin" <pe...@labs.gte.com>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Wednesday, October 02, 2002 8:14 AM
> Subject: 4.1.12 JSPC question
> 
> >
> > I'm trying to get JSPC to work correctly and compile my webapp, but I am
> > having a bit of difficulty. jspc with tomcat 4.0.3 worked fine, but
> > 4.1.12 is having trouble resolving the included files and is therefore
> > throwing NPE.  I've gone through every tomcat 4 doc on the site and I've
> > read through the javadoc, but it's still unclear to me which jspc
> > options are required and which are not.
> >
> > I've managed to compile single jsp files, but not a webapp.  Here is an
> > example of the command I am using.
> >
> > C:\tomcat\bin>jspc -webapp c:\project\myapp -d
> > c:\tomcat\work\Standalone\localhost\_ -uriroot c:\project\myapp -uribase
> > c:\project\myapp
> >
> > I'm hoping it's just stupid user error on my part. One thing is my pages
> > use JSTL <c:import> as well as other JSTL tags.
> >
> > peter
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: 4.1.12 JSPC question

Posted by Peter Lin <tc...@yahoo.com>.
 
actually, the problem in my case was due to .tld file in jakarta jsp 1.1 taglibs. Once I removed the .tld files from the jar, jspc was able to compile with -webapp option just fine.
My guess is there is a bug with respect to how jasper compiler handles taglib tld files. For some reason, if there's a .tld file in /mywebapp/WEB-INF/ and the jar file, it tries to use the one in the jar.
since the web.xml points to the one in /WEB-INF/, it causes a conflict, which results in NPE.
 
peter lin
 
 Kris Schneider wrote:Peter,

Not sure if you're running into the same problem, but here's a thread
that didn't get much of a reaction. I haven't filed a bug on this
(yet?):

http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg62000.html
name=smime.p7s 


---------------------------------
Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!

Re: 4.1.12 JSPC question

Posted by Kris Schneider <kr...@dotech.com>.
Peter,

Not sure if you're running into the same problem, but here's a thread
that didn't get much of a reaction. I haven't filed a bug on this
(yet?):

http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg62000.html

peter lin wrote:
> 
> after a lot of digging, I tracked part of the problem down to jakarta
> string taglib. once I removed that from my file, it correctly compiles
> the jsp page.  I'm working on tracking down the exact cause, but it
> might be an issue with jsp 1.1 tags. JSTL 1.2 compliant, but string
> taglib is 1.1.
> 
> if anyone has seen this, I'd like to hear about it. it might help me
> diagnose the problem and find a fix faster.
> 
> peter
> 
> Rick Fincher wrote:
> >
> > Hi Peter,
> >
> > The docs are not very good on this.  There is good news and bad news.  The
> > bad news is that even using JSPC all you get is a bunch of uncompiled
> > servlets.  You still have the slowdown at runtime with the first compile
> > into class files.  You can go in and compile the servlets but getting the
> > classpaths correct is difficult and in many cases the command line is too
> > long to be processed.
> >
> > The good new is that there are ant scripts for doing all of this for you in
> > 4.1.12. Check the Manager App How-To in the docs for details.
> >
> > Rick
> >
> > ----- Original Message -----
> > From: "peter lin" <pe...@labs.gte.com>
> > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > Sent: Wednesday, October 02, 2002 8:14 AM
> > Subject: 4.1.12 JSPC question
> >
> > >
> > > I'm trying to get JSPC to work correctly and compile my webapp, but I am
> > > having a bit of difficulty. jspc with tomcat 4.0.3 worked fine, but
> > > 4.1.12 is having trouble resolving the included files and is therefore
> > > throwing NPE.  I've gone through every tomcat 4 doc on the site and I've
> > > read through the javadoc, but it's still unclear to me which jspc
> > > options are required and which are not.
> > >
> > > I've managed to compile single jsp files, but not a webapp.  Here is an
> > > example of the command I am using.
> > >
> > > C:\tomcat\bin>jspc -webapp c:\project\myapp -d
> > > c:\tomcat\work\Standalone\localhost\_ -uriroot c:\project\myapp -uribase
> > > c:\project\myapp
> > >
> > > I'm hoping it's just stupid user error on my part. One thing is my pages
> > > use JSTL <c:import> as well as other JSTL tags.
> > >
> > > peter
> >
> > --
> > To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> > For additional commands, e-mail: <ma...@jakarta.apache.org>

-- 
Kris Schneider <ma...@dotech.com>
D.O.Tech       <http://www.dotech.com/>

Re: 4.1.12 JSPC question

Posted by peter lin <pe...@labs.gte.com>.
Here is a bit more information. I took a look at the jar files for jsp
1.1 tags and they include a taglib.tld file in meta-inf/.  Once I remove
that, it compiles the pages fine.  It looks like there's a conflict in
either jasper compiler or jspc that is unable to resolve which .tld file
to use.

peter lin


peter lin wrote:
> 
> after a lot of digging, I tracked part of the problem down to jakarta
> string taglib. once I removed that from my file, it correctly compiles
> the jsp page.  I'm working on tracking down the exact cause, but it
> might be an issue with jsp 1.1 tags. JSTL 1.2 compliant, but string
> taglib is 1.1.
> 
> if anyone has seen this, I'd like to hear about it. it might help me
> diagnose the problem and find a fix faster.
> 
> peter
> 
>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: 4.1.12 JSPC question

Posted by peter lin <pe...@labs.gte.com>.
Here is a bit more information. I took a look at the jar files for jsp
1.1 tags and they include a taglib.tld file in meta-inf/.  Once I remove
that, it compiles the pages fine.  It looks like there's a conflict in
either jasper compiler or jspc that is unable to resolve which .tld file
to use.

peter lin


peter lin wrote:
> 
> after a lot of digging, I tracked part of the problem down to jakarta
> string taglib. once I removed that from my file, it correctly compiles
> the jsp page.  I'm working on tracking down the exact cause, but it
> might be an issue with jsp 1.1 tags. JSTL 1.2 compliant, but string
> taglib is 1.1.
> 
> if anyone has seen this, I'd like to hear about it. it might help me
> diagnose the problem and find a fix faster.
> 
> peter
> 
>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: 4.1.12 JSPC question

Posted by peter lin <pe...@labs.gte.com>.
after a lot of digging, I tracked part of the problem down to jakarta
string taglib. once I removed that from my file, it correctly compiles
the jsp page.  I'm working on tracking down the exact cause, but it
might be an issue with jsp 1.1 tags. JSTL 1.2 compliant, but string
taglib is 1.1.

if anyone has seen this, I'd like to hear about it. it might help me
diagnose the problem and find a fix faster.

peter

Rick Fincher wrote:
> 
> Hi Peter,
> 
> The docs are not very good on this.  There is good news and bad news.  The
> bad news is that even using JSPC all you get is a bunch of uncompiled
> servlets.  You still have the slowdown at runtime with the first compile
> into class files.  You can go in and compile the servlets but getting the
> classpaths correct is difficult and in many cases the command line is too
> long to be processed.
> 
> The good new is that there are ant scripts for doing all of this for you in
> 4.1.12. Check the Manager App How-To in the docs for details.
> 
> Rick
> 
> ----- Original Message -----
> From: "peter lin" <pe...@labs.gte.com>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Wednesday, October 02, 2002 8:14 AM
> Subject: 4.1.12 JSPC question
> 
> >
> > I'm trying to get JSPC to work correctly and compile my webapp, but I am
> > having a bit of difficulty. jspc with tomcat 4.0.3 worked fine, but
> > 4.1.12 is having trouble resolving the included files and is therefore
> > throwing NPE.  I've gone through every tomcat 4 doc on the site and I've
> > read through the javadoc, but it's still unclear to me which jspc
> > options are required and which are not.
> >
> > I've managed to compile single jsp files, but not a webapp.  Here is an
> > example of the command I am using.
> >
> > C:\tomcat\bin>jspc -webapp c:\project\myapp -d
> > c:\tomcat\work\Standalone\localhost\_ -uriroot c:\project\myapp -uribase
> > c:\project\myapp
> >
> > I'm hoping it's just stupid user error on my part. One thing is my pages
> > use JSTL <c:import> as well as other JSTL tags.
> >
> > peter
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: 4.1.12 JSPC question

Posted by Rick Fincher <rn...@tbird.com>.
Hi Peter,

The docs are not very good on this.  There is good news and bad news.  The
bad news is that even using JSPC all you get is a bunch of uncompiled
servlets.  You still have the slowdown at runtime with the first compile
into class files.  You can go in and compile the servlets but getting the
classpaths correct is difficult and in many cases the command line is too
long to be processed.

The good new is that there are ant scripts for doing all of this for you in
4.1.12. Check the Manager App How-To in the docs for details.

Rick

----- Original Message -----
From: "peter lin" <pe...@labs.gte.com>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Wednesday, October 02, 2002 8:14 AM
Subject: 4.1.12 JSPC question


>
> I'm trying to get JSPC to work correctly and compile my webapp, but I am
> having a bit of difficulty. jspc with tomcat 4.0.3 worked fine, but
> 4.1.12 is having trouble resolving the included files and is therefore
> throwing NPE.  I've gone through every tomcat 4 doc on the site and I've
> read through the javadoc, but it's still unclear to me which jspc
> options are required and which are not.
>
> I've managed to compile single jsp files, but not a webapp.  Here is an
> example of the command I am using.
>
> C:\tomcat\bin>jspc -webapp c:\project\myapp -d
> c:\tomcat\work\Standalone\localhost\_ -uriroot c:\project\myapp -uribase
> c:\project\myapp
>
> I'm hoping it's just stupid user error on my part. One thing is my pages
> use JSTL <c:import> as well as other JSTL tags.
>
> peter



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>