Re: Ship java app to windows box

2002-12-10 Thread Ola Berg
>My question is if it is common to ship java web app to Windows box with tomcat and 
>jdk.  

Common, I don't know, but it isn't legal (license-wise) to redistribute the JDK (only 
the JRE), and the JDK is needed for tomcat. 

Second: whíle you can distribute tomcat bundled with your application, you probably 
want to integrate with the static web server on site (IIS?). Someone needs to do the 
laying-on-hands, be it either you, the IT staff or some consultant/contractor.

>From an IT perspective, I can see their point. Religious views on OS or not, you are 
>actually asking them to support a completely new platform and technology, and that 
>isn't done in a snap. Perhaps do they feel that they cannot guarantee to deliver at 
>the quality they are used to, should they have to cope with a technology they don't 
>know. 

Tomcat and Java might be easy to admin, but it is not _trivial_ (else why should we 
have this list?). There are a couple of new skills and routines for the IT department 
to incorporate, and they should be given the time and motivation to do so. IT folks 
don't want things in their system that they don't know how to restart, configure, 
back-up and in other ways manage.

What do the management say about this? Does anyone stand behind you? What motivates 
and controls the selection of supported technologies within the organization? Who 
tells the IT folks what they should do?

/O


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: How does mod_jk2 find properties file.

2002-12-10 Thread Bill Barker
One of the reasons that jk2 is a beta :-).  It looks like it is trying to
use the "standard" Apache layout and not handling the "RedHat" layout.  My
suggestion is to file a bug at: http://nagoya.apache.org/bugzilla/ so that
it won't get lost in all of the "I don't understand..." messages.

I'm not a Jk2-native expert, but I believe that you can work-around this by
including a directive in your httpd.conf file like:
JkSet conf:file etc/httpd/workers2.properties

"Theodore A. Jencks" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I'm getting a strange error when starting apache 2.0.43 running on Redhat
Linux 8.0 mod_jk2 version 2.0.2.  Here is what apache reports:

[Tue Dec 10 18:30:29 2002] [error] config.update(): Can't find config file
/etc/httpd/conf/workers2.properties
[Tue Dec 10 18:30:29 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:29 2002] [notice] Apache configured -- resuming normal
operations
[Tue Dec 10 18:30:29 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:29 2002] [error] mod_jk child init 1 0
[Tue Dec 10 18:30:30 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:31 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:31 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file


This is rather strange since I've got workers2.properties configured like
this:

[config:]
file=/etc/httpd/workers2.properties
debug=0
debugEnv=0

[shm:]
info=Scoreboard. Required for reconfiguration and status with multiprocess
servers
file=/opt/tomcat/logs/httpd/jk2.shm
size=100
debug=0
disabled=0

When I copy workers2.properties to /etc/httpd/conf/workers2.properties it
finds the config file.  I'm just wondering what causes jk2 to look for the
workers2.properties file in /etc/httpd/conf when all my apache conf files
are just in /etc/httpd/httpd.conf


Regards,
Theo





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Tomcat/HTTPD Integration

2002-12-10 Thread Bill Barker
Hum, ForwardURICompat is what does the trick for me on Apache 1.3.x (as well
as including "index.jsp" in the Apache DirectoryIndex).  At least in my
case, this tricks Apache into sending the request to Tomcat as
"/myapp/index.jsp", so it doesn't do the redirect, and the browser is none
the wiser.

I'm guessing that it is because of your mal-formed "JkMount /*Servlet
worker1" directive.  I believe that this gets (quietly) translated to
"JkMount /* worker1", so mod_jk finishes the translation early.  You need to
specify one JkMount for each of your '*Servlet's (or use the ApacheConfig
Listener if you have a lot of them).

"Johnson, Garrett" <[EMAIL PROTECTED]> wrote in message
5DE7B60BFBA5D411B961000629D5225552D735@NYCCNDX3">news:5DE7B60BFBA5D411B961000629D5225552D735@NYCCNDX3...
> I'm sorry, I didn't make this clear.  I should've discussed my
environment:
>
> Win2K
> Apache 2.0
> Tomcat 4.1
> mod_jk installed.
>
> The question I have is, what am I missing?  I've changed the httpd.conf
> file, and now at the end it has:
>
> LoadModule jk_module modules/mod_jk.dll
> JkWorkersFile conf/workers.properties
> JkLogFile logs/mod_jk.log
> JkLogLevel info
> JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
> JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
> JkRequestLogFormat "%w %V %T"
> JkMount /*.jsp worker1
> JkMount /*Servlet worker1
>
> However, this doesn't cut it.  I can't understand why... :(
>
> As for the RequestDispatcher/request.sendRedirect, yup, that's EXACTLY
what
> I needed.  SNIFF - I look at the j2ee API for hours and couldn't stumble
> across that. :D
>
> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 5:32 PM
> To: Tomcat Users List
> Subject: RE: Tomcat/HTTPD Integration
>
>
> Garrett,
>
> > 1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd
like
> > to be able to access it using Apache HTTPD instead of Tomcat's built-in
> > server.
>
> Right.  You setup a connector, e.g., mod_jk, mod_jk2, mod_webapp.  Heck, I
> even have a case where I have mod_proxy being used (don't ask why --
archaic
> and going away, but it works)!
>
> ref:
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/connectors.html
>
> > How do I both instruct Apache to serve up all requests for the root
> > directory to Tomcat, and how do I set up that alias to use MY index
> > page?
>
> It is easier than you think.  Check the docs for your connector of choice.
> The best documentation is probably for mod_jk.
>
> If you want a laugh, here is how you do it with mod_rewrite/mod_proxy:
>
> RewriteRule   ^/(.*)$   http://localhost:8080/$1 [P]
> ProxyPassReverse  / http://localhost:8080/
>
> Again, *not* something I recommend.  [FWIW, you could use ProxyPass
instead
> of a rewrite rule, but there is a lot more going on that isn't shown
above.]
>
> > context.getRequestDispatcher("/start.jsp" );
> > how do I get the URL on the client side to reflect the forwarding?
>
> If you want the browser to go back to the start.jsp page, you send it
there
> with request.sendRedirect("/start.jsp"), not a RequestDispatcher.
>
> > Thanks in advance, kids...
>
> You're welcome gramps ...  ;-)
>
> --- Noel
>
>
> --
> To unsubscribe, e-mail:
> 
> For additional commands, e-mail:
> 





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Building Tomcat 4.1.12 from source

2002-12-10 Thread Bill Barker
In the source distribution, jasper is packaged under the
jakarta-tomcat-4.1.12-src/jasper directory.  You need to set
"jasper.home=jasper" (w/o the quotes) in your build.properties file.

Note, that it is actually much easier to build from source than the BUILDING
instructions make it out to be.  Except for "Java Activation", "Java Mail",
JSSE, JTA, (which are all optional) you can get the rest by unpacking the
source distribution, and copying "build.properties.sample" to
"build.properties".  If you are behind a firewall, edit the file to set
"proxy.host", and "proxy.port" to your proxy server.  Set any other
properties you want to change, and then do "ant download".

"Faine, Mark" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Solaris 8
> Tomcat 4.1.12
> I'm trying to build from source using the BUILDING instructions in the
> source directory. I've completed everything on the list, even the optional
> packages.
>
> Now I get this error:
>
>
> BUILD FAILED
>
file:/export/home/temp/appserv/temp/jakarta-tomcat-jasper/jasper2/build.xml:
> 119: Compile failed; see the compiler error output for details.
>
>
> There is nothing in there anywhere about jasper or jasper2 or anything
> jasper related. Even so I got jasper from cvs and attempted to do my "ant
> dist" again, still I can't get past jasper. Is jakarta-tomcat-jasper
needed,
> if so why isn't it mentioned in the BUILDING file and how come I can only
> find it in CVS?
>
> Does anyone know what I need to do get this to finish building?
>
> Thanks,
> Mark





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Custom Valves and Administration Tool

2002-12-10 Thread Jon Eaves
Hi again Bill,


Aha.  I was hoping this wasn't going to be the answer.  Oh well.

[ snip ]

If this is the case, why does the code for the Valve recommend 
implementing the Lifecycle interface ? What was the design reason for
that ?h

By implementing Lifecycle, you get well-defined states to allocate and 
release any resources that your Valve may need.  Since the order of
setting attributes is undefined, it makes it much easier to determine
resources that depend on multiple attribute values.  It's pretty much
independent of the MBeans.


Excellent, so the Valves can then conform to an defined
servlet/applet/midlet like behaviour.  I noticed the use of the
start() etc methods in the Valve and guessed that was something to
do with it, but also guessed wrong that it was relating to the MBeans.


It's purely because of the Valve definition in server.xml, when it can't
 find the MBean to manage it.  Actually, the Valve should function fine
even with the error:  It's just noise in the log.


Yup.  My Valves were all working just fine with the errors, but I wanted
to be neat and tidy ;-)




The reason I ask is because it seems bit of dicking around just to 
implement a new Valve.  Writing the code took about 2 hours, it then
took 2 days to get the exception stuff sorted out.

What is the additional information used for ? And was there a better 
(read simpler and less mucking around) way to solve my "get rid of the
exception" than addition of the descriptor, or is that required for
all additional components in Tomcat ?


With the MBean info, it is possible to use other JMX-enabled tools to
manage Tomcat (including your Valve).  The admin web-app is only one
example of such a tool.  It is also likely that JMX support will improve
in Tomcat 5.x.

Of course, the simplest way to "get rid of the exception" is to disable
(aka comment out) the MBeans Listeners in server.xml.


OK.  I'll have a play around with that.  I think I tried that originally,
and when I did, the Administration application stopped working, but that
may just have been co-incidence.

Thanks very much Bill and Craig for your patience.

Cheers,
	-- jon

--
Jon Eaves <[EMAIL PROTECTED]>
http://www.eaves.org/jon/


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Tomcat examples - reply to Carlos

2002-12-10 Thread Bill Barker
Actually, this is not quite right.  There is a bug in xerces  2.2.0 & 2.2.1
that causes this error with struts applications (such as the admin web-app).
You can either use xerces 2.1.0 or the xerces nightly to make it go away
(replace the files in $CATALINA_HOME/common/endorsed).

"Turner, John" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>
> This was answered already, yesterday.  See this block of text in the error
> message:
>
> [ERROR] Digester - -Parse Fatal Error at line 307 column 39: The string
"--"
> is not permitted within comments.  "--" is not permitted within comments.>
>
> In one of your XML files, probably server.xml, on line 307, you have the
> string "--" inside of a comment.  This is not permitted.
>
> If you do not have "--" on or near line 307, then what has probably
happened
> is that a XML element higher in the file (like line 300 or 250 or
whatever)
> was added and improperly terminated, throwing off the XML parser.
>
> Fix the comment string on or about line 307, or if there isn't one on or
> about line 307, go through the file and make sure every element is
properly
> terminated.
>
> John
>
> > -Original Message-
> > From: Carlos Alberto Pelaez Ayala [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 10, 2002 11:20 AM
> > To: Tomcat Users List
> > Subject: RE: Tomcat examples - reply to Carlos
> >
> >
> > Dear Mark, thank?s for your help. Let me to say what is my
> > problem. I have
> > installed Tomcat 4.1.12 in Solaris 8 SPARC. I don?t use the
> > binary. I use
> > the source code and build my tomcat with ant and all
> > libraries. Ok, i look
> > the page http://localhost:8080 and my tomcat work?s fine. But
> > when i try to
> > see the examples (JSP examples, Servlet examples, and the
> > administrator
> > (/admin)) appear this message:
> >
> > HTTP Status 404 - /examples/jsp/
> >
> > --
> > --
> > 
> >
> > type Status report
> >
> > message /examples/jsp/
> >
> > description The requested resource (/examples/jsp/) is not available.
> >
> >
> > --
> > --
> > 
> >
> > Apache Tomcat/4.1.12
> >
> > in my directory logs, appear differents files and tells:
> >
> > localhost_log.txt tells:
> >
> > 2002-12-07 10:51:03 StandardHost[localhost]: Removing web
> > application at
> > context path /examples
> > 2002-12-07 10:51:03 StandardHost[localhost]:
> > ContainerBase.removeChild:
> > stop:
> > LifecycleException:  Container StandardContext[/examples] has not been
> > started
> > at org.apache.catalina.core.StandardContext.stop
> > (StandardContext.java:3569)
> > at org.apache.catalina.core.ContainerBase.removeChild
> > (ContainerBase.java:1036)
> > at org.apache.catalina.core.StandardHostDeployer.remove
> > (StandardHostDeployer.java:420)
> >
> >
> > localhost_examples_logs.txt Tells:
> >
> > 2002-12-07 11:47:30 ContextConfig[/examples]: Marking this application
> > unavailable due to previous error(s)
> > 2002-12-07 11:47:30 StandardManager[/examples]: Seeding random number
> > generator
> > class java.security.SecureRandom
> > 2002-12-07 11:47:30 StandardManager[/examples]: Seeding of
> > random number
> > generator has been completed
> > 2002-12-07 11:47:30 StandardContext[/examples]: Context
> > startup failed due
> > to
> > previous errors
> >
> >
> >
> > localhost_admin_log.txt Tells:2002-12-07 11:47:30
> > ContextConfig[/admin]:
> > Marking this application unavailable due to previous error(s)
> > 2002-12-07 11:47:30 StandardManager[/admin]: Seeding random
> > number generator
> > class java.security.SecureRandom
> > 2002-12-07 11:47:30 StandardManager[/admin]: Seeding of random number
> > generator
> > has been completed
> > 2002-12-07 11:47:30 StandardContext[/admin]: Context startup
> > failed due to
> > previous errors
> >
> >
> > and catalina.out Tells:
> >
> > Starting service Tomcat-Standalone
> > Apache Tomcat/4.1.12
> > org.xml.sax.SAXParseException: The string "--" is not permitted within
> > comments.
> > at
> > org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException
> > (Unknown Source)
> > at
> > org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source)
> > at org.apache.xerces.impl.XMLScanner.scanComment(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLDTDScannerImpl.scanComment(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLDTDScannerImpl.scanDecls(Unknown Source)
> > at
> > org.apache.xerces.impl.XMLDTDScannerImpl.scanDTDExternalSubset
> > (Unknown Source)
> > at
> > org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch
> > (Unknown Source)
> > at
> > org.apache.xerces.impl.XMLDocumentFra

Re: Custom Valves and Administration Tool

2002-12-10 Thread Bill Barker

"Jon Eaves" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Craig R. McClanahan wrote:
> >
>
> First of all as there's been so much beating on the Tomcat developers
> I'd like to offer my whole-hearted congratulations to each and every
> one of you.  You've done a great job, and what's more, in spite of
> the (unwarranted) vitriol that is spewed in your direction, you keep
> coming back for more.  You guys and gals are legends.
>
> Secondly, the community here is fantastic and the way that users came
> to the "defense" of the Tomcat team was phenomenal.  Good work one and
> all.  As an author involved in a similar effort (www.bouncycastle.org)
> there are very few people who take the time to say "Thanks", but the
> effect on the developers morale is worth it.
>
> Remember everybody on the list, that's all they get paid in, and it
> doesn't cost anything to say it
>
> Now, if you don't mind, I've got just one more question ;-)
>
> > On Wed, 11 Dec 2002, Jon Eaves wrote:
> >>
> >>I was hoping to manage the valves via the Administration tool.
> >>
> >>Q1. Is this possible ?
> >
> >
> > Yes, with some work.
>
> Aha.  I was hoping this wasn't going to be the answer.  Oh well.
>
> [ snip ]
>
> If this is the case, why does the code for the Valve recommend
> implementing the Lifecycle interface ? What was the design reason
> for that ?h

By implementing Lifecycle, you get well-defined states to allocate and
release any resources that your Valve may need.  Since the order of setting
attributes is undefined, it makes it much easier to determine resources that
depend on multiple attribute values.  It's pretty much independent of the
MBeans.

>
> Additionally, why does the MBeans server barf when loading custom
> beans without the mbeans-descriptor.xml file ? Is this due to the
> Lifecycle interface being implemented, or just purely because of
> the Valve definition in server.xml it is expecting to find a bean
> that it can manage.

It's purely because of the Valve definition in server.xml, when it can't
find the MBean to manage it.  Actually, the Valve should function fine even
with the error:  It's just noise in the log.

>
> The reason I ask is because it seems bit of dicking around just to
> implement a new Valve.  Writing the code took about 2 hours, it
> then took 2 days to get the exception stuff sorted out.
>
> What is the additional information used for ? And was there a better
> (read simpler and less mucking around) way to solve my "get rid of
> the exception" than addition of the descriptor, or is that required
> for all additional components in Tomcat ?

With the MBean info, it is possible to use other JMX-enabled tools to manage
Tomcat (including your Valve).  The admin web-app is only one example of
such a tool.  It is also likely that JMX support will improve in Tomcat 5.x.

Of course, the simplest way to "get rid of the exception" is to disable (aka
comment out) the MBeans Listeners in server.xml.

>
> Cheers,
> -- jon
>
> --
> Jon Eaves <[EMAIL PROTECTED]>
> http://www.eaves.org/jon/





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: The future of Tomcat and java.nio

2002-12-10 Thread Nicholas Orr
You might get a faster reply from "developers" if you post this in the
developers mailing list.

It would be good to see something like this.  I only use apache for this
fact of fast static content serving and nothing else.

Nicholas Orr

-Original Message-
From: Joe Tomcat [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, 11 December 2002 12:32 PM
To: Tomcat Users List
Subject: The future of Tomcat and java.nio


It seems like Java 1.4's NIO package offers some very high-performance IO
capabilities, such as select loops, which could allow Java to serve static
content as fast as Apache can.  Will Tomcat be going in the direction of
using a NIO-based connector that might incorporate these high-performance
features?

I'm curious and hoping to hear what the deverlopers' thoughts are on this.



--
To unsubscribe, e-mail:

For additional commands, e-mail:



**
The information contained in this e-mail is confidential and is
intended only for the use of the addressee(s).
If you receive this e-mail in error, any use, distribution or
copying of this e-mail is not permitted. You are requested to
forward unwanted e-mail and address any problems to the
MIM Holdings Limited Support Centre.

For general enquires:   ++61 7 3833 8000
Support Centre e-mail:  [EMAIL PROTECTED]
Support Centre phone:   Australia 1800500646
International ++61 7 38338042
**


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: IIS webserver and JK2

2002-12-10 Thread Jacob Kjome

Well, you have to map it in your connector configuration just like you 
would servlet mappings or *.jsp.

For instance, for Tomcat's examples webapp with mod_jk configuration I have 
this:

JkMount /examples/jsp/security/protected/j_security_check  ajp13


Jake

At 10:51 PM 12/10/2002 -0500, you wrote:
Formbased authentication does not work if IIS is configured with Tomcat
but works with normal HTTP server. Can somebody throw some light?
I get 404 error stating j_security_check resource not available.

This is the same with /examples/jsp/security/protected/login.jsp too!

Hari



Re: war files and context entries

2002-12-10 Thread Jacob Kjome

Try creating a context.xml file and put yoru  entry in 
that.  Now put your context.xml in META-INF of your .war file.  Remove the 
context entry from Server.xml.  When Tomcat starts up and doesn't see your 
war there, it will mark the context as disabled and will get confused if 
you later try to put the .war file for that context there while Tomcat is 
running.  Now Start Tomcat fresh and then deploy your .war file.  Things 
should work fine now.

Jake

At 07:45 PM 12/10/2002 -0800, you wrote:
I have a war file that I deploy to my server 4.1.12.  If I just deploy
the war file without making any entries in the server.xml file and start
Tomcat, everything is fine.  OK so far.  However, if I make an explicit
context entry in the server.xml file for the war file using the
following entry:





When I try to start tomcat, it looks as if everything is going fine then
it just quits with no errors or anything.  I checked the logfile, and
the last entry is:
[timestamp] StandardContext[/cda]: Sending application start events
[timestamp] StandardContext[/cda]: Starting filters

Am I missing something here? Obviously I am cause it doesnt work.  I
know my war file is correctly configured because it works fine without
the  entry.

Dave Patton



The future of Tomcat and java.nio

2002-12-10 Thread Joe Tomcat
It seems like Java 1.4's NIO package offers some very high-performance
IO capabilities, such as select loops, which could allow Java to serve
static content as fast as Apache can.  Will Tomcat be going in the
direction of using a NIO-based connector that might incorporate these
high-performance features?

I'm curious and hoping to hear what the deverlopers' thoughts are on
this.



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat/HTTPD Integration

2002-12-10 Thread Jacob Kjome

Did you put "workers.properties" in Apache's "conf" directory?  Because 
providing a relative path to the conf directory isn't gong to see it in 
Tomcat's conf directory which is where "workers.properties" normally 
is.  Either move workers.properties to Apache's conf directory or specify 
the full path to the workers.properties in the Tomcat conf directory.

Jake

At 05:38 PM 12/10/2002 -0500, you wrote:
I'm sorry, I didn't make this clear.  I should've discussed my environment:

Win2K
Apache 2.0
Tomcat 4.1
mod_jk installed.

The question I have is, what am I missing?  I've changed the httpd.conf
file, and now at the end it has:

LoadModule jk_module modules/mod_jk.dll
JkWorkersFile conf/workers.properties
JkLogFile logs/mod_jk.log
JkLogLevel info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
JkMount /*.jsp worker1
JkMount /*Servlet worker1

However, this doesn't cut it.  I can't understand why... :(

As for the RequestDispatcher/request.sendRedirect, yup, that's EXACTLY what
I needed.  SNIFF - I look at the j2ee API for hours and couldn't stumble
across that. :D

-Original Message-
From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 5:32 PM
To: Tomcat Users List
Subject: RE: Tomcat/HTTPD Integration


Garrett,

> 1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd like
> to be able to access it using Apache HTTPD instead of Tomcat's built-in
> server.

Right.  You setup a connector, e.g., mod_jk, mod_jk2, mod_webapp.  Heck, I
even have a case where I have mod_proxy being used (don't ask why -- archaic
and going away, but it works)!

ref: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/connectors.html

> How do I both instruct Apache to serve up all requests for the root
> directory to Tomcat, and how do I set up that alias to use MY index
> page?

It is easier than you think.  Check the docs for your connector of choice.
The best documentation is probably for mod_jk.

If you want a laugh, here is how you do it with mod_rewrite/mod_proxy:

RewriteRule   ^/(.*)$   http://localhost:8080/$1 [P]
ProxyPassReverse  / http://localhost:8080/

Again, *not* something I recommend.  [FWIW, you could use ProxyPass instead
of a rewrite rule, but there is a lot more going on that isn't shown above.]

> context.getRequestDispatcher("/start.jsp" );
> how do I get the URL on the client side to reflect the forwarding?

If you want the browser to go back to the start.jsp page, you send it there
with request.sendRedirect("/start.jsp"), not a RequestDispatcher.

> Thanks in advance, kids...

You're welcome gramps ...  ;-)

--- Noel


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 



Re: Help: Upgrading from 4.0.2 to 4.1.12

2002-12-10 Thread Larry Meadors
I just went from 4.0.6 to 4.1.12, and found two things that may make
your life easier.

1) All my logging went into files instead of to the console.

2) 4.1 seems much fussier with stuff. For example, I had a reference to
a tld that did not exist in my web.xml, so an app that worked great in
4.0 would not start in 4.1 - DOH! This was before I figured out where
the log was, so I was one unhappy camper. :-)

Larry

>>> [EMAIL PROTECTED] 12/10/02 21:30 PM >>>
I am currently running tomcat 4.0.2 with a
mod_webapp connector for apache version 1.3.22

do I need to upgrade the mod_webapp connector 
That was a real bear the first time around 
It took sometime to find a binary that would
work with my Redhat 7.2 system. I tried
various to recompile a working version but was
never succesful. ;(

I would like to upgrade to 4.1.12 but I am a little
concerned about problems I might encounter .

I currently have tomcat in /usr/local/jakarta-tomcat-4.0.2
and see that installing from the rpm puts it
into /var/tomcat4 so that is ok. 

I am assuming that once I make the necessary changes to 
server.xml and tomcat-users.xml . I should be good to go

Just shut down the running version and startup the new one

Seems to easy. Am I missing something :)


Thanks in advance

Rob Cartier





--
To unsubscribe, e-mail:  

For additional commands, e-mail:




--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Help: Upgrading from 4.0.2 to 4.1.12

2002-12-10 Thread Rob Cartier
I am currently running tomcat 4.0.2 with a
mod_webapp connector for apache version 1.3.22

do I need to upgrade the mod_webapp connector 
That was a real bear the first time around 
It took sometime to find a binary that would
work with my Redhat 7.2 system. I tried
various to recompile a working version but was
never succesful. ;(

I would like to upgrade to 4.1.12 but I am a little
concerned about problems I might encounter .

I currently have tomcat in /usr/local/jakarta-tomcat-4.0.2
and see that installing from the rpm puts it
into /var/tomcat4 so that is ok. 

I am assuming that once I make the necessary changes to 
server.xml and tomcat-users.xml . I should be good to go

Just shut down the running version and startup the new one

Seems to easy. Am I missing something :)


Thanks in advance

Rob Cartier





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: JK - warning/question about naming workers (and auto-generating mod_jk.conf)

2002-12-10 Thread Madere, Colin
Well, it seems that:

site1 -> worker.ajp13:8009 -> tomcathost1
site2 -> worker.ajp13:8009 -> tomcathost2 (but mapped to same
docBase/appBase)

works with the examples hitting both for session data in different browsers
to be sure.  Did this by just adding the extra Host in Tomcat and the
Listener, then auto-generating mod_jk.conf with a single worker set up in
workers.properties and starting up Apache (after waiting the obligatory 10
seconds or so :] ).

So since it doesn't seem as though I need more workers I'm going to try this
out.  Is there necessarily a performance reason to go with more?  I didn't
get that impression and I think I've read just about all the JK docs out
there in about 5 locations (4 of which are on the apache.org tree).  Of
course, I did some skimming at times.

WARNING:
Note about auto-generated "mod_jk.conf" file.

It seems no matter what you name your workers, the auto-generated virtual
hosts are based _only_ on the  tags in your server.xml for Tomcat and
the process _does not_ look at your workers.properties file.  Evidence to
suggest this is that the autogenerated file _always_ "JkMounts" to a worker
named "ajp13" even if you do not have one defined as such in
workers.properties.

If anyone has experienced different behavior, please speak up.  If this is
documented somewhere, please post a link!

Colin

> -Original Message-
> From: Turner, John [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 9:45 PM
> To:   'Tomcat Users List'
> Subject:  RE: JK - warning/question about naming workers
> 
> 
> Well, in the short term, I don't think there is anything preventing you
> from
> setting up:
> 
> site1 -> worker.site1:8009 -> tomcat1:8009 
> site2 -> worker.site2:8010 -> tomcat1:8010
> site3 -> worker.site3:8011 -> tomcat1:8011
> 
> That would simply require three CoyoteConnectors.  We use something
> similar
> on our Tomcat 3.x servers...every vhost has it's own connector and
> connector
> port, but that's using JServ.
> 
> Right now, my test box for 4.1.12 has:
> 
> site1 -> worker.site1 -> tomcat1:8009
> site2 -> worker.site2 -> tomcat1:8009
> 
> But again, I haven't beat up on that, so I can't say that it works in all
> cases.
> 
> John
> 
> 
> -Original Message-
> From: Madere, Colin [mailto:[EMAIL PROTECTED]] 
> Sent: Tuesday, December 10, 2002 4:11 PM
> To: 'Tomcat Users List'
> Subject: RE: JK - warning/question about naming workers
> 
> Well it would make sense that all could use 8009 if they are different
> hosts
> on different IPs, but depending on how the port is used that may not work
> if
> you want to use a single Tomcat host for multiple Apache hosts.
> 
> That is my situation I'm trying to get working.
> 
> site1 -> worker.site1 -> tomcat1 (this works, obviously)
> site2 -> worker.site? -> tomcat1
> site3 -> worker.site? -> tomcat1
> 
> Any suggestions on this appreciated.  I don't want it to "just work", I
> want
> to be sure I know why it works and that it's not going to blow up when it
> goes to production.
> 
> Thanks for the super-fast feedback, John.
> 
> > -Original Message-
> > From:   Turner, John [SMTP:[EMAIL PROTECTED]]
> > Sent:   Tuesday, December 10, 2002 2:21 PM
> > To: 'Tomcat Users List'
> > Subject:RE: JK - warning/question about naming workers
> > 
> > 
> > Actually, I posted too soon.  After I thought about it, I realized that
> I
> > haven't really beat that test instance up any, I've been focusing on one
> > particular webapp and one particular client/URL.
> > 
> > I did end up having to add another entry to workers.properties for a
> > second
> > hostname, though as it stands now it looks like the various workers can
> > all
> > use port 8009.  I will have to investigate further.
> > 
> > I apologize for the previously posted misinformation that said one
> worker
> > definition could handle multiple vhosts.
> > 
> > John
> > 
> > > -Original Message-
> > > From: Turner, John [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, December 10, 2002 2:53 PM
> > > To: 'Tomcat Users List'
> > > Subject: RE: JK - warning/question about naming workers
> > > 
> > > 
> > > 
> > > As far as I know, the "host" parameter in workers.properties 
> > > is the lcoation
> > > of the Tomcat server...it has nothing to do with the hostname 
> > > used in the
> > > URL.
> > > 
> > > If you had more than one Host in server.xml, you would put an 
> > > ApacheConfig
> > > Listener in there for each one.
> > > 
> > > I have this setup in my 4.1.12 test instance right now.  
> > > There are multiple
> > > Hosts in server.xml, each with one or more Contexts.  
> > > Workers.properties
> > > only has one worker defined, and the mod_jk.conf file generated by
> > > ApacheConfig has multiple Apache VirtualHosts defined.
> > > 
> > > HTH
> > > 
> > > John
> > > 
> > > > -Original Message-
> > > > From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> > > > Sent: Tuesday, December 10, 2002 2:47 PM
> > > > To: 'Tomcat Users Li

IIS webserver and JK2

2002-12-10 Thread Hari Venkatesan
Formbased authentication does not work if IIS is configured with Tomcat
but works with normal HTTP server. Can somebody throw some light?
I get 404 error stating j_security_check resource not available.
 
This is the same with /examples/jsp/security/protected/login.jsp too!
 
Hari



RE: JK - warning/question about naming workers

2002-12-10 Thread Turner, John

Well, in the short term, I don't think there is anything preventing you from
setting up:

site1 -> worker.site1:8009 -> tomcat1:8009 
site2 -> worker.site2:8010 -> tomcat1:8010
site3 -> worker.site3:8011 -> tomcat1:8011

That would simply require three CoyoteConnectors.  We use something similar
on our Tomcat 3.x servers...every vhost has it's own connector and connector
port, but that's using JServ.

Right now, my test box for 4.1.12 has:

site1 -> worker.site1 -> tomcat1:8009
site2 -> worker.site2 -> tomcat1:8009

But again, I haven't beat up on that, so I can't say that it works in all
cases.

John


-Original Message-
From: Madere, Colin [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 10, 2002 4:11 PM
To: 'Tomcat Users List'
Subject: RE: JK - warning/question about naming workers

Well it would make sense that all could use 8009 if they are different hosts
on different IPs, but depending on how the port is used that may not work if
you want to use a single Tomcat host for multiple Apache hosts.

That is my situation I'm trying to get working.

site1 -> worker.site1 -> tomcat1 (this works, obviously)
site2 -> worker.site? -> tomcat1
site3 -> worker.site? -> tomcat1

Any suggestions on this appreciated.  I don't want it to "just work", I want
to be sure I know why it works and that it's not going to blow up when it
goes to production.

Thanks for the super-fast feedback, John.

> -Original Message-
> From: Turner, John [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 2:21 PM
> To:   'Tomcat Users List'
> Subject:  RE: JK - warning/question about naming workers
> 
> 
> Actually, I posted too soon.  After I thought about it, I realized that I
> haven't really beat that test instance up any, I've been focusing on one
> particular webapp and one particular client/URL.
> 
> I did end up having to add another entry to workers.properties for a
> second
> hostname, though as it stands now it looks like the various workers can
> all
> use port 8009.  I will have to investigate further.
> 
> I apologize for the previously posted misinformation that said one worker
> definition could handle multiple vhosts.
> 
> John
> 
> > -Original Message-
> > From: Turner, John [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 10, 2002 2:53 PM
> > To: 'Tomcat Users List'
> > Subject: RE: JK - warning/question about naming workers
> > 
> > 
> > 
> > As far as I know, the "host" parameter in workers.properties 
> > is the lcoation
> > of the Tomcat server...it has nothing to do with the hostname 
> > used in the
> > URL.
> > 
> > If you had more than one Host in server.xml, you would put an 
> > ApacheConfig
> > Listener in there for each one.
> > 
> > I have this setup in my 4.1.12 test instance right now.  
> > There are multiple
> > Hosts in server.xml, each with one or more Contexts.  
> > Workers.properties
> > only has one worker defined, and the mod_jk.conf file generated by
> > ApacheConfig has multiple Apache VirtualHosts defined.
> > 
> > HTH
> > 
> > John
> > 
> > > -Original Message-
> > > From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, December 10, 2002 2:47 PM
> > > To: 'Tomcat Users List'
> > > Subject: JK - warning/question about naming workers
> > > 
> > > 
> > > I just fought with a problem for quite a while and thought 
> > I'd share a
> > > caution and ask a question.
> > > 
> > > The mod_jk.conf auto-generated by Tomcat assumes that your 
> > > worker for the
> > > /examples (and other default apps in Tomcat) is named 
> > > "ajp13".  If you name
> > > it anything else you'll get a 500 error since JK drops the 
> > > request due to no
> > > valid worker being found.  You MUST name a worker "ajp13" for 
> > > those things
> > > to work.
> > > 
> > > This brings up a question for me, how does Tomcat decide to 
> > > map apps to
> > > workers to auto-generate mod_jk.conf correctly?  Does it 
> > > assume that you
> > > will have all contexts that you want to map to a worker under 
> > > a single host?
> > > If so, doesn't this imply that you can't map multiple workers 
> > > to the same
> > > host (if Tomcat keys off the host)?  Am I off in left-field?  
> > > In all the
> > > documentation I've sought out did I miss the explanation of 
> > > this somewhere?
> > > 
> > > Thanks again to those vigilant responders on this list!
> > > 
> > > Colin
> > > 
> > > 
> > > --
> > > To unsubscribe, e-mail:   
> > > 
> > > For additional commands, e-mail: 
> > > 
> > > 
> > 
> > --
> > To unsubscribe, e-mail:   
> 
> For additional commands, e-mail:
> 
> 
> 
> --
> To unsubscribe, e-mail:
> 
> For additional commands, e-mail:
> 

--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked b

RE: Two instances of Tomcat

2002-12-10 Thread Turner, John

To use multiple instances of Tomcat, you don't need to install it in a
different directory.

You use CATALINA_HOME to represent Tomcat's main installation (like
/usr/local/tomcat) and then you use CATALINA_BASE to represent the "Catalina
home" for each of your Tomcat instances.  

There are others on the list that know more about JVM memory settings, but I
wanted to point out that you don't need a completely separate install of
Tomcat to run multiple instances.  One of my servers has about 15 Tomcat
instances running, but Tomcat is only installed once.

John


-Original Message-
From: Mohbe, Sameer [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 10, 2002 6:19 PM
To: '[EMAIL PROTECTED]'
Subject: Two instances of Tomcat 

Hi Folks ,
 Need some  urgent help regarding  setting  up two instances
of Tomcat .Here goes the details .We used to have Apache 1.3.23 + Tomcat
4.0.2 configuration running on Red hat 7.0.We were running two web apps
under Single instance of tomcat. To make them independent we are moving
towards Two instances of tomcat .So we installed second instance residing in
/opt/tomcat2 directory ,first being  in the directory called
/opt/tomcat.Changes on server.xml were made for  two different  port nos.Now
Everything works ok till the point  when we try to generate a report in
second web application it gives a Java.lang Out of Memory error.This Final
report feature uses the Formula 1 Software which is  a e-spreadsheet.Can any
one please tell me what all settings are required for the TWO instances of
tomcat.do we need TWO copies of  Worker.properties files (Coz we have only
one ) and if yes then what changes need to be done .Is the Java error
related to JVM memory settings .We have set TOMCAT_OPTS in /etc/profile for
-Xms64 and -Xmx512.

Regards
Sameer



--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.419 / Virus Database: 235 - Release Date: 11/13/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.419 / Virus Database: 235 - Release Date: 11/13/2002
 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




war files and context entries

2002-12-10 Thread Dave Patton
I have a war file that I deploy to my server 4.1.12.  If I just deploy
the war file without making any entries in the server.xml file and start
Tomcat, everything is fine.  OK so far.  However, if I make an explicit
context entry in the server.xml file for the war file using the
following entry:





When I try to start tomcat, it looks as if everything is going fine then
it just quits with no errors or anything.  I checked the logfile, and
the last entry is:
[timestamp] StandardContext[/cda]: Sending application start events
[timestamp] StandardContext[/cda]: Starting filters

Am I missing something here? Obviously I am cause it doesnt work.  I
know my war file is correctly configured because it works fine without
the  entry.

Dave Patton



RE: I don´t understand the objective of this open list!

2002-12-10 Thread Matthew O'Haire

If you find Tomcat hard to setup and use there are other options.  Several
vendors actually use Apache and Tomcat as OEM for their web application
servers.

One of them is Borland, who's Application Server (web server edition)
http://www.borland.com/besweb/ provides a nice management GUI for
starting/stopping/deployment/etc.  It ain't perfect but it's an improvement
on "raw" Apache/Tomcat.

You also get a vendor who supports the products and can provide assistance
(and someone to yell at ;-)  All for a pretty reasonable US$399.




Re: Weird error on Win2k server

2002-12-10 Thread Billy Ng
> Are you sure you have JDK 1.4? Do you have only the JRE or the full JDK?

Yes, we do.  The installler will call the jdk installer.



> If you have only the JRE, then that's the problem. Tomcat needs the full
> JDK version (that include a file called tools.jar).

Really?  Some told me I could include the JRE and tools.jar to run tomcat 4.
We are about to ship the app without JDK in the next version.

Billy Ng

>
> -- Jeanfrancois
>
> Billy Ng wrote:
>
> >I am testing the installer that installs our java web app, jdk 1.4,
tomcat 4 on the Win2k.  It works just fine on Win2k workstation, but not the
Win2k Server.  I get the Error 500 with
> >
> >org.apache.jasper.JasperException: Unable to compile class for JSP
> >
> >What causes that?  Please help!
> >
> >Billy Ng
> >
> >
> >
>
>
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




How does mod_jk2 find properties file.

2002-12-10 Thread Theodore A. Jencks
I'm getting a strange error when starting apache 2.0.43 running on Redhat Linux 8.0 
mod_jk2 version 2.0.2.  Here is what apache reports:

[Tue Dec 10 18:30:29 2002] [error] config.update(): Can't find config file 
/etc/httpd/conf/workers2.properties
[Tue Dec 10 18:30:29 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:29 2002] [notice] Apache configured -- resuming normal operations
[Tue Dec 10 18:30:29 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:29 2002] [error] mod_jk child init 1 0
[Tue Dec 10 18:30:30 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:31 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:31 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file
[Tue Dec 10 18:30:32 2002] [error] shm.init(): No file


This is rather strange since I've got workers2.properties configured like this:

[config:]
file=/etc/httpd/workers2.properties
debug=0
debugEnv=0

[shm:]
info=Scoreboard. Required for reconfiguration and status with multiprocess servers
file=/opt/tomcat/logs/httpd/jk2.shm
size=100
debug=0
disabled=0

When I copy workers2.properties to /etc/httpd/conf/workers2.properties it finds the 
config file.  I'm just wondering what causes jk2 to look for the workers2.properties 
file in /etc/httpd/conf when all my apache conf files are just in /etc/httpd/httpd.conf


Regards,
Theo




--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Custom Valves and Administration Tool

2002-12-10 Thread Jon Eaves
Craig R. McClanahan wrote:




First of all as there's been so much beating on the Tomcat developers
I'd like to offer my whole-hearted congratulations to each and every
one of you.  You've done a great job, and what's more, in spite of
the (unwarranted) vitriol that is spewed in your direction, you keep
coming back for more.  You guys and gals are legends.

Secondly, the community here is fantastic and the way that users came
to the "defense" of the Tomcat team was phenomenal.  Good work one and
all.  As an author involved in a similar effort (www.bouncycastle.org)
there are very few people who take the time to say "Thanks", but the
effect on the developers morale is worth it.

Remember everybody on the list, that's all they get paid in, and it
doesn't cost anything to say it

Now, if you don't mind, I've got just one more question ;-)


On Wed, 11 Dec 2002, Jon Eaves wrote:


I was hoping to manage the valves via the Administration tool.

Q1. Is this possible ?



Yes, with some work.


Aha.  I was hoping this wasn't going to be the answer.  Oh well.

[ snip ]

If this is the case, why does the code for the Valve recommend
implementing the Lifecycle interface ? What was the design reason
for that ?h

Additionally, why does the MBeans server barf when loading custom
beans without the mbeans-descriptor.xml file ? Is this due to the
Lifecycle interface being implemented, or just purely because of
the Valve definition in server.xml it is expecting to find a bean
that it can manage.

The reason I ask is because it seems bit of dicking around just to
implement a new Valve.  Writing the code took about 2 hours, it
then took 2 days to get the exception stuff sorted out.

What is the additional information used for ? And was there a better
(read simpler and less mucking around) way to solve my "get rid of
the exception" than addition of the descriptor, or is that required
for all additional components in Tomcat ?

Cheers,
	-- jon

--
Jon Eaves <[EMAIL PROTECTED]>
http://www.eaves.org/jon/


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Weird error on Win2k server

2002-12-10 Thread Jeanfrancois Arcand
Are you sure you have JDK 1.4? Do you have only the JRE or the full JDK? 
If you have only the JRE, then that's the problem. Tomcat needs the full 
JDK version (that include a file called tools.jar).

-- Jeanfrancois

Billy Ng wrote:

I am testing the installer that installs our java web app, jdk 1.4, tomcat 4 on the Win2k.  It works just fine on Win2k workstation, but not the Win2k Server.  I get the Error 500 with 

org.apache.jasper.JasperException: Unable to compile class for JSP

What causes that?  Please help!

Billy Ng

 



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Weird error on Win2k server

2002-12-10 Thread Billy Ng
I am testing the installer that installs our java web app, jdk 1.4, tomcat 4 on the 
Win2k.  It works just fine on Win2k workstation, but not the Win2k Server.  I get the 
Error 500 with 

org.apache.jasper.JasperException: Unable to compile class for JSP

What causes that?  Please help!

Billy Ng



connection problems with Tomcat 4.0.2 and Tomcat 4.1.12

2002-12-10 Thread Joaquim
Folks,

I really need some help with this problem.  Does anyone have information
that can help me?

Thank you.

--
Joaquim Laureano
Email: [EMAIL PROTECTED]



--- Begin Message ---
Hi,

I have Tomcat 4.0.2 and Tomcat 4.1.12 installed on the same server. The
application web.xml file is the same. The Tomcat's configuration file,
server.xml and web.xml, for as much as I can see, contain the same
confiured elements. The server is running behind a DFL300 firewall,
using a vitual IP address.  The server has port 80 forwarded to 8080.

Here is the problem.
If I enter http://mywebsiteIPorDNS, 4.1.12 delivers the welcome.jsp to
the browser without any problem, however, I have to add the port
(http://mywebsiteIPorDNS:80) for 4.0.2 to work. Without the port, 4.0.2
will cause the browser to give an error message saying "www.welcome.jsp
could not be found. ..."

On the other hand, while 4.0.2 works fine with the following code:

<% String avar = "dasdf"; %>


...
...

4.1.12 is unable to resolve the variable and the compiled servlet ends
up with "value=avar".

I would appreciate if anyone could help me undertand what I am missing.
Thank you.

--
Joaquim Laureano
Email: [EMAIL PROTECTED]





--- End Message ---
--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


RE: RMI Class Annotation

2002-12-10 Thread Greg Trasuk

Interesting problem.  You're right that the java.server.rmi.codebase
property is ignored in Tomcat.  The property is only used by the
RMIClassloader when a class's loader has "no obvious codebase property".  If
the classloader extends from URLClassLoader, as Tomcat's WebAppClassloader
does, then the value of getURLs() is used for the annotation.  In the case
of Tomcat, that annotation will include everything in WEB-INF/lib,
common/lib, etc.  For RMI purposes, it's entirely useless anyway, since it
doesn't contain a url to your publicly accessible classes for RMI download.
There's a way to add a real codebase (check in the tomcat-dev archives), but
you can't get rid of the stuff that's already there.  I've thought about
writing a modified WebAppClasslLoader to support RMI better, but I don't
want the support headaches!

Workaround:  Check which classes you're sending down the pipe (they're
probably arguments to an RMI method call).  Could you have the instances
created on the RMI server and sent to you?  They would then have the
server's codebase annotation rather than yours.  This should also work with
a factory object that gets sent to you by the RMI server, so long as the
classes are not available in the local classpath.  Repeat -- The classes
used as arguments in your RMI method calls should not be available in your
local WEB-INF/lib directory (although they'll have to implement interfaces
that are available locally).  I suppose you could also create a
URLClassLoader pointing to your codebase and use it to create your
instances, but it seems like a lot of work, plus you still have the need to
implement locally-available interfaces.

Hope this helps,

Greg Trasuk, President
StratusCom Manufacturing Systems Inc. - We use information technology to
solve business problems on your plant floor.
http://stratuscom.ca

>-Original Message-
>From: David Esposito [mailto:[EMAIL PROTECTED]]
>Sent: December 09, 2002 10:18
>To: [EMAIL PROTECTED]
>Subject: RMI Class Annotation
>
>
>Hello all,
>
>My problem is this: I am running Tomcat 4.1 as an embedded
>service in JBOSS
>3.0.4 ... One of my servlets makes an RMI call to an RMI
>server running on a
>different box. The problem is that the classpath that JBOSS
>creates (and
>Tomcat inherits, i believe) is so large that it actually has
>an impact on
>the performance of the RMI method invocation. That is, the
>value returned by
>RMIClassLoader.getClassAnnotation() is over 35kilobytes!!
>
>Here's just a brief snippet:
>
>file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/work/MainEngine/localh
>ost/testjms/W
>EB-INF/classes/
>file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/work/MainEngine/localh
>ost/testjms/W
>EB-INF/lib/jbossall-client.jar
>file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/work/MainEngine/localh
>ost/testjms/W
>EB-INF/lib/log4j.jar
>file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/tomcat-4.
1.x/common/li
>b/naming-common.jar/81.naming-common.jar
>file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/de
>fault/lib/jnp
>server.jar/17.jnpserver.jar
>file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/tomcat-4.
1.x/server/li
b/tomcat-jk.jar/85.tomcat-jk.jar
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/default/lib/cou
nter-plugin.jar/38.counter-plugin.jar
file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/server/classes/
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/default/deploy/
jca-service.xml/45.jca-service.xml
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/tomcat-4.1.x/server/li
b/commons-modeler.jar/86.commons-modeler.jar
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/default/lib/jbo
ssmx.jar/2.jbossmx.jar
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/default/lib/jbo
ss-j2ee.jar/16.jboss-j2ee.jar
file:/C:/jboss-3.0.4-tomcat/server/default/tmp/deploy/server/default/lib/mai
l-plugin.jar/20.mail-plugin.jar

This turns a 20ms RMI method invocation (when invoked from a standalone java
application) into a 800ms RMI method invocation (when invoked from the
servlet) because of all of the upstream bandwidth that is required ...
Needless to say, this is a problem ...

Does anyone have any input? I read a few messages that were posted about
this problem and someone commented that Tomcat is not behaving correctly;
that is, it's using the webapp's classloader's classpath instead of the RMI
codebase's classpath ... It seems to me that the RMIClassLoader should only
be concerned with classpaths set in the java.rmi.server.codebase?

Thanks in advance,
Dave


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Great Investment opportunity

2002-12-10 Thread bond
 YOU CAN BE THE TEENAGER! PARENTS OF 15 - YEAR OLD - FIND $71,000 CASH HIDDEN IN HIS 
CLOSET! Does this headline look familiar? Of course it does. You most likely havejust 
seen this story recently featured on a major nightly news program(USA). And reported 
elsewhere in the world (including my neck of the woods -New Zealand). His mother was 
cleaning and putting laundry away when shecame across a large brown paper bag that was 
suspiciously buried beneathsome clothes and a skateboard in the back of her 
15-year-old sons closet.Nothing could have prepared her for the shock she got when she 
opened thebag and found it was full of cash. Five-dollar bills, twenties, fifties 
andhundreds - all neatly rubber-banded in labeled piles. "My first thought was that he 
had robbed a bank", says the 41-year-oldwoman, "There was over $71,000 dollars in that 
bag -- that's more than myhusband earns in a year". The woman immediately called her 
husband at the car-dealership where heworked to tell him what she had discovered. He 
came home right away andthey drove together to the boys school and picked him up. 
Little did theysuspect that where the money came from was more shocking than 
actuallyfinding it in the closet.As it turns out, the boy had been sending out, 
viaE-mail, a type of "Report" to E-mail addresses that he obtained off theInternet. 
Everyday after school for the past 2 months, he had been doingthis right on his 
computer in his bedroom. "I just got the E-mail one day and I figured what the heck, I 
put my nameon it like the instructions said and I started sending it out", says 
theclever 15-year-old. The E-mail letter listed 5 addresses and contained instructions 
to sendone $5 dollar bill to each person on the list, then delete the address atthe 
top and move the others addresses Down , and finally to add your name tothe top of the 
list. The letter goes on to state that you would receive several thousanddollars in 
five-dollar bills within 2 weeks if you sent out the letter withyour name at the top 
of the 5-address list. "I get junk E-mail all the time,and really did not think it was 
going to work", the boy continues. Within the first few days of sending out the 
E-mail, the Post Office Boxthat his parents had gotten him for his video-game magazine 
subscriptionsbegan to fill up with not magazines, but envelopes containing $5 bills. 
"About a week later I rode [my bike] down to the post office and my boxhad 1 magazine 
and about 300 envelops stuffed in it. There was also a yellowslip that said I had to 
go up to the [post office] counter. I thought I was introuble or something (laughs)". 
He goes on, "I went up to the counter andthey had a whole box of more mail for me. I 
had to ride back home and emptyout my backpack because I could not carry it all". Over 
the next few weeks,the boy continued sending out the E-mail. "The money just kept 
coming inand I just kept sorting it and stashing it in the closet, barely had timefor 
my homework". He had also been riding his bike to several of the banksin his area and 
exchanging the $5 bills for twenties, fifties and hundreds. "I didn't want the banks 
to get suspicious so I kept riding to differentbanks with like five thousand at a time 
in my backpack. I would usually tellthe lady at the bank counter that my dad had sent 
me in to exchange themoney] and he was outside waiting for me. One time the lady gave 
me areally strange look and told me that she would not be able to do it for meand my 
dad would have to come in and do it, but I just rode to the next bankdown the street 
(laughs). "Surprisingly, the boy did not have any reason tobe afraid. The reporting 
news team examined and investigated the so-called "chain-letter" the boy wassending 
out and found that it was not a chain-letter at all. In fact, itwas completely legal 
according to US Postal and Lottery Laws, Title 18,Section 1302 and 1341, or Title 18, 
Section 3005 in the US code, also in thecode of federal regulations, Volume 16, 
Sections 255 and 436, which state aproduct or service must be exchanged for money 
received. Every five-dollar bill that he received contained a little note that 
read,"Please send me report number XYX". This simple note made the letter legalbecause 
he was exchanging a service (A Report on how-to) for a five-dollarfee. [This is the 
end of the media release. If you would like to understand howthe system works and get 
your $71,000 - please continue reading. Whatappears below is what the 15 year old was 
sending out on the net - YOU CANUSE IT TOO - just follow the simple instructions]. 
+++ BE FINANCIALLY FREE LIKE OTHERS 
WITHIN A YEAR!!! Before you say "Bull",please read the following. This is the letter 
you have been hearing about onthe news lately. Due to the popularity of this letter on 
the Internet, anational weekly news program recently devoted an entire show to 
theinvestigation of this program described below, 

Re: Custom Valves and Administration Tool

2002-12-10 Thread Craig R. McClanahan


On Wed, 11 Dec 2002, Jon Eaves wrote:

> Date: Wed, 11 Dec 2002 09:38:48 +1100
> From: Jon Eaves <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: Custom Valves and Administration Tool
>
> Hi all,
>
> Thanks to Bill Barker, my custom valves now are installed happily
> within Tomcat and are valving away nicely without spewing MBean
> exceptions into the log.
>
> I was hoping to manage the valves via the Administration tool.
>
> Q1. Is this possible ?

Yes, with some work.

> Q2. Do I have to modify the Admin tool ?

Yes.  You'll need to add JSP pages, a form bean, and the appropriate set
of Actions (the admin webapp is based on Struts) for your custom Valve's
properties, plus tweak the generic code for things like "add valve" to
make your type of valve an option on the list.

> Q3. How do I configure it ? (what needs to be in server.xml ?)
>

It's not really a matter of configuration -- the admin tool has specific
logic for each specific type of component that it supports.  The only
reasonably generic part is building the initial tree from the components
actually running inside Tomcat (which was in turn based on the original
contents of server.xml), and saving the updated set of components actually
running back to the server.xml file.

> I would have thought it was possible, as the Admin tool appears
> to parse the server.xml and generate stuff based on that, and my
> Valves have implemented the LifecycleListener interfaces so I'm
> a tad confused about where to go from here.
>

Ideally, the admin tool would be completely generic -- you could add your
custom components (perhaps along with a description of how they fit in in
some sort of XML file), and the admin tool would automatically build the
required screens and functionality.  IMHO, implementing this ideal in a
completely generic way is somewhere between very difficult and not
feasible if you want to end up with a high quality UI, but assistance in
doing this would be welcomed.

> Cheers,
>   -- jon
>
> PS: I've said it before, and I'll say it again, the documentation
> in Tomcat for general users/administrators is first rate. This
> stuff is a bit thin, but what they heck, most people don't need
> or want to do this.
>
> --
> Jon Eaves <[EMAIL PROTECTED]>
> http://www.eaves.org/jon/

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Specifying tag outside of server.xml

2002-12-10 Thread Craig R. McClanahan


On Tue, 10 Dec 2002, Wendy Smoak wrote:

> Date: Tue, 10 Dec 2002 09:17:34 -0700
> From: Wendy Smoak <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: "Tomcat Users List (E-mail)" <[EMAIL PROTECTED]>
> Subject: Specifying  tag outside of server.xml
>
>
> I seem to remember making files named app-context.xml and putting them in
> the 'conf' directory along with server.xml.  Probably on 3.3.1, it was that
> long ago.
>
> Now (on 4.1) from what I can tell from the admin webapp, it seems that I am
> to make an xml file matching the name of the context and put it directly in
> the webapps folder.
>
> Can someone point me to the documentation that gives the rules for this?  I
> don't want to edit server.xml if I can avoid it.
>

In 4.1, a "context configuration file" is pretty similar in spirit to the
app-context.xml file from 3.3.  You can put a  element in it, as
well as all the nested elements that are legal inside a .  It's
purpose, as you've gathered, is to avoid the need to edit server.xml
directly.

> Is there a way to include this xml file (with the  tag) in the .war
> file and have it deploy to where it belongs?  Or do you just include it and
> expect the person who's doing the deployment to move the file to the webapps
> directory?
>

There are three different ways to deploy apps that use a context
configuration file:

* Stick the XML file itself in the webapps directory.  This
  will auto-deploy an app with a context path based on the root
  part of the filename (the admin and manager webapps in a
  standard Tomcat 4.1.x install use this approach).

* You can use the "install" command of the manager webapp, and
  pass a path to a context configuration file instead of to a
  directory or a WAR.  As with other uses of "install", this works
  only if you're on a filesystem accessible to the Tomcat instance
  that is running (typically, you're on the same machine).

* You can use the "deploy" command of the manager webapp to deploy
  a WAR file, and include a "META-INF/context.xml" file inside the
  WAR for the non-default characteristics.  This capability can be
  disabled as well -- check the config docs for the  element
  for more info.

> Thanks!
>
> --
> Wendy Smoak
> Applications Systems Analyst, Sr.
> Arizona State University PA Information Resources Management
>

Craig




--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: I don´t understand the objective of this open list !

2002-12-10 Thread Craig R. McClanahan


On Tue, 10 Dec 2002, Turner, John wrote:

> You're forgetting that Tomcat is a reference implementation.

This is not actually true in the legal sense, or really any longer
relevant in the practical sense.

In the legal sense, Tomcat code is *used in* the reference implementation
for J2EE, which has been the official RI to date for the servlet and JSP
specs.  Tomcat by itself is not, and never has been, the "official" RI.
It is now possible, though (thanks to the JCP modifications championed by
Apache, and announced at JavaOne 2002), to certify that Tomcat officially
conforms to the specs -- but it is till not, on its own, the RI.

In a practical sense, way to many people have invested way too much time
in adding high qualify features and performance improvements to Tomcat to
think of it as "just" a reference implementation.  Tomcat generally gets
in the neighborhood of 80k downloads per month, just off of Apache's main
web site.  I suspect that more than a few of those downloads end up on
production servers for mission critical applications :-).

> Nobody is positioning it as a be-all, end-all commercial solution.

By the way, there is no such thing as a "be-all, end-all" solution to any
complex problem, commercial or otherwise :-).

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Q: SingleThreadModel and Tomcat

2002-12-10 Thread Craig R. McClanahan


On Mon, 9 Dec 2002, David Boyer wrote:

> Date: Mon, 09 Dec 2002 12:19:12 -0600
> From: David Boyer <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: Q: SingleThreadModel and Tomcat
>
> It seems like different servlet containers vary in how they approach access to 
>classes that implement SingleThreadModel. When multiple threads want to access the 
>class, some servlet containers will create multiple instances of the class while 
>others queue the threads for exclusive access to a single instance of the class.
>
> Which approach does Tomcat take?
>

Until relatively recently, Tomcat did the latter approach. Current
versions support a pool of instances.

However, in general, I would recommend against usting SingleThreadModel in
your applications.  The sense of thread safety that you get is an illusion
if you're also using sessions - it's very easy to triger multiple requests
to the same session at the same time.  In addition, dealing with the pool
of STM servlet instances is just wasted overhead that slows your app down.

Far better would be to learn how to write thread-safe servlets in the
first place.  It's not that hard -- the principal thing to avoid is using
instance variables (in your servlets) to represent state information for a
particular request.

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Reloading classes in shared dir

2002-12-10 Thread Craig R. McClanahan


On Mon, 9 Dec 2002, Luiz Ricardo wrote:

> Date: Mon, 9 Dec 2002 14:14:40 -0200
> From: Luiz Ricardo <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat-Users List <[EMAIL PROTECTED]>
> Subject: Reloading classes in shared dir
>
> Hi everybody,
>
> I would like to know if there is any way to configure TomCat to reload the
> classes installed in CATALINA_HOME/shared.
>

No, it's not -- and it basically cannot be.  :-(

Java does not provide any mechanisms for replacing classes in an existing
class loader.  The only thing you can do is throw away the entire class
loader itself, and create a new one (which is how Tomcat handles
application reloads).

Because the shared (and common) class loaders are parents to the webapp
class loaders, that would mean throwing away all of the current webapps
and starting over.  Essentially, you'd be doing exactly what stopping and
starting Tomcat already does.

> Luiz Ricardo

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: How to get a "File" for a certain folder

2002-12-10 Thread Craig R. McClanahan


On Mon, 9 Dec 2002, Patrick Kosiol wrote:

> Date: Mon, 09 Dec 2002 12:34:30 +0100
> From: Patrick Kosiol <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: How to get a "File" for a certain folder
>
> Hi,
>
> how can I get a File-Object for a certain Folder placed under my
> $CATALINA_HOME/webapps/ROOT/ - Folder. I want to traverse over the files
> that are placed there.
> Can anyone help me?
>

There is no guarantee that there is such a thing as a folder for your
webapps -- it's entirely legal for servlet containers to run your app
directly from a WAR file.

For maximum portability, you should use the
ServletContext.getResourcePaths() method to give you the names of the
resources in a particular "directory" of your webapp -- this will work
whether or not the container actually runs your app from an unpacked
directory.

> thx
> Patrick

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: RequestDispatcher scenarios ( was RE: static url routing)

2002-12-10 Thread Craig R. McClanahan


On Mon, 9 Dec 2002, RXZ JLo wrote:

> Date: Mon, 9 Dec 2002 03:21:25 -0800 (PST)
> From: RXZ JLo <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: RequestDispatcher scenarios ( was RE: static url routing)
>
>
> --- "Craig R. McClanahan" <[EMAIL PROTECTED]> wrote:
> > To do a redirect filter, then, you'd examine the
> > request URI to determine
> > what kind of remapping is needed, and then do a
> > RequestDispatcher.forward() call to the remapped
> > resource name.  After the
> > forward returns (which means that the actual
> > response has been created),
> > simply return instead of calling chain.doFilter() to
> > pass the request on.
> >
>
> I am looking for various scenarios where
> RequestDispatcher is used. When I searched the list, I
> noticed that it can be used in a Servlet too. What
> then is the difference between using it in a Filter
> and using it in servlet? Can I just use it in the
> Servlet to serve my purpose(of serving static
> content)?
>

If you're serving your own static content with your own servlet, then you
could do this.  Using a Filter lets you use Tomcat's standard static file
serving servlet with no modifications.

> Thank you
> rf.

Craig



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Jeanfrancois Arcand
Have you try running your test and verbosing as much as possible 
information inside the log file (increase the debug level in 
server.xml)? Try it to see if Tomcat 4.1.x output something useful to 
trace the problem. Post your result (ot the last couple of lines). Maybe 
it will help.

-- Jeanfrancois

Aymeric Alibert wrote:

Thanks for the feedback.
 
When I ran my load tests I used -Xmx512m -Xms512m as heap settings.
I also tried increasing or decreasing it but it didn't change the results.
I am running on Solaris and I have all the recommended patches for
JDK1.4.1 installed.
 
I can reproduce the problem: it is always crashing during the test,
but it can be after 2 minutes or 20 minutes depending on the run.
My problem is that I cannot create a simple test case that will crash the
server because of the complexity of our environment ( it includes 
multiples
Oracle databases and LDAP connectivity).
I tried to isolate the problem to a single jsp like you recommend 
it but that didn't work.
(I could fine several combinations that would trigger the crash).
So I am not sure what I could provide as a test case except our full 
dev environment.
 
I can deploy the same application on TC4.0.4 and it runs fine. I tried 
many versions
of Tomcat 4.1 (4.1.7, 4.1.12, 4.1.14 and 4.1.16) and are all failing.

I attached the VM log.
 
Thanks,
 
 
Aymeric
 
 

>>> [EMAIL PROTECTED] 12/10/02 04:48PM >>>
Howdy,
If your OS requires patches in order to run the JDK (whatever version
you're trying to run), make sure those patches are installed.  I had
this exact issue happen on Solaris, and installing the proper Solaris
patches made it go away.

You say "The same behavior can be reproduced with both JDK1.4.0 and
JDK1.4.1" and yet "I cannot create a test case to reproduce my problem."
Which one is it?  ;)  If you can reproduce it, the full details of how
to reproduce it can be posted to Sun's bug parade, and they'll track
down whatever tools they need in order to mimic your environment.  If
you can't reproduce it, there's no bug as far as they're concerned.

Finally, I'm not sure I understand this bullet:

>- I works fine with TC4.1

So your app works fine on TC 4.1?  I thought that was the whole problem?
Or did you mean it works fine with TC 4.0 and not 4.1?  If it's the
latter, as I suspect, perhaps you could start by deploying a very small
subset of your app and repeating the test.  Then increase the deployed
subset and retest.  The idea is that a certain feature of tomcat as used
by your app is crashing the VM, and to find out which section of your
app is causing this.  The more you can narrow it down, the better.

Yoav Shapira
Millennium ChemInformatics

--
To unsubscribe, e-mail:   

For additional commands, e-mail: 




--
To unsubscribe, e-mail:   
For additional commands, e-mail: 



RE: TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Aymeric Alibert



Thanks for the feedback.
 
When I ran my load tests I used -Xmx512m -Xms512m as heap settings. 
I also tried increasing or decreasing it but it didn't change the 
results.
I am running on Solaris and I have all the recommended patches for 
JDK1.4.1 installed.
 
I can reproduce the problem: it is always crashing during the test, 
but it can be after 2 minutes or 20 minutes depending on the run.
My problem is that I cannot create a simple test case that will crash 
the
server because of the complexity of our environment ( it includes multiples 

Oracle databases and LDAP connectivity). 
I tried to isolate the problem to a single jsp like you recommend 
it but that didn't work.
(I could fine several combinations that would trigger the crash).
So I am not sure what I could provide as a test case except our full dev 
environment.
 
I can deploy the same application on TC4.0.4 and it runs fine. I tried many 
versions
of Tomcat 4.1 (4.1.7, 4.1.12, 4.1.14 and 4.1.16) and are all failing.
I attached the VM log.
 
Thanks, 
 
 
Aymeric
 
 
>>> [EMAIL PROTECTED] 12/10/02 04:48PM 
>>>Howdy,If your OS requires patches in order to run the JDK 
(whatever versionyou're trying to run), make sure those patches are 
installed.  I hadthis exact issue happen on Solaris, and installing the 
proper Solarispatches made it go away.You say "The same behavior can 
be reproduced with both JDK1.4.0 andJDK1.4.1" and yet "I cannot create a 
test case to reproduce my problem."Which one is it?  ;)  If you 
can reproduce it, the full details of howto reproduce it can be posted to 
Sun's bug parade, and they'll trackdown whatever tools they need in order to 
mimic your environment.  Ifyou can't reproduce it, there's no bug as 
far as they're concerned.Finally, I'm not sure I understand this 
bullet:>- I works fine with TC4.1So your app works fine on TC 
4.1?  I thought that was the whole problem?Or did you mean it works 
fine with TC 4.0 and not 4.1?  If it's thelatter, as I suspect, perhaps 
you could start by deploying a very smallsubset of your app and repeating 
the test.  Then increase the deployedsubset and retest.  The idea 
is that a certain feature of tomcat as usedby your app is crashing the VM, 
and to find out which section of yourapp is causing this.  The more you 
can narrow it down, the better.Yoav ShapiraMillennium 
ChemInformatics--To unsubscribe, e-mail:   For 
additional commands, e-mail: 


hs_err_pid13559.log
Description: Binary data
--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


Regarding post: http://www.mail-archive.com/glenn@zathras.earthdome.org/msg00092.html

2002-12-10 Thread James Chrystal



Glenn,
 
    You had mentioned this problem 
back in February, but got it resolved via xms.  What settings did you use? 
I've got a 500Mhz machine with 512 MB RAM.  It's running a lot of programs, 
so giving it much more than 128 MB is out of the question.
 
JC
--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


Re: Off Topic: SAP DB

2002-12-10 Thread Peng Tuck Kwok
Yes. working fine for me. Works ok with sun app server as well.


Fabio Mengue wrote:

Hello,

Does anyone here has tested or uses SAP DB (www.sapdb.org) ?

I am willing to try it, but the setup is a little complicated.

Thanks,

Fabio.





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat/HTTPD Integration

2002-12-10 Thread Noel J. Bergman
Garrett,

I am heading out for the evening, but your configuration is similar to one
on John Turner's site, so take a look at:

  http://www.johnturner.com/howto/apache2-tomcat4112-sol8-howto.html

Hope that helps.

--- Noel

-Original Message-
From: Johnson, Garrett [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 17:39
To: 'Tomcat Users List'
Subject: RE: Tomcat/HTTPD Integration


I'm sorry, I didn't make this clear.  I should've discussed my environment:

Win2K
Apache 2.0
Tomcat 4.1
mod_jk installed.

The question I have is, what am I missing?  I've changed the httpd.conf
file, and now at the end it has:

LoadModule jk_module modules/mod_jk.dll
JkWorkersFile conf/workers.properties
JkLogFile logs/mod_jk.log
JkLogLevel info
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
JkRequestLogFormat "%w %V %T"
JkMount /*.jsp worker1
JkMount /*Servlet worker1

However, this doesn't cut it.  I can't understand why... :(

As for the RequestDispatcher/request.sendRedirect, yup, that's EXACTLY what
I needed.  SNIFF - I look at the j2ee API for hours and couldn't stumble
across that. :D

-Original Message-
From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 5:32 PM
To: Tomcat Users List
Subject: RE: Tomcat/HTTPD Integration


Garrett,

> 1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd like
> to be able to access it using Apache HTTPD instead of Tomcat's built-in
> server.

Right.  You setup a connector, e.g., mod_jk, mod_jk2, mod_webapp.  Heck, I
even have a case where I have mod_proxy being used (don't ask why -- archaic
and going away, but it works)!

ref: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/connectors.html

> How do I both instruct Apache to serve up all requests for the root
> directory to Tomcat, and how do I set up that alias to use MY index
> page?

It is easier than you think.  Check the docs for your connector of choice.
The best documentation is probably for mod_jk.

If you want a laugh, here is how you do it with mod_rewrite/mod_proxy:

RewriteRule   ^/(.*)$   http://localhost:8080/$1 [P]
ProxyPassReverse  / http://localhost:8080/

Again, *not* something I recommend.  [FWIW, you could use ProxyPass instead
of a rewrite rule, but there is a lot more going on that isn't shown above.]

> context.getRequestDispatcher("/start.jsp" );
> how do I get the URL on the client side to reflect the forwarding?

If you want the browser to go back to the start.jsp page, you send it there
with request.sendRedirect("/start.jsp"), not a RequestDispatcher.

> Thanks in advance, kids...

You're welcome gramps ...  ;-)

--- Noel


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Two instances of Tomcat

2002-12-10 Thread Mohbe, Sameer
Hi Folks ,
 Need some  urgent help regarding  setting  up two instances
of Tomcat .Here goes the details .We used to have Apache 1.3.23 + Tomcat
4.0.2 configuration running on Red hat 7.0.We were running two web apps
under Single instance of tomcat. To make them independent we are moving
towards Two instances of tomcat .So we installed second instance residing in
/opt/tomcat2 directory ,first being  in the directory called
/opt/tomcat.Changes on server.xml were made for  two different  port nos.Now
Everything works ok till the point  when we try to generate a report in
second web application it gives a Java.lang Out of Memory error.This Final
report feature uses the Formula 1 Software which is  a e-spreadsheet.Can any
one please tell me what all settings are required for the TWO instances of
tomcat.do we need TWO copies of  Worker.properties files (Coz we have only
one ) and if yes then what changes need to be done .Is the Java error
related to JVM memory settings .We have set TOMCAT_OPTS in /etc/profile for
-Xms64 and -Xmx512.

Regards
Sameer



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat 4.1, DBCP and Oracle

2002-12-10 Thread Sundar Chakravarthy
I got it working, just put the ResourceParam entry inside
The right context ( example in my case )in server.xml and not as the doc says i.e 
Between  and 


-Original Message-
From: Thomas Achleitner [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 10, 2002 2:11 AM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle

Good Morning!

Yes, i just renamed classes12.zip to classes12.jar. Tomcat should recognize it when 
rebooting the server!
No further repackaging necessary!

How do you know that tomcat didn't recognize classes12.jar?

thomas

-Original Message-
From: Campano, Troy [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 5:57 PM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Damn, I'm still getting the same error after I re-did my configuration like yours.
java.sql.SQLException: Cannot load JDBC driver class 'null'

When you put your JAR into /common/lib/ did Tomcat automatically recognize it when you 
rebooted the server?
Mine didn't, though it did in Tomcat 4.0.x.
I wonder if that had something to do with it.

Did all you do was rename classes12.zip to classes12.jar?
Did you have to do any repackaging?

thank you!

~ t r o y ~

-Original Message-
From: Thomas Achleitner [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 11:38 AM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Here are the relevant snapshots of the code (classes12.jar in common/lib):
server.xml:

 
factoryoracle.jdbc.pool.OracleDataSourceFactory
userNamescott
passwordtiger
driverClassNameoracle.jdbc.OracleDriver
urljdbc:oracle:thin:@testdb:1525:ORA5


web.xml:

  Resource reference to a factory for java.sql.Connection
  instances that may be used for talking to a particular
  database that is configured in the server.xml file.
  jdbc/OracleDS
  javax.sql.DataSource
  Container


Source code that obtains connection:
initCtx = new InitialContext();
envCtx = (Context) initCtx.lookup("java:comp/env");
dataSource = (DataSource) envCtx.lookup("jdbc/OracleDS");
con = dataSource.getConnection();

hope that helps !
thomas

-Original Message-
From: Campano, Troy [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 5:26 PM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Woa...

Could you send me a copy of your server.xml, web.xml, and how you create the 
connection in your Servlet/JSP?

That would be greatly appreciated.


thank you very much!

~ t r o y ~

-Original Message-
From: Thomas Achleitner [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 11:24 AM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


hi!
tomcat 4.1.12
classes12.jar

thomas

-Original Message-
From: Campano, Troy [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 5:22 PM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Hi Thomas...

What version of Tomcat are you using?
Are you using classes12.jar (zip)?

thanks!

~ t r o y ~


-Original Message-
From: Thomas Achleitner [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 11:15 AM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


hi troy!

You can take oracle.jdbc.OracleDriver as well (the oracle forum told me that 
oracle.jdbc.driver.OracleDriver is only kept for backwards compatibility). If I remove 
following parameters then it works fine with my application:

  maxLimit
  10


  minLimit
  5


  cacheScheme
  1


I think you should have a look at the docu for those parameters. I just have no idea 
why they don't work. The parameter user should be changed to userName as well 
(casesensitive).

thomas

-Original Message-
From: Campano, Troy [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 4:53 PM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Hello Thomas,
I take it you mean oracle.jdbc.driver.OracleDriver.
I added it, bounced the server, and still the same dreadful error:

java.sql.SQLException: Cannot load JDBC driver class 'null'


thank you for your help though!

~ t r o y ~


-Original Message-
From: Thomas Achleitner [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 10:44 AM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Hi!
I think paraemter driverClassName is missing. Try: 
driverClassNameoracle.jdbc.OracleDriver

hope this helps!

thomas

-Original Message-
From: Campano, Troy [  
mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 4:36 PM
To: Balzarotti Paolo; Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle


Nope...no luck.
Same error:
java.sql.SQLException: Cannot load JDBC driver class 'null'

My server.xml looks like this now:


  

RE: Ship java app to windows box

2002-12-10 Thread Steve Stearns
On Tue, 2002-12-10 at 16:49, Johnson, Garrett wrote:
> There are a lot of reasons why one would prefer java over asp, but why not
> just take this position with the IT people:
> TOUGH.
> The fact is, they're IT.  If you, as a developer decide, as part of your
> job, that a problem cannot be solved without using java, then they, as IT
> people, as part of their jobs, need to make that work.

Ultimately what this all boils down to is the age old question of
business cases for anything.  What does it cost the IT department to
install and support tomcat?  What does it cost to develop the entire
application in two different environments?  It is better for the
business, to do this in the most cost-effective way possible.  Unless
the IT people can demonstrate that it costs too much to support this,
then they should just cope.

The job of IT and developers is to find the most effective way to get
the job done.  Sometimes IT is right to shoot down the developers, but
it doesn't sound like that's the case here.  

---Steve


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Jeanfrancois Arcand


Aymeric Alibert wrote:


We are running a Tomcat 4.0 server in our production environment and
I am trying to upgrade to Tomcat 4.1.

I ran some load test recently and was horrified to see the server crashing even
under moderate load. After more testing, I found that starting the VM with the
-server option systematically crash the VM after few minutes of load test.
The server works fine even under heavy load with the -client option.
The same behavior can be reproduced with both JDK1.4.0 and JDK1.4.1.

My TC4.0 server runs fine with the -server option.


If you application runs fine with the -client option, why not using that 
option? Also, have you try to increased the memory allocated for Tomcat 
(using the -Xmx option)?

Are you sure your test is correct, meaning are youy testing a situation 
that will never occurs? (probably not :-))


Now, this is obviously a JVM problem but probably won't have any help from 
SUN since:
- I cannot create a test case to reproduce my problem.
- I works fine with TC4.1

Can someone help me with this issue or at least guide me to the right contact?
I found several tickets opened on the SUN bug database with similar issues but
none of them had a resolution or people assigned to work on them.

;-) I know. As with any technology, you need a clear test case. I just 
spend weeks trying to reproduce a Xerces bug outside Tomcat. Until a 
genious Tomcat user  found the a test case, the Xerces team (with 
reason) did want to look at my stuff :-( )

-- Jeanfrancois


Thanks!

Aymeric

 



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Shapira, Yoav
Howdy,
If your OS requires patches in order to run the JDK (whatever version
you're trying to run), make sure those patches are installed.  I had
this exact issue happen on Solaris, and installing the proper Solaris
patches made it go away.

You say "The same behavior can be reproduced with both JDK1.4.0 and
JDK1.4.1" and yet "I cannot create a test case to reproduce my problem."
Which one is it?  ;)  If you can reproduce it, the full details of how
to reproduce it can be posted to Sun's bug parade, and they'll track
down whatever tools they need in order to mimic your environment.  If
you can't reproduce it, there's no bug as far as they're concerned.

Finally, I'm not sure I understand this bullet:

>- I works fine with TC4.1

So your app works fine on TC 4.1?  I thought that was the whole problem?
Or did you mean it works fine with TC 4.0 and not 4.1?  If it's the
latter, as I suspect, perhaps you could start by deploying a very small
subset of your app and repeating the test.  Then increase the deployed
subset and retest.  The idea is that a certain feature of tomcat as used
by your app is crashing the VM, and to find out which section of your
app is causing this.  The more you can narrow it down, the better.

Yoav Shapira
Millennium ChemInformatics

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Ship java app to windows box

2002-12-10 Thread Johnson, Garrett
There are a lot of reasons why one would prefer java over asp, but why not
just take this position with the IT people:

TOUGH.

The fact is, they're IT.  If you, as a developer decide, as part of your
job, that a problem cannot be solved without using java, then they, as IT
people, as part of their jobs, need to make that work.

You have described, as a reason to use Tomcat, a valid, legitimate business
case:  (Portability.)

The IT guys have not: ("really don't like to?"  What are you, kidding?)

And what's the big deal about installing the JDK and Tomcat?  Now that
Tomcat 4.1 is available in a binary install, a _monkey_ could install them
both.

-Original Message-
From: Steve Stearns [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 5:35 PM
To: Tomcat Users List
Subject: Re: Ship java app to windows box


On Tue, 2002-12-10 at 15:46, Billy Ng wrote:
> Hi folks,
> 
> I really need some opinion here.  We build the web app with java
> because it is portable, but some of the IT guys really don't like to
> install tomcat, jdk on their Windows boxes.  My question is if it is
> common to ship java web app to Windows box with tomcat and jdk.  They
> said we should not even build the java app in the first place.  They
> want ASP.  I was shipping products to Unix boxes so I don't know why
> Windows people will have such complaints.  If you have shipped your
> java web app to Windows box before, please share your opinion with me.

Shipping a java app to windows is common assuming that you aren't intent
on running ASP's.  IIS will integrate with web application servers,
including tomcat, websphere and weblogic.  It makes perefect sense to do
this if Java provides benefits to you that make it a superiror choice to
ASP's.  In your case, the primary benefit seems to be cross-platform
capability, which is something ASP's definitely cannot do.

Running tomcat is an effective and low-cost way of running your java web
application in a windows environment.  If you need to deploy in a
homogenous environment it makes a lot more sense to install Tomcat on
the windows box than to rewrite the entire application to run in two
different environments.  Using tomcat to run a java web application is
really no different than using IIS to run ASP's, it just happens to be
that IIS is pre-installed on windows whereas you actually have to
install Tomcat yourself.   

I've deployed java applications to windows environments many times, and
I've always done so because I wanted to have the flexibility to deploy
on different platforms.  We could have a religious war over whether
ASP's or JSP's are better, but ultimately if cross-platform capability
is important, only one of these is the correct answer.

---Steve



--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Pooleery, Manoj
This looks more likely a memory issue to me.  Have you tried setting the
heap size for the JVM?  I had faced a similar problem earlier and it was
solved when I changed the heap memory settings.  Depending upon the server's
memory, you can use the '-Xmx xxk -Xms xxk' option to change your heap
settings.

-Manoj.

-Original Message-
From: Aymeric Alibert [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 5:38 PM
To: <
Subject: TC 4.1 and VM crash: how to report issue?


We are running a Tomcat 4.0 server in our production environment and
I am trying to upgrade to Tomcat 4.1.

I ran some load test recently and was horrified to see the server crashing
even
under moderate load. After more testing, I found that starting the VM with
the
-server option systematically crash the VM after few minutes of load test.
The server works fine even under heavy load with the -client option.
The same behavior can be reproduced with both JDK1.4.0 and JDK1.4.1.

My TC4.0 server runs fine with the -server option.

Now, this is obviously a JVM problem but probably won't have any help from 
SUN since:
- I cannot create a test case to reproduce my problem.
- I works fine with TC4.1

Can someone help me with this issue or at least guide me to the right
contact?
I found several tickets opened on the SUN bug database with similar issues
but
none of them had a resolution or people assigned to work on them.

Thanks!

Aymeric



Custom Valves and Administration Tool

2002-12-10 Thread Jon Eaves
Hi all,

Thanks to Bill Barker, my custom valves now are installed happily
within Tomcat and are valving away nicely without spewing MBean
exceptions into the log.

I was hoping to manage the valves via the Administration tool.

Q1. Is this possible ?
Q2. Do I have to modify the Admin tool ?
Q3. How do I configure it ? (what needs to be in server.xml ?)

I would have thought it was possible, as the Admin tool appears
to parse the server.xml and generate stuff based on that, and my
Valves have implemented the LifecycleListener interfaces so I'm
a tad confused about where to go from here.

Cheers,
	-- jon

PS: I've said it before, and I'll say it again, the documentation
in Tomcat for general users/administrators is first rate. This
stuff is a bit thin, but what they heck, most people don't need
or want to do this.

--
Jon Eaves <[EMAIL PROTECTED]>
http://www.eaves.org/jon/


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




TC 4.1 and VM crash: how to report issue?

2002-12-10 Thread Aymeric Alibert
We are running a Tomcat 4.0 server in our production environment and
I am trying to upgrade to Tomcat 4.1.

I ran some load test recently and was horrified to see the server crashing even
under moderate load. After more testing, I found that starting the VM with the
-server option systematically crash the VM after few minutes of load test.
The server works fine even under heavy load with the -client option.
The same behavior can be reproduced with both JDK1.4.0 and JDK1.4.1.

My TC4.0 server runs fine with the -server option.

Now, this is obviously a JVM problem but probably won't have any help from 
SUN since:
- I cannot create a test case to reproduce my problem.
- I works fine with TC4.1

Can someone help me with this issue or at least guide me to the right contact?
I found several tickets opened on the SUN bug database with similar issues but
none of them had a resolution or people assigned to work on them.

Thanks!

Aymeric



RE: Tomcat/HTTPD Integration

2002-12-10 Thread Johnson, Garrett
I'm sorry, I didn't make this clear.  I should've discussed my environment:

Win2K
Apache 2.0
Tomcat 4.1
mod_jk installed.

The question I have is, what am I missing?  I've changed the httpd.conf
file, and now at the end it has:

LoadModule jk_module modules/mod_jk.dll
JkWorkersFile conf/workers.properties 
JkLogFile logs/mod_jk.log 
JkLogLevel info 
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] " 
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories 
JkRequestLogFormat "%w %V %T" 
JkMount /*.jsp worker1
JkMount /*Servlet worker1

However, this doesn't cut it.  I can't understand why... :(

As for the RequestDispatcher/request.sendRedirect, yup, that's EXACTLY what
I needed.  SNIFF - I look at the j2ee API for hours and couldn't stumble
across that. :D

-Original Message-
From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 5:32 PM
To: Tomcat Users List
Subject: RE: Tomcat/HTTPD Integration


Garrett,

> 1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd like
> to be able to access it using Apache HTTPD instead of Tomcat's built-in
> server.

Right.  You setup a connector, e.g., mod_jk, mod_jk2, mod_webapp.  Heck, I
even have a case where I have mod_proxy being used (don't ask why -- archaic
and going away, but it works)!

ref: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/connectors.html

> How do I both instruct Apache to serve up all requests for the root
> directory to Tomcat, and how do I set up that alias to use MY index
> page?

It is easier than you think.  Check the docs for your connector of choice.
The best documentation is probably for mod_jk.

If you want a laugh, here is how you do it with mod_rewrite/mod_proxy:

RewriteRule   ^/(.*)$   http://localhost:8080/$1 [P]
ProxyPassReverse  / http://localhost:8080/

Again, *not* something I recommend.  [FWIW, you could use ProxyPass instead
of a rewrite rule, but there is a lot more going on that isn't shown above.]

> context.getRequestDispatcher("/start.jsp" );
> how do I get the URL on the client side to reflect the forwarding?

If you want the browser to go back to the start.jsp page, you send it there
with request.sendRedirect("/start.jsp"), not a RequestDispatcher.

> Thanks in advance, kids...

You're welcome gramps ...  ;-)

--- Noel


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Ship java app to windows box

2002-12-10 Thread Steve Stearns
On Tue, 2002-12-10 at 15:46, Billy Ng wrote:
> Hi folks,
> 
> I really need some opinion here.  We build the web app with java
> because it is portable, but some of the IT guys really don't like to
> install tomcat, jdk on their Windows boxes.  My question is if it is
> common to ship java web app to Windows box with tomcat and jdk.  They
> said we should not even build the java app in the first place.  They
> want ASP.  I was shipping products to Unix boxes so I don't know why
> Windows people will have such complaints.  If you have shipped your
> java web app to Windows box before, please share your opinion with me.

Shipping a java app to windows is common assuming that you aren't intent
on running ASP's.  IIS will integrate with web application servers,
including tomcat, websphere and weblogic.  It makes perefect sense to do
this if Java provides benefits to you that make it a superiror choice to
ASP's.  In your case, the primary benefit seems to be cross-platform
capability, which is something ASP's definitely cannot do.

Running tomcat is an effective and low-cost way of running your java web
application in a windows environment.  If you need to deploy in a
homogenous environment it makes a lot more sense to install Tomcat on
the windows box than to rewrite the entire application to run in two
different environments.  Using tomcat to run a java web application is
really no different than using IIS to run ASP's, it just happens to be
that IIS is pre-installed on windows whereas you actually have to
install Tomcat yourself.   

I've deployed java applications to windows environments many times, and
I've always done so because I wanted to have the flexibility to deploy
on different platforms.  We could have a religious war over whether
ASP's or JSP's are better, but ultimately if cross-platform capability
is important, only one of these is the correct answer.

---Steve



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat/HTTPD Integration

2002-12-10 Thread Noel J. Bergman
Garrett,

> 1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd like
> to be able to access it using Apache HTTPD instead of Tomcat's built-in
> server.

Right.  You setup a connector, e.g., mod_jk, mod_jk2, mod_webapp.  Heck, I
even have a case where I have mod_proxy being used (don't ask why -- archaic
and going away, but it works)!

ref: http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/connectors.html

> How do I both instruct Apache to serve up all requests for the root
> directory to Tomcat, and how do I set up that alias to use MY index
> page?

It is easier than you think.  Check the docs for your connector of choice.
The best documentation is probably for mod_jk.

If you want a laugh, here is how you do it with mod_rewrite/mod_proxy:

RewriteRule   ^/(.*)$   http://localhost:8080/$1 [P]
ProxyPassReverse  / http://localhost:8080/

Again, *not* something I recommend.  [FWIW, you could use ProxyPass instead
of a rewrite rule, but there is a lot more going on that isn't shown above.]

> context.getRequestDispatcher("/start.jsp" );
> how do I get the URL on the client side to reflect the forwarding?

If you want the browser to go back to the start.jsp page, you send it there
with request.sendRedirect("/start.jsp"), not a RequestDispatcher.

> Thanks in advance, kids...

You're welcome gramps ...  ;-)

--- Noel


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Ship java app to windows box

2002-12-10 Thread Noel J. Bergman
> I really need some opinion here.  We build the web app with java
> because it is portable

Good idea.

> but some of the IT guys really don't like to install tomcat, jdk
> on their Windows boxes.

And do their personal preferences matter?  You install what you need to
install in order to get the job done.

> My question is if it is common to ship java web app to Windows box
> with tomcat and jdk.

The answer is yes, if one is foolish enough (or forced) to use Windows as a
server platform [to cut down in the flame-fest, note that I am posting this
from a WinXP box using Outlook], then it is perfectly common to ship a java
webapp on a Windows box.

> They said we should not even build the java app in the first place.
> They want ASP.

Gee, what a shock.  Remember your first point: "We build the web app with
java because it is portable."  Good idea.  Stick with it.

> I was shipping products to Unix boxes so I don't know why Windows
> people will have such complaints.

Because some people treat operating systems like religions, instead of the
tools that they are.

--- Noel


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Non-ending servlet request threads - timeout? (StandardWrapper)

2002-12-10 Thread Justin Ruthenbeck

All --

Tomcat 4.0.3 (integrated jBoss)
Apache 2.0.40
jk
JDK 1.3.0

We're using jBoss/Tomcat to provide a web front-end to a java application 
which can generally be considered stand-alone.  Normal requests are 
processed by this application and return quickly, but we occasionally run 
into problems where, for one reason or another, the request thread can 
never return (due to a problem in the stand-alone application).  This 
results in the user seeing spinning globes in their browser until the 
request times out and the user goes about their business.  However...

On the Tomcat side, the request thread never appears to timeout.  In the 
shorterm, this causes no problems, but get enough of these, and there's 
obvious problems with non-recoverable threads.  This can be seen when we 
try to shut Tomcat down with the StandardWrapper's message "Waiting for X 
instance(s) to be deallocated".  Since the threads apparently don't 
timeout, the shutdown hangs and I have to kill the process 
alltogether.  Not ideal, especially during development.  

Any ideas on how to force these threads to timeout?  I feel like I must be 
missing something since I would imagine this is something many people may 
run into.

Thanks for any insights or observations...
justin


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 



FormBased Authentication

2002-12-10 Thread Hari Venkatesan


I have IIS 5.0 configured with Tomcat 4.1.12. My form based
authentication is failing to find j_security_check and comes back with
resource not available. 

The same code when executed with normal http server works. 

Any ideas? ?

Hari

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Ship java app to windows box

2002-12-10 Thread Shapira, Yoav
Howdy,
If they want you to write you app in ASP, they must have a server
somewhere where they plan to install your app.

If possible, you should simply install the JDK and Tomcat on that server
and then ship your java app to it.  

I realize corporate policies differ greatly in this area, but the
support staff at companies I've worked / run projects for have generally
been amenable to the above logic.

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Billy Ng [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, December 10, 2002 4:46 PM
>To: Tomcat Users List
>Subject: Ship java app to windows box
>
>Hi folks,
>
>I really need some opinion here.  We build the web app with java
because it
>is portable, but some of the IT guys really don't like to install
tomcat,
>jdk on their Windows boxes.  My question is if it is common to ship
java
>web app to Windows box with tomcat and jdk.  They said we should not
even
>build the java app in the first place.  They want ASP.  I was shipping
>products to Unix boxes so I don't know why Windows people will have
such
>complaints.  If you have shipped your java web app to Windows box
before,
>please share your opinion with me.
>
>Thanks!
>
>Billy Ng

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Tomcat/HTTPD Integration

2002-12-10 Thread Johnson, Garrett
Ladies and Gentlemen:

I've got 2 problems here:

1.  I've got a webapp sitting in the /webapps/ROOT directory, and I'd like
to be able to access it using Apache HTTPD instead of Tomcat's built-in
server.  However, the way it's set up now, simply typing in
http://www.myserver.com will bring up my index.jsp page.  How do I both
instruct Apache to serve up all requests for the root directory to Tomcat,
and how do I set up that alias to use MY index page?

2.  I'm currently instructing my servlet to handle erroneous form data by
sending the user back to the JSP with the form in it, with a flag embedded
within the request.  This let's me force them to resubmit, only with
reminder messages.  The code on the servlet side looks essentially like
this:

try
{
updateDatabase( req ); //My own method
}
catch( SQLException e )
{
req.setAttribute( "error", "true );
ServletContext context = getServletContext();
RequestDispatcher dispatcher = context.getRequestDispatcher(
"/start.jsp" );
dispatcher.forward( req, res );
}

My question is, how do I get the URL on the client side to reflect the
forwarding?  Right now, the URL in the browser still indicates that they're
being handled by the servlet, while I want it to indicate that they've
returned to http://www.myserver.com/start.jsp.

Thanks in advance, kids...

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Run Servlet on Tomcat Start-up.

2002-12-10 Thread Noel J. Bergman
See the load-on-startup element in the Servlet 2.3 specification.  There is
a commented out example in webapps/webdav/web-inf/web.xml.

--- Noel


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Ship java app to windows box

2002-12-10 Thread Billy Ng
Hi folks,

I really need some opinion here.  We build the web app with java because it is 
portable, but some of the IT guys really don't like to install tomcat, jdk on their 
Windows boxes.  My question is if it is common to ship java web app to Windows box 
with tomcat and jdk.  They said we should not even build the java app in the first 
place.  They want ASP.  I was shipping products to Unix boxes so I don't know why 
Windows people will have such complaints.  If you have shipped your java web app to 
Windows box before, please share your opinion with me.

Thanks!

Billy Ng



Run Servlet on Tomcat Start-up.

2002-12-10 Thread vim m

Hi:

I would like to automatically run a servlet everytime my Tomcat server is restarted. 
Is there any way that could be done? 

Any pointers appreciated.

Thanks.

 



-
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now


RE: Large JSP causes tomcat to crash with multiple users

2002-12-10 Thread khaled . saleh
There is no performance problems when the page loads without crashing the
JVM, it loads quickly.

The JSP make calls to beans, and there are a couple of queries that are
submitted to the database.  The JDBC is in Java and there is no JNI calls
made anywhere is the code.

The weared thing is, why splitting the JSP file into two files fixes the
problem?

I filed a bug on the java's bug site with the following information, not
sure if it will be helpful:

Message from hotspot
#
# HotSpot Virtual Machine Error, Internal Error
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Error ID: 47454E45524154452F4F502D41500E435050084B 01
#
# Problematic Thread: prio=5 tid=0x66daa8 nid=0x17 runnable
#


Stack trace for the failing thread (from the core file):

current thread: t@23
=>[1] __sigprocmask(0x0, 0xd687e528, 0x0, 0x0, 0x0, 0x0),
at 0xff369ab8
  [2] _resetsig(0xff36c340, 0x0, 0x0, 0xd6881d78,
0xff37e000, 0x0), at 0xff35e50c
  [3] _sigon(0xd6881d78, 0xff385980, 0x6, 0xd687e5fc,
0xd6881d78, 0xd687e640), at 0xff35dcac
  [4] _thrp_kill(0x0, 0x17, 0x6, 0xff37e000, 0x17,
0xff2bc4a0), at 0xff360cc0
  [5] raise(0x6, 0x0, 0x0, 0x, 0xff2bc40c,
0xd687e750), at 0xff24b190
  [6] abort(0xff2b801c, 0xd687e750, 0x0, 0xfff8, 0x4,
0xd687e771), at 0xff2357bc
  [7] os::abort(0x1, 0xfe796000, 0x1, 0xfe796000, 0x66daa8,
0xd687e76c), at 0xfe6e7ac4
  [8] report_error(0xdc, 0xd687eff4, 0x84b, 0xfe746da0,
0xfe7d1830, 0xfe796000), at 0xfe652c08
  [9] report_fatal(0x84b, 0xfe796000, 0xfe748ed8,
0xd687fc3c, 0xfe7a7fdc, 0xfe796000), at 0xfe6524d8
  [10] GenerateOopMap::error_work(0xfe796000, 0xfe749230,
0xd687fc3c, 0x0, 0xd687fbec, 0xfd9), at 0xfe660b98
  [11] GenerateOopMap::report_error(0xd687ff1c, 0xfe749230,
0x4057, 0x4, 0xd687fcf4, 0x66daa8), at 0xfe660bcc
  [12] GenerateOopMap::expand_current_instr(0xd687ff1c,
0x4057, 0xfe796000, 0x4, 0xd687fcf4, 0x4057), at 0xfe662384
  [13] GenerateOopMap::rewrite_load_or_store(0x2,
0xfe796000, 0x4, 0x2a, 0x11a, 0xd687fd68), at 0xfe6428f8
  [14] GenerateOopMap::rewrite_refval_conflicts(0xd687ff1c,
0xfabf9610, 0x111d710, 0xfe796000, 0xfe7d307c, 0xfe7d3b2c),
at 0xfe57c3b8
  [15] GenerateOopMap::compute_map(0xfe79f720, 0xfa0f36dc,
0xfe796000, 0x, 0x1, 0x0), at 0xfe5751f0
  [16] ResolveOopMapConflicts::do_potential_rewrite
(0xd6880018, 0xd6880018, 0xd687ff1c, 0x,
0xfff8, 0xfa0f9a50), at 0xfe574b2c
  [17] Rewriter::rewrite_method(0xd6880018, 0xfe796000,
0xd688001c, 0x66daa8, 0xfe7d307c, 0xfe7d3b2c), at 0xfe56a940
  [18] Rewriter::rewrite(0xfe7d3b28, 0xfe7d3b24, 0x1, 0x4,
0x8, 0xf8e45728), at 0xfe569e94
  [19] instanceKlass::link_class_impl(0xf8c00af8, 0x66daa8,
0xd6880238, 0xfe796000, 0x66daa8, 0xd6880154), at 0xfe568d50
  [20] instanceKlass::initialize_impl(0xd6880340,
0xfa0f9428, 0xfe796000, 0x66daa8, 0x66daa8, 0xd68802dc), at
0xfe580688
  [21] instanceKlass::initialize(0xfa0f9428, 0x66daa8,
0x2815c0, 0xfe796000, 0x66daa8, 0xd688035c), at 0xfe580584
  [22] JVM_NewInstance(0xfa0f9428, 0x66daa8, 0x66db2c,
0xfe796000, 0xfe7aa28c, 0x0), at 0xfe59a890
  [23] 0xfb106528(0xfa0f95b8, 0xe0ed5848, 0x0, 0xad008,
0xf8c02f08, 0x0), at 0xfb106527
 [24] 0xfb106328(0xfa0f95b8, 0xe0ed5848, 0xd6880624,
0x, 0xd9f7, 0x0), at 0xfb106327
  [25] 0xa4500(0xe0ed39b0, 0xe0ed5848, 0xd688069c, 0xafa48,
0x70, 0x0), at 0xa44ff
  [26] 0xa4500(0xe0ed39b0, 0xd688072c, 0xd6880730, 0xafa48,
0xf8d01a20, 0x0), at 0xa44ff
  [27] 0xfb1bd5b4(0xe0ed39b0, 0x1, 0xd68807bc, 0xad234,
0x0, 0x0), at 0xfb1bd5b3
  [28] 0xa44bc(0xe0ed39b0, 0x140, 0x0, 0xafa48, 0xd9f7,
0x0), at 0xa44bb
  [29] 0xa44bc(0xd94bd8e8, 0xd68808f0, 0xd68808f4, 0xaf998,
0xd9f7, 0x0), at 0xa44bb
  [30] 0xa44bc(0xd94bd8e8, 0xa6508, 0xd6880998, 0xafaec,
0x2, 0x0), at 0xa44bb
  [31] 0xa4764(0xdf029328, 0xd68819c0, 0x66daa8, 0xafc24,
0xb6, 0xfa0edb48), at 0xa4763
  [32] 0xa44bc(0xd94b7fa8, 0xd6880b60, 0xd6880b64, 0xad794,
0x10, 0x0), at 0xa44bb
  [33] 0xa44bc(0xd94b7fa8, 0xd6880bf8, 0xd6880bfc, 0xaf998,
0xd6880b24, 0x0), at 0xa44bb
  [34] 0xa44bc(0xd94b7fa8, 0xa6508, 0xfe796000, 0xaf998,
0x0, 0x0), at 0xa44bb
  [35] 0xa4764(0xda032240, 0xd6880d10, 0xd6880d14, 0xafc24,
0x1, 0x0), at 0xa4763
  [36] 0xa44bc(0xda032240, 0xdfb7e2b0, 0xdfb7e3a0, 0xaf998,
0xf8d01a20, 0x0), at 0xa44bb
  [37] 0xfb34421c(0xda032240, 0xdfb7e2b0, 0xdfb7e3a0,
0xad234, 0x0, 0x0), at 0xfb34421b
  [38] 0xa44bc(0xda032240, 0x140, 0x0, 0xafaec, 0xd9f7,
0x0), at 0xa44bb
  [39] 0xa44bc(0xd8d3ca68, 0xd6880f68, 0xd6880f6c, 0xaf998,
0xd9f7, 0x0), at 0xa44bb
  [40] 0xa44bc(0xd8d3ca68, 0xa6508, 0xd6880ff8, 0xafaec,
0x2, 0x0), at 0xa44bb
  [41] 0xa4764(0xd8c268d0, 0xd68819c0, 0x66daa8, 0xafc24,
0xb6, 0xfa0e84c0), at 0xa4763
  [42] 0xa44bc(0xd8c268d0, 0xd68819c0, 0x66daa8, 0xad794,
0xb6, 0xfa0e7c60), at 0xa44bb
  [43] 0xa44bc(0xd8c0c770, 0xd68811f0, 0xd68811f4, 0xad794,
0xd9f7, 0x0), at 0xa44bb
  [44] 0xa44bc(0xd8c0c770, 0xa6508, 0xd6881284, 0xaf998,
0xfe79f180, 0x0), at 0xa44bb
  [45] 0xa44bc(0xd8c0c770, 0x, 0x, 0xafa48,

Re: URGENT : Multiple host in Tomcat

2002-12-10 Thread Rasputin
* Laxmikanth M.S. <[EMAIL PROTECTED]> [1238 13:38]:

> I have two host...
> one is the default and one more i have created...

> the second host I am pointing to a DNS enrty.I have even created a
> context for this host but when I open the site it show the below error
> check it at http://ftisites.sonata-software.com:8080
 
> even i want to remove te port number from the site...how that can be done
> "HTTP Status 500 - No Context configured to process this request

Please post the Host entries from server.xml .
There should be one for each virtual host you want, the trick is each host has
it's own 'webapps' folder, set by the appBase attribute in the XML tag.

The error below seems to suggest you haven't created a ROOT element for one of the 
vhosts.

Name-based virtual hosting generally works a treat on tomcat; it's the same
method Apache uses by default for it's virtual hosts.

> type Status report
> message No Context configured to process this request
> description The server encountered an internal error (No Context configured
> to process this request) that prevented it from fulfilling this request."

-- 
Rasputin :: Jack of All Trades - Master of Nuns

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: JK - warning/question about naming workers

2002-12-10 Thread Madere, Colin
Now it's my turn to reply to quickly :)  It seems the 8009 is on the Tomcat
side so it shouldn't matter how many workers are talking to it from JK.
Anyways, to clarify my situation, I don't NEED all the Apache hosts to talk
to a single Tomcat host, I just don't NEED them to be different Tomcat hosts
so, really, whichever way works I'll set it up that way.

Basically, I have 4 sites which need to talk to apps running under Tomcat,
but how the apps react will primarily be handled by the user's roles after
they log in.

> -Original Message-
> From: Madere, Colin [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 3:11 PM
> To:   'Tomcat Users List'
> Subject:  RE: JK - warning/question about naming workers
> 
> Well it would make sense that all could use 8009 if they are different
> hosts
> on different IPs, but depending on how the port is used that may not work
> if
> you want to use a single Tomcat host for multiple Apache hosts.
> 
> That is my situation I'm trying to get working.
> 
> site1 -> worker.site1 -> tomcat1 (this works, obviously)
> site2 -> worker.site? -> tomcat1
> site3 -> worker.site? -> tomcat1
> 
> Any suggestions on this appreciated.  I don't want it to "just work", I
> want
> to be sure I know why it works and that it's not going to blow up when it
> goes to production.
> 
> Thanks for the super-fast feedback, John.
> 
> > -Original Message-
> > From:   Turner, John [SMTP:[EMAIL PROTECTED]]
> > Sent:   Tuesday, December 10, 2002 2:21 PM
> > To: 'Tomcat Users List'
> > Subject:RE: JK - warning/question about naming workers
> > 
> > 
> > Actually, I posted too soon.  After I thought about it, I realized that
> I
> > haven't really beat that test instance up any, I've been focusing on one
> > particular webapp and one particular client/URL.
> > 
> > I did end up having to add another entry to workers.properties for a
> > second
> > hostname, though as it stands now it looks like the various workers can
> > all
> > use port 8009.  I will have to investigate further.
> > 
> > I apologize for the previously posted misinformation that said one
> worker
> > definition could handle multiple vhosts.
> > 
> > John
> > 
> > > -Original Message-
> > > From: Turner, John [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, December 10, 2002 2:53 PM
> > > To: 'Tomcat Users List'
> > > Subject: RE: JK - warning/question about naming workers
> > > 
> > > 
> > > 
> > > As far as I know, the "host" parameter in workers.properties 
> > > is the lcoation
> > > of the Tomcat server...it has nothing to do with the hostname 
> > > used in the
> > > URL.
> > > 
> > > If you had more than one Host in server.xml, you would put an 
> > > ApacheConfig
> > > Listener in there for each one.
> > > 
> > > I have this setup in my 4.1.12 test instance right now.  
> > > There are multiple
> > > Hosts in server.xml, each with one or more Contexts.  
> > > Workers.properties
> > > only has one worker defined, and the mod_jk.conf file generated by
> > > ApacheConfig has multiple Apache VirtualHosts defined.
> > > 
> > > HTH
> > > 
> > > John
> > > 
> > > > -Original Message-
> > > > From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> > > > Sent: Tuesday, December 10, 2002 2:47 PM
> > > > To: 'Tomcat Users List'
> > > > Subject: JK - warning/question about naming workers
> > > > 
> > > > 
> > > > I just fought with a problem for quite a while and thought 
> > > I'd share a
> > > > caution and ask a question.
> > > > 
> > > > The mod_jk.conf auto-generated by Tomcat assumes that your 
> > > > worker for the
> > > > /examples (and other default apps in Tomcat) is named 
> > > > "ajp13".  If you name
> > > > it anything else you'll get a 500 error since JK drops the 
> > > > request due to no
> > > > valid worker being found.  You MUST name a worker "ajp13" for 
> > > > those things
> > > > to work.
> > > > 
> > > > This brings up a question for me, how does Tomcat decide to 
> > > > map apps to
> > > > workers to auto-generate mod_jk.conf correctly?  Does it 
> > > > assume that you
> > > > will have all contexts that you want to map to a worker under 
> > > > a single host?
> > > > If so, doesn't this imply that you can't map multiple workers 
> > > > to the same
> > > > host (if Tomcat keys off the host)?  Am I off in left-field?  
> > > > In all the
> > > > documentation I've sought out did I miss the explanation of 
> > > > this somewhere?
> > > > 
> > > > Thanks again to those vigilant responders on this list!
> > > > 
> > > > Colin
> > > > 
> > > > 
> > > > --
> > > > To unsubscribe, e-mail:   
> > > > 
> > > > For additional commands, e-mail: 
> > > > 
> > > > 
> > > 
> > > --
> > > To unsubscribe, e-mail:   
> > 
> > For additional commands, e-mail:
> > 
> > 
> > 
> > --
> > To unsubscribe, e-mail:
> > 
> > For additional commands, e-mail:
> > 

RE: JK - warning/question about naming workers

2002-12-10 Thread Madere, Colin
Well it would make sense that all could use 8009 if they are different hosts
on different IPs, but depending on how the port is used that may not work if
you want to use a single Tomcat host for multiple Apache hosts.

That is my situation I'm trying to get working.

site1 -> worker.site1 -> tomcat1 (this works, obviously)
site2 -> worker.site? -> tomcat1
site3 -> worker.site? -> tomcat1

Any suggestions on this appreciated.  I don't want it to "just work", I want
to be sure I know why it works and that it's not going to blow up when it
goes to production.

Thanks for the super-fast feedback, John.

> -Original Message-
> From: Turner, John [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 2:21 PM
> To:   'Tomcat Users List'
> Subject:  RE: JK - warning/question about naming workers
> 
> 
> Actually, I posted too soon.  After I thought about it, I realized that I
> haven't really beat that test instance up any, I've been focusing on one
> particular webapp and one particular client/URL.
> 
> I did end up having to add another entry to workers.properties for a
> second
> hostname, though as it stands now it looks like the various workers can
> all
> use port 8009.  I will have to investigate further.
> 
> I apologize for the previously posted misinformation that said one worker
> definition could handle multiple vhosts.
> 
> John
> 
> > -Original Message-
> > From: Turner, John [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 10, 2002 2:53 PM
> > To: 'Tomcat Users List'
> > Subject: RE: JK - warning/question about naming workers
> > 
> > 
> > 
> > As far as I know, the "host" parameter in workers.properties 
> > is the lcoation
> > of the Tomcat server...it has nothing to do with the hostname 
> > used in the
> > URL.
> > 
> > If you had more than one Host in server.xml, you would put an 
> > ApacheConfig
> > Listener in there for each one.
> > 
> > I have this setup in my 4.1.12 test instance right now.  
> > There are multiple
> > Hosts in server.xml, each with one or more Contexts.  
> > Workers.properties
> > only has one worker defined, and the mod_jk.conf file generated by
> > ApacheConfig has multiple Apache VirtualHosts defined.
> > 
> > HTH
> > 
> > John
> > 
> > > -Original Message-
> > > From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, December 10, 2002 2:47 PM
> > > To: 'Tomcat Users List'
> > > Subject: JK - warning/question about naming workers
> > > 
> > > 
> > > I just fought with a problem for quite a while and thought 
> > I'd share a
> > > caution and ask a question.
> > > 
> > > The mod_jk.conf auto-generated by Tomcat assumes that your 
> > > worker for the
> > > /examples (and other default apps in Tomcat) is named 
> > > "ajp13".  If you name
> > > it anything else you'll get a 500 error since JK drops the 
> > > request due to no
> > > valid worker being found.  You MUST name a worker "ajp13" for 
> > > those things
> > > to work.
> > > 
> > > This brings up a question for me, how does Tomcat decide to 
> > > map apps to
> > > workers to auto-generate mod_jk.conf correctly?  Does it 
> > > assume that you
> > > will have all contexts that you want to map to a worker under 
> > > a single host?
> > > If so, doesn't this imply that you can't map multiple workers 
> > > to the same
> > > host (if Tomcat keys off the host)?  Am I off in left-field?  
> > > In all the
> > > documentation I've sought out did I miss the explanation of 
> > > this somewhere?
> > > 
> > > Thanks again to those vigilant responders on this list!
> > > 
> > > Colin
> > > 
> > > 
> > > --
> > > To unsubscribe, e-mail:   
> > > 
> > > For additional commands, e-mail: 
> > > 
> > > 
> > 
> > --
> > To unsubscribe, e-mail:   
> 
> For additional commands, e-mail:
> 
> 
> 
> --
> To unsubscribe, e-mail:
> 
> For additional commands, e-mail:
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: package objects does not exist

2002-12-10 Thread Wendy Smoak
Dhaval wrote:
> I have deployed a web application called 'proj' in the webapps directory,
and have > all the jsp files in there, while my .java files reside in
proj/WEB-
> INF/classes/objects directory.  When I try to go to 
> http://localhost:8080/proj/login.jsp, it throws back an error saying
'package
>  objects does not exist'.  I have a page import directive in my login.jsp
page 
> that imports objects.*.

As John mentioned, those should be '.class' files, not '.java' files.

Also, do these .java files all have 'package objects;' at the top?

-- 
Wendy



RE: package objects does not exist

2002-12-10 Thread Turner, John

Don't your .java files have to be compiled into .class files?

John


> -Original Message-
> From: Dhaval Mehta [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 3:50 PM
> To: [EMAIL PROTECTED]
> Subject: package objects does not exist
> 
> 
> 
> Hi there!
> 
> I have deployed a web application called 'proj' in the 
> webapps directory, and have all the jsp files in there, while 
> my .java files reside in proj/WEB-INF/classes/objects 
> directory.  When I try to go to 
> http://localhost:8080/proj/login.jsp, it throws back an error 
> saying 'package objects does not exist'.  I have a page 
> import directive in my login.jsp page that imports objects.*.
> 
> Could anyone please give me some pointers on what could be wrong?
> 
> Thanks,
> Dhaval Mehta
> 
> 
> 
> -
> Do you Yahoo!?
> Yahoo! Mail Plus - Powerful. Affordable. Sign up now
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




package objects does not exist

2002-12-10 Thread Dhaval Mehta

Hi there!

I have deployed a web application called 'proj' in the webapps directory, and have all 
the jsp files in there, while my .java files reside in proj/WEB-INF/classes/objects 
directory.  When I try to go to http://localhost:8080/proj/login.jsp, it throws back 
an error saying 'package objects does not exist'.  I have a page import directive in 
my login.jsp page that imports objects.*.

Could anyone please give me some pointers on what could be wrong?

Thanks,
Dhaval Mehta



-
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now


Re: SSL enabling through Java Application

2002-12-10 Thread Mike W-M
Looks like an interesting application!
Presumably you're aware that Tomcat doesn't come with SSL by default and
that you need to install an implementation (generally Sun's) of the required
security classes?  In Java parlance, it's called "JSSE".
There's a HOWTO in (at least the 4.0) docs on the jakarta site

Mike.

- Original Message -
From: "Abhijat Thakur" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 10, 2002 7:23 PM
Subject: SSL enabling through Java Application



I have been able to embed tomcat in my java application and startup tomcat
on port 8080. I am trying to create a Connector for HTTPS but every time i
do that i get.

java.lang.ClassNotFoundException: Can't find any SSL implementation
at
org.apache.coyote.http11.Http11Protocol.checkSocketFactory(Http11Protocol.ja
va:454)
at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:133)
at
org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.java:10
02)
at org.apache.catalina.startup.Embedded.start(Embedded.java:999)
at com.bdna.pl.testing.EmbeddedTomcat.startTomcat(EmbeddedTomcat.java:92)
at com.bdna.pl.testing.EmbeddedTomcat.main(EmbeddedTomcat.java:166)
LifecycleException:  Protocol handler initialization failed:
java.lang.ClassNotFoundException: Can't find any SSL implementation
at
org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.java:10
04)
at org.apache.catalina.startup.Embedded.start(Embedded.java:999)
at com.bdna.pl.testing.EmbeddedTomcat.startTomcat(EmbeddedTomcat.java:92)
at com.bdna.pl.testing.EmbeddedTomcat.main(EmbeddedTomcat.java:166)

The code snippet that i use to create a connector. Here embedded is instance
of Embedded class.

// Assemble and install a default HTTP connector
Connector connector =
  embedded.createConnector(null, 8080, false);
embedded.addConnector(connector);

  //This code fails
  Connector sslConnector =
  embedded.createConnector(null, 8443, true);
embedded.addConnector(sslConnector);

thanks

abhijat

--
To unsubscribe, e-mail:

For additional commands, e-mail:





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: apache-tomcat : 405 mettod not allowed error: please help

2002-12-10 Thread Turner, John

Yes, you need to restart Apache.  You can use the 'graceful' option of
apachectl, and Apache will reread it's configuration nicely after waiting
for all open requests to be finished:

/some/path/to/apache/bin/apachectl graceful

For the Context element, you would want that within/under the Host element
for scds.safeguardproperties.com.

Tomcat's Host = Apache's VirtualHost/ServerName
Tomcat's Context = roughly similar to Apache's DocumentRoot

HTH

John

> -Original Message-
> From: Anup Ray [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 3:22 PM
> To: Tomcat Users List
> Subject: RE: apache-tomcat : 405 mettod not allowed error: please help
> 
> 
> Hi John,
> Thank you for your suggestions. I have gone through and 
> implemented your
> suggestions but I still gets the same 405 method not allowed
> error(https://scds.safeguardproperties.com/jspellhtml/test.htm
> l). Could you
> please little bit more time and give me further suggestion.
> I now enabled tomcat standalone HTTP connector and the jspellhtml
> application is working stand alone. You can see here
> http://u10-2:8090/jspellhtml/test.html
> More info: I tried like this:
> 1) you're missing a Host element in server.xml for
> scds.safeguardproperties.com.---implemented it.
> 
>   ^M
>appBase="webapps"
> unpackWARs="t
> rue">^M
> _
> 2) you're missing a Conext element for /jspellhtml (or 
> whatever URL will be
> used to reach the app)---Could you please tell me where to implement.
> I have symbolic link setup at apache doc. root though (at
> /var/apache/htdocs.)
> lrwxrwxrwx   1 root other 36 Nov  7 18:19 jspellhtml ->
> /usr/local/tomcat/webapps/jspellhtml
> 
> 3) Apache virtual host for scds.safeguardproperties.com 
> ---already setup
> #
> 
> DocumentRoot /var/apache/htdocs
> ServerName scds.safeguardproperties.com
> #ServerName cdidev.safeguardproperties.com
> SSLEngine On
> SSLCertificateFile /usr/local/apache/1.3.22-1/conf/ssl.crt/server.crt
> SSLCertificateKeyFile 
> /usr/local/apache/1.3.22-1/conf/ssl.key/server.key
> JkMount /*.jsp ajp13
> JkMount /servlet/* ajp13
> JkMount /jspellhtml/* ajp13
> 
> 
> 4) a JkMount in that Apache virtual host for /jspellhtml---done it in
> httpd.conf
> JkMount /jspellhtml/* ajp13
> 5. I could not restart apache server as it is in production. 
> Do I have to
> restart apache to implement the change done in 4.
> 
> 6. Please help me solving this problem.
> thanks,
> Anup
> -Original Message-
> From: Turner, John [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:14 PM
> To: 'Tomcat Users List'
> Subject: RE: apache-tomcat : 405 mettod not allowed error: please help
> 
> 
> 
> Looks to me like:
> 
> 1) you're missing a Host element in server.xml for
> scds.safeguardproperties.com
> 
> 2) you're missing a Conext element for /jspellhtml (or 
> whatever URL will be
> used to reach the app)
> 
> 3) Apache virtual host for scds.safeguardproperties.com
> 
> 4) a JkMount in that Apache virtual host for /jspellhtml
> 
> The only reason your test.html file is working is because it 
> goes to Apache
> and Apache can find it and knows what to do with a HTML file.
> 
> I'm surprised this even works with Tomcat Stand-alone.  I was 
> unable to
> access the URL using port 8090, so couldn't verify that it 
> does work.  If
> it's working, it's because Tomcat's defaults are letting it 
> work, but that
> won't help you with Apache.
> 
> John
> 
> 
> > -Original Message-
> > From: Anup Ray [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 10, 2002 11:59 AM
> > To: Tomcat Users List
> > Subject: apache-tomcat : 405 mettod not allowed error: please help
> >
> >
> >
> > My platform is Sun Sparc Solaris 8. I have apache-ssl server
> > already running
> > on production.
> > I want to integrate tomcat with apache so that a "jspellhtml"
> > application
> > ( a spellcheck program) runs with apache-tomcat environment. I used
> > mod_jk.so connector.
> > Now with tomcat HTTP standalone connector jspellhtml
> > application works well
> > with test.html example.
> > But with apache-mod_jk-tomcat, jspellhtml giving the 
> following error:
> > Method Not Allowed
> > The requested method POST is not allowed for the URL
> > /jspellhtml/JSpell.jsp.
> >
> >
> > --
> > --
> > 
> >
> > Apache/1.3.22 Server at scds.safeguardproperties.com Port 443
> > ___
> > Could you please help fixing this peoblem.
> > more info:
> > 1. 
https://scds.safeguardproperties.com/jspellhtml/test.html  ---with
> apache-mod_jk-tomcat
>this gives initial display and also dosplays a "spell
> check" button. When
> I click spell check button I get the above errors.
>
> 2.
> https://scds.safeguardproperties.com:8090/jspellhtml/test.html
>  ---tomcat
> standalone (at port 8090) http connector --Spellcheck works
> perfectly for
> test.html.
>

--
To unsubscribe, e-mail:


RE: apache-tomcat : 405 mettod not allowed error: please help

2002-12-10 Thread Anup Ray
Hi John,
Thank you for your suggestions. I have gone through and implemented your
suggestions but I still gets the same 405 method not allowed
error(https://scds.safeguardproperties.com/jspellhtml/test.html). Could you
please little bit more time and give me further suggestion.
I now enabled tomcat standalone HTTP connector and the jspellhtml
application is working stand alone. You can see here
http://u10-2:8090/jspellhtml/test.html
More info: I tried like this:
1) you're missing a Host element in server.xml for
scds.safeguardproperties.com.---implemented it.

  ^M
  ^M
_
2) you're missing a Conext element for /jspellhtml (or whatever URL will be
used to reach the app)---Could you please tell me where to implement.
I have symbolic link setup at apache doc. root though (at
/var/apache/htdocs.)
lrwxrwxrwx   1 root other 36 Nov  7 18:19 jspellhtml ->
/usr/local/tomcat/webapps/jspellhtml

3) Apache virtual host for scds.safeguardproperties.com ---already setup
#

DocumentRoot /var/apache/htdocs
ServerName scds.safeguardproperties.com
#ServerName cdidev.safeguardproperties.com
SSLEngine On
SSLCertificateFile /usr/local/apache/1.3.22-1/conf/ssl.crt/server.crt
SSLCertificateKeyFile /usr/local/apache/1.3.22-1/conf/ssl.key/server.key
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /jspellhtml/* ajp13


4) a JkMount in that Apache virtual host for /jspellhtml---done it in
httpd.conf
JkMount /jspellhtml/* ajp13
5. I could not restart apache server as it is in production. Do I have to
restart apache to implement the change done in 4.

6. Please help me solving this problem.
thanks,
Anup
-Original Message-
From: Turner, John [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:14 PM
To: 'Tomcat Users List'
Subject: RE: apache-tomcat : 405 mettod not allowed error: please help



Looks to me like:

1) you're missing a Host element in server.xml for
scds.safeguardproperties.com

2) you're missing a Conext element for /jspellhtml (or whatever URL will be
used to reach the app)

3) Apache virtual host for scds.safeguardproperties.com

4) a JkMount in that Apache virtual host for /jspellhtml

The only reason your test.html file is working is because it goes to Apache
and Apache can find it and knows what to do with a HTML file.

I'm surprised this even works with Tomcat Stand-alone.  I was unable to
access the URL using port 8090, so couldn't verify that it does work.  If
it's working, it's because Tomcat's defaults are letting it work, but that
won't help you with Apache.

John


> -Original Message-
> From: Anup Ray [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 11:59 AM
> To: Tomcat Users List
> Subject: apache-tomcat : 405 mettod not allowed error: please help
>
>
>
> My platform is Sun Sparc Solaris 8. I have apache-ssl server
> already running
> on production.
> I want to integrate tomcat with apache so that a "jspellhtml"
> application
> ( a spellcheck program) runs with apache-tomcat environment. I used
> mod_jk.so connector.
> Now with tomcat HTTP standalone connector jspellhtml
> application works well
> with test.html example.
> But with apache-mod_jk-tomcat, jspellhtml giving the following error:
> Method Not Allowed
> The requested method POST is not allowed for the URL
> /jspellhtml/JSpell.jsp.
>
>
> --
> --
> 
>
> Apache/1.3.22 Server at scds.safeguardproperties.com Port 443
> ___
> Could you please help fixing this peoblem.
> more info:
> 1. https://scds.safeguardproperties.com/jspellhtml/test.html  ---with
> apache-mod_jk-tomcat
>this gives initial display and also dosplays a "spell
> check" button. When
> I click spell check button I get the above errors.
>
> 2.
> https://scds.safeguardproperties.com:8090/jspellhtml/test.html
>  ---tomcat
> standalone (at port 8090) http connector --Spellcheck works
> perfectly for
> test.html.
>

--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: JK - warning/question about naming workers

2002-12-10 Thread Turner, John

Actually, I posted too soon.  After I thought about it, I realized that I
haven't really beat that test instance up any, I've been focusing on one
particular webapp and one particular client/URL.

I did end up having to add another entry to workers.properties for a second
hostname, though as it stands now it looks like the various workers can all
use port 8009.  I will have to investigate further.

I apologize for the previously posted misinformation that said one worker
definition could handle multiple vhosts.

John

> -Original Message-
> From: Turner, John [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 2:53 PM
> To: 'Tomcat Users List'
> Subject: RE: JK - warning/question about naming workers
> 
> 
> 
> As far as I know, the "host" parameter in workers.properties 
> is the lcoation
> of the Tomcat server...it has nothing to do with the hostname 
> used in the
> URL.
> 
> If you had more than one Host in server.xml, you would put an 
> ApacheConfig
> Listener in there for each one.
> 
> I have this setup in my 4.1.12 test instance right now.  
> There are multiple
> Hosts in server.xml, each with one or more Contexts.  
> Workers.properties
> only has one worker defined, and the mod_jk.conf file generated by
> ApacheConfig has multiple Apache VirtualHosts defined.
> 
> HTH
> 
> John
> 
> > -Original Message-
> > From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 10, 2002 2:47 PM
> > To: 'Tomcat Users List'
> > Subject: JK - warning/question about naming workers
> > 
> > 
> > I just fought with a problem for quite a while and thought 
> I'd share a
> > caution and ask a question.
> > 
> > The mod_jk.conf auto-generated by Tomcat assumes that your 
> > worker for the
> > /examples (and other default apps in Tomcat) is named 
> > "ajp13".  If you name
> > it anything else you'll get a 500 error since JK drops the 
> > request due to no
> > valid worker being found.  You MUST name a worker "ajp13" for 
> > those things
> > to work.
> > 
> > This brings up a question for me, how does Tomcat decide to 
> > map apps to
> > workers to auto-generate mod_jk.conf correctly?  Does it 
> > assume that you
> > will have all contexts that you want to map to a worker under 
> > a single host?
> > If so, doesn't this imply that you can't map multiple workers 
> > to the same
> > host (if Tomcat keys off the host)?  Am I off in left-field?  
> > In all the
> > documentation I've sought out did I miss the explanation of 
> > this somewhere?
> > 
> > Thanks again to those vigilant responders on this list!
> > 
> > Colin
> > 
> > 
> > --
> > To unsubscribe, e-mail:   
> > 
> > For additional commands, e-mail: 
> > 
> > 
> 
> --
> To unsubscribe, e-mail:   

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Jeanfrancois Arcand
Seems to be an Hotspot problem. I have the same configuration without 
having problem.

You should have a better answer on java.sun.com...Sorry :-(

-- Jeanfrancois

Will Hartung wrote:

Hi All!

We're just porting our app to 4.1.12. After fighting classpath problems, the
latest and greatest is this:


From the localhost_log file, the last enry was:


2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading container
servlet invoker.

On the stdout/stderr of the tomcat container:

bin> sh catalina.sh run
Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_TMPDIR: C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
Using JAVA_HOME:   c:\JDK1.3
[INFO] Registry - -Loading registry information
[INFO] Registry - -Creating new Registry instance
[INFO] Registry - -Creating MBeanServer
[INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
Starting service Tomcat-Standalone
Apache Tomcat/4.1.12
#
# HotSpot Virtual Machine Error, Internal Error
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Error ID: 43113F32554E54494D45110E4350500290
#

W2K with Cygwin and JVM 1.3

java version "1.3.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)

Any ideas on how to hunt this kind of thing down? Are app does have a
startup servlet, so it's no doubt within that, but I was hoping for some
general ideas on why this is exploding.

Thanx!

Regards,

Will Hartung
([EMAIL PROTECTED])







--
To unsubscribe, e-mail:   
For additional commands, e-mail: 


 



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Ron Day
It could be jdk 1.4.1_01 when I changed to that and tried to run
struts-console, either the jvm was shut down or my machine rebooted. when I
went back to 1.3.1 everything worked fine.

Ron

-Original Message-
From: Will Hartung [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 1:07 PM
To: Tomcat Users List
Subject: 4.1.12 dumps VM, any ideas?


Hi All!

We're just porting our app to 4.1.12. After fighting classpath problems, the
latest and greatest is this:

>From the localhost_log file, the last enry was:

2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading container
servlet invoker.

On the stdout/stderr of the tomcat container:

bin> sh catalina.sh run
Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_TMPDIR: C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
Using JAVA_HOME:   c:\JDK1.3
[INFO] Registry - -Loading registry information
[INFO] Registry - -Creating new Registry instance
[INFO] Registry - -Creating MBeanServer
[INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
Starting service Tomcat-Standalone
Apache Tomcat/4.1.12
#
# HotSpot Virtual Machine Error, Internal Error
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Error ID: 43113F32554E54494D45110E4350500290
#

W2K with Cygwin and JVM 1.3

java version "1.3.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)

Any ideas on how to hunt this kind of thing down? Are app does have a
startup servlet, so it's no doubt within that, but I was hoping for some
general ideas on why this is exploding.

Thanx!

Regards,

Will Hartung
([EMAIL PROTECTED])







--
To unsubscribe, e-mail:

For additional commands, e-mail:





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Ben Ricker
On Tue, 2002-12-10 at 13:54, Shapira, Yoav wrote:
> Hi,
> Damn, I was just about to suggest 1.4.1_01 ;)
> 
> I've had that error happen before on JDK 1.3 on Solaris, not W2K.  The
> problem was I hadn't installed the OS-level patches required by Solaris
> for that JDK version.  So I don't know if this applicable to your
> problem...
> 
> Yoav Shapira
> Millennium ChemInformatics

Just a thought: you can run java without HotSpot and see if it runs. If
it does, then you are probably looking at a bug in HotSpot (THAT never
happens *grin). If it does not, then you are probably looking at a
problem with your system.

HTH,

Ben Ricker

> 
> >-Original Message-
> >From: Will Hartung [mailto:[EMAIL PROTECTED]]
> >Sent: Tuesday, December 10, 2002 2:33 PM
> >To: Tomcat Users List
> >Subject: Re: 4.1.12 dumps VM, any ideas?
> >
> >As a followup, it also kills a JDK 1.4.1_01 JVM as well. :-(
> >
> >Thanx again!
> >
> >Will
> >
> >
> >> Hi All!
> >>
> >> We're just porting our app to 4.1.12. After fighting classpath
> problems,
> >the
> >> latest and greatest is this:
> >>
> >> From the localhost_log file, the last enry was:
> >>
> >> 2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading
> container
> >> servlet invoker.
> >>
> >> On the stdout/stderr of the tomcat container:
> >>
> >> bin> sh catalina.sh run
> >> Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> >> Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> >> Using CATALINA_TMPDIR:
> C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
> >> Using JAVA_HOME:   c:\JDK1.3
> >> [INFO] Registry - -Loading registry information
> >> [INFO] Registry - -Creating new Registry instance
> >> [INFO] Registry - -Creating MBeanServer
> >> [INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
> >> Starting service Tomcat-Standalone
> >> Apache Tomcat/4.1.12
> >> #
> >> # HotSpot Virtual Machine Error, Internal Error
> >> # Please report this error at
> >> # http://java.sun.com/cgi-bin/bugreport.cgi
> >> #
> >> # Error ID: 43113F32554E54494D45110E4350500290
> >> #
> >>
> >> W2K with Cygwin and JVM 1.3
> >>
> >> java version "1.3.1_01"
> >> Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
> >> Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
> >>
> >> Any ideas on how to hunt this kind of thing down? Are app does have a
> >> startup servlet, so it's no doubt within that, but I was hoping for
> some
> >> general ideas on why this is exploding.
> >>
> >> Thanx!
> >>
> >> Regards,
> >>
> >> Will Hartung
> >> ([EMAIL PROTECTED])
> >>
> >>
> >>
> >>
> >>
> >>
> >>
> >> --
> >> To unsubscribe, e-mail:
> >
> >> For additional commands, e-mail:
> >
> >>
> >>
> >
> >
> >
> >--
> >To unsubscribe, e-mail:    >[EMAIL PROTECTED]>
> >For additional commands, e-mail:  >[EMAIL PROTECTED]>
> 
> 
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
> 
-- 
Ben Ricker <[EMAIL PROTECTED]>
Wellinx.com


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Shapira, Yoav
Hi,
Damn, I was just about to suggest 1.4.1_01 ;)

I've had that error happen before on JDK 1.3 on Solaris, not W2K.  The
problem was I hadn't installed the OS-level patches required by Solaris
for that JDK version.  So I don't know if this applicable to your
problem...

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Will Hartung [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, December 10, 2002 2:33 PM
>To: Tomcat Users List
>Subject: Re: 4.1.12 dumps VM, any ideas?
>
>As a followup, it also kills a JDK 1.4.1_01 JVM as well. :-(
>
>Thanx again!
>
>Will
>
>
>> Hi All!
>>
>> We're just porting our app to 4.1.12. After fighting classpath
problems,
>the
>> latest and greatest is this:
>>
>> From the localhost_log file, the last enry was:
>>
>> 2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading
container
>> servlet invoker.
>>
>> On the stdout/stderr of the tomcat container:
>>
>> bin> sh catalina.sh run
>> Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
>> Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
>> Using CATALINA_TMPDIR:
C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
>> Using JAVA_HOME:   c:\JDK1.3
>> [INFO] Registry - -Loading registry information
>> [INFO] Registry - -Creating new Registry instance
>> [INFO] Registry - -Creating MBeanServer
>> [INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
>> Starting service Tomcat-Standalone
>> Apache Tomcat/4.1.12
>> #
>> # HotSpot Virtual Machine Error, Internal Error
>> # Please report this error at
>> # http://java.sun.com/cgi-bin/bugreport.cgi
>> #
>> # Error ID: 43113F32554E54494D45110E4350500290
>> #
>>
>> W2K with Cygwin and JVM 1.3
>>
>> java version "1.3.1_01"
>> Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
>> Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
>>
>> Any ideas on how to hunt this kind of thing down? Are app does have a
>> startup servlet, so it's no doubt within that, but I was hoping for
some
>> general ideas on why this is exploding.
>>
>> Thanx!
>>
>> Regards,
>>
>> Will Hartung
>> ([EMAIL PROTECTED])
>>
>>
>>
>>
>>
>>
>>
>> --
>> To unsubscribe, e-mail:
>
>> For additional commands, e-mail:
>
>>
>>
>
>
>
>--
>To unsubscribe, e-mail:   [EMAIL PROTECTED]>
>For additional commands, e-mail: [EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Kris Schneider
What happens if you run outside of Cygwin (i.e. open up a command prompt and run
%CATALINA_HOME%\bin\startup)?

Quoting Will Hartung <[EMAIL PROTECTED]>:

> As a followup, it also kills a JDK 1.4.1_01 JVM as well. :-(
> 
> Thanx again!
> 
> Will
> 
> 
> > Hi All!
> >
> > We're just porting our app to 4.1.12. After fighting classpath problems,
> the
> > latest and greatest is this:
> >
> > From the localhost_log file, the last enry was:
> >
> > 2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading container
> > servlet invoker.
> >
> > On the stdout/stderr of the tomcat container:
> >
> > bin> sh catalina.sh run
> > Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> > Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> > Using CATALINA_TMPDIR: C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
> > Using JAVA_HOME:   c:\JDK1.3
> > [INFO] Registry - -Loading registry information
> > [INFO] Registry - -Creating new Registry instance
> > [INFO] Registry - -Creating MBeanServer
> > [INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
> > Starting service Tomcat-Standalone
> > Apache Tomcat/4.1.12
> > #
> > # HotSpot Virtual Machine Error, Internal Error
> > # Please report this error at
> > # http://java.sun.com/cgi-bin/bugreport.cgi
> > #
> > # Error ID: 43113F32554E54494D45110E4350500290
> > #
> >
> > W2K with Cygwin and JVM 1.3
> >
> > java version "1.3.1_01"
> > Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
> > Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
> >
> > Any ideas on how to hunt this kind of thing down? Are app does have a
> > startup servlet, so it's no doubt within that, but I was hoping for some
> > general ideas on why this is exploding.
> >
> > Thanx!
> >
> > Regards,
> >
> > Will Hartung
> > ([EMAIL PROTECTED])
> >
> >
> >
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> 
> > For additional commands, e-mail:
> 
> >
> >
> 
> 
> 
> --
> To unsubscribe, e-mail:  
> 
> For additional commands, e-mail:
> 
> 


-- 
Kris Schneider 
D.O.Tech   

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: JK - warning/question about naming workers

2002-12-10 Thread Turner, John

As far as I know, the "host" parameter in workers.properties is the lcoation
of the Tomcat server...it has nothing to do with the hostname used in the
URL.

If you had more than one Host in server.xml, you would put an ApacheConfig
Listener in there for each one.

I have this setup in my 4.1.12 test instance right now.  There are multiple
Hosts in server.xml, each with one or more Contexts.  Workers.properties
only has one worker defined, and the mod_jk.conf file generated by
ApacheConfig has multiple Apache VirtualHosts defined.

HTH

John

> -Original Message-
> From: Madere, Colin [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 2:47 PM
> To: 'Tomcat Users List'
> Subject: JK - warning/question about naming workers
> 
> 
> I just fought with a problem for quite a while and thought I'd share a
> caution and ask a question.
> 
> The mod_jk.conf auto-generated by Tomcat assumes that your 
> worker for the
> /examples (and other default apps in Tomcat) is named 
> "ajp13".  If you name
> it anything else you'll get a 500 error since JK drops the 
> request due to no
> valid worker being found.  You MUST name a worker "ajp13" for 
> those things
> to work.
> 
> This brings up a question for me, how does Tomcat decide to 
> map apps to
> workers to auto-generate mod_jk.conf correctly?  Does it 
> assume that you
> will have all contexts that you want to map to a worker under 
> a single host?
> If so, doesn't this imply that you can't map multiple workers 
> to the same
> host (if Tomcat keys off the host)?  Am I off in left-field?  
> In all the
> documentation I've sought out did I miss the explanation of 
> this somewhere?
> 
> Thanks again to those vigilant responders on this list!
> 
> Colin
> 
> 
> --
> To unsubscribe, e-mail:   
> 
> For additional commands, e-mail: 
> 
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




JK - warning/question about naming workers

2002-12-10 Thread Madere, Colin
I just fought with a problem for quite a while and thought I'd share a
caution and ask a question.

The mod_jk.conf auto-generated by Tomcat assumes that your worker for the
/examples (and other default apps in Tomcat) is named "ajp13".  If you name
it anything else you'll get a 500 error since JK drops the request due to no
valid worker being found.  You MUST name a worker "ajp13" for those things
to work.

This brings up a question for me, how does Tomcat decide to map apps to
workers to auto-generate mod_jk.conf correctly?  Does it assume that you
will have all contexts that you want to map to a worker under a single host?
If so, doesn't this imply that you can't map multiple workers to the same
host (if Tomcat keys off the host)?  Am I off in left-field?  In all the
documentation I've sought out did I miss the explanation of this somewhere?

Thanks again to those vigilant responders on this list!

Colin


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Configuration problems with Tomcat 4.0.2 and Tomcat 4.1.12 ???

2002-12-10 Thread Joaquim
Hi,

I have Tomcat 4.0.2 and Tomcat 4.1.12 installed on the same server. The
application web.xml file is the same. The Tomcat's configuration file,
server.xml and web.xml, for as much as I can see, contain the same
confiured elements. The server is running behind a DFL300 firewall,
using a vitual IP address.  The server has port 80 forwarded to 8080.

Here is the problem.
If I enter http://mywebsiteIPorDNS, 4.1.12 delivers the welcome.jsp to
the browser without any problem, however, I have to add the port
(http://mywebsiteIPorDNS:80) for 4.0.2 to work. Without the port, 4.0.2
will cause the browser to give an error message saying "www.welcome.jsp
could not be found. ..."

On the other hand, while 4.0.2 works fine with the following code:

<% String avar = "dasdf"; %>


...
...

4.1.12 is unable to resolve the variable and the compiled servlet ends
up with "value=avar".

I would appreciate if anyone could help me undertand what I am missing.
Thank you.

--
Joaquim Laureano
Email: [EMAIL PROTECTED]




--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: removeAbandoned does not work

2002-12-10 Thread Kranthi Yemula
My intension was not to close the the connection and check whether DBCP is
going to
handle this for me becuase I have set 'removeAbandoned' paramter in
server.xml.

> -Original Message-
> From: Joaquim [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 11:34 AM
> To: Tomcat Users List
> Subject: Re: removeAbandoned does not work
> 
> 
> Are you getting any exception?  The close statements are in the try 
> catch block,
> if you get an exception, they not be executed.  I would put the close 
> statements
> in a finally statement, to ensure that they would be executed.
> 
> Kranthi Yemula wrote:
> 
> >Hi,
> > 
> >I am using tomcat 4.0.3. I am playing with Datasources.
> >I am having trouble validating 'removing abandoned database pool
> >connections'.
> > 
> >I did the below:
> >---
> >1) I have set up the below parameters in my server.xml
> > 
> >
> >
> >removeAbandoned
> >true
> >
> >
> >
> >removeAbandonedTimeout
> >20
> >
> >
> >
> >logAbandoned
> >true
> >
> > 
> >---
> > 
> >2) I modified my test program so that it does not close  
> databse connection.
> >
> > 
> >package foo;
> > 
> >import javax.naming.*;
> >import javax.sql.*;
> >import java.sql.*;
> > 
> >public class DBTest {
> > 
> >  String foo = "Not Connected";
> >  int bar = -1;
> > 
> >  public void init() {
> >try{
> >  Context ctx = new InitialContext();
> >  if(ctx == null )
> >  throw new Exception("Boom - No Context");
> > 
> >  Context envCtx = (Context) ctx.lookup("java:comp/env");
> > 
> >  // Look up our data source
> >DataSource ds = 
> (DataSource)ctx.lookup("java:comp/env/jdbc/Kranthi");
> > 
> >
> >  if (ds != null) {
> >Connection conn = ds.getConnection();
> > 
> >if(conn != null)  {
> >foo = "Got Connection "+conn.toString();
> >Statement stmt = conn.createStatement();
> >ResultSet rst =
> >stmt.executeQuery(
> >  "select id, foo, bar from testdata");
> >if(rst.next()) {
> >   foo=rst.getString(2);
> >   bar=rst.getInt(3);
> >}
> >/*stmt.close();
> >rst.close();
> >conn.close();
> >*/
> >}
> >  }
> >}catch(Exception e) {
> >  e.printStackTrace();
> >}
> > }
> > 
> >-
> ---
> >--
> > 
> >I call the jsp that calls the above java program. But, its 
> not actually
> >closing the open connections.
> > 
> >Can anybody please help me.
> > 
> >Thanks,
> >KYemula.
> >
> >
> >  
> >
> 
> -- 
> Joaquim Laureano
> Lusostar Technologies, LLC
> Phone: 732-542-4890
> Email: [EMAIL PROTECTED]
> 
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> 
> For additional commands, e-mail: 
> 
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Rpm install problem

2002-12-10 Thread Mader, Cary J
I'm installing tomcat 4.1.12 rpm, but get a message "tomcat4: unknown
service" message.  The startup script is not being written to /etc/init.d
directory. Any ideas on why I'm getting this error?  It's a Suse 8.1
distribution.

Thanks.
Cary 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: removeAbandoned does not work

2002-12-10 Thread Joaquim
Are you getting any exception?  The close statements are in the try 
catch block,
if you get an exception, they not be executed.  I would put the close 
statements
in a finally statement, to ensure that they would be executed.

Kranthi Yemula wrote:

Hi,

I am using tomcat 4.0.3. I am playing with Datasources.
I am having trouble validating 'removing abandoned database pool
connections'.

I did the below:
---
1) I have set up the below parameters in my server.xml



removeAbandoned
true



removeAbandonedTimeout
20



logAbandoned
true


---

2) I modified my test program so that it does not close  databse connection.


package foo;

import javax.naming.*;
import javax.sql.*;
import java.sql.*;

public class DBTest {

 String foo = "Not Connected";
 int bar = -1;

 public void init() {
   try{
 Context ctx = new InitialContext();
 if(ctx == null )
 throw new Exception("Boom - No Context");

 Context envCtx = (Context) ctx.lookup("java:comp/env");

 // Look up our data source
   DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/Kranthi");


 if (ds != null) {
   Connection conn = ds.getConnection();

   if(conn != null)  {
   foo = "Got Connection "+conn.toString();
   Statement stmt = conn.createStatement();
   ResultSet rst =
   stmt.executeQuery(
 "select id, foo, bar from testdata");
   if(rst.next()) {
  foo=rst.getString(2);
  bar=rst.getInt(3);
   }
   /*stmt.close();
   rst.close();
   conn.close();
   */
   }
 }
   }catch(Exception e) {
 e.printStackTrace();
   }
}


--

I call the jsp that calls the above java program. But, its not actually
closing the open connections.

Can anybody please help me.

Thanks,
KYemula.


 


--
Joaquim Laureano
Lusostar Technologies, LLC
Phone: 732-542-4890
Email: [EMAIL PROTECTED]





--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: 4.1.12 dumps VM, any ideas?

2002-12-10 Thread Will Hartung
As a followup, it also kills a JDK 1.4.1_01 JVM as well. :-(

Thanx again!

Will


> Hi All!
>
> We're just porting our app to 4.1.12. After fighting classpath problems,
the
> latest and greatest is this:
>
> From the localhost_log file, the last enry was:
>
> 2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading container
> servlet invoker.
>
> On the stdout/stderr of the tomcat container:
>
> bin> sh catalina.sh run
> Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
> Using CATALINA_TMPDIR: C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
> Using JAVA_HOME:   c:\JDK1.3
> [INFO] Registry - -Loading registry information
> [INFO] Registry - -Creating new Registry instance
> [INFO] Registry - -Creating MBeanServer
> [INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
> Starting service Tomcat-Standalone
> Apache Tomcat/4.1.12
> #
> # HotSpot Virtual Machine Error, Internal Error
> # Please report this error at
> # http://java.sun.com/cgi-bin/bugreport.cgi
> #
> # Error ID: 43113F32554E54494D45110E4350500290
> #
>
> W2K with Cygwin and JVM 1.3
>
> java version "1.3.1_01"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
> Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)
>
> Any ideas on how to hunt this kind of thing down? Are app does have a
> startup servlet, so it's no doubt within that, but I was hoping for some
> general ideas on why this is exploding.
>
> Thanx!
>
> Regards,
>
> Will Hartung
> ([EMAIL PROTECTED])
>
>
>
>
>
>
>
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

>
>



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




SSL enabling through Java Application

2002-12-10 Thread Abhijat Thakur

I have been able to embed tomcat in my java application and startup tomcat on port 
8080. I am trying to create a Connector for HTTPS but every time i do that i get.

java.lang.ClassNotFoundException: Can't find any SSL implementation 
at org.apache.coyote.http11.Http11Protocol.checkSocketFactory(Http11Protocol.java:454) 
 
at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:133)
at org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.java:1002) 
 
at org.apache.catalina.startup.Embedded.start(Embedded.java:999)
at com.bdna.pl.testing.EmbeddedTomcat.startTomcat(EmbeddedTomcat.java:92)   
at com.bdna.pl.testing.EmbeddedTomcat.main(EmbeddedTomcat.java:166) 
LifecycleException:  Protocol handler initialization failed: 
java.lang.ClassNotFoundException: Can't find any SSL implementation
at org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.java:1004) 
 
at org.apache.catalina.startup.Embedded.start(Embedded.java:999)
at com.bdna.pl.testing.EmbeddedTomcat.startTomcat(EmbeddedTomcat.java:92)   
at com.bdna.pl.testing.EmbeddedTomcat.main(EmbeddedTomcat.java:166) 

The code snippet that i use to create a connector. Here embedded is instance of 
Embedded class.

// Assemble and install a default HTTP connector
Connector connector =
  embedded.createConnector(null, 8080, false);
embedded.addConnector(connector);

  //This code fails  
  Connector sslConnector =
  embedded.createConnector(null, 8443, true);
embedded.addConnector(sslConnector);

thanks

abhijat

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




removeAbandoned does not work

2002-12-10 Thread Kranthi Yemula
Hi,
 
I am using tomcat 4.0.3. I am playing with Datasources.
I am having trouble validating 'removing abandoned database pool
connections'.
 
I did the below:
---
1) I have set up the below parameters in my server.xml
 


removeAbandoned
true



removeAbandonedTimeout
20



logAbandoned
true

 
---
 
2) I modified my test program so that it does not close  databse connection.

 
package foo;
 
import javax.naming.*;
import javax.sql.*;
import java.sql.*;
 
public class DBTest {
 
  String foo = "Not Connected";
  int bar = -1;
 
  public void init() {
try{
  Context ctx = new InitialContext();
  if(ctx == null )
  throw new Exception("Boom - No Context");
 
  Context envCtx = (Context) ctx.lookup("java:comp/env");
 
  // Look up our data source
DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/Kranthi");
 

  if (ds != null) {
Connection conn = ds.getConnection();
 
if(conn != null)  {
foo = "Got Connection "+conn.toString();
Statement stmt = conn.createStatement();
ResultSet rst =
stmt.executeQuery(
  "select id, foo, bar from testdata");
if(rst.next()) {
   foo=rst.getString(2);
   bar=rst.getInt(3);
}
/*stmt.close();
rst.close();
conn.close();
*/
}
  }
}catch(Exception e) {
  e.printStackTrace();
}
 }
 

--
 
I call the jsp that calls the above java program. But, its not actually
closing the open connections.
 
Can anybody please help me.
 
Thanks,
KYemula.




4.1.12 dumps VM, any ideas?

2002-12-10 Thread Will Hartung
Hi All!

We're just porting our app to 4.1.12. After fighting classpath problems, the
latest and greatest is this:

>From the localhost_log file, the last enry was:

2002-12-09 14:36:57 StandardWrapper[/myApp:invoker]: Loading container
servlet invoker.

On the stdout/stderr of the tomcat container:

bin> sh catalina.sh run
Using CATALINA_BASE:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_HOME:   C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12
Using CATALINA_TMPDIR: C:\cygwin\tmp\tomcat\jakarta-tomcat-4.1.12\temp
Using JAVA_HOME:   c:\JDK1.3
[INFO] Registry - -Loading registry information
[INFO] Registry - -Creating new Registry instance
[INFO] Registry - -Creating MBeanServer
[INFO] Http11Protocol - -Initializing Coyote HTTP/1.1 on port 8080
Starting service Tomcat-Standalone
Apache Tomcat/4.1.12
#
# HotSpot Virtual Machine Error, Internal Error
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Error ID: 43113F32554E54494D45110E4350500290
#

W2K with Cygwin and JVM 1.3

java version "1.3.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_01a)
Java HotSpot(TM) Client VM (build 1.3.1_01, mixed mode)

Any ideas on how to hunt this kind of thing down? Are app does have a
startup servlet, so it's no doubt within that, but I was hoping for some
general ideas on why this is exploding.

Thanx!

Regards,

Will Hartung
([EMAIL PROTECTED])







--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Server.xml

2002-12-10 Thread Turner, John

For the JK protocol, you can use either Ajp13Connector or CoyoteConnector.
It's up to you.

Ajp13Connector: only JK

CoyoteConnector: JK, JK2, HTTP

The CoyoteConnector on port 8080 in the default server.xml is for serving
HTTP requests if you run Tomcat alone.  If you use Apache and JK/JK2, most
people disable the connector on 8080 and leave the one on 8009 (or whatever)
enabled.

John


> -Original Message-
> From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 1:44 PM
> To: Tomcat Users List
> Subject: RE: Server.xml
> 
> 
> Jake
> 
> Should I uncomment the the following lines to make it work with IIS
> 
>   port="8009" minProcessors="5" maxProcessors="75"
> acceptCount="10" debug="0"/>
> 
> Hari
> 
> -Original Message-
> From: Jacob Kjome [mailto:[EMAIL PROTECTED]] 
> Sent: Tuesday, December 10, 2002 1:40 PM
> To: Tomcat Users List
> Subject: Re: Server.xml
> 
> Hello Hari,
> 
> That's just a matter of the docs being not quite up-to-date.  The
> Coyote connector is the connector for both http and jk (jk and jk2).
> The other stuff is deprecated, although it still works just fine.
> 
> Jake
> 
> Tuesday, December 10, 2002, 12:24:23 PM, you wrote:
> 
> 
> 
> HV> Can somebody explain why in the default server.xml file we have 
> 
> HV>  HV> port="8080" minProcessors="5" maxProcessors="75"
> enableLookups="true"
> HV> redirectPort="8443" acceptCount="10" debug="0"
> connectionTimeout="2"
> HV> useURIValidationHack="false"/>
> 
> HV> and 
> 
> HV>  HV> port="8009" minProcessors="5" maxProcessors="75"
> enableLookups="true"
> HV> redirectPort="8443" acceptCount="10" debug="0"
> connectionTimeout="2"
> HV> useURIValidationHack="false"
> HV> protocolHandlerClassName="org.apache.jk.server.JkCoyoteHandler"/>
> 
> HV> but AJPconnector that listens on port 8009 has been 
> commented out. 
> 
> HV> Also when the server starts, we get an INFO message 
> "ajp13 listening
> on
> HV> tcp port 8009.
> 
> HV> I am trying to configure IIS and to redirect and having problems.
> The
> HV> documentation says that I need the following on server.xml file
> 
> HV>  HV>port="8009" minProcessors="5" maxProcessors="75"
> HV>acceptCount="10" debug="0"/>
> 
> HV> Should I then comment out the previous connectors and have only
> HV> AjpConnector
> 
> HV> Please help
> 
> HV> Hari
> 
> HV> --
> HV> To unsubscribe, e-mail:
> 
> HV> For additional commands, e-mail:
> 
> 
> 
> 
> -- 
> Best regards,
>  Jacobmailto:[EMAIL PROTECTED]
> 
> 
> --
> To unsubscribe, e-mail:
> 
> For additional commands, e-mail:
> 
> 
> 
> --
> To unsubscribe, e-mail:   

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Server.xml

2002-12-10 Thread Hari Venkatesan
Jake

Should I uncomment the the following lines to make it work with IIS



Hari

-Original Message-
From: Jacob Kjome [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 10, 2002 1:40 PM
To: Tomcat Users List
Subject: Re: Server.xml

Hello Hari,

That's just a matter of the docs being not quite up-to-date.  The
Coyote connector is the connector for both http and jk (jk and jk2).
The other stuff is deprecated, although it still works just fine.

Jake

Tuesday, December 10, 2002, 12:24:23 PM, you wrote:



HV> Can somebody explain why in the default server.xml file we have 

HV>  port="8080" minProcessors="5" maxProcessors="75"
enableLookups="true"
HV> redirectPort="8443" acceptCount="10" debug="0"
connectionTimeout="2"
HV> useURIValidationHack="false"/>

HV> and 

HV>  port="8009" minProcessors="5" maxProcessors="75"
enableLookups="true"
HV> redirectPort="8443" acceptCount="10" debug="0"
connectionTimeout="2"
HV> useURIValidationHack="false"
HV> protocolHandlerClassName="org.apache.jk.server.JkCoyoteHandler"/>

HV> but AJPconnector that listens on port 8009 has been commented out. 

HV> Also when the server starts, we get an INFO message "ajp13 listening
on
HV> tcp port 8009.

HV> I am trying to configure IIS and to redirect and having problems.
The
HV> documentation says that I need the following on server.xml file

HV> port="8009" minProcessors="5" maxProcessors="75"
HV>acceptCount="10" debug="0"/>

HV> Should I then comment out the previous connectors and have only
HV> AjpConnector

HV> Please help

HV> Hari

HV> --
HV> To unsubscribe, e-mail:

HV> For additional commands, e-mail:




-- 
Best regards,
 Jacobmailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Server.xml

2002-12-10 Thread Jacob Kjome
Hello Hari,

That's just a matter of the docs being not quite up-to-date.  The
Coyote connector is the connector for both http and jk (jk and jk2).
The other stuff is deprecated, although it still works just fine.

Jake

Tuesday, December 10, 2002, 12:24:23 PM, you wrote:



HV> Can somebody explain why in the default server.xml file we have 

HV>  port="8080" minProcessors="5" maxProcessors="75" enableLookups="true"
HV> redirectPort="8443" acceptCount="10" debug="0" connectionTimeout="2"
HV> useURIValidationHack="false"/>

HV> and 

HV>  port="8009" minProcessors="5" maxProcessors="75" enableLookups="true"
HV> redirectPort="8443" acceptCount="10" debug="0" connectionTimeout="2"
HV> useURIValidationHack="false"
HV> protocolHandlerClassName="org.apache.jk.server.JkCoyoteHandler"/>

HV> but AJPconnector that listens on port 8009 has been commented out. 

HV> Also when the server starts, we get an INFO message "ajp13 listening on
HV> tcp port 8009.

HV> I am trying to configure IIS and to redirect and having problems. The
HV> documentation says that I need the following on server.xml file

HV> port="8009" minProcessors="5" maxProcessors="75"
HV>acceptCount="10" debug="0"/>

HV> Should I then comment out the previous connectors and have only
HV> AjpConnector

HV> Please help

HV> Hari

HV> --
HV> To unsubscribe, e-mail:   
HV> For additional commands, e-mail: 



-- 
Best regards,
 Jacobmailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: slight OT: RequestInterceptor

2002-12-10 Thread Subir Sengupta
What version of TC are you using?  4.x does not use interceptors, 3.x does.

-Original Message-
From: Manavendra Gupta [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 3:34 AM
To: Tomcat Users List
Subject: slight OT: RequestInterceptor


Hi,

This probably is slightly off-topic, but I would like to know:

1. How to implement a RequestInterceptor? Is there some sample code
available?
2. Is it a good idea to implement one for managing sessions?

Thanks,
Manav.


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Server.xml

2002-12-10 Thread Hari Venkatesan


Can somebody explain why in the default server.xml file we have 



and 



but AJPconnector that listens on port 8009 has been commented out. 

Also when the server starts, we get an INFO message "ajp13 listening on
tcp port 8009.

I am trying to configure IIS and to redirect and having problems. The
documentation says that I need the following on server.xml file



Should I then comment out the previous connectors and have only
AjpConnector

Please help

Hari

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat + commons-logging + log4j

2002-12-10 Thread Pedro Salazar
Greetings,

Wendy, first let me give my thanks to you for your assistance, and let's
go to my problem here.

I updated log4j.properties to log to a file (I comment in the
ConsoleAppender). but, I don't know why it not only doesn't creates the
log file I specified, that it also only updates in catalina only to the
INFO level! The DEBUG level logs aren't passing the filter!!

What am I doing wrong??

my log4j.properties in WEB-INF/classes/:
"
log4j.rootLogger=DEBUG,NGIN
log4j.category.PT.ptinovacao.ngincare=DEBUG,NGIN
#log4j.appender.NGIN=org.apache.log4j.ConsoleAppender
log4j.appender.NGIN=org.apache.log4j.RollingFileAppender
log4j.appender.NGIN.File=../logs/ngincare.log
log4j.appender.NGIN.MaxFileSize=1024KB
log4j.appender.NGIN.layout=org.apache.log4j.PatternLayout
log4j.appender.NGIN.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n
"

thanks,
Pedro Salazar
-- 
pedro salazar (pt-inovacao) <[EMAIL PROTECTED]>
key id: D803BC61


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Problem running in Tomcat 4.1.2 - works fine in 4.0

2002-12-10 Thread Turner, John

The default invoker servlet is disabled by default in 4.1.12.

This comes up quite a bit, check the archives for yesterday, AFAIK it was
answered then.

http://archives.real-time.com/pipermail/tomcat-users/2002-December/thread.ht
ml#88025

John


> -Original Message-
> From: Gopi Mandava [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:51 PM
> To: [EMAIL PROTECTED]
> Subject: Problem running in Tomcat 4.1.2 - works fine in 4.0
> 
> 
> Hi,
> 
> I'm trying to port my application to 4.1.2 from 4.0. I added 
> my application 
> context to the server.xml file. When I try to access any of 
> my servlets, I 
> get an error page with "The requested resource 
> /xpm/servlet/MyServlet not 
> available" message.
> 
> I set up a simple application with just the "HelloWorld" 
> servlet and when I 
> try to access it, I get the same resource not available 
> exception. This 
> works fine in my Tomcat 4.0 setup. I use the same URL: 
> http://localhost:8080/test/servlet/Hello
> 
> Here is the web.xml I used in both cases:
> 
> 
> 
> 
>   PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
>  "http://java.sun.com/dtd/web-app_2_3.dtd";>
> 
> 
>  My Web Application
> 
>   
>   Hello
>   Hello
> 
> 
> -
> 
> Do I have to add anything extra to web.xml in 4.1.2 to make it work?
> 
> Thanks,
> Gopi
> 
> 
> 
> --
> To unsubscribe, e-mail:   

For additional commands, e-mail:


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Problem running in Tomcat 4.1.2 - works fine in 4.0

2002-12-10 Thread Gopi Mandava
Hi,

I'm trying to port my application to 4.1.2 from 4.0. I added my application 
context to the server.xml file. When I try to access any of my servlets, I 
get an error page with "The requested resource /xpm/servlet/MyServlet not 
available" message.

I set up a simple application with just the "HelloWorld" servlet and when I 
try to access it, I get the same resource not available exception. This 
works fine in my Tomcat 4.0 setup. I use the same URL: 
http://localhost:8080/test/servlet/Hello

Here is the web.xml I used in both cases:





PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd";>


My Web Application

	
		Hello
		Hello
		

-

Do I have to add anything extra to web.xml in 4.1.2 to make it work?

Thanks,
Gopi



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 



RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Doug Blackburn
Kris,
Thanks. I missed that!

-Original Message-
From: Kris Schneider [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:40 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug



  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }


or


  


Quoting Doug Blackburn <[EMAIL PROTECTED]>:

> This does not compile. The JSP Syntax document specifies that <% in jsp
> syntax is equivalent to  in xml syntax and moreover that
> "JSP and XML syntax cannot be mixed within a page."
>
> -Original Message-
> From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:26 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
>
>
> Try replacing the  to <%
> It might work.
>
> Hari
>
> -Original Message-
> From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:29 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
>
> Why does it compile when I take out the for loop?
>
> -Original Message-
> From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:20 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
>
>
> It is not a problem with Tomcat. Your JSP is not getting compiled
> correctly into a servlet class.
>
> " org.apache.jasper.JasperException: Unable to compile class for JSP"
>
> "org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
> ava:479)"
>
> Your compilation is failing at line 479.
>
> 
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> 
>
> Should this be scriplet or <%
>
> Take a look at your jsp and see if all opening tags and closing tags
> exist.
>
> Hari
>
> -Original Message-
> From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:14 PM
> To: Tomcat Users List
> Subject: JSP: XML vs JSP Syntax: Looks like a bug
>
> The complete code for two very simple jsp's are below. They both do the
> same
> thing, display a value. The problem is that (2) gets an internal error
> upon
> request (error message follows code). (1) works fine.
>
> If I take the for loop out of (2) and set the integer to some value, the
> request is processed and the value is displayed correctly. Tomcat does
> not
> seem to be able to handle a for loop in a scriptlet tag, but is able to
> handle it in jsp syntax. This looks like a bug.
>
> Since I am new to Tomcat I thought I would send out the email to see if
> there is something I have neglected before submitting a bug report.
>
> Any comments would be appreciated.
> Thanks
> Doug
>
> 
> (1)JSP SYNTAX
> -
> <%
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> %>
>
> <%= "The count is " + count %>
>
> -
> (2)XML SYNTAX
> -
>xmlns:jsp="http://java.sun.com/JSP/Page";
>   version="1.2">
>
> 
>
> 
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> 
>
> 
> "The count is " + count
> 
>
> 
>
> 
> 
> ---
> ERROR MESSAGE
> -
>
> HTTP Status 500 -
>
> 
> 
> 
>
> type Exception report
>
> message
>
> description The server encountered an internal error () that prevented
> it
> from fulfilling this request.
>
> exception
>
> org.apache.jasper.JasperException: Unable to compile class for JSP
>   at
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja
> va:4
> 79)
>   at
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
> va:1
> 84)
>   at
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
>   at
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
>   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>   at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
> tion
> FilterChain.java:247)
>   at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
> erCh
> ain.java:193)
>   at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
> e.ja
> va:260)
>   at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvok
> eNext(StandardPipeline.java:643)
>   at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
> 80)
>   at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
>   at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
> e.ja
> va:191)
>   at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvok
> eNext(StandardPipeline.java:643)
>   at
> org.apache.catalina.core.StandardPipeline.invo

RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Noel J. Bergman
> This does not compile. The JSP Syntax document specifies that <% in jsp
> syntax is equivalent to  in xml syntax and moreover that
> "JSP and XML syntax cannot be mixed within a page."

One of my least favorite parts othe JSP 1.2 specification.  Fortunately,
this is changed in JSP 2.0 so that the XML tags are valid in *all* JSP
pages.  One major reason for why I want to use Tomcat 5 ASAP.

--- Noel


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Kris Schneider

  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }


or


  


Quoting Doug Blackburn <[EMAIL PROTECTED]>:

> This does not compile. The JSP Syntax document specifies that <% in jsp
> syntax is equivalent to  in xml syntax and moreover that
> "JSP and XML syntax cannot be mixed within a page."
> 
> -Original Message-
> From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:26 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
> 
> 
> Try replacing the  to <%
> It might work.
> 
> Hari
> 
> -Original Message-
> From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:29 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
> 
> Why does it compile when I take out the for loop?
> 
> -Original Message-
> From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:20 PM
> To: Tomcat Users List
> Subject: RE: XML vs JSP Syntax: Looks like a bug
> 
> 
> It is not a problem with Tomcat. Your JSP is not getting compiled
> correctly into a servlet class.
> 
> " org.apache.jasper.JasperException: Unable to compile class for JSP"
> 
> "org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
> ava:479)"
> 
> Your compilation is failing at line 479.
> 
> 
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> 
> 
> Should this be scriplet or <%
> 
> Take a look at your jsp and see if all opening tags and closing tags
> exist.
> 
> Hari
> 
> -Original Message-
> From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:14 PM
> To: Tomcat Users List
> Subject: JSP: XML vs JSP Syntax: Looks like a bug
> 
> The complete code for two very simple jsp's are below. They both do the
> same
> thing, display a value. The problem is that (2) gets an internal error
> upon
> request (error message follows code). (1) works fine.
> 
> If I take the for loop out of (2) and set the integer to some value, the
> request is processed and the value is displayed correctly. Tomcat does
> not
> seem to be able to handle a for loop in a scriptlet tag, but is able to
> handle it in jsp syntax. This looks like a bug.
> 
> Since I am new to Tomcat I thought I would send out the email to see if
> there is something I have neglected before submitting a bug report.
> 
> Any comments would be appreciated.
> Thanks
> Doug
> 
> 
> (1)JSP SYNTAX
> -
> <%
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> %>
> 
> <%= "The count is " + count %>
> 
> -
> (2)XML SYNTAX
> -
>xmlns:jsp="http://java.sun.com/JSP/Page";
>   version="1.2">
> 
> 
> 
> 
>   int count = 0;
>   for (int j = 0; j <= 10; j++) {
> count = j;
>   }
> 
> 
> 
> "The count is " + count
> 
> 
> 
> 
> 
> 
> ---
> ERROR MESSAGE
> -
> 
> HTTP Status 500 -
> 
> 
> 
> 
> 
> type Exception report
> 
> message
> 
> description The server encountered an internal error () that prevented
> it
> from fulfilling this request.
> 
> exception
> 
> org.apache.jasper.JasperException: Unable to compile class for JSP
>   at
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja
> va:4
> 79)
>   at
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
> va:1
> 84)
>   at
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
>   at
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
>   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>   at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
> tion
> FilterChain.java:247)
>   at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
> erCh
> ain.java:193)
>   at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
> e.ja
> va:260)
>   at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvok
> eNext(StandardPipeline.java:643)
>   at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
> 80)
>   at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
>   at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
> e.ja
> va:191)
>   at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
> nvok
> eNext(StandardPipeline.java:643)
>   at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
> 80)
>   at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
>   at
> org.apache.catalina.core.StandardContext.invoke(Standar

RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Doug Blackburn
This does not compile. The JSP Syntax document specifies that <% in jsp
syntax is equivalent to  in xml syntax and moreover that
"JSP and XML syntax cannot be mixed within a page."

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:26 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug


Try replacing the  to <%
It might work.

Hari

-Original Message-
From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:29 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug

Why does it compile when I take out the for loop?

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:20 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug


It is not a problem with Tomcat. Your JSP is not getting compiled
correctly into a servlet class.

" org.apache.jasper.JasperException: Unable to compile class for JSP"

"org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
ava:479)"

Your compilation is failing at line 479.


  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }


Should this be scriplet or <%

Take a look at your jsp and see if all opening tags and closing tags
exist.

Hari

-Original Message-
From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:14 PM
To: Tomcat Users List
Subject: JSP: XML vs JSP Syntax: Looks like a bug

The complete code for two very simple jsp's are below. They both do the
same
thing, display a value. The problem is that (2) gets an internal error
upon
request (error message follows code). (1) works fine.

If I take the for loop out of (2) and set the integer to some value, the
request is processed and the value is displayed correctly. Tomcat does
not
seem to be able to handle a for loop in a scriptlet tag, but is able to
handle it in jsp syntax. This looks like a bug.

Since I am new to Tomcat I thought I would send out the email to see if
there is something I have neglected before submitting a bug report.

Any comments would be appreciated.
Thanks
Doug


(1)JSP SYNTAX
-
<%
  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }
%>

<%= "The count is " + count %>

-
(2)XML SYNTAX
-
http://java.sun.com/JSP/Page";
  version="1.2">




  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }



"The count is " + count






---
ERROR MESSAGE
-

HTTP Status 500 -





type Exception report

message

description The server encountered an internal error () that prevented
it
from fulfilling this request.

exception

org.apache.jasper.JasperException: Unable to compile class for JSP
at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja
va:4
79)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:1
84)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tion
FilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erCh
ain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.ja
va:260)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.ja
va:191)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:239
6)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:180
)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVa
lve.
java:170)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:641)
at
org.apache.cat

RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Hari Venkatesan
Try replacing the  to <% 
It might work.

Hari 

-Original Message-
From: Doug Blackburn [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 10, 2002 12:29 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug

Why does it compile when I take out the for loop?

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:20 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug


It is not a problem with Tomcat. Your JSP is not getting compiled
correctly into a servlet class.

" org.apache.jasper.JasperException: Unable to compile class for JSP"

"org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
ava:479)"

Your compilation is failing at line 479.


  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }


Should this be scriplet or <%

Take a look at your jsp and see if all opening tags and closing tags
exist.

Hari

-Original Message-
From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:14 PM
To: Tomcat Users List
Subject: JSP: XML vs JSP Syntax: Looks like a bug

The complete code for two very simple jsp's are below. They both do the
same
thing, display a value. The problem is that (2) gets an internal error
upon
request (error message follows code). (1) works fine.

If I take the for loop out of (2) and set the integer to some value, the
request is processed and the value is displayed correctly. Tomcat does
not
seem to be able to handle a for loop in a scriptlet tag, but is able to
handle it in jsp syntax. This looks like a bug.

Since I am new to Tomcat I thought I would send out the email to see if
there is something I have neglected before submitting a bug report.

Any comments would be appreciated.
Thanks
Doug


(1)JSP SYNTAX
-
<%
  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }
%>

<%= "The count is " + count %>

-
(2)XML SYNTAX
-
http://java.sun.com/JSP/Page";
  version="1.2">




  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }



"The count is " + count






---
ERROR MESSAGE
-

HTTP Status 500 -





type Exception report

message

description The server encountered an internal error () that prevented
it
from fulfilling this request.

exception

org.apache.jasper.JasperException: Unable to compile class for JSP
at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja
va:4
79)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:1
84)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tion
FilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erCh
ain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.ja
va:260)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.ja
va:191)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:239
6)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:180
)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVa
lve.
java:170)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:641)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:172
)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:641)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
or

RE: XML vs JSP Syntax: Looks like a bug

2002-12-10 Thread Doug Blackburn
Why does it compile when I take out the for loop?

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:20 PM
To: Tomcat Users List
Subject: RE: XML vs JSP Syntax: Looks like a bug


It is not a problem with Tomcat. Your JSP is not getting compiled
correctly into a servlet class.

" org.apache.jasper.JasperException: Unable to compile class for JSP"

"org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.j
ava:479)"

Your compilation is failing at line 479.


  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }


Should this be scriplet or <%

Take a look at your jsp and see if all opening tags and closing tags
exist.

Hari

-Original Message-
From: Doug Blackburn [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 12:14 PM
To: Tomcat Users List
Subject: JSP: XML vs JSP Syntax: Looks like a bug

The complete code for two very simple jsp's are below. They both do the
same
thing, display a value. The problem is that (2) gets an internal error
upon
request (error message follows code). (1) works fine.

If I take the for loop out of (2) and set the integer to some value, the
request is processed and the value is displayed correctly. Tomcat does
not
seem to be able to handle a for loop in a scriptlet tag, but is able to
handle it in jsp syntax. This looks like a bug.

Since I am new to Tomcat I thought I would send out the email to see if
there is something I have neglected before submitting a bug report.

Any comments would be appreciated.
Thanks
Doug


(1)JSP SYNTAX
-
<%
  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }
%>

<%= "The count is " + count %>

-
(2)XML SYNTAX
-
http://java.sun.com/JSP/Page";
  version="1.2">




  int count = 0;
  for (int j = 0; j <= 10; j++) {
count = j;
  }



"The count is " + count






---
ERROR MESSAGE
-

HTTP Status 500 -





type Exception report

message

description The server encountered an internal error () that prevented
it
from fulfilling this request.

exception

org.apache.jasper.JasperException: Unable to compile class for JSP
at
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja
va:4
79)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:1
84)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tion
FilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erCh
ain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.ja
va:260)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.ja
va:191)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:239
6)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:180
)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVa
lve.
java:170)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:641)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:172
)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:641)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
80)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java
:174)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
nvok
eNext(StandardPipeline.java:643)
at
org.apache.catalina.core

  1   2   3   >