Re: A dead cat

2002-12-09 Thread Simon Kelly
Thanks for the reply.

I have started redeploying manually, as you suggested.  This seems to be
working very well so far.  A bit long winded but at least nothing has gone
wrong.  Just incase it is of any use and may shine some light on the
original problem the details of the machine and set up with web.xml are
shown below.

Thanks again for you help.

Regards

Simon

Machine:  1G Pentium (Standard off the shelf job)
OS:  MS Windows 2000
Java:  Sun j2sdk1.4.0_02
Tomcat:  4.1.12

web.xml  (This is the one for my application.  If you ment another just ask
and ye shall receive)

?xml version=1.0 encoding=UTF-8?

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

web-app
servlet
servlet-name
testrun
/servlet-name
servlet-class
FrontServlet
/servlet-class
/servlet
servlet-mapping
servlet-name
testrun
/servlet-name
url-pattern
/test-index.html
/url-pattern
/servlet-mapping
session-config
session-timeout
30
/session-timeout
/session-config
welcome-file-list
welcome-file
/index.html
/welcome-file
/welcome-file-list
/web-app








- Original Message -
From: Shapira, Yoav [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Friday, December 06, 2002 3:06 PM
Subject: RE: A dead cat


Howdy,
It is difficult to help specifically, but here are a couple of general
notes that may be relevant:

1. Tomcat won't die (actually, the JVM won't die) if you've created any
non-daemon threads in your application.  If you create such threads,
either set them as daemons or ensure their proper termination.

2. I suggest simplifying your deployment process, at least temporarily.
Don't use the manager to redeploy.  Copy the war file manually each
time.  Unless you have some special settings, don't enter a Context
element for your webapp in server.xml.  Restart tomcat, ensuring it's
dead, between each deployment.

If you could post more details, including OS name and version, tomcat
version, JDK version, your web.xml file, we could probably help more.

Yoav Shapira
Millennium ChemInformatics


-Original Message-
From: Simon Kelly [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 06, 2002 4:19 AM
To: [EMAIL PROTECTED]
Subject: A dead cat

Hi,

I am currently using tomcat as a standalone server to test some webapps
that
I am creating.  I have some experiance with web servers but little or
no
experiance with tomcat.  And I have a couple of major problems.

1)  The cat is dead but won't go away!  I have installed tomcat twice
now,
the first time I had a conflict within the port addressing for tomcat
and
my
exist database where both were configured to listen on the same port.
A
school boy error really, but when I killed off tomcat and edited the
server
config file to listen on an other port I got Exceptions every time I
tried
to restart tomcat.  I uninstalled and then reinstalled tomcat and
everything
was working fine for a couple of days.  However! After problem 2
occured
the
same situation has come back with tomcat.  The one thing I have noticed
though is that the tomcat.exe in the process list cannot be killed
using
task manager.

2)  When tomcat was up and running the second time I managed to get the
war
file into the webapps dir and it automatically detected it, created a
directory and deployed.  However, after a while and during one of the
updates to the app, tomcat seemed to jam and would not reload the app.
I
tryed to use the manager, but it would not let me even restart the app.
So,
I removed it from the directory and then restarted tomcat.  This time
tomcat
would not even see the file was there and I had to install it using
manager.
This worked for the first couple of changes, but then this too failed
and
now tomcat will not respond at all.

I am going to unistall and reinstall again, but if anyone knows why
this is
going wrong I would be most greatful.

As a side, during the deployment using manager I got the  app in by
declaring the path '/katrin' and then giving the file url
'file:/c:/programme/apache group/tomcat 4.1/webapps/katrin.war'.  This
worked for a couple of times, but then failed.  There are a direct copy
of
the last lines I entered.  Is there something I have done wrong in the
url,
as it is this error Mallformed url ... that I am getting.

Kindest regards

Simon

Institut fuer
Prozessdatenverarbeitung
und Elektronik,
Forschungszentrum Karlsruhe GmbH,
Postfach 3640,
D-76021 Karlsruhe,
Germany.

Tel: (+49)/7247 82-4042
E-mail : [EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:tomcat-user-
[EMAIL PROTECTED]
For additional commands, e-mail: mailto:tomcat-user-
[EMAIL PROTECTED]


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, 

RE: Help with using mod_jk2

2002-12-09 Thread Robert L Sowders
Here's another,

ftp://pokey.wr.usgs.gov/pub/rsowders/Apache2_Jk2_TC4.1.x_JSDK1.4.x.zip

If you're not using windows then just pay attention to the configuration.

rls





Madere, Colin [EMAIL PROTECTED]
12/08/2002 07:58 PM
Please respond to Tomcat Users List

 
To: 'Tomcat Users List' [EMAIL PROTECTED]
cc: 
Subject:RE: Help with using mod_jk2


There is some less knowledge-assuming documentation here:

http://www.johnturner.com/howto/apache-tomcat-howto.html

But I've yet to find nor receive reference to any trully complete
documentation.  Your best bet is to see if you can make it work with the
stuff that's around (and searching the list archives) and then ask a
specific question when you get stuck :(


 -Original Message-
 From:  Mike DiChiappari [SMTP:[EMAIL PROTECTED]]
 Sent:  Saturday, December 07, 2002 9:34 PM
 To:[EMAIL PROTECTED]
 Subject:   Help with using mod_jk2
 
 Is there any good documentation out there that describes how to get 
 mod_jk2 working with Apache 2.0 and tomcat 4.x?  The docs on the 
 jakarta site are good if you already know what your doing and love 
 geek-speak.  I am looking for something that simply leads me through 
 the process without already assuming I know everything about 
 connectors and other junk (that's not relevant).
 
 Thanks,
 Mike
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: JK and multiple virtual hosts on Apache (repost)

2002-12-09 Thread Robert L Sowders
This has come up quite often in the past.  Search the archives for 
JkUriSet.  When using apache/modssl make sure you use IP based virtual 
hosts.

rls





Madere, Colin [EMAIL PROTECTED]
12/08/2002 08:00 PM
Please respond to Tomcat Users List

 
To: 'Tomcat Users List' [EMAIL PROTECTED]
cc: 
Subject:RE: JK and multiple virtual hosts on Apache (repost)


Thanks for the input, but I don't want any port numbers in the URLs for a
number of reasons.  Hence my use of the JK connector (that and only 
wanting
to set up SSL through Apache and not Tomcat).

I'm quite surprised no one else on this list has a setup similar to what 
I'm
doing

 -Original Message-
 From:  David Brown [SMTP:[EMAIL PROTECTED]]
 Sent:  Friday, December 06, 2002 7:48 PM
 To:'Tomcat Users List'
 Subject:   Re: JK and multiple virtual hosts on Apache 
(repost)
 
 Madere, Colin writes: 
 
  I might have had some list trouble so I'm reposting this (since I got 
no
  responses so far). 
  
  -Original Message-
  From:   Madere, Colin [SMTP:[EMAIL PROTECTED]]
  Sent:   Thursday, December 05, 2002 5:55 PM
  To: '[EMAIL PROTECTED]'
  Subject:4 Apache2 VirtualHosts + 1 Tomcat4 = ? JK 
connectors? 
  
  Before I go off into JK configuration craziness, I thought I'd post 
my
  situation and see what rises to the top. 
  
  What I have: 
  
  1 Apache 2.0.43 with 4 virutal hosts (3 w/ SSL)
  1 Tomcat 4.12 (no virtual hosts as of yet)
  1 JK 1.2.0 connector working properly with the non-SSL host from 
Apache
 
  
  What I want to do: 
  
  Have any requests for apps running on Tomcat from any of the 4 
virtual
  hosts
  to be redirected to the same Tomcat instance.  This is mainly for
  simplicity
  since I will be using Tomcat Realms for login to determine what to do
 for
  a
  user in the app based on role.  If I have to do 4 virtual hosts in
 Tomcat,
  then let me know :) 
  
  Is the correct way to make this work with JK to create 4 
Connector
  instances at, say, ports 8009-8012 in my tomcat server.xml, then set 
up
 4
  JK
  workers in workers.properties with each respective virtual host's
 domain
  name and redirection port?  Or is there some way to use a single
  connector?
  (I'm guessing NOT the latter due to the port probably being bound by
 the
  connector process) 
  
  Having said this and if my former idea is the correct way, for the 
JK
  connector entry in my Tomcat server.xml, is the redirectPort
 arbitrarily
  chosen?  I have 8443 in for my single connector/site/host setup, 
would
 I
  simply use 8443-8446? 
  
  Any input on this setup appreciated. 
  
  
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  --
  To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
 mailto:[EMAIL PROTECTED] 
  
 
 
 Hello Colin, i'm unsure about advising on this because i'm running the 
 non-threading apache 1.3.27. i have a very similar setup as u describe
 that 
 works 4 me: i have 4 virtual hosts running on the public wire plus a dns 

 server. the virtual hosts 4 defined in apache only w/ all https 
JDBCRealm 
 protected directories serving jsp and servlets redirected from apache on 

 port 8443. all https cgi-bin is redirected through port 443. otherwise 
all
 
 http is port 80 and 8080 for jsp/servlets. this config is pretty much 
 out-of-the-box w/o any undue config on the tc side except for the 
 JDBCRealm and a custom web.xml for each webapp both secure and 
non-secure.
 
 only server.xml editing done was basically to uncomment the connectors 
for
 
 port 8443 (ssl and non-ssl connectors). no extra stuff like Host tags 
or
 
 anything like that to confuse the issue. hope this helps, david. 
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Name Based Virtual Host Problem

2002-12-09 Thread Robert L Sowders
You have told apache to answer www.yyy.com not yyy.com.  When you ask for 
yyy.com and you get xxx.com then the default virtual is answering not your 
intended target.  There are a few ways to solve this.  Easiest would be to 
make a cname for www.yyy.com of yyy.com and have DNS correct the omission 
of the www or setup IP based virtual hosts, then alias all the IPs to the 
same nic. 

In any case this is an Apache specific question and would be better served 
on the Apache lists not here.

rls





Laxmikanth M.S. [EMAIL PROTECTED]
12/08/2002 10:46 PM
Please respond to Tomcat Users List

 
To: [EMAIL PROTECTED]
cc: 
Subject:Name Based Virtual Host Problem


Hi all,
I have configured apache1.3.27 and tomcat4.1.12.
I have configured two sites as below using Name Based Hosting.
when I type www.xxx.com and www.yyy.com the correct sites are coming - no
problem ...but when I type yyy.com it opens www.xxx.com's pages...why 
this
happensd ..how it can be solved
thanks in advance

*
NameVirtualHost  *
VirtualHost *
#ServerAdmin [EMAIL PROTECTED]
DocumentRoot /usr/local/apache/tggf
ServerName www.xxx.com
/VirtualHost

VirtualHost *
#ServerAdmin [EMAIL PROTECTED]
DocumentRoot /usr/local/apache/site
ServerName www.yyy.com
/VirtualHost

* 

regards
Laxmiaknth

*
Disclaimer: The information in this e-mail and any attachments is
confidential / privileged. It is intended solely for the addressee or
addressees. If you are not the addressee indicated in this message, you 
may
not copy or deliver this message to anyone. In such case, you should 
destroy
this message and kindly notify the sender by reply email. Please advise
immediately if you or your employer does not consent to Internet email for
messages of this kind.
*

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: apache tomcat integration

2002-12-09 Thread Robert L Sowders
Apache is telling you that there is something wrong with the loading of 
the mod_jk.so, either the LoadModule line in the httpd.conf is wrong or 
the .so file is bogus in some way.

run the apachectl configtest to check the syntax of the httpd.conf.  You 
should get the same error.  Now double check the LoadModule line for that 
module in the httpd.conf.  Triple check that the syntax a path are correct 
for the command.  Try moving it to the end of the LoadModule section or 
the beginning.  If you are using Apache 1.3.x then make sure you have the 
AddModule statement also and it is in the same relative position as the 
LoadModule statement.

rls





Manish  Sharma [EMAIL PROTECTED]
12/07/2002 09:37 PM
Please respond to Tomcat Users List

 
To: [EMAIL PROTECTED]
cc: 
Subject:apache tomcat integration


  Dear Sir/Mam..

please help me on this issue. i'm facing problem in apache tomcat 
integration on linux server.
  there's error after restart the apache. theres message started 
ok.
  but in error.log two errors.
  Syntax error on line 2 of
  /home/suvigya/Desktop/manish/jakarta-tomcat-4.1.12-LE-jdk14/co
  nf/jk/mode_jk.conf:
  Invalid command 'LoadModule', perhaps mis-spelled or defined by 
a
  module not included in the server configuration

  i have made all required changes in httpd.conf,mode_jk.conf 
  workers.properties. i have copied mod_jk.so in apache's lib.
  so please help me on this issue as soon as possible.
  i'll be very thankful to you.

  Manish Sharma reply me [EMAIL PROTECTED]
  Java Programmer
  VGL Softech Ltd.
  Jaipur (India).





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: apache tomcat integration

2002-12-09 Thread Vikram Dham
Also make sure ( by using httpd -l) that shared objects(mod_so) are enabled
in your apache configuration. If you don't see mod_so it means loadmodule
makes no sense to apache.

HTH

Vikram
- Original Message -
From: Robert L Sowders [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 4:03 AM
Subject: Re: apache tomcat integration


 Apache is telling you that there is something wrong with the loading of
 the mod_jk.so, either the LoadModule line in the httpd.conf is wrong or
 the .so file is bogus in some way.

 run the apachectl configtest to check the syntax of the httpd.conf.  You
 should get the same error.  Now double check the LoadModule line for that
 module in the httpd.conf.  Triple check that the syntax a path are correct
 for the command.  Try moving it to the end of the LoadModule section or
 the beginning.  If you are using Apache 1.3.x then make sure you have the
 AddModule statement also and it is in the same relative position as the
 LoadModule statement.

 rls





 Manish  Sharma [EMAIL PROTECTED]
 12/07/2002 09:37 PM
 Please respond to Tomcat Users List


 To: [EMAIL PROTECTED]
 cc:
 Subject:apache tomcat integration


   Dear Sir/Mam..

 please help me on this issue. i'm facing problem in apache tomcat
 integration on linux server.
   there's error after restart the apache. theres message started
 ok.
   but in error.log two errors.
   Syntax error on line 2 of
   /home/suvigya/Desktop/manish/jakarta-tomcat-4.1.12-LE-jdk14/co
   nf/jk/mode_jk.conf:
   Invalid command 'LoadModule', perhaps mis-spelled or defined by
 a
   module not included in the server configuration

   i have made all required changes in httpd.conf,mode_jk.conf 
   workers.properties. i have copied mod_jk.so in apache's lib.
   so please help me on this issue as soon as possible.
   i'll be very thankful to you.

   Manish Sharma reply me [EMAIL PROTECTED]
   Java Programmer
   VGL Softech Ltd.
   Jaipur (India).





 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]





 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Tomcat shared libraries

2002-12-09 Thread Bodycombe, Andrew
If there are libraries you require both inside and outside tomcat, you could
consider placing them in /jre/lib/ext. They are then available to all java
applications using the particular JRE instance, including tomcat. For pre
1.4 versions, I found this useful for things like JSSE and regular
expressions.

Andy.



-Original Message-
From: Dave Ford
To: Tomcat Users List
Cc: [EMAIL PROTECTED]
Sent: 08/12/2002 20:38
Subject: Re: Tomcat shared libraries



 Now the problem is this: Tomcat doesn't use libraries from anywhere
but
 within its scope.

Rick, I was reading your discussion with Craig McClanahan and I agree
with
you - that a web app should be able to access classes outside the tomcat
folder. Copying class into catalina/shared for each build is a pain
(even
with ant). Symlinks won't work on windows. Why couldn't tomcat add an
entry
into server.xml, to point to extra class location? Orion has had this
for a
few years now.

 * Mung around with the batch files and add the required directories to
the
 classpath for Tomcat.

How exactly did you do this? What batch file?

Dave Ford
Smart Soft - The Developer Training Company
http://www.smart-soft.com

- Original Message -
From: Herrick, Rick [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, September 10, 2002 7:29 PM
Subject: Tomcat shared libraries


 I'm currently in the process of developing a web application with
Tomcat
as
 the default reference platform.  Although we'll support running with
BEA,
 JRun, etc., our installer app will install and modify settings only if
 you're installing for Tomcat.  I have to make a decision on how to
proceed
 with our installer and really need to understand this problem.

 Now the problem is this: Tomcat doesn't use libraries from anywhere
but
 within its scope.  That is, it ignores the system classpath in its
default
 configuration.  I've read the class loader how-to (which isn't really
a
 how-to, but whatever), and also worked with it for quite some time, so
I
 understand pretty well how it works.  Basically your classes and JARs
need
 to be placed somewhere within the context of Tomcat: WEB-INF\classes,
 WEB-INF\lib, $CATALINA_HOME/common/classes,
 $CATALINA_HOME/common/endorsed/*.jar, $CATALINA_HOME/common/lib/*.jar,
 $CATALINA_HOME/shared/classes, and $CATALINA_HOME/shared/lib/*.jar.

 The problem is that this is a strictly web app-centric view of the
world.
 In fact, many of the libraries that we need to use from within our web
app
 are standard class libraries that other non-web applications need to
use,
 such as our main server product, our non-web client applications,
 development tools, and so on.  This leaves me three choices:

 * Replicate the libraries in two places, one for non-web apps and one
for
 web apps (this solution, BTW, has to be cross-platform capable, so
using
 links is out).  This is less than desirable because of the maintenance
 problem with controlling versions.

 * Place the primary libraries within the Tomcat context and refer the
other
 applications to that location.  This doesn't work both for legacy and
 upgrade reasons (i.e. if you've already got a server installed, it
expects
 to find its support libraries in a particular place and not have them
moved
 over to another location) and because it's nonsensical for a
non-web-based
 application to refer to an app server's repository.



 I do the third.  This works just dandy: my required libraries remain
in
 their central product-centric location, everyone can find what they
need,
 and there's only one version of the libraries around (well, it's a
 development machine, so of course there's about 10 versions of every
library
 around, but *I* know where they are :^).

 I browsed through the archives of this list and found the following
quote:

 From

http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg64144.html
:
 How do I add an existing jar to a servlet's classpath, if that jar
doesn't
 want to live under WEB-INF/lib?  (I ultimately asked this here, and
got a
 solid you can't response, so I'm satisfied.  However, I've seen this
asked
 here often, so it'd make a great FAQ submission.--Paul Brinkley

 My question is, why is this so?  Why is it that you can't?  Since I
know
 you can in practice (by setting the CLASSPATH sometime after
 setclasspath.bat nukes the system classpath or by removing
setclasspath.bat
 altogether), the prohibition seems arbitrary.  Is there a security
issue
 with Tomcat doing class loading outside of the Tomcat context?  It
seems
to
 me that it's mainly due to a provincial view of a web app as a
 self-contained entity, but in reality most of the people I know
writing
web
 apps nowadays are running into *exactly* this sort of issue again and
again.


 So to make our installer work, at this point I'm actually moving the
 existing setclasspath.bat file to some tmp name and creating a new one
that
 sets the CLASSPATH to what we need.  Is there any problem with this
other
 than it's not 

Re: Why run tomcat as root

2002-12-09 Thread Rasputin
* Nikola Milutinovic [EMAIL PROTECTED] [1238 08:38]:
 
 Just to clarify things a bit, before I ask for a new feature in Tomcat. 
 Most security conciencious servers on UNIX (like BIND 9) use this 
 sequence:
 
 1. Bind to TCP ports
 2. Load all dynamic modules, libraries (usually done by the loader)
 3. chroot()
 4. setuid()
 
Yes, this looks like a UNIX specific thing, but what does this gain you?
All it protects you from is file access, an unprivileged user does the
same without the hassle of chrooting a JVM. The network is still
vulnerable to abuse.

(following is a general comment and not directed at Nikola personally)

Just run tomcat as a normal user and port-forward. Read Proxy Support HOWTO
and treat the forwarded port as a proxy server. Job done. Get on with
your life.

This discussion has gone on for over a week now.  I seem to remember
there are one or two other lists for Linux system administration on the
Net so can we please pack this thread in? :)

(PS: If you insist on normal users binding to port 80, google for
'privileges' and read some white papers. The BSDs have done a lot of work
in this area.)

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

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: tomcat + eclipse

2002-12-09 Thread Cédric Viaud
JSP debugging. They explain how to do ot on their site. I've never used it
before, but will certainly have to soonly.

I'll get you informed.

Regards,

Cédric

- Original Message -
From: Cristiano Silva [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Friday, December 06, 2002 1:22 PM
Subject: Re: tomcat + eclipse


 And debugging JSP... do you know it works?

 Em Sex 06 Dez 2002 08:18, Cédric Viaud escreveu:
  The answer is YESSS :
 
  http://www.sysdeo.com/eclipse/tomcatPlugin.html
 
  And it works fine.
 
  HTH,
 
 Cédric
 
  - Original Message -
  From: [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Wednesday, December 04, 2002 11:27 AM
  Subject: tomcat + eclipse
 
   Hi
  
   I'm using Eclipse as my IDE
  
   is there a way to integrate Tomcat with Eclipse?
  
   thanx

 --
 
 Cristiano Moreira Silva
 Lecom S/A - Liderança Estratégica em Comunicação Digital
 WebDeveloper - Tecnologia
 http://www.lecom.com.br
 [EMAIL PROTECTED]


 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Help with using mod_jk2 continued

2002-12-09 Thread Theodore A. Jencks
This seems to me a large problem with this particular project.  There isn't enough 
clear documentation on setting up and installing mod_jk2.  I posted a problem a while 
back that no one has responded to yet.  Perhaps because no one in the know saw the 
post or perhaps I was just unclear.  If the developer of mod_jk2 or someone in the 
know would explain a couple things to me I'm pretty sure I could write some decent 
documentation on setting up and using mod_jk2.  It's clear there are plenty of 
questions out there about Tomcat; just look at the number of messages this list 
receives.

First, I've managed to compile and install the application however there is one thing 
that's really annoying.  I'm not sure if it's a bug but when I compile mod_jk2 I have 
to put the apache header files in $(apr.home)/include.  My particular installation 
happens to have apache's header files in /usr/include/apache.  It seems to me you 
should be able to tell ant where to look for the header files without having to copy 
them.

Second, there is no mention in any of the docs about certain files that you need to 
make mod_jk2 run.  For instance there is no mention of jtc.jar.  In fact there are a 
bunch of other jar files that the build produces which I've got no clue what to do 
with.  I read some place that jtc.jar is a replacement for tomcat-coyote.jar, 
tomcat-http11.jar and tomcat-util.jar.  If there were more documentation on what these 
files actually were and what they do things would be much easier to understand.

Third, the documentation on configuring mod_jk2 is totally inadequate.  Sure some 
configuration examples are give however following the docs didn't help me any.  Apache 
still gets a page not found error when I try going to any of the example web apps even 
with the recommended configuration.  I don't even know were to look for debugging 
information because the docs are devoid of that info.

I don't want to sound like I'm complaining because I'm glad there is an open source 
solution such as tomcat and mod_jk2.  I'd just like for there to be some usable 
documentation.  And if any developers are willing to help me in understanding how 
tomcat and mod_jk2 work together, I'll be at your service; glad and willing to write 
some clear and complete documentation for this project.

Regards,
Theo



-Original Message-
From: Robert L Sowders [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 12:45 AM
To: Tomcat Users List
Cc: 'Tomcat Users List'
Subject: RE: Help with using mod_jk2


Here's another,

ftp://pokey.wr.usgs.gov/pub/rsowders/Apache2_Jk2_TC4.1.x_JSDK1.4.x.zip

If you're not using windows then just pay attention to the configuration.

rls





Madere, Colin [EMAIL PROTECTED]
12/08/2002 07:58 PM
Please respond to Tomcat Users List


To: 'Tomcat Users List' [EMAIL PROTECTED]
cc:
Subject:RE: Help with using mod_jk2


There is some less knowledge-assuming documentation here:

http://www.johnturner.com/howto/apache-tomcat-howto.html

But I've yet to find nor receive reference to any trully complete documentation.  Your 
best bet is to see if you can make it work with the stuff that's around (and searching 
the list archives) and then ask a specific question when you get stuck :(


 -Original Message-
 From:  Mike DiChiappari [SMTP:[EMAIL PROTECTED]]
 Sent:  Saturday, December 07, 2002 9:34 PM
 To:[EMAIL PROTECTED]
 Subject:   Help with using mod_jk2

 Is there any good documentation out there that describes how to get
 mod_jk2 working with Apache 2.0 and tomcat 4.x?  The docs on the
 jakarta site are good if you already know what your doing and love
 geek-speak.  I am looking for something that simply leads me through
 the process without already assuming I know everything about
 connectors and other junk (that's not relevant).

 Thanks,
 Mike

 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Using filters to transform output

2002-12-09 Thread Andreas Hucks
Hi,

I have an existing PHP application I want to port to Java servlets (I am an
experienced programmer, but new to Java servlets). It is basically an admin
interface for managing user accounts for community sites. To keep this as
flexible and true to a MVC-pattern as possible, I figured I'd have my
servlet generate a custom response object from a custom request object. I
then would write filters to translate the request parameters to my custom
request and on the way back, create the actual output from my custom
response. This way I should be able to make the same app usable by different
clients by just throwing in another filter (required client types at the
moment are (X)HTML, Flash/XML, and Flash/FlashRemoting).

From what I understand, this is one of the main uses of filters. My question
is, how do I pass the custom request/response objects between  my filters
and the servlet? I guess it involves HttpServletResponseWrappers, but I
can't figure out how (you can overwrite getWriter() and such, but that is of
no use to me). What I would need is to attach my result as a generic object
to the HttpServletResponse, and have my filter retrieve it, format it, and
write the response to the client.

I can do the above by having my servlet output XML, and then having my
filter transform the XML to the actual output. But this seems to be
unnecessary overhead to me (unless I want to use XSLT anyway, which I
don't).

Thanks,
Andreas


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Tomcat Windows

2002-12-09 Thread Alberto Puerta

 Hi.

 When start Tomcat in Windows, startup.bat is launched with a MS-DOS window
but i'd like to run it as a process and without any visible window that
somebody can close and stop the server.

 Is ther any solution? Using bootstrap.jar (i test it and nothing)?

 Thanks.


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Tomcat Windows

2002-12-09 Thread Roberts, Eric
Run Tomcat as a service - see the documentation for how to!

-Original Message-
From: Alberto Puerta [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 11:38
To: Tomcat Usuarios
Subject: Tomcat  Windows



 Hi.

 When start Tomcat in Windows, startup.bat is launched with a MS-DOS window
but i'd like to run it as a process and without any visible window that
somebody can close and stop the server.

 Is ther any solution? Using bootstrap.jar (i test it and nothing)?

 Thanks.


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RequestDispatcher scenarios ( was RE: static url routing)

2002-12-09 Thread RXZ JLo

--- 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)?

Thank you
rf.



__
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




How to configure datasources in tomcat 4.1.12 to obtain OracleResultSets

2002-12-09 Thread Thomas Achleitner
Hi!
 
Since my application running under both OracleAS and Tomcat 4.1.12 should obtain 
connection pooling i tried to configure the application servers. Our application makes 
use of OracleResultSet. I configured OracleAS by editing the data-sources.xml file 
which works very well: 
data-source 
class=com.evermind.sql.DriverManagerDataSource 
name=OracleDS 
location=jdbc/OracleCoreDS 
xa-location=jdbc/xa/OracleXADS 
ejb-location=jdbc/OracleDS 
connection-driver=oracle.jdbc.driver.OracleDriver 
username=scott 
password=tiger 
url=jdbc:oracle:thin:@testdb:1525:ORA5 
inactivity-timeout=30 
/ 

The code for jndi lookup is here. It works fine when i cast ResultSet to 
OracleResultSet using OracleAS: 
initCtx = new InitialContext(); 
envCtx = (Context) initCtx.lookup(java:comp/env); 
dataSource = (DataSource) envCtx.lookup(jdbc/OracleDS); 
con = dataSource.getConnection(); 
ResultSet rs = con.executeQuery(..); 
OracleResultSet orars = (OracleResultSet)rs; 

Then i configured tomcat 4.1.12 server.xml file: 
Resource name=jdbc/OracleDS auth=Container type=javax.sql.DataSource/ 
ResourceParams name=jdbc/OracleDS 
parameternameusername/namevaluescott/value/parameter 
parameternamepassword/namevaluetiger/value/parameter 
parameternamedriverClassName/namevalueoracle.jdbc.driver.OracleDriver/value/parameter
 
parameternameurl/namevaluejdbc:oracle:thin:@testdb:1525:ORA5/value/parameter
 
/ResourceParams 

The same source for jndi lookup brings up a ClassCastException at line 
OracleResultSet orars = (OracleResultSet)rs; 

Therefore i tried to add a new parameter in tomcats server.xml: 
parameternamefactory/namevaluecom.evermind.sql.DriverManagerDataSource/value/parameter
 

Now following exceptions occurs: 
javax.naming.NamingException: Could not create resource factory instance, 
com.evermind.sql.DriverManagerDataSource 
java.lang.Object 
org.apache.naming.factory.ResourceFactory.getObjectInstance(java.lang.Object, 
javax.naming.Name, javax.naming.Context, java.util.Hashtable) 

I have oc4j.jar and classes12.jar in tomcats home directory under config/lib. 

How should i configure tomcat to be able to use connection pooling and 
OracleResultSets? 

Thanks in advance! 

thomas



URL contains encoded special chars when trying to enter Context Admin

2002-12-09 Thread Ronen Shenkar
Hello,
I'm using tomcat 3.2 and I'm trying to use the admin tool.
I'm getting the following exception after choosing Context Admin
Any ideas?
Thanks, ronen

Error: 500
Location: /admin/contextAdmin/contextAdmin.jsp
Internal Servlet Error:
javax.servlet.ServletException: URL contains encoded special chars.
at
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp
l.java:459)
at
contextAdmin._0002fcontextAdmin_0002fcontextAdmin_0002ejspcontextAdmin_jsp_0
._jspService(_0002fcontextAdmin_0002fcontextAdmin_0002ejspcontextAdmin_jsp_0
.java:197)
at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja
va:130)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja
va:282)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81
2)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectionHandler.java:213)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Unknown Source)
Root cause: 
java.lang.IllegalArgumentException: URL contains encoded special chars.
at
org.apache.tomcat.util.RequestUtil.URLDecode(RequestUtil.java:317)
at ContextAdmin.getContextInfo(ContextAdmin.java:76)
at
contextAdmin._0002fcontextAdmin_0002fcontextAdmin_0002ejspcontextAdmin_jsp_0
._jspService(_0002fcontextAdmin_0002fcontextAdmin_0002ejspcontextAdmin_jsp_0
.java:135)
at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja
va:130)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja
va:282)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:130)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81
2)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectionHandler.java:213)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Unknown Source)


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




How to get a File for a certain folder

2002-12-09 Thread Patrick Kosiol
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?

thx
Patrick


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



How to get a File for a certain folder

2002-12-09 Thread Patrick Kosiol


Patrick Kosiol wrote:


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?

thx
Patrick


--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]

I have forgot to say that I want to do this trought out of a Servlet 
that is placed under $CATALINA_HOME/webapps/ROOT/WEB-INF/classes/myapp



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



File structure in webapps for tomcat.

2002-12-09 Thread Simon Kelly
Hi,

I am trying to get my servlet to write to and read from files within my
webapp structure.  However, when the servlet runs it seems that the working
directory during its lifecycle is c:\xxx\tomcat 4.1.  Is there any way, in
web.xml, to force the servlet to run in it's own app directory structure?

Regards

Simon


Institut fuer
Prozessdatenverarbeitung
und Elektronik,
Forschungszentrum Karlsruhe GmbH,
Postfach 3640,
D-76021 Karlsruhe,
Germany.

Tel: (+49)/7247 82-4042
E-mail : [EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: File structure in webapps for tomcat.

2002-12-09 Thread Laxmikanth M.S.
use class URI in java.net.* package.
no need to set in server.xml

Regards
Laxmikanth M S 
Off*  : 91-80-6610330 extn 1256
Res* : 91-80-5267150
http://www.sonata-software.com

 Coming together is the beginning, staying together is progress and working
 together is Success
What lies behind us and what lies before us are tiny matters compared to
what lies within us  - Emerson


 -Original Message-
 From: Simon Kelly [SMTP:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 5:23 PM
 To:   Tomcat Users List
 Subject:  File structure in webapps for tomcat.
 
 Hi,
 
 I am trying to get my servlet to write to and read from files within my
 webapp structure.  However, when the servlet runs it seems that the
 working
 directory during its lifecycle is c:\xxx\tomcat 4.1.  Is there any way, in
 web.xml, to force the servlet to run in it's own app directory structure?
 
 Regards
 
 Simon
 
 
 Institut fuer
 Prozessdatenverarbeitung
 und Elektronik,
 Forschungszentrum Karlsruhe GmbH,
 Postfach 3640,
 D-76021 Karlsruhe,
 Germany.
 
 Tel: (+49)/7247 82-4042
 E-mail : [EMAIL PROTECTED]
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
*
Disclaimer: The information in this e-mail and any attachments is
confidential / privileged. It is intended solely for the addressee or
addressees. If you are not the addressee indicated in this message, you may
not copy or deliver this message to anyone. In such case, you should destroy
this message and kindly notify the sender by reply email. Please advise
immediately if you or your employer does not consent to Internet email for
messages of this kind.
*

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: How to configure datasources in tomcat 4.1.12 to obtain OracleResultSets

2002-12-09 Thread Roberts, Eric
Try

parameternamefactory/namevalueorg.apache.commons.dbcp.BasicDataSourceFactory/value/parameter

Hope this helps.

-Original Message-
From: Thomas Achleitner [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 12:28
To: [EMAIL PROTECTED]
Subject: How to configure datasources in tomcat 4.1.12 to obtain
OracleResultSets 


Hi!
 
Since my application running under both OracleAS and Tomcat 4.1.12 should obtain 
connection pooling i tried to configure the application servers. Our application makes 
use of OracleResultSet. I configured OracleAS by editing the data-sources.xml file 
which works very well: 
data-source 
class=com.evermind.sql.DriverManagerDataSource 
name=OracleDS 
location=jdbc/OracleCoreDS 
xa-location=jdbc/xa/OracleXADS 
ejb-location=jdbc/OracleDS 
connection-driver=oracle.jdbc.driver.OracleDriver 
username=scott 
password=tiger 
url=jdbc:oracle:thin:@testdb:1525:ORA5 
inactivity-timeout=30 
/ 

The code for jndi lookup is here. It works fine when i cast ResultSet to 
OracleResultSet using OracleAS: 
initCtx = new InitialContext(); 
envCtx = (Context) initCtx.lookup(java:comp/env); 
dataSource = (DataSource) envCtx.lookup(jdbc/OracleDS); 
con = dataSource.getConnection(); 
ResultSet rs = con.executeQuery(..); 
OracleResultSet orars = (OracleResultSet)rs; 

Then i configured tomcat 4.1.12 server.xml file: 
Resource name=jdbc/OracleDS auth=Container type=javax.sql.DataSource/ 
ResourceParams name=jdbc/OracleDS 
parameternameusername/namevaluescott/value/parameter 
parameternamepassword/namevaluetiger/value/parameter 
parameternamedriverClassName/namevalueoracle.jdbc.driver.OracleDriver/value/parameter
 
parameternameurl/namevaluejdbc:oracle:thin:@testdb:1525:ORA5/value/parameter
 
/ResourceParams 

The same source for jndi lookup brings up a ClassCastException at line 
OracleResultSet orars = (OracleResultSet)rs; 

Therefore i tried to add a new parameter in tomcats server.xml: 
parameternamefactory/namevaluecom.evermind.sql.DriverManagerDataSource/value/parameter
 

Now following exceptions occurs: 
javax.naming.NamingException: Could not create resource factory instance, 
com.evermind.sql.DriverManagerDataSource 
java.lang.Object 
org.apache.naming.factory.ResourceFactory.getObjectInstance(java.lang.Object, 
javax.naming.Name, javax.naming.Context, java.util.Hashtable) 

I have oc4j.jar and classes12.jar in tomcats home directory under config/lib. 

How should i configure tomcat to be able to use connection pooling and 
OracleResultSets? 

Thanks in advance! 

thomas

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: make the app as ROOT.war

2002-12-09 Thread David Brown
Billy Ng writes: 

If my app needs to overwrite the ROOT.war, will it only kill the tomcat's examples?  if not, what are the problems will I get?  I notice the tomcat 4 exe installer installs the admin stuff, will it be a problem if I overwrite the ROOT? 

Thanks! 

Billy Ng

Hello Billy, u don't want to do this. the ROOT application context is 
actually a docBase defined in server.xml. and, this is the /examples 
webapp that lets u see the tc documentation and other usefull stuff online 
w/o directory references. in the long run u r much better off creating u own 
webapp .war and exanding it in ur own webapps directory. see the /examples 
build: ant and build.xml. i u r not already familiar w/ the java and tc way 
of building projects u really need to look in to using ant. hope this helps, 
david. 


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



oracle+tomcat 4.1.x+dbcp = driverClassName is required!

2002-12-09 Thread Pedro Salazar
Greetings,

I'm getting this exception when I try to lookup and cast a DataSource:

[catalina.out]
javax.naming.NamingException: DbcpDataSourceFactory: driverClassName is
required
org.apache.naming.factory.DbcpDataSourceFactory.getObjectInstance(DbcpDataSourceFactory.java:199)
org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:177)
javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:301)
 org.apache.naming.NamingContext.lookup(NamingContext.java:835)
...

[server.xml]
I'm using a resource inside globalNamingResources and linked with
resourceLink in context (but I already tried a explicit resource
inside context).

[web.xml]
I'm using a resource-ref.

System: 
-tomcat 4.1.2 (JavaWebServicesDeveloperPack 1.0.1)
-dbcp 1.0
-jdbc oracle driver (renamed to jar and without javax.sql package) in
common/lib directory.

But I know that the driver is being loaded because before call my web
application, I saw this info message in catalina.out:

DbcpDataSourceFactory:  driverClassName=oracle.jdbc.driver.OracleDriver,
url=jdbc:oracle:thin:@192.168.89.52:1521:dbtest, user=test_01


I don't know why but it works fine in tomcat 4.0.6 I got it in other
machine. So, what is the problem here?

If need I can supply the exactly configurations (resource, resource-ref,
...).

thanks,
Pedro Salazar.

-- 
pedro salazar (pt-inovacao) [EMAIL PROTECTED]
key id: D803BC61


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: File structure in webapps for tomcat.

2002-12-09 Thread David Brown
Simon Kelly writes: 

Hi, 

I am trying to get my servlet to write to and read from files within my
webapp structure.  However, when the servlet runs it seems that the working
directory during its lifecycle is c:\xxx\tomcat 4.1.  Is there any way, in
web.xml, to force the servlet to run in it's own app directory structure? 

Regards 

Simon 


Institut fuer
Prozessdatenverarbeitung
und Elektronik,
Forschungszentrum Karlsruhe GmbH,
Postfach 3640,
D-76021 Karlsruhe,
Germany. 

Tel: (+49)/7247 82-4042
E-mail : [EMAIL PROTECTED] 


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED] 



Hello Simon, servlets do run in their own webapp directory structure if 
defined in their own web.xml and deploy w/ and expanded .war file. u have 
not given enough info on what u have done in terms of deployment and what u 
r planning to do as a project goal. thanx, david. 


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



RE: oracle+tomcat 4.1.x+dbcp = driverClassName is required!

2002-12-09 Thread Roberts, Eric
Pedro,

You need javax.sql - that is the package containing DataSource.
Your Resource type should be: type=javax.sql.DataSource
You need these parameters in addition to url, username and password:
  parameter
namedriverClassName/name
valueoracle.jdbc.driver.OracleDriver/value
  /parameter
  parameter
namefactory/name
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

In the Context the ResourceLink type should be: type=javax.sql.DataSource

You do not need any resource-ref in your web.xml - just use your ResourceLink name as 
follows:
Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/{name_of_resource_link});

if (ds != null) {
DbCon = ds.getConnection();
}

Hope this helps.

-Original Message-
From: Pedro Salazar [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 13:49
To: Tomcat Users List
Subject: oracle+tomcat 4.1.x+dbcp = driverClassName is required!


Greetings,

I'm getting this exception when I try to lookup and cast a DataSource:

[catalina.out]
javax.naming.NamingException: DbcpDataSourceFactory: driverClassName is
required
org.apache.naming.factory.DbcpDataSourceFactory.getObjectInstance(DbcpDataSourceFactory.java:199)
org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:177)
javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:301)
 org.apache.naming.NamingContext.lookup(NamingContext.java:835)
...

[server.xml]
I'm using a resource inside globalNamingResources and linked with
resourceLink in context (but I already tried a explicit resource
inside context).

[web.xml]
I'm using a resource-ref.

System: 
-tomcat 4.1.2 (JavaWebServicesDeveloperPack 1.0.1)
-dbcp 1.0
-jdbc oracle driver (renamed to jar and without javax.sql package) in
common/lib directory.

But I know that the driver is being loaded because before call my web
application, I saw this info message in catalina.out:

DbcpDataSourceFactory:  driverClassName=oracle.jdbc.driver.OracleDriver,
url=jdbc:oracle:thin:@192.168.89.52:1521:dbtest, user=test_01


I don't know why but it works fine in tomcat 4.0.6 I got it in other
machine. So, what is the problem here?

If need I can supply the exactly configurations (resource, resource-ref,
...).

thanks,
Pedro Salazar.

-- 
pedro salazar (pt-inovacao) [EMAIL PROTECTED]
key id: D803BC61


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




virtualhost-based root context?

2002-12-09 Thread Thomas Sandor
hi all,

does anyone got an idea, how to set up the ROOT context for each of my
virtualhost? like in apache DocumentRoot, so when invoking the URL, each /
goes to a specified HTML directory. But in case of a dynamic app server I
have only /xyz/ contexts, but when invoking a domain e.g.: somewhat.com and
I redirect it to somewhat.com/somewhat looks awfull.

so I don't know if any app server supports a virtualhost based context
distribution, so I can tell which context to use for /?

any help is warmly welcomed.

cheers,
Thomas


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: File structure in webapps for tomcat.

2002-12-09 Thread Simon Kelly
Ah,

Ok.  What I have is a standard war file structure deployed in the
c:\programme\apache group\tomcat 4.1\webapps directory, with the servlet
held in WEB-INF/Classes and the web.xml set up as follows.

web-app
servlet
servlet-name
main
/servlet-name
servlet-class
FrontServlet
/servlet-class
/servlet
servlet-mapping
servlet-name
main
/servlet-name
url-pattern
/katrinmain
/url-pattern
/servlet-mapping

The war file is structure like this:

*.html (All my standard pages)
images/ (For all images I will be using)
queryfiles/  (These files are for searching a xml db and are the ones I am
trying to reference)
WEB-INF/  (Usual layout in here, with my servlets, libs, and extra classes)

Within the servlet I am running I need to open tempfiles, and open and read
the files within queryfiles/, it is this that I am having the problem with.
During the running of the servlet, I have done

File currentdir = File(.)

To get the current working directory (And as far as I know the directory the
servlet is running in) and then printted it to the screen.  It is showing
that the current directory is c:\programme\apache group\tomcat 4.1\.  Now,
if the servlet is running in its own directory I should see
c:\programme\apache group\tomcat 4.1\webapps\katrin\.  but I don't.  This is
where my problem comes as I need to access the files in c:\programme\apache
group\tomcat 4.1\webapps\katrin\queryfiles\  If the servlet current working
directory is tomcat, then I will need to tag the rest of the path onto the
end of the current working directory everytime.  This will not make the
portable web app that I need.

Cheers

Simon



- Original Message -
From: David Brown [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 12:45 PM
Subject: Re: File structure in webapps for tomcat.


 Simon Kelly writes:

  Hi,
 
  I am trying to get my servlet to write to and read from files within my
  webapp structure.  However, when the servlet runs it seems that the
working
  directory during its lifecycle is c:\xxx\tomcat 4.1.  Is there any way,
in
  web.xml, to force the servlet to run in it's own app directory
structure?
 
  Regards
 
  Simon
 
 
  Institut fuer
  Prozessdatenverarbeitung
  und Elektronik,
  Forschungszentrum Karlsruhe GmbH,
  Postfach 3640,
  D-76021 Karlsruhe,
  Germany.
 
  Tel: (+49)/7247 82-4042
  E-mail : [EMAIL PROTECTED]
 
 
  --
  To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
mailto:[EMAIL PROTECTED]
 


 Hello Simon, servlets do run in their own webapp directory structure if
 defined in their own web.xml and deploy w/ and expanded .war file. u have
 not given enough info on what u have done in terms of deployment and what
u
 r planning to do as a project goal. thanx, david.


 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




ClassLoader issue

2002-12-09 Thread Ola Berg
Could anyone describe how to load classes within a servlet using a URLClassLoader in 
Tomcat, or reference to a link somewhere?

/O


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Connection Pooling Help

2002-12-09 Thread Kevin Passey
Hi,

Can somebody point out my mistake for me - I'm starting to bang my head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name

 
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with DBCP/h2);

 Context ctx = new InitialContext();
 if (ctx == null)
out.println(Something is wrong with Tomcat);

 DataSource ds = (DataSource)
ctx.lookup(java:comp/env/jdbc/shiltonDB);

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

if (conn != null) {
   out.println(bGot Connection:/b  + conn.toString() +
p);
   Statement stmt = conn.createStatement();
   String sql = select * from BSSTYL;
   ResultSet rst = stmt.executeQuery(sql);
   if (rst.next()) {
  out.println(bValue of HDCUST on first record:/b +
rst.getString(dbfield1)+ p);
   }
   out.println(This was our little database-access
servlet...);
   conn.close();
}
 }
  } catch (Exception e) {
 e.printStackTrace();
  }
   }

   /**
* if somebody does a http-post, we do an interal dispatch to doGet()
*/
   public void doPost(HttpServletRequest req,
  HttpServletResponse res) {
  doGet(req, res);
   }
}

ds is alway null - what am I missing.

Thanks in advance.



Kevin 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Mod_jk is not compatible this version of apache

2002-12-09 Thread Turner, John

Where is there to look?  Upgrade your Apache.  There are several security
fixes between .40 and .43, and mod_jk is version sensitive.  

John


 -Original Message-
 From: John B. Moore [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, December 07, 2002 5:47 PM
 To: [EMAIL PROTECTED]
 Subject: Mod_jk is not compatible this version of apache
 
 
 Versions
 Apache  httpd-2.0.40
 Tomcat 4.1.12
 
  OS
  Readhat 8 with latest kernal
 
   I had compile Apache and it runs just fine, Tomcat also runs find 
 independently
 
I then downloaded  the connectors for 4.1.12 and followed 
 the John 
 Turner directions for compiling the mod_jk... and copied to the 
 ../modules directory and updated the server.xml with the
 auto config.. check that the /auto/mod_jk.conf was being written and 
 that it contained the correct path to the mod_jk.so module 
 and matches 
 the include in the httpd.conf file.
 
Sadly I'm getting the error message
 
 httpd: module mod_jk.so is not compatible with this version of 
 apache..
 
 Anyone with some suggestions on where I need to look next... I'm 
 stumped..
 
  John..
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: URGENT HELP NEEDED!

2002-12-09 Thread Turner, John

This URL worked fine:
http://www.xicom.biz/test3.jsp

This URL didn't work at all:
http://www.xicom.biz:9084/test3.jsp

John

 -Original Message-
 From: Alex K. [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 08, 2002 1:48 AM
 To: Tomcat Users List
 Subject: URGENT HELP NEEDED!
 
 
 Hello,
  
  How is everyone?
  
  I have a really really weird problem with mod_jk
  
  
  For some reason it forwards servlets file to tomcat, but jsp files it
 does not forward to tomcat at all.
  
  Here is a line out of mod_jk.log 
  
  When a .jsp file is sent to it:
  
 jk_uri_worker_map_t::map_uri_to_worker, Found a suffix match ajp13 -
 *.jsp
  
 And here is what happens when a servlet request is processed
  
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (464)]: Attempting to
 map URI '/servlet/HelloWorldExample'
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (489)]:
 jk_uri_worker_map_t::map_uri_to_worker, Found a context match ajp13 -
 /servlet/
 [Sun Dec 08 01:56:54 2002]  [jk_worker.c (132)]: Into
 wc_get_worker_for_name ajp13
 [Sun Dec 08 01:56:54 2002]  [jk_worker.c (136)]: 
 wc_get_worker_for_name,
 done  found a worker
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1352)]: Into
 jk_worker_t::get_endpoint
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1075)]: Into
 jk_endpoint_t::service
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (280)]: Into
 ajp_marshal_into_msgb
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (413)]:
 ajp_marshal_into_msgb - Done
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (116)]: Into jk_open_socket
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (123)]: 
 jk_open_socket, try to
 connect socket = 6
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (132)]: 
 jk_open_socket, after
 connect ret = 0
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (140)]: jk_open_socket, set
 TCP_NODELAY to on
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (148)]: jk_open_socket,
 return, sd = 6
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (588)]: In
 jk_endpoint_t::ajp_connect_to_endpoint, connected sd = 6
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (612)]: sending to ajp13
 #403
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (853)]: 
 ajp_send_request 2:
 request body to send 0 - request body to resend 0
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #24
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (461)]:
 ajp_unmarshal_response: status = 200
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (466)]:
 ajp_unmarshal_response: Number of headers is = 1
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (506)]:
 ajp_unmarshal_response: Header[0] [Content-Type] = [text/html]
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #397
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #2
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1307)]: Into
 jk_endpoint_t::done
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (447)]: Into
 jk_uri_worker_map_t::map_uri_to_worker
  
  
 my mod_jk.conf
 IfModule !mod_jk.c
   LoadModule jk_module libexec/mod_jk.so
 /IfModule
  
 JkWorkersFile
 /usr/local/jakarta/jakarta-tomcat-4.0.3-src/build/conf/jk/wor
 kers.prope
 rties
 JkLogFile
 /usr/local/jakarta/jakarta-tomcat-4.0.3-src/build/logs/mod_jk.log
  
  
  
 my workers.properties is
  
 #workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat-4.0
 workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat-4.0.3-src/build
 workers.java_home=/usr/local/jre
 ps=/
 worker.list=ajp13
  
 # Definition for Ajp13 worker
 #
 worker.ajp13.port=8009
 worker.ajp13.host=localhost
 worker.ajp13.type=ajp13
  
  
  
 my entry in httpd.conf file is
 IfModule mod_jk.c
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 JkMount /servlets/* ajp13
 /IfModule
  
 from tomcat's log
  
 2002-12-08 02:45:14 Ajp13Processor[8009][0] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][1] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][2] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][3] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][4] Starting background thread
  
 from tomcat's server.xml 
  
 !-- Define an AJP 1.3 Connector on port 8009 --
 Connector className=org.apache.ajp.tomcat4.Ajp13Connector
port=8009 minProcessors=5 maxProcessors=75
acceptCount=10 debug=0/
  
 Apache and Tomcat work fine standalone and tomcat is serving pages on
 its own.
  
 To see this behavior please go to:
  
 http://www.xicom.biz:9084/test3.jsp
  
 then to http://www.xicom.biz/test3.jsp
  
 then to http://www.xicom.biz/servlet/HelloWorldExample 
  
 what is going on??!?!?!?
  
 Please help, our client are currently down because of this. 
  
 Really interesting thing is that this setup has been up and 
 running for
 some months now.
  
 Please let me know what is happening!
  
 Best Regards,
  
 Alex Korneyev
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 

RE: Connection Pooling Help

2002-12-09 Thread Roberts, Eric
Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name

 
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with DBCP/h2);

 Context ctx = new InitialContext();
 if (ctx == null)
out.println(Something is wrong with Tomcat);

 DataSource ds = (DataSource)
ctx.lookup(java:comp/env/jdbc/shiltonDB);

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

if (conn != null) {
   out.println(bGot Connection:/b  + conn.toString() +
p);
   Statement stmt = conn.createStatement();
   String sql = select * from BSSTYL;
   ResultSet rst = stmt.executeQuery(sql);
   if (rst.next()) {
  out.println(bValue of HDCUST on first record:/b +
rst.getString(dbfield1)+ p);
   }
   out.println(This was our little database-access
servlet...);
   conn.close();
}
 }
  } catch (Exception e) {
 e.printStackTrace();
  }
   }

   /**
* if somebody does a http-post, we do an interal dispatch to doGet()
*/
   public void doPost(HttpServletRequest req,
  HttpServletResponse res) {
  doGet(req, res);
   }
}

ds is alway null - what am I missing.

Thanks in advance.



Kevin 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: URGENT HELP NEEDED PLEASE ADVISE

2002-12-09 Thread Turner, John

This URL works fine:
 http://www.xicom.biz/test3.jsp

This URL does not:
http://www.xicom.biz:9084/test3.jsp

PS: you might want to rethink how you post messages...subject lines with
URGENT in them probably get ignored more often then they get answered, and
the subject of your posts should summarize your problem.  Something like
Servlets work fine, JSPs do not in 4.1.12 or something similar will
probably get you help a lot quicker than URGENT HELP NEEDED NOW or
whatever.

John


 -Original Message-
 From: Alex K. [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 08, 2002 12:22 PM
 To: Tomcat Users List
 Subject: URGENT HELP NEEDED PLEASE ADVISE
 
 
 Hello,
  
  How is everyone?
  
  I have a really really weird problem with mod_jk
  
  
  For some reason it forwards servlets file to tomcat, but jsp files it
 does not forward to tomcat at all.
  
  Here is a line out of mod_jk.log 
  
  When a .jsp file is sent to it:
  
 jk_uri_worker_map_t::map_uri_to_worker, Found a suffix match ajp13 -
 *.jsp
  
 And here is what happens when a servlet request is processed
  
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (464)]: Attempting to
 map URI '/servlet/HelloWorldExample'
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (489)]:
 jk_uri_worker_map_t::map_uri_to_worker, Found a context match ajp13 -
 /servlet/
 [Sun Dec 08 01:56:54 2002]  [jk_worker.c (132)]: Into
 wc_get_worker_for_name ajp13
 [Sun Dec 08 01:56:54 2002]  [jk_worker.c (136)]: 
 wc_get_worker_for_name,
 done  found a worker
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1352)]: Into
 jk_worker_t::get_endpoint
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1075)]: Into
 jk_endpoint_t::service
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (280)]: Into
 ajp_marshal_into_msgb
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (413)]:
 ajp_marshal_into_msgb - Done
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (116)]: Into jk_open_socket
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (123)]: 
 jk_open_socket, try to
 connect socket = 6
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (132)]: 
 jk_open_socket, after
 connect ret = 0
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (140)]: jk_open_socket, set
 TCP_NODELAY to on
 [Sun Dec 08 01:56:54 2002]  [jk_connect.c (148)]: jk_open_socket,
 return, sd = 6
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (588)]: In
 jk_endpoint_t::ajp_connect_to_endpoint, connected sd = 6
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (612)]: sending to ajp13
 #403
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (853)]: 
 ajp_send_request 2:
 request body to send 0 - request body to resend 0
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #24
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (461)]:
 ajp_unmarshal_response: status = 200
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (466)]:
 ajp_unmarshal_response: Number of headers is = 1
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (506)]:
 ajp_unmarshal_response: Header[0] [Content-Type] = [text/html]
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #397
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (698)]: received 
 from ajp13
 #2
 [Sun Dec 08 01:56:54 2002]  [jk_ajp_common.c (1307)]: Into
 jk_endpoint_t::done
 [Sun Dec 08 01:56:54 2002]  [jk_uri_worker_map.c (447)]: Into
 jk_uri_worker_map_t::map_uri_to_worker
  
  
 my mod_jk.conf
 IfModule !mod_jk.c
   LoadModule jk_module libexec/mod_jk.so
 /IfModule
  
 JkWorkersFile
 /usr/local/jakarta/jakarta-tomcat-4.0.3-src/build/conf/jk/wor
 kers.prope
 rties
 JkLogFile
 /usr/local/jakarta/jakarta-tomcat-4.0.3-src/build/logs/mod_jk.log
  
  
  
 my workers.properties is
  
 #workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat-4.0
 workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat-4.0.3-src/build
 workers.java_home=/usr/local/jre
 ps=/
 worker.list=ajp13
  
 # Definition for Ajp13 worker
 #
 worker.ajp13.port=8009
 worker.ajp13.host=localhost
 worker.ajp13.type=ajp13
  
  
  
 my entry in httpd.conf file is
 IfModule mod_jk.c
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 JkMount /servlets/* ajp13
 /IfModule
  
 from tomcat's log
  
 2002-12-08 02:45:14 Ajp13Processor[8009][0] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][1] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][2] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][3] Starting background thread
 2002-12-08 02:45:14 Ajp13Processor[8009][4] Starting background thread
  
 from tomcat's server.xml 
  
 !-- Define an AJP 1.3 Connector on port 8009 --
 Connector className=org.apache.ajp.tomcat4.Ajp13Connector
port=8009 minProcessors=5 maxProcessors=75
acceptCount=10 debug=0/
  
 Apache and Tomcat work fine standalone and tomcat is serving pages on
 its own.
  
 To see this behavior please go to:
  
 http://www.xicom.biz:9084/test3.jsp
  
 then to http://www.xicom.biz/test3.jsp
  
 then to 

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

2002-12-09 Thread capa
In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i found help. 
I hope that the people that participates of this list, don´t have damages about 
other people that don´t belong´s at your countries.
Thank´s for NOTHING.


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Kevin Passey
Eric,

It's the same - DS == null. :-(

Thanks anyway.

Kevin

-Original Message-
From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:33
To: Tomcat Users List
Subject: RE: Connection Pooling Help


Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name

 
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with DBCP/h2);

 Context ctx = new InitialContext();
 if (ctx == null)
out.println(Something is wrong with Tomcat);

 DataSource ds = (DataSource)
ctx.lookup(java:comp/env/jdbc/shiltonDB);

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

if (conn != null) {
   out.println(bGot Connection:/b  + conn.toString() +
p);
   Statement stmt = conn.createStatement();
   String sql = select * from BSSTYL;
   ResultSet rst = stmt.executeQuery(sql);
   if (rst.next()) {
  out.println(bValue of HDCUST on first record:/b +
rst.getString(dbfield1)+ p);
   }
   out.println(This was our little database-access
servlet...);
   conn.close();
}
 }
  } catch (Exception e) {
 e.printStackTrace();
  }
   }

   /**
* if somebody does a http-post, we do an interal dispatch to doGet()
*/
   public void doPost(HttpServletRequest req,
  HttpServletResponse res) {
  doGet(req, res);
   }
}

ds is alway null - what am I missing.

Thanks in advance.



Kevin 

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]

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

2002-12-09 Thread Cox, Charlie
RequestDispatcher works the same in a servlet or a filter. You can use
forward() in a filter and not call doFilter() just like you call forward()
in your servlet followed by a return; 

The diffference is that your request will get mapped to one servlet, but it
can also be mapped to multiple filters, each of which could serve their own
purpose. In my case this allows me to use the same servlet for different
virtual hosts and have the host-specific code in a filter.

If you need to put logic around static files, you can use a filter to
contain the logic and then let the tomcat serve the file. 

Charlie

 -Original Message-
 From: RXZ JLo [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 6:21 AM
 To: Tomcat Users List
 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)?
 
 Thank you
 rf.
 
 
 
 __
 Do you Yahoo!?
 Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
 http://mailplus.yahoo.com
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: ClassLoader issue

2002-12-09 Thread Cox, Charlie
have you looked at tomcat's classloader document?

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html

Charlie

 -Original Message-
 From: Ola Berg [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 8:15 AM
 To: Tomcat Users List
 Subject: ClassLoader issue
 
 
 Could anyone describe how to load classes within a servlet 
 using a URLClassLoader in Tomcat, or reference to a link somewhere?
 
 /O
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: ClassLoader issue

2002-12-09 Thread Ola Berg

 have you looked at tomcat's classloader document?
 
 http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html
 
 Charlie

Yes, and it basically talks about the class loaders that Tomcat uses. But I want to be 
able to load classes from an jar file at an arbitrary URL specified at runtime, 
without having to put it in any of the predefined directories.

I suspect though that the issue might be parentship of my newly instantiated 
URLClassLoader. But I don't know.

All I know is that 

static Class getClass( String className, URL[] urls) throws 
ClassLoader cl = new URLClassLoader( urls);

etc

works outside of Tomcat but not within.

Basically, the thing hangs (no SecurityException or anything). It leads me to think 
that the problem lies in the reversed order that servlet containers use when resolving 
classes, but I don't know what to do in order to fix it.

/O




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Donie Kelly
You're defiantly blacklisted now :)



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:40
To: [EMAIL PROTECTED]
Subject: I don´t understand the objective of this open list !

In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i found
help.
I hope that the people that participates of this list, don´t have damages
about
other people that don´t belong´s at your countries.
Thank´s for NOTHING.


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Hari Venkatesan

Try changing the following parameter value in server.xml file 

valuejdbc:as400://10.0.0.1/value

valuejdbc:as400://{name of your machine} /value instead of the ip
address of the as400

Hari

-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]] 
Sent: Monday, December 09, 2002 8:40 AM
To: 'Tomcat Users List'
Subject: RE: Connection Pooling Help

Eric,

It's the same - DS == null. :-(

Thanks anyway.

Kevin

-Original Message-
From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:33
To: Tomcat Users List
Subject: RE: Connection Pooling Help


Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my
head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the
JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name

 
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with
DBCP/h2);

 Context ctx = new InitialContext();
 if (ctx == null)
out.println(Something is wrong with Tomcat);

 DataSource ds = (DataSource)
ctx.lookup(java:comp/env/jdbc/shiltonDB);

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

if (conn != null) {
   out.println(bGot Connection:/b  + conn.toString() +
p);
   Statement stmt = conn.createStatement();
   String sql = select * from BSSTYL;
   ResultSet rst = stmt.executeQuery(sql);
   if (rst.next()) {
  out.println(bValue of HDCUST on first record:/b
+
rst.getString(dbfield1)+ p);
   }
   out.println(This was our little database-access
servlet...);
   conn.close();
}
 }
  } catch (Exception e) {
 e.printStackTrace();
  }
   }

   /**
* if somebody does a http-post, we do an interal dispatch to doGet()
*/
   public void doPost(HttpServletRequest req,
  HttpServletResponse res) {
  

RE: apache tomcat integration

2002-12-09 Thread Turner, John

mode_jk.conf is incorrect.  If you are using the auto-generation feature
of Tomcat for generating Apache configuration, the file name would be called
mod_jk.conf without the e.

John


 -Original Message-
 From: Manish Sharma [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 08, 2002 12:38 AM
 To: [EMAIL PROTECTED]
 Subject: apache tomcat integration
 
 
   Dear Sir/Mam..
 
 please help me on this issue. i'm facing problem in apache tomcat 
 integration on linux server.
   there's error after restart the apache. theres message started 
 ok.
   but in error.log two errors.
   Syntax error on line 2 of
   /home/suvigya/Desktop/manish/jakarta-tomcat-4.1.12-LE-jdk14/co
   nf/jk/mode_jk.conf:
   Invalid command 'LoadModule', perhaps mis-spelled or defined by 
 a
   module not included in the server configuration
 
   i have made all required changes in httpd.conf,mode_jk.conf 
   workers.properties. i have copied mod_jk.so in apache's lib.
   so please help me on this issue as soon as possible.
   i'll be very thankful to you.
 
   Manish Sharma reply me [EMAIL PROTECTED]
   Java Programmer
   VGL Softech Ltd.
   Jaipur (India).
 
 
 
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Laxmikanth M.S.
This is not the list for fighting..
if u have personal grievance please send it to intended person not to the
list
please avoid flooding mails like this hereafter.even I am sorry for
sending to all but no othergo

Regards
Laxmikanth M S 
Off*  : 91-80-6610330 extn 1256
Res* : 91-80-5267150
http://www.sonata-software.com

 Coming together is the beginning, staying together is progress and working
 together is Success
What lies behind us and what lies before us are tiny matters compared to
what lies within us  - Emerson


 -Original Message-
 From: Donie Kelly [SMTP:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 7:16 PM
 To:   'Tomcat Users List'
 Subject:  RE: I don´t understand the objective of this open list !
 
 You're defiantly blacklisted now :)
 
 
 
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 13:40
 To: [EMAIL PROTECTED]
 Subject: I don´t understand the objective of this open list !
 
 In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i found
 help.
 I hope that the people that participates of this list, don´t have damages
 about
 other people that don´t belong´s at your countries.
 Thank´s for NOTHING.
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
*
Disclaimer: The information in this e-mail and any attachments is
confidential / privileged. It is intended solely for the addressee or
addressees. If you are not the addressee indicated in this message, you may
not copy or deliver this message to anyone. In such case, you should destroy
this message and kindly notify the sender by reply email. Please advise
immediately if you or your employer does not consent to Internet email for
messages of this kind.
*

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Custom Error 500 Page Is Not Displayed

2002-12-09 Thread ian.pilborough
Hi,

I have an installation of Tomcat 4.0.6 running on Win 2k Advanced Server, JDK 1.3.1_01 
using IIS 5.0 as web server. I have set-up custom error pages in web.xml for both 404 
and 500 to display helpful messages relevant to the application I've built. Any 404s 
are nicely displayed using the 404 error page defined in web.xml, but any 500s are not 
and I get the Tomcat default Internal Server error displayed, which isn't nice for my 
users.

I can't understand why the 404 works and 500 doesn't. Should the type of error that is 
coming back, e.g. an undefined variable or NullPointerException affect the error page 
I've chosen being displayed? If it's a NullPointerException that's a runtime error, 
but an undefined variable is a compile time error does this affect the redirection to 
the error page I've added?

I hope I'm not missing something basic because all examples, FAQs and other sites I've 
visited show that I'm doing the right thing and the fact that the 404 works further 
proves that. Any help is greatly appreciated.

Ian

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: File structure in webapps for tomcat.

2002-12-09 Thread Simon Kelly
I've just been looking at the URL package, but I can't see how that is going
to get around the directory problem?  I need the host to be transparent to
the servlet and the files to be always found from the web app location.  If
I start putting urls in, I will start to tie myself to specific locations.

Is there a way of getting the current URL path from the server without
writing it in explisitly.

Cheers

Simon

PS
Excuse the spelling, I've been at the for days now and I'm getting a little
tierd. ;-)

- Original Message -
From: Laxmikanth M.S. [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 12:55 PM
Subject: RE: File structure in webapps for tomcat.


 use class URI in java.net.* package.
 no need to set in server.xml

 Regards
 Laxmikanth M S
 Off*  : 91-80-6610330 extn 1256
 Res* : 91-80-5267150
 http://www.sonata-software.com

  Coming together is the beginning, staying together is progress and
working
  together is Success
 What lies behind us and what lies before us are tiny matters compared to
 what lies within us  - Emerson


  -Original Message-
  From: Simon Kelly [SMTP:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 5:23 PM
  To: Tomcat Users List
  Subject: File structure in webapps for tomcat.
 
  Hi,
 
  I am trying to get my servlet to write to and read from files within my
  webapp structure.  However, when the servlet runs it seems that the
  working
  directory during its lifecycle is c:\xxx\tomcat 4.1.  Is there any way,
in
  web.xml, to force the servlet to run in it's own app directory
structure?
 
  Regards
 
  Simon
 
 
  Institut fuer
  Prozessdatenverarbeitung
  und Elektronik,
  Forschungszentrum Karlsruhe GmbH,
  Postfach 3640,
  D-76021 Karlsruhe,
  Germany.
 
  Tel: (+49)/7247 82-4042
  E-mail : [EMAIL PROTECTED]
 
 
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 *
 Disclaimer: The information in this e-mail and any attachments is
 confidential / privileged. It is intended solely for the addressee or
 addressees. If you are not the addressee indicated in this message, you
may
 not copy or deliver this message to anyone. In such case, you should
destroy
 this message and kindly notify the sender by reply email. Please advise
 immediately if you or your employer does not consent to Internet email for
 messages of this kind.
 *

 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Problem with http OPTIONS using mod_jk for IIS

2002-12-09 Thread Joakim Ström
Thanks for the info Tim,
I have managed to solve the problems I had in JK2, which
sometimes corrupted data, so I will use that instead--I
don't get the OPTIONS bug at all in JK2.

Joakim Strom



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Manavendra Gupta
I am surprised with the number of ppl facing this problem, including myself.
And it makes me wonder how others on this list have been able to use
DataSource/Connection Pooling with tomcat. It seems to be one feature where
majority of ppl have been facing problems, yet there is not much of
information on this (including the JNDI HOW-TO). It would be interesting to
hear from someone who had faced and subsequently resolved this problem.

Manav.

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 7:27 PM
To: Tomcat Users List
Subject: RE: Connection Pooling Help



Try changing the following parameter value in server.xml file

valuejdbc:as400://10.0.0.1/value

valuejdbc:as400://{name of your machine} /value instead of the ip
address of the as400

Hari

-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 8:40 AM
To: 'Tomcat Users List'
Subject: RE: Connection Pooling Help

Eric,

It's the same - DS == null. :-(

Thanks anyway.

Kevin

-Original Message-
From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:33
To: Tomcat Users List
Subject: RE: Connection Pooling Help


Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my
head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the
JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name


valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with
DBCP/h2);

 Context ctx = new InitialContext();
 if (ctx == null)
out.println(Something is wrong with Tomcat);

 DataSource ds = (DataSource)
ctx.lookup(java:comp/env/jdbc/shiltonDB);

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

if (conn != null) {
   out.println(bGot Connection:/b  + conn.toString() +
p);
   Statement stmt = conn.createStatement();
   String sql = select * from BSSTYL;

RE: A dead cat

2002-12-09 Thread Shapira, Yoav
Hi,
I would just suggest one quick test combination, but I don't have time
to look into the issue in depth: 
- Get JDK 1.4.1
- Since you're using JDK 1.4.x, try running the -LE-jdk14 tomcat
distribution, not the full distro.  The tomcat download page details the
differences between the two.

Yoav Shapira
Millennium ChemInformatics


-Original Message-
From: Simon Kelly [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 2:59 AM
To: Tomcat Users List
Subject: Re: A dead cat

Thanks for the reply.

I have started redeploying manually, as you suggested.  This seems to
be
working very well so far.  A bit long winded but at least nothing has
gone
wrong.  Just incase it is of any use and may shine some light on the
original problem the details of the machine and set up with web.xml are
shown below.

Thanks again for you help.

Regards

Simon

Machine:  1G Pentium (Standard off the shelf job)
OS:  MS Windows 2000
Java:  Sun j2sdk1.4.0_02
Tomcat:  4.1.12

web.xml  (This is the one for my application.  If you ment another just
ask
and ye shall receive)

?xml version=1.0 encoding=UTF-8?

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

web-app
servlet
servlet-name
testrun
/servlet-name
servlet-class
FrontServlet
/servlet-class
/servlet
servlet-mapping
servlet-name
testrun
/servlet-name
url-pattern
/test-index.html
/url-pattern
/servlet-mapping
session-config
session-timeout
30
/session-timeout
/session-config
welcome-file-list
welcome-file
/index.html
/welcome-file
/welcome-file-list
/web-app








- Original Message -
From: Shapira, Yoav [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Friday, December 06, 2002 3:06 PM
Subject: RE: A dead cat


Howdy,
It is difficult to help specifically, but here are a couple of general
notes that may be relevant:

1. Tomcat won't die (actually, the JVM won't die) if you've created any
non-daemon threads in your application.  If you create such threads,
either set them as daemons or ensure their proper termination.

2. I suggest simplifying your deployment process, at least temporarily.
Don't use the manager to redeploy.  Copy the war file manually each
time.  Unless you have some special settings, don't enter a Context
element for your webapp in server.xml.  Restart tomcat, ensuring it's
dead, between each deployment.

If you could post more details, including OS name and version, tomcat
version, JDK version, your web.xml file, we could probably help more.

Yoav Shapira
Millennium ChemInformatics


-Original Message-
From: Simon Kelly [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 06, 2002 4:19 AM
To: [EMAIL PROTECTED]
Subject: A dead cat

Hi,

I am currently using tomcat as a standalone server to test some
webapps
that
I am creating.  I have some experiance with web servers but little or
no
experiance with tomcat.  And I have a couple of major problems.

1)  The cat is dead but won't go away!  I have installed tomcat twice
now,
the first time I had a conflict within the port addressing for tomcat
and
my
exist database where both were configured to listen on the same port.
A
school boy error really, but when I killed off tomcat and edited the
server
config file to listen on an other port I got Exceptions every time I
tried
to restart tomcat.  I uninstalled and then reinstalled tomcat and
everything
was working fine for a couple of days.  However! After problem 2
occured
the
same situation has come back with tomcat.  The one thing I have
noticed
though is that the tomcat.exe in the process list cannot be killed
using
task manager.

2)  When tomcat was up and running the second time I managed to get
the
war
file into the webapps dir and it automatically detected it, created a
directory and deployed.  However, after a while and during one of the
updates to the app, tomcat seemed to jam and would not reload the app.
I
tryed to use the manager, but it would not let me even restart the
app.
So,
I removed it from the directory and then restarted tomcat.  This time
tomcat
would not even see the file was there and I had to install it using
manager.
This worked for the first couple of changes, but then this too failed
and
now tomcat will not respond at all.

I am going to unistall and reinstall again, but if anyone knows why
this is
going wrong I would be most greatful.

As a side, during the deployment using manager I got the  app in by
declaring the path '/katrin' and then giving the file url
'file:/c:/programme/apache group/tomcat 4.1/webapps/katrin.war'.  This
worked for a couple of times, but then failed.  There are a direct
copy
of
the last lines I entered.  Is there something I have done wrong in the
url,
as it is this error Mallformed url ... that I am 

symlink within tomcat 4.1.12

2002-12-09 Thread Uwe Barthel
hi tomcat-user-list,

Sorry, ugly english :-/

How I conf. Tomcat 4.1.12, that he follow sym. links ?
I've this construct on my devel. workstation:

project.cvs/myproj/lib/myLib.jar
project.cvs/myproj/webapps  (docBase of myproj)
[some static stuff]
./WEB-INF/classes
./WEB-INF/lib - ../../lib  (sym. link)

the appBase points to .../project.cvs
in this dir stay a myproj.xml with this content:
-888---
Context path=/myproj docBase=./myproj/webapps
debug=0 reloadable=true
/Context
-888---

but tomcat4 doesn't find the myLib.jar

it's a Debian Woody workstation with J2SDK 1.4.1_01

-- 
| Uwe Barthel . [EMAIL PROTECTED] ... Tel: +49-351-4353400
| VidSoft GmbH  http://www.vidsoft.de  Fax: +49-351-4353428
| seeing is believing . arena.vidconference.de .-.. [EMAIL PROTECTED]
| GnuPG KeyID: 3DD904E7 ...
| Fingerprint: 74C3 B1E1 422F 8EEF FB70  BC0F B8FA BB46 3DD9 04E7 .
+--=[ Usenet Compliant Signature (RFC 2646) ]=-- www.x-reizend.de 



signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil


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

2002-12-09 Thread Turner, John

Would you rather that people who can't help you waste your time sending you
on wild goose chases that don't help at all?  If you're not getting a
response to your post, it's because nobody can help you.  That's not our
fault.  Deal with it.

John


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 8:40 AM
 To: [EMAIL PROTECTED]
 Subject: I don´t understand the objective of this open list !
 
 
 In 3 opportunities i wrote to this stuped (sorry) list, and 
 NEVER i found help. 
 I hope that the people that participates of this list, don´t 
 have damages about 
 other people that don´t belong´s at your countries.
 Thank´s for NOTHING.
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread capa
what curious that is the first time that someone here, can to answer to 
something. Yes, this list is not for fighting, but is for help at other 
persons...maybe you can help me to solve my easy technical problem and forget 
this, because i think that you don´t have damages, it´s right ?.
Thank´s.

Mensaje citado por: Laxmikanth M.S. [EMAIL PROTECTED]:

 This is not the list for fighting..
 if u have personal grievance please send it to intended person not to
 the
 list
 please avoid flooding mails like this hereafter.even I am sorry
 for
 sending to all but no othergo
 
 Regards
 Laxmikanth M S 
 Off*  : 91-80-6610330 extn 1256
 Res* : 91-80-5267150
 http://www.sonata-software.com
 
  Coming together is the beginning, staying together is progress and
 working
  together is Success
 What lies behind us and what lies before us are tiny matters compared
 to
 what lies within us  - Emerson
 
 
  -Original Message-
  From:   Donie Kelly [SMTP:[EMAIL PROTECTED]]
  Sent:   Monday, December 09, 2002 7:16 PM
  To: 'Tomcat Users List'
  Subject:RE: I don´t understand the objective of this open list !
  
  You're defiantly blacklisted now :)
  
  
  
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: 09 December 2002 13:40
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
  
  In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i
 found
  help.
  I hope that the people that participates of this list, don´t have
 damages
  about
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
  
  
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 *
 Disclaimer: The information in this e-mail and any attachments is
 confidential / privileged. It is intended solely for the addressee or
 addressees. If you are not the addressee indicated in this message, you
 may
 not copy or deliver this message to anyone. In such case, you should
 destroy
 this message and kindly notify the sender by reply email. Please
 advise
 immediately if you or your employer does not consent to Internet email
 for
 messages of this kind.
 *
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: symlink within tomcat 4.1.12

2002-12-09 Thread Turner, John

symlinks are disabled by default in 4.1.12.  I think the workaround for it
is broken in .12 and .13, and fixed in .14 and later, but I could be wrong
(I don't use symlinks).  Check the archives for allowLinking and check the
release notes.

John

 -Original Message-
 From: Uwe Barthel [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:13 AM
 To: Tomcat Users List
 Subject: symlink within tomcat 4.1.12
 
 
 hi tomcat-user-list,
 
 Sorry, ugly english :-/
 
 How I conf. Tomcat 4.1.12, that he follow sym. links ?
 I've this construct on my devel. workstation:
 
 project.cvs/myproj/lib/myLib.jar
 project.cvs/myproj/webapps(docBase of myproj)
   [some static stuff]
   ./WEB-INF/classes
   ./WEB-INF/lib - ../../lib  (sym. link)
 
 the appBase points to .../project.cvs
 in this dir stay a myproj.xml with this content:
 -888---
 Context path=/myproj docBase=./myproj/webapps
 debug=0 reloadable=true
 /Context
 -888---
 
 but tomcat4 doesn't find the myLib.jar
 
 it's a Debian Woody workstation with J2SDK 1.4.1_01
 
 -- 
 | Uwe Barthel . [EMAIL PROTECTED] ... Tel: 
 +49-351-4353400
 | VidSoft GmbH  http://www.vidsoft.de  Fax: 
 +49-351-4353428
 | seeing is believing . arena.vidconference.de .-.. 
 [EMAIL PROTECTED]
 | GnuPG KeyID: 3DD904E7 
 ...
 | Fingerprint: 74C3 B1E1 422F 8EEF FB70  BC0F B8FA BB46 3DD9 
 04E7 .
 +--=[ Usenet Compliant Signature (RFC 2646) ]=-- www.x-reizend.de 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Turner, John

Word of advice:  making threats about damages to our country is the
absolute worst way to go about asking for help.  I doubt anyone will help
you now, even if they could.

You should think about learning some manners.  You'll get a lot farther in
life, a lot easier.

John

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:14 AM
 To: Tomcat Users List
 Subject: RE: I don´t understand the objective of this open list !
 
 
 what curious that is the first time that someone here, can to 
 answer to 
 something. Yes, this list is not for fighting, but is for 
 help at other 
 persons...maybe you can help me to solve my easy technical 
 problem and forget 
 this, because i think that you don´t have damages, it´s right ?.
 Thank´s.
 
 Mensaje citado por: Laxmikanth M.S. 
 [EMAIL PROTECTED]:
 
  This is not the list for fighting..
  if u have personal grievance please send it to intended 
 person not to
  the
  list
  please avoid flooding mails like this hereafter.even I am sorry
  for
  sending to all but no othergo
  
  Regards
  Laxmikanth M S 
  Off*  : 91-80-6610330 extn 1256
  Res* : 91-80-5267150
  http://www.sonata-software.com
  
   Coming together is the beginning, staying together is progress and
  working
   together is Success
  What lies behind us and what lies before us are tiny 
 matters compared
  to
  what lies within us  - Emerson
  
  
   -Original Message-
   From: Donie Kelly [SMTP:[EMAIL PROTECTED]]
   Sent: Monday, December 09, 2002 7:16 PM
   To:   'Tomcat Users List'
   Subject:  RE: I don´t understand the objective of this open list !
   
   You're defiantly blacklisted now :)
   
   
   
   -Original Message-
   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
   Sent: 09 December 2002 13:40
   To: [EMAIL PROTECTED]
   Subject: I don´t understand the objective of this open list !
   
   In 3 opportunities i wrote to this stuped (sorry) list, 
 and NEVER i
  found
   help.
   I hope that the people that participates of this list, don´t have
  damages
   about
   other people that don´t belong´s at your countries.
   Thank´s for NOTHING.
   
   
   --
   To unsubscribe, e-mail:
   mailto:[EMAIL PROTECTED]
   For additional commands, e-mail:
   mailto:[EMAIL PROTECTED]
   
   --
   To unsubscribe, e-mail:
   mailto:[EMAIL PROTECTED]
   For additional commands, e-mail:
   mailto:[EMAIL PROTECTED]
  
 *
  Disclaimer: The information in this e-mail and any attachments is
  confidential / privileged. It is intended solely for the 
 addressee or
  addressees. If you are not the addressee indicated in this 
 message, you
  may
  not copy or deliver this message to anyone. In such case, you should
  destroy
  this message and kindly notify the sender by reply email. Please
  advise
  immediately if you or your employer does not consent to 
 Internet email
  for
  messages of this kind.
  
 *
  
  --
  To unsubscribe, e-mail:  
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  
 
 --
 To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread capa
Sorry, buy your words don´t give me fear. I only search technical help for 
something. i don´t have interest in to obtain enemies, I´d like friends that 
can help me. Only friends.
I don´t need your threats. 
Thank´s.

Mensaje citado por: Donie Kelly [EMAIL PROTECTED]:

 You're defiantly blacklisted now :)
 
 
 
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 13:40
 To: [EMAIL PROTECTED]
 Subject: I don´t understand the objective of this open list !
 
 In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i
 found
 help.
 I hope that the people that participates of this list, don´t have
 damages
 about
 other people that don´t belong´s at your countries.
 Thank´s for NOTHING.
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: RE: I don´t understand the objective of thisopen list !

2002-12-09 Thread Felipe Schnack
  Just do not post to the list anymore okay? I actually think your
e-mail should be banned from the list. If nobody replied your question
is because your english is not very easy to understand. You spoke
something about people from other coutries, I'm not sure if I understood
you, but I'm a brazilian and get lots of help here, I love this list -
my only complaint is that I receive too much mails per day. :-)

On Mon, 2002-12-09 at 12:19, [EMAIL PROTECTED] wrote:
 Sorry, buy your words don´t give me fear. I only search technical help for 
 something. i don´t have interest in to obtain enemies, I´d like friends that 
 can help me. Only friends.
 I don´t need your threats. 
 Thank´s.
 
 Mensaje citado por: Donie Kelly [EMAIL PROTECTED]:
 
  You're defiantly blacklisted now :)
  
  
  
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: 09 December 2002 13:40
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
  
  In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i
  found
  help.
  I hope that the people that participates of this list, don´t have
  damages
  about
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
  
  
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  --
  To unsubscribe, e-mail:  
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  
 
 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]
 
-- 

Felipe Schnack
Analista de Sistemas
[EMAIL PROTECTED]
Cel.: (51)91287530
Linux Counter #281893

Faculdade Ritter dos Reis
www.ritterdosreis.br
[EMAIL PROTECTED]
Fone/Fax.: (51)32303328


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread David Kavanagh
Hmm, let me help...
The note you were  responding to was meant in good humor. Notice the 
smiley face at the end. That means that the comment was meant as a joke. 
I'm sorry if you aren't in that kind of mood right now.

Why don't you try stating the problem(s) you are having, including 
OS/jdk/tomcat version numbers.

David

PS. Sometimes, I don't get a reponse to something I post. I just look 
elsewhere for help. (documentation, source code...)

On 12/9/2002 9:19 AM, [EMAIL PROTECTED] wrote:

Sorry, buy your words don´t give me fear. I only search technical help for 
something. i don´t have interest in to obtain enemies, I´d like friends that 
can help me. Only friends.
I don´t need your threats. 
Thank´s.

Mensaje citado por: Donie Kelly [EMAIL PROTECTED]:

You're defiantly blacklisted now :)



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:40
To: [EMAIL PROTECTED]
Subject: I don´t understand the objective of this open list !

In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i
found
help.
I hope that the people that participates of this list, don´t have
damages
about
other people that don´t belong´s at your countries.
Thank´s for NOTHING.


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:  
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]






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

2002-12-09 Thread Donie Kelly
I reckon you should develop a sense of humour and take it in the way it was
intended. I don't care what country you come from and neither does anybody
else here. I've personally got major help from this list and find it an
invaluable source of information. Your post below will get you nowhere. Post
you question in a form that is answerable and you just might get some use
from the list.

Donie

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 14:20
To: Tomcat Users List
Subject: RE: I don´t understand the objective of this open list !

Sorry, buy your words don´t give me fear. I only search technical help for
something. i don´t have interest in to obtain enemies, I´d like friends that
can help me. Only friends.
I don´t need your threats.
Thank´s.

Mensaje citado por: Donie Kelly [EMAIL PROTECTED]:

 You're defiantly blacklisted now :)



 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 13:40
 To: [EMAIL PROTECTED]
 Subject: I don´t understand the objective of this open list !

 In 3 opportunities i wrote to this stuped (sorry) list, and NEVER i
 found
 help.
 I hope that the people that participates of this list, don´t have
 damages
 about
 other people that don´t belong´s at your countries.
 Thank´s for NOTHING.


 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

 --
 To unsubscribe, e-mail: 
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Statically compile mod_jk into Apache.

2002-12-09 Thread Faine, Mark
Solaris 8
Tomcat 4.1.12
Apache 1.3.27

I want to statically compile mod_jk in Apache. For performance reasons we
have an Apache installation that does not use any dynamically loaded
modules.  AFAIK it couldn't even if we wanted it to (without re-compiling)
because we used  -DDYNAMIC_MODULE_LIMIT=0 when compiling.  

The problem is I can't find any docs on statically compiling mod_jk into
Apache .  Is it even possible? If so, what are the
requirements/prerequisites for doing so? 

Also, What about mod_jk2 with Apache 2.x can a static compilation be done
here?

Thanks,
-Mark

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread capa
Dear Jhon, 
Thank´s for your answer. Yes, maybe my questions is very dificult because:
1. Nobody has to installed tomcat 4.1.12 and
2. Nobody has to run the simple examples of tomcat 4.1.12 after the install.

Jhon, this questions are very easy. Please, i give you excuses for this, but i 
don´t understand how to people with big knowledges don´t have a minimal time 
for help something.
And, i don´t understand, how the people have time to waste for to answer my 
claim and don´t have time to answer my technical problem.

Thank´s.


Mensaje citado por: Turner, John [EMAIL PROTECTED]:

 
 Would you rather that people who can't help you waste your time sending
 you
 on wild goose chases that don't help at all?  If you're not getting a
 response to your post, it's because nobody can help you.  That's not
 our
 fault.  Deal with it.
 
 John
 
 
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 8:40 AM
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
  
  
  In 3 opportunities i wrote to this stuped (sorry) list, and 
  NEVER i found help. 
  I hope that the people that participates of this list, don´t 
  have damages about 
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
  
  
  --
  To unsubscribe, e-mail:   
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail: 
  mailto:[EMAIL PROTECTED]
  
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Michael Weissenbacher
if you don't get answers i suggest you to take a look at this great text
http://www.tuxedo.org/~esr/faqs/smart-questions.html
it's How To Ask Questions The Smart Way by Eric Steven Raymond and i think
it does apply here

regards
mw
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 8:40 AM
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
  
  
  In 3 opportunities i wrote to this stuped (sorry) list, and 
  NEVER i found help. 
  I hope that the people that participates of this list, don´t 
  have damages about 
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
  
  
  --
  To unsubscribe, e-mail:   
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail: 
  mailto:[EMAIL PROTECTED]
  
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Faine, Mark
I only  just subscribed to this list a few minutes ago and I will first say
that if I can ever help you in any way I will. 

Having said that, you are fighting a loosing battle here by condemning the
very people you are asking for help.  There is an old saying, you get more
flies with honey than with vinegar.

-Mark


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Monday, December 09, 2002 8:29 AM
To: Tomcat Users List
Subject: RE: I don´t understand the objective of this open list !


Dear Jhon, 
Thank´s for your answer. Yes, maybe my questions is very dificult because:
1. Nobody has to installed tomcat 4.1.12 and 2. Nobody has to run the simple
examples of tomcat 4.1.12 after the install.

Jhon, this questions are very easy. Please, i give you excuses for this, but
i 
don´t understand how to people with big knowledges don´t have a minimal time

for help something.
And, i don´t understand, how the people have time to waste for to answer my 
claim and don´t have time to answer my technical problem.

Thank´s.


Mensaje citado por: Turner, John [EMAIL PROTECTED]:

 
 Would you rather that people who can't help you waste your time 
 sending you on wild goose chases that don't help at all?  If you're 
 not getting a response to your post, it's because nobody can help you.  
 That's not our
 fault.  Deal with it.
 
 John
 
 
  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 8:40 AM
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
  
  
  In 3 opportunities i wrote to this stuped (sorry) list, and
  NEVER i found help. 
  I hope that the people that participates of this list, don´t 
  have damages about 
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
  
  
  --
  To unsubscribe, e-mail:   
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Turner, John

Please repost your problem.  Be as specific as possible.  Provide version
numbers, and the text of any error messages you are seeing.

Please understand that your opinion of minimal time is inaccurate.  I'm
not even on the Tomcat team, and I spend several hours a day, every day,
reading and responding to posts on this list.  Time spent by most people on
this list is much much more than minimal.

That's why you will get your questions answered quickly if you stop the poor
attitude, be polite, and be patient.  This help is free, after all.  If you
want me to devote an hour or two to you and you only, then pay for my time.
I am sure others feel the same way.  I accept PayPal.  Please pay in
advance, and there is no guarantee that I can resolve your problem.
Otherwise, be patient like everyone else.

John


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:29 AM
 To: Tomcat Users List
 Subject: RE: I don´t understand the objective of this open list !
 
 
 Dear Jhon, 
 Thank´s for your answer. Yes, maybe my questions is very 
 dificult because:
 1. Nobody has to installed tomcat 4.1.12 and
 2. Nobody has to run the simple examples of tomcat 4.1.12 
 after the install.
 
 Jhon, this questions are very easy. Please, i give you 
 excuses for this, but i 
 don´t understand how to people with big knowledges don´t have 
 a minimal time 
 for help something.
 And, i don´t understand, how the people have time to waste 
 for to answer my 
 claim and don´t have time to answer my technical problem.
 
 Thank´s.
 
 
 Mensaje citado por: Turner, John [EMAIL PROTECTED]:
 
  
  Would you rather that people who can't help you waste your 
 time sending
  you
  on wild goose chases that don't help at all?  If you're not 
 getting a
  response to your post, it's because nobody can help you.  That's not
  our
  fault.  Deal with it.
  
  John
  
  
   -Original Message-
   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
   Sent: Monday, December 09, 2002 8:40 AM
   To: [EMAIL PROTECTED]
   Subject: I don´t understand the objective of this open list !
   
   
   In 3 opportunities i wrote to this stuped (sorry) list, and 
   NEVER i found help. 
   I hope that the people that participates of this list, don´t 
   have damages about 
   other people that don´t belong´s at your countries.
   Thank´s for NOTHING.
   
   
   --
   To unsubscribe, e-mail:   
   mailto:[EMAIL PROTECTED]
   For additional commands, e-mail: 
   mailto:[EMAIL PROTECTED]
   
  
  --
  To unsubscribe, e-mail:  
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
  
  
 
 --
 To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Remotely restart Tomcat.

2002-12-09 Thread Michael A. Angelo
Is there a way to hit the admin or something so that I can restart Tomcat remotely? I 
am using Struts and the only way I know to get things going again after changing the 
struts-config.xml file is to restart Tomcat. Can't just restart my web app.

Help!



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

2002-12-09 Thread Donie Kelly
I still don't understand the question. If it's so easy maybe it's because
people are sick of answering simple questions where people don't read the
how-to or installation guides properly. The archive for this list is at
http://mikal.org/interests/java/tomcat/ 

I suggest you spend a little time there first and come back if you have a
real problem.

Donie


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 14:29
To: Tomcat Users List
Subject: RE: I don´t understand the objective of this open list !

Dear Jhon,
Thank´s for your answer. Yes, maybe my questions is very dificult because:
1. Nobody has to installed tomcat 4.1.12 and
2. Nobody has to run the simple examples of tomcat 4.1.12 after the install.

Jhon, this questions are very easy. Please, i give you excuses for this, but
i
don´t understand how to people with big knowledges don´t have a minimal time
for help something.
And, i don´t understand, how the people have time to waste for to answer my
claim and don´t have time to answer my technical problem.

Thank´s.


Mensaje citado por: Turner, John [EMAIL PROTECTED]:


 Would you rather that people who can't help you waste your time sending
 you
 on wild goose chases that don't help at all?  If you're not getting a
 response to your post, it's because nobody can help you.  That's not
 our
 fault.  Deal with it.

 John


  -Original Message-
  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 8:40 AM
  To: [EMAIL PROTECTED]
  Subject: I don´t understand the objective of this open list !
 
 
  In 3 opportunities i wrote to this stuped (sorry) list, and
  NEVER i found help.
  I hope that the people that participates of this list, don´t
  have damages about
  other people that don´t belong´s at your countries.
  Thank´s for NOTHING.
 
 
  --
  To unsubscribe, e-mail:  
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 

 --
 To unsubscribe, e-mail: 
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Shapira, Yoav
Hi,
Maybe this will help.  I'll describe my rationale when I saw your question.  As you 
summarized them:

1. Nobody has to installed tomcat 4.1.12 and
2. Nobody has to run the simple examples of tomcat 4.1.12 after the
install.

Obviously, people (including myself) have done this before.  However, as someone who 
tries to contribute to this list by answering people's questions, I:
- Look for questions that are of interest to me to answer / discuss, which tend to be 
things a bit more involved than the above.
- Am limited by time.

don´t understand how to people with big knowledges don´t have a minimal
time for help something.

Understand it ;)  There are a lot of people on this list who are very knowledgeable 
and like to help.  However, most of us do have full-time jobs and this list does have 
hundreds of messages a day.  No one (I know of ;)) gets paid for answering questions 
on this list.  People answer what's interesting to them.

And then, when the occasional person goes off on a how come no one answered my 
question?!?! rant, I personally tend to block them out and not pay much attention to 
future questions from them.  It's not ideal, but that's the way it is.

Yoav Shapira
Millennium ChemInformatics

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Remotely restart Tomcat.

2002-12-09 Thread Aleksandr Shneyderman
Well you can also reload the context
in which you have your struts application

Use manager (not the admin) app for that,
it accepts the url commands from your 
browser

works for me.

 -Original Message-
 From: Michael A. Angelo [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:39 AM
 To: Tomcat Users List
 Subject: Remotely restart Tomcat.
 
 
 Is there a way to hit the admin or something so that I can 
 restart Tomcat remotely? I am using Struts and the only way I 
 know to get things going again after changing the 
 struts-config.xml file is to restart Tomcat. Can't just restart 
 my web app.
 
 Help!
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Bodycombe, Andrew
I've not done it myself in tomcat, only in EJB containers, but as a starting
point, I would suggest trying to get it to work by setting the connection
pool as a global resource instead of a resource specific to your context. 

Then try and get your context-specific connection pool working.

I too am surprised by the number of people facing this problem.

Andy.

-Original Message-
From: Manavendra Gupta
To: Tomcat Users List
Sent: 09/12/2002 14:14
Subject: RE: Connection Pooling Help

I am surprised with the number of ppl facing this problem, including
myself.
And it makes me wonder how others on this list have been able to use
DataSource/Connection Pooling with tomcat. It seems to be one feature
where
majority of ppl have been facing problems, yet there is not much of
information on this (including the JNDI HOW-TO). It would be interesting
to
hear from someone who had faced and subsequently resolved this problem.

Manav.

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 7:27 PM
To: Tomcat Users List
Subject: RE: Connection Pooling Help



Try changing the following parameter value in server.xml file

valuejdbc:as400://10.0.0.1/value

valuejdbc:as400://{name of your machine} /value instead of the ip
address of the as400

Hari

-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 8:40 AM
To: 'Tomcat Users List'
Subject: RE: Connection Pooling Help

Eric,

It's the same - DS == null. :-(

Thanks anyway.

Kevin

-Original Message-
From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:33
To: Tomcat Users List
Subject: RE: Connection Pooling Help


Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my
head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the
JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name


valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet extends HttpServlet {

   public void doGet(HttpServletRequest req,
 HttpServletResponse res) {

  try {
 ServletOutputStream out = res.getOutputStream();
 out.println(htmlbody);
 out.println(h2Using Tomcat Connection Pooling with
DBCP/h2);


Re: Custom Error 500 Page Is Not Displayed

2002-12-09 Thread Tomislav Miladinovic
Hi Ian,

I am pretty new in this area so I can't help with your question but if you don't mind 
I have question for you. I recently installed Tomcat 4.1.12 and at startup I am 
getting error you are talking about.

The page cannot be displayed

HTTP 500 - Internal server error 
Internet Explorer 

So, I am not able to see Tomcat home page. If you can help or give me some clue/idea I 
will appreciate that.

Thanks,
Tomislav
 

- Original Message - 
From: [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 6:04 AM
Subject: Custom Error 500 Page Is Not Displayed


Hi,

I have an installation of Tomcat 4.0.6 running on Win 2k Advanced Server, JDK 1.3.1_01 
using IIS 5.0 as web server. I have set-up custom error pages in web.xml for both 404 
and 500 to display helpful messages relevant to the application I've built. Any 404s 
are nicely displayed using the 404 error page defined in web.xml, but any 500s are not 
and I get the Tomcat default Internal Server error displayed, which isn't nice for my 
users.

I can't understand why the 404 works and 500 doesn't. Should the type of error that is 
coming back, e.g. an undefined variable or NullPointerException affect the error page 
I've chosen being displayed? If it's a NullPointerException that's a runtime error, 
but an undefined variable is a compile time error does this affect the redirection to 
the error page I've added?

I hope I'm not missing something basic because all examples, FAQs and other sites I've 
visited show that I'm doing the right thing and the fact that the 404 works further 
proves that. Any help is greatly appreciated.

Ian

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Remotely restart Tomcat.

2002-12-09 Thread Michael A. Angelo
I believe I tried to just restart my context and that doesn't do it. Also,
when you add new classes you also need to restart the entire tomcat server.

Is this not true? It has been my experience so far.


- Original Message -
From: Aleksandr Shneyderman [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 9:40 AM
Subject: RE: Remotely restart Tomcat.


 Well you can also reload the context
 in which you have your struts application

 Use manager (not the admin) app for that,
 it accepts the url commands from your
 browser

 works for me.

  -Original Message-
  From: Michael A. Angelo [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 9:39 AM
  To: Tomcat Users List
  Subject: Remotely restart Tomcat.
 
 
  Is there a way to hit the admin or something so that I can
  restart Tomcat remotely? I am using Struts and the only way I
  know to get things going again after changing the
  struts-config.xml file is to restart Tomcat. Can't just restart
  my web app.
 
  Help!
 

 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]






--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Roberto Bouza

 The main problem if you are using apache or not, is the connector. I don't
know if you are using apache but if you are using apache with tomcat DON'T USE
the WebApp connector, is not maintained anymore and does not work correctly with
apache 1.*, 2.*. USE mod_jk2 it works fine with the pool connection. I had the
same problem a few days ago and I resolve the problem changing connectors.

 I hope this help.

Quoting Manavendra Gupta [EMAIL PROTECTED]:

 I am surprised with the number of ppl facing this problem, including
 myself.
 And it makes me wonder how others on this list have been able to use
 DataSource/Connection Pooling with tomcat. It seems to be one feature where
 majority of ppl have been facing problems, yet there is not much of
 information on this (including the JNDI HOW-TO). It would be interesting to
 hear from someone who had faced and subsequently resolved this problem.
 
 Manav.
 
 -Original Message-
 From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 7:27 PM
 To: Tomcat Users List
 Subject: RE: Connection Pooling Help
 
 
 
 Try changing the following parameter value in server.xml file
 
 valuejdbc:as400://10.0.0.1/value
 
 valuejdbc:as400://{name of your machine} /value instead of the ip
 address of the as400
 
 Hari
 
 -Original Message-
 From: Kevin Passey [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 8:40 AM
 To: 'Tomcat Users List'
 Subject: RE: Connection Pooling Help
 
 Eric,
 
 It's the same - DS == null. :-(
 
 Thanks anyway.
 
 Kevin
 
 -Original Message-
 From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 13:33
 To: Tomcat Users List
 Subject: RE: Connection Pooling Help
 
 
 Kevin,
 
 Try:
 
   Context ctx = new InitialContext();
   Context envCtx = (Context) ctx.lookup(java:/comp/env/);
   DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);
 
 
 -Original Message-
 From: Kevin Passey [mailto:[EMAIL PROTECTED]]
 Sent: Montag, 09. Dezember 2002 14:25
 To: Tomcat Users List (E-mail)
 Subject: Connection Pooling Help
 
 
 Hi,
 
 Can somebody point out my mistake for me - I'm starting to bang my
 head..
 
 I am trying to get connection pooling working on my AS/400 using the
 Commons-DBCP.
 
 I have placed this JAR in TOMCAT_HOME/common/lib along with the
 JT400.JAR
 
 I have added the context entries to my server.xml file - thus:-
 
 !-- AS400 Connection Pooling Test --
 Context path=/shilton docBase=shilton debug=5
 reloadable=true crossContext=true
Resource name=jdbc/shiltonDB auth=Container
 type=javax.sql.DataSource /
 
ResourceParams name=jdbc/shiltonDB
   parameter
  namefactory/name
 
 
 valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
   /parameter
 
   parameter
  namemaxActive/name
 
  value100/value
   /parameter
 
   parameter
  namemaxIdle/name
 
  value3/value
   /parameter
 
   parameter
  namemaxWait/name
 
  value100/value
   /parameter
 
   parameter
  nameusername/name
 
  valueINTERNET/value
   /parameter
 
   parameter
  namepassword/name
 
  valueINTERNET/value
   /parameter
 
   parameter
  namedriverClassName/name
 
  valuecom.ibm.as400.access.AS400JDBCDriver/value
   /parameter
 
   parameter
  nameurl/name
 
  valuejdbc:as400://10.0.0.1/value
   /parameter
/ResourceParams
 /Context
 
 I have added this to my WEB-INF web.xml file:-
 
 resource-ref
 
 description
 
 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.
 
 /description
 
 res-ref-name
 
 jdbc/shiltonDB
 
 /res-ref-name
 
 res-type
 
 javax.sql.DataSource
 
 /res-type
 
 res-auth
 
 Container
 
 /res-auth
 
 /resource-ref
 
 And I have this java program to test the connection
 
 import javax.naming.*;
 import javax.sql.*;
 import javax.servlet.http.HttpServlet;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import javax.servlet.ServletOutputStream;
 import java.sql.*;
 
 public class DBCPServlet extends HttpServlet {
 
public void doGet(HttpServletRequest req,
  HttpServletResponse res) {
 
   try {
  

Using IWS 4.1 with Tomcat 4.1.12 under Solaris 8

2002-12-09 Thread Benoit Derouet
Hi all,

I was using IWS 4.1 with tomcat 3.2.x under Solaris 8 and this works fine.

I want to upgrade to Tomcat 4.1.12, but I am unable to make it works. The connector of 
my 3.2.x installation do not handle AJP 1.3, so I compile the nsapi-connector.so. The 
compilation works fine, but IWS can't start with this connector, I have this message 
at startup:

Status: 
[https-masquerouge.calendra.com]: start failed. (2: unknown early startup error)
[https-masquerouge.calendra.com]: conf_init: Error running init function load-modules: 
dlopen of 
/export/home/test/calendra/cdm40_2510/Server/bin/netscape/nsapi_redirector.so failed 
(ld.so.1: ns-httpd: fatal: relocation error: file 
/export/home/test/calendra/cdm40_2510/Server/bin/netscape/nsapi_redirector.so: symbol 
wc_open: referenced symbol not found)
[https-masquerouge.calendra.com]: server exit: status 1

Error 
An error occurred during startup. 
The server https-masquerouge.calendra.com was not started. 

I just don't know at all what is the problem and how can I solve this.

Maybe someone have this connector working ??

Thanks in advance

Regards,

Benoit Derouet

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




virtualhost based root context??

2002-12-09 Thread Thomas Sandor
hi all,

does anyone got an idea, how to set up the ROOT context for each of my
virtualhost? like in apache DocumentRoot, so when invoking the URL, each /
goes to a specified HTML directory. But in case of a dynamic app server I
have only /xyz/ contexts, but when invoking a domain e.g.: somewhat.com and
I redirect it to somewhat.com/somewhat looks awfull.

so I don't know if any app server supports a virtualhost based context
distribution, so I can tell which context to use for /?

any help is warmly welcomed.

cheers,
Thomas


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




question regarding error message

2002-12-09 Thread Horniks6
can u please tell me what javalangnoclassdeffounderror means? i can no longer 
get into yahoo games, and get this message. how do i fix? thanks in advance.



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

2002-12-09 Thread Turner, John

On a side note, I checked that URL and found that the archive stops after
March 2002.  Or did I miss something?

John


 -Original Message-
 From: Donie Kelly [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:29 AM
 To: 'Tomcat Users List'
 Subject: RE: I don´t understand the objective of this open list !
 
 
 I still don't understand the question. If it's so easy maybe 
 it's because
 people are sick of answering simple questions where people 
 don't read the
 how-to or installation guides properly. The archive for this 
 list is at
 http://mikal.org/interests/java/tomcat/ 
 
 I suggest you spend a little time there first and come back 
 if you have a
 real problem.
 
 Donie
 
 
 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 14:29
 To: Tomcat Users List
 Subject: RE: I don´t understand the objective of this open list !
 
 Dear Jhon,
 Thank´s for your answer. Yes, maybe my questions is very 
 dificult because:
 1. Nobody has to installed tomcat 4.1.12 and
 2. Nobody has to run the simple examples of tomcat 4.1.12 
 after the install.
 
 Jhon, this questions are very easy. Please, i give you 
 excuses for this, but
 i
 don´t understand how to people with big knowledges don´t have 
 a minimal time
 for help something.
 And, i don´t understand, how the people have time to waste 
 for to answer my
 claim and don´t have time to answer my technical problem.
 
 Thank´s.
 
 
 Mensaje citado por: Turner, John [EMAIL PROTECTED]:
 
 
  Would you rather that people who can't help you waste your 
 time sending
  you
  on wild goose chases that don't help at all?  If you're not 
 getting a
  response to your post, it's because nobody can help you.  That's not
  our
  fault.  Deal with it.
 
  John
 
 
   -Original Message-
   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
   Sent: Monday, December 09, 2002 8:40 AM
   To: [EMAIL PROTECTED]
   Subject: I don´t understand the objective of this open list !
  
  
   In 3 opportunities i wrote to this stuped (sorry) list, and
   NEVER i found help.
   I hope that the people that participates of this list, don´t
   have damages about
   other people that don´t belong´s at your countries.
   Thank´s for NOTHING.
  
  
   --
   To unsubscribe, e-mail:  
   mailto:[EMAIL PROTECTED]
   For additional commands, e-mail:
   mailto:[EMAIL PROTECTED]
  
 
  --
  To unsubscribe, e-mail: 
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: question regarding error message

2002-12-09 Thread Reynir Hübner
Hi, 

It means that the class you are trying to load is not found in the classpath of your 
application.
My guess is that you are on the wrong list (yahoo games ?)

Hope it helps
-reynir

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
 Sent: 9. desember 2002 02:43
 To: [EMAIL PROTECTED]
 Subject: question regarding error message
 
 
 can u please tell me what javalangnoclassdeffounderror means? 
 i can no longer 
 get into yahoo games, and get this message. how do i fix? 
 thanks in advance.
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Tomcat 4.1, DBCP and Oracle

2002-12-09 Thread Campano, Troy
Well I figured tomcat wasn't finding my driver when I didn't hard code it in 
setclasspath.sh because I didn't see it here:
Key is java.class.path -- 
/usr/local/java/lib/tools.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/commons-dbcp.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/commons-collections.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/commons-lang.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/commons-logging-api.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/commons-pool.jar:/usr/local/jakarta-tomcat-4.1.16/common/lib/classes12.jar:/usr/local/jakarta-tomcat-4.1.16/bin/bootstrap.jar

...when I printed out java.class.path and it showed up after I hardcoded the value.
Also, my other pages which don't use connection pooling weren't finding the driver 
until I hardcoded the value.
 
 
I took your example and put in my variables for server.xml:

Context path=/inventoryServer docBase=inventoryServer debug=5 
reloadable=false crossContext=false
 

Resource name=jdbc/inventoryPool auth=Container 
type=javax.sql.DataSource/
ResourceParams name=jdbc/inventoryPool
parameter
nameusername/name
valuemyUsername/value
/parameter
parameter
namepassword/name
valuemyPassword/value
/parameter
parameter
namedriverClassName/name
valueoracle.jdbc.driver.OracleDriver/value
/parameter
parameter
nameurl/name
value mailto:jdbc:oracle:thin:[EMAIL PROTECTED]:1521: 
jdbc:oracle:thin:myschema@myNode:1521:myInstance/value
/parameter
parameter
namefactory/name
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
/parameter
parameter
namemaxActive/name
value100/value
/parameter
parameter
namemaxIdle/name
value100/value
/parameter
parameter
namemaxWait/name
value100/value
/parameter
parameter
namevalidationQuery/name
valueSELECT 1 FROM dual/value
/parameter
/ResourceParams
/Context
 

 
My web.xml looks like this:
?xml version=1.0 encoding=ISO-8859-1?
 
!DOCTYPE web-app  PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN
http://java.sun.com/j2ee/dtds/web-app_2_3.dtd 
http://java.sun.com/j2ee/dtds/web-app_2_3.dtd;
 
web-app
taglib
taglib-uri http://java.sun.com/jstl/core 
http://java.sun.com/jstl/core/taglib-uri
taglib-location/WEB-INF/c.tld/taglib-location
 /taglib
 taglib
taglib-uri http://java.sun.com/jstl/xml 
http://java.sun.com/jstl/xml/taglib-uri
taglib-location/WEB-INF/x.tld/taglib-location
 /taglib
 taglib
taglib-uri http://java.sun.com/jstl/fmt 
http://java.sun.com/jstl/fmt/taglib-uri
taglib-location/WEB-INF/fmt.tld/taglib-location
 /taglib
 taglib
taglib-uri http://java.sun.com/jstl/sql 
http://java.sun.com/jstl/sql/taglib-uri
taglib-location/WEB-INF/sql.tld/taglib-location
 /taglib
 
resource-ref
 descriptionOracle Datasource example/description
 res-ref-namejdbc/inventoryPool/res-ref-name
 res-typejavax.sql.DataSource/res-type
 res-authContainer/res-auth
/resource-ref
 
/web-app

 
 
And I call my connection like this:
  Connection conn = null;
  Context initContext = new InitialContext();
  Context envContext  = (Context) initContext.lookup(java:/comp/env);
  DataSource ds = (DataSource) envContext.lookup(jdbc/inventoryPool);
  conn = ds.getConnection();
 
 
Am I do anything wrong with these?
 
 
 
thanks!


Troy Campano 
Database Management / Programmer 
Liberty Mutual 
(603) 245 4092 

-Original Message-
From: Jacob Kjome [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, December 08, 2002 3:27 PM
To: Tomcat Users List
Subject: RE: Tomcat 4.1, DBCP and Oracle



Yes, I have been able to do that.

When you say that Tomcat doesn't automatically recognize the file in its
classpath, how do you know that?  And when you hard code it in /bin/setclasspath.sh 
and it sees it, does your DataSource config now work?

If not, then there is a config problem.  You'll have to post your configuration in 
order to flesh that issue out.

One hint, make sure to use username and not user for DBCP configuration.  Attached 
is the DBCP config I use for your reference.

Jake

At 10:38 PM 12/7/2002 -0500, you wrote:



Hi, 
I've done this.
I renamed zip to jar. put it in /common/lib.
When I bounce tomcat...it doesn't automatically recognize the file in its
classpath, so I hard code it in /bin/setclasspath.sh, then it sees it.

I've set this up before. I have no problems setting this up with tomcat
4.0.X. It works like a charm. I've had the problem with 4.1.12 and not
4.1.16-beta.

I was working with someone on the Apache Bug database (is that the
tomcat-dev mailing list?). We didn't get anywhere.

So that's why I was wondering if there has 

RE: virtualhost based root context??

2002-12-09 Thread Reynir Hübner
If I understand you correctly you want create a virtual host definition in server.xml

It's done this way : 

Host name=www.something.com debug=0  
  Context path= docBase=C:\webappbase\ reloadable=true/
/Host

Hope it helps
-reynir




 -Original Message-
 From: Thomas Sandor [mailto:[EMAIL PROTECTED]] 
 Sent: 9. desember 2002 10:01
 To: [EMAIL PROTECTED]
 Subject: virtualhost based root context??
 
 
 hi all,
 
 does anyone got an idea, how to set up the ROOT context for 
 each of my virtualhost? like in apache DocumentRoot, so when 
 invoking the URL, each / goes to a specified HTML 
 directory. But in case of a dynamic app server I have only 
 /xyz/ contexts, but when invoking a domain e.g.: somewhat.com 
 and I redirect it to somewhat.com/somewhat looks awfull.
 
 so I don't know if any app server supports a virtualhost 
 based context distribution, so I can tell which context to 
 use for /?
 
 any help is warmly welcomed.
 
 cheers,
 Thomas
 
 
 --
 To unsubscribe, e-mail:   
 mailto:tomcat-user- [EMAIL PROTECTED]
 For 
 additional commands, 
 e-mail: mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




[OFFTOPIC] RE: question regarding error message

2002-12-09 Thread Turner, John

1 - this is a list for Tomcat user questions and support.

2 - that message typically means that a) the JVM on your machine is
misconfigured or needs to be reinstalled, or b) the applet or the link to
the applet is misconfigured on the server side (which you would have no
control over).

John

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Sunday, December 08, 2002 9:43 PM
 To: [EMAIL PROTECTED]
 Subject: question regarding error message
 
 
 can u please tell me what javalangnoclassdeffounderror means? 
 i can no longer 
 get into yahoo games, and get this message. how do i fix? 
 thanks in advance.
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Tomcat 4.1, DBCP and Oracle

2002-12-09 Thread Campano, Troy
I originally did it through the admin panel, but I made sure that I drilled down to 
the context of my webapp before I defined the data source.

The resource tags in my server.xml are within my webapps context.


thanks!

~ Troy Campano ~

-Original Message-
From: Dan Tran [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, December 07, 2002 11:56 PM
To: Tomcat Users List
Subject: Re: Tomcat 4.1, DBCP and Oracle


Did you configure Oracle DataSource thru the web interface of Admin app in Tomcat 4.1? 
If you did, you will need to link the Global datasource to your webapp in server.xml. 
Please look up ResourceLink tag

-D
- Original Message -
From: Campano, Troy [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, December 07, 2002 7:43 PM
Subject: RE: Tomcat 4.1, DBCP and Oracle


Oh sorry, i meant i have the problem with 4.1.16-beta as well.

thank you!

-Original Message-
From: Campano, Troy
To: Jacob Kjome; [EMAIL PROTECTED]
Sent: 12/7/02 10:38 PM
Subject: RE: Tomcat 4.1, DBCP and Oracle


Hi,
I've done this.
I renamed zip to jar. put it in /common/lib.
When I bounce tomcat...it doesn't automatically recognize the file in its classpath, 
so I hard code it in /bin/setclasspath.sh, then it sees it.

I've set this up before. I have no problems setting this up with tomcat 4.0.X. It 
works like a charm. I've had the problem with 4.1.12 and not 4.1.16-beta.

I was working with someone on the Apache Bug database (is that the tomcat-dev mailing 
list?). We didn't get anywhere.

So that's why I was wondering if there has been anyone who has successfully able to 
hook up tomcat 4.1.12, DBCP and Oracle. Were you able to do it?

thank you for your help...it's greatly appreciated.

~ Troy Campano ~

-Original Message-
From: Jacob Kjome
To: Tomcat Users List
Sent: 12/7/02 2:57 PM
Subject: RE: Tomcat 4.1, DBCP and Oracle


1.  Rename classes12.zip to classes12.jar.  You don't have to repackage the classes, 
simply rename the file. 2.  Put classes12.jar in CATALINA_HOME/common/lib.  That is 
the *only* place it can go because both the server and the application require access 
to it.  Libraries under the common (jars in /lib or /endorsed and class files in 
/classes) directory are seen by both the appserver and webapps unlike stuff under 
/shared or stuff under /server.

Then follow the docs for configuration: 
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples
-howto.html

Jake

At 12:45 PM 12/7/2002 -0500, you wrote:
Oh yeah...the error I get is:
java.sql.SQLException: Cannot load JDBC driver class 'null'


~ t r o y ~


   -Original Message-
  From: Campano, Troy
  Sent: Saturday, December 07, 2002 12:44 PM
  To:   '[EMAIL PROTECTED]'
  Subject:  Tomcat 4.1, DBCP and Oracle
 
  Has anyone been able to get Tomcat 4.1.12 or Tomcat 4.1.16 working
with
 DBCP and Oracle (classes12.zip)?
  I've tried a billion combinations of configurations and nothing
works.
 
  I've see other people on the web have also had this problem. I've 
  tried for months to figure this out and I've opened bug cases,
but
 nothing seems to work.
 
  Anyone able to do it?
 
  thank you!
 
  ~ Troy Campano ~

--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




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

2002-12-09 Thread Donie Kelly
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/

Didn't realise the archive on the other site was out of date. :(
Donie


-Original Message-
From: Turner, John [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 14:44
To: 'Tomcat Users List'
Subject: RE: I don´t understand the objective of this open list !


On a side note, I checked that URL and found that the archive stops after
March 2002.  Or did I miss something?

John


 -Original Message-
 From: Donie Kelly [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 9:29 AM
 To: 'Tomcat Users List'
 Subject: RE: I don´t understand the objective of this open list !


 I still don't understand the question. If it's so easy maybe
 it's because
 people are sick of answering simple questions where people
 don't read the
 how-to or installation guides properly. The archive for this
 list is at
 http://mikal.org/interests/java/tomcat/

 I suggest you spend a little time there first and come back
 if you have a
 real problem.

 Donie


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 14:29
 To: Tomcat Users List
 Subject: RE: I don´t understand the objective of this open list !

 Dear Jhon,
 Thank´s for your answer. Yes, maybe my questions is very
 dificult because:
 1. Nobody has to installed tomcat 4.1.12 and
 2. Nobody has to run the simple examples of tomcat 4.1.12
 after the install.

 Jhon, this questions are very easy. Please, i give you
 excuses for this, but
 i
 don´t understand how to people with big knowledges don´t have
 a minimal time
 for help something.
 And, i don´t understand, how the people have time to waste
 for to answer my
 claim and don´t have time to answer my technical problem.

 Thank´s.


 Mensaje citado por: Turner, John [EMAIL PROTECTED]:

 
  Would you rather that people who can't help you waste your
 time sending
  you
  on wild goose chases that don't help at all?  If you're not
 getting a
  response to your post, it's because nobody can help you.  That's not
  our
  fault.  Deal with it.
 
  John
 
 
   -Original Message-
   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
   Sent: Monday, December 09, 2002 8:40 AM
   To: [EMAIL PROTECTED]
   Subject: I don´t understand the objective of this open list !
  
  
   In 3 opportunities i wrote to this stuped (sorry) list, and
   NEVER i found help.
   I hope that the people that participates of this list, don´t
   have damages about
   other people that don´t belong´s at your countries.
   Thank´s for NOTHING.
  
  
   --
   To unsubscribe, e-mail: 
   mailto:[EMAIL PROTECTED]
   For additional commands, e-mail:
   mailto:[EMAIL PROTECTED]
  
 
  --
  To unsubscribe, e-mail:
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail:
  mailto:[EMAIL PROTECTED]
 
 

 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

 --
 To unsubscribe, e-mail:  
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: problems executing the examples.

2002-12-09 Thread Andoni
See this error from one of the files you posted:

[ERROR] Digester - -Parse Fatal Error at line 307 column 39: The string --
is
not permitted within comments. org.xml.sax.SAXParseException: The string
--
is not permitted within comments.

Try doing a text search using grep (if in solaris) for the string --

See what you get.

Andoni.


- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, December 07, 2002 4:57 PM
Subject: problems executing the examples.


 Hello, i install tomcat 4.1.12 . The first page (http://localhost:8080)
work's
 fine. But when i try to see te jsp examples or the servlet examples,
appear
 this error:


 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



 I see the logs, and this show this Errors:

 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.XMLDocumentFragmentScannerImpl.scanDocument
 (Unknown Source)
 at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
 at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
 at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
 at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
 at org.apache.commons.digester.Digester.parse(Digester.java:1514)
 at org.apache.catalina.startup.ContextConfig.tldScanStream
 (ContextConfig.java:977)
 at org.apache.catalina.startup.ContextConfig.tldScanTld
 (ContextConfig.java:1006)
 at org.apache.catalina.startup.ContextConfig.tldScan
 (ContextConfig.java:870)
 at org.apache.catalina.startup.ContextConfig.start
 (ContextConfig.java:647)
 at org.apache.catalina.startup.ContextConfig.lifecycleEvent
 (ContextConfig.java:243)
 at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent
 (LifecycleSupport.java:166)
 at org.apache.catalina.core.StandardContext.start
 (StandardContext.java:3493)
 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188)
 at org.apache.catalina.core.StandardHost.start(StandardHost.java:738)
 at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188)
 at org.apache.catalina.core.StandardEngine.start
 (StandardEngine.java:347)
 at org.apache.catalina.core.StandardService.start
 (StandardService.java:497)
 at org.apache.catalina.core.StandardServer.start
 (StandardServer.java:2189)
 at org.apache.catalina.startup.Catalina.start(Catalina.java:510)
 at 

Tomcat 4.1.12 exception reporting vs Resin exception reproting

2002-12-09 Thread Sukhwinder Singh
Hi,

I am using tomcat 4.1.12 for learning and development purpose. And I am
facing some problems regarding exception handling of tomcat. During
development Tomcat doesn't provide detailed description of an exception.
Instead of providing greater details about what caused the exception and
where it was thrown it just display the name of the bean which was called
from a jsp.

In an test application, I am using a jsp page which uses a CatalogBean to
get a list of products. CatalogBean again uses a DBBean to get access to
database through odbc and execute a query. When exception is thrown in
DBBean because of unavailability of db connection or some other problem it
throws an exception. And again CatalogBean catches the exception and
rethrows it. This exception is handled by jsp page and a stack trace is
printed.

Here is the line in jsp file which uses a bean:

---
jsp:useBean id=catalog class=CatalogBean scope=request /



Here is how list of products i retrieved:

   -
   %
 try


Product[] products = catalog.getProducts();
for (int i = 0; i  products.length; i++)
{
out.println(tr);
out.println(td+ products[i].getName() + /td);
out.println(td + products[i].getPrice() + /td);
out.println(tda
href=\/work/servlet/UpdateServlet?action=1pid=+products[i].getId()+\Ad
d/a/td);
out.println(/tr);
}
 }
 catch(Exception e)
 {
e.printStackTrace(new java.io.PrintWriter(out));
 }
  %
  --


Here is the constructor of CatalogBean which is called by useBean in jsp:

  --
--
public CatalogBean() throws Exception
{
products = Collections.synchronizedList(new ArrayList(25));
try
{
db = new DBBean(shop, sukh, test);

}
catch (Exception e)
{
throw new Exception (Could not create DBBean, e);
}
}
   -
-

And here is the constructor of DBBean which is called by CatalogBean:

   -
---

public DBBean(String dsn, String dbUser, String dbPassword) throws
Exception
{
this(sun.jdbc.odbc.JdbcOdbcDriver, jdbc:odbc:+dsn, dbUser,
dbPassword);

}

public DBBean(String driverClass, String conString, String dbUser,
String dbPassword) throws Exception
{
try
{
Class.forName(driverClass);
con = DriverManager.getConnection(conString, dbUser,
dbPassword);
stmt = con.createStatement();

}
catch (ClassNotFoundException e)
{
e.printStackTrace();
throw new Exception(Driver  + driverClass +  not found. ,
e);
}
catch (SQLException sqle)
{
sqle.printStackTrace();
throw new Exception(Could not connect:  + sqle);
}
catch (Exception e)
{
e.printStackTrace();
throw new Exception(Some error occured while connecting to
database:  + e);
}
 }

   -


Now when database access is not available or some other error occurs here is
how tomcat reports this problem when jsp page above is accessed:

   -
---

   type Exception report

   message

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

   exception

   org.apache.jasper.JasperException: CatalogBean
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va)
at

RMI Class Annotation

2002-12-09 Thread David Esposito
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/localhost/testjms/W
EB-INF/classes/
file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/work/MainEngine/localhost/testjms/W
EB-INF/lib/jbossall-client.jar
file:/C:/jboss-3.0.4-tomcat/tomcat-4.1.x/work/MainEngine/localhost/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/default/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:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: problems executing the examples.

2002-12-09 Thread capa
Thank's my FRIEND.

Mensaje citado por: Turner, John [EMAIL PROTECTED]:

 
 Looks like it would be in server.xml.
 
 John
 
 
  -Original Message-
  From: Andoni [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 10:06 AM
  To: Tomcat Users List
  Subject: Re: problems executing the examples.
  
  
  See this error from one of the files you posted:
  
  [ERROR] Digester - -Parse Fatal Error at line 307 column 39: 
  The string --
  is
  not permitted within comments. 
  org.xml.sax.SAXParseException: The string
  --
  is not permitted within comments.
  
  Try doing a text search using grep (if in solaris) for the string --
  
  See what you get.
  
  Andoni.
  
  
  - Original Message -
  From: [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Saturday, December 07, 2002 4:57 PM
  Subject: problems executing the examples.
  
  
   Hello, i install tomcat 4.1.12 . The first page 
  (http://localhost:8080)
  work's
   fine. But when i try to see te jsp examples or the servlet
 examples,
  appear
   this error:
  
  
   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
  
  
  
   I see the logs, and this show this Errors:
  
   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.XMLDocumentFragmentScannerImpl.scanDocument
   (Unknown Source)
   at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown
 Source)
   at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown
 Source)
   at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
   at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown
 Source)
   at org.apache.commons.digester.Digester.parse(Digester.java:1514)
   at org.apache.catalina.startup.ContextConfig.tldScanStream
   (ContextConfig.java:977)
   at org.apache.catalina.startup.ContextConfig.tldScanTld
   (ContextConfig.java:1006)
   at org.apache.catalina.startup.ContextConfig.tldScan
   (ContextConfig.java:870)
   at org.apache.catalina.startup.ContextConfig.start
   (ContextConfig.java:647)
   at org.apache.catalina.startup.ContextConfig.lifecycleEvent
   (ContextConfig.java:243)
   at 

RE: Tomcat 4.1, DBCP and Oracle

2002-12-09 Thread Campano, Troy
Nope...no luck.
Same error:
java.sql.SQLException: Cannot load JDBC driver class 'null'

My server.xml looks like this now:

Context path=/inventoryServer docBase=inventoryServer debug=5 
reloadable=false crossContext=false
  Resource name=jdbc/inventoryPool 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/
  ResourceParams name=jdbc/inventoryPool
parameter
  namefactory/name
  valueoracle.jdbc.pool.OracleDataSourceFactory/value
/parameter
parameter
  nameurl/name
  valuejdbc:oracle:thin:@myNode:1521:myIstance/value
/parameter
parameter
  nameuser/name
  valuemyUser/value
/parameter
parameter
  namepassword/name
  valuemyPass/value
/parameter
parameter
  namemaxLimit/name
  value10/value
/parameter
parameter
  nameminLimit/name
  value5/value
/parameter
parameter
  namecacheScheme/name
  value1/value
/parameter
  /ResourceParams
/Context



Any ideas?

~ t r o y ~

-Original Message-
From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]] 
Sent: Monday, December 09, 2002 10:11 AM
To: Campano, Troy
Subject: R: Tomcat 4.1, DBCP and Oracle


No,
they suggest to use an oracle.jdbc.pool.OracleConnectionCacheImpl
and an oracle.jdbc.pool.OracleDataSourceFactory
look in chapter 5 
It's an old post, I don't know its validity 8-?

-


 Oracle JDBC DataSource Example
This example shows how to configure Tomcat to use Oracle's JDBC connection cache data 
source.

First ensure the Oracle JDBC driver is installed correctly. The Oracle drivers can 
typically be located in the $ORACLE_HOME/jdbc/lib directory:

The Oracle JDBC driver must be added to the $CATALINA_HOME/common/lib directory, so 
that it can be loaded as a JNDI Resource. 
Ensure the driver file(s) has a .jar extension, so that it can be automatically loaded 
by Tomcat's class loader. 
Add a Tomcat Resource and ResourceParams element to the web application's Context in 
the $CATALINA_HOME/conf/server.xml file:

Context ... ... Resource name=jdbc/EmployeeDB 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/ ResourceParams 
name=jdbc/EmployeeDB parameter namefactory/name 
valueoracle.jdbc.pool.OracleDataSourceFactory/value /parameter parameter 
nameurl/name valuejdbc:oracle:thin:@localhost:1521:EmployeeDB/value 
/parameter parameter nameuser/name valuedbusername/value /parameter 
parameter namepassword/name valuedbpassword/value /parameter parameter 
namemaxLimit/name value10/value /parameter parameter nameminLimit/name 
value5/value /parameter parameter namecacheScheme/name value1/value 
/parameter /ResourceParams ... /Context 
The configuration properties for Oracle's connection cache data source resource 
factory (oracle.jdbc.pool.OracleDataSourceFactory) are as follows:

cacheScheme - The connection caching scheme: 1 - Dynamic Scheme; creates connections 
as required beyond maxLimit, but will close additional connections beyond maxLimit 
when they become available. 2 - Fixed Return Null Scheme; returns null when no spare 
connections are available. 3 - Fixed Wait Scheme; blocks waiting until a spare 
connection becomes available. database login password. The default value is Dynamic 
Scheme. 
maxLimit - The maximum number of connections in the pool. The default value is 10. 
minLimit - The minimum number of connections in the pool. The default value is 0. 
password - The database login password. 
url - The JDBC connection URL. 
user - The database login username. 
Add a corresponding resource-env-ref element in the web application's web.xml file:

resource-env-ref resource-env-ref-name jdbc/EmployerDB /resource-env-ref-name 
resource-env-ref-type oracle.jdbc.pool.OracleConnectionCacheImpl 
/resource-env-ref-type resource-env-ref 
Note the OracleConnectionCacheImpl class implements the javax.sql.DataSource 
interface, and should be used like a regular data source.

 -Messaggio originale-
 Da: Campano, Troy [mailto:[EMAIL PROTECTED]]
 Inviato: lunedì 9 dicembre 2002 16.08
 A: Balzarotti Paolo
 Oggetto: RE: Tomcat 4.1, DBCP and Oracle
 
 
 Is that the same thing as this?
 
 http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasourc
 e-examples-howto.html
 
 
 -Original Message-
 From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 10:02 AM
 To: Campano, Troy
 Subject: R: Tomcat 4.1, DBCP and Oracle
 
 
 Hello Troy,
 look at this
 http://www.mail-archive.com/tomcat-dev@jakarta.apache.org/msg2
 7217.html
 
  -Messaggio originale-
  Da: Campano, Troy [mailto:[EMAIL PROTECTED]]
  Inviato: lunedì 9 dicembre 2002 15.30
  A: Balzarotti Paolo
  Oggetto: RE: Tomcat 4.1, DBCP and Oracle
  
  
  Hi Paolo,
  No, nothing has worked yet...unfortunately.
  
  ~ T r o y ~
  
  -Original Message-
  From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]]
  Sent: Monday, December 09, 2002 5:56 AM
  To: Campano, Troy
  Subject: Tomcat 4.1, DBCP and Oracle
  
  
  

RE: Error 500 in Internet Explorer

2002-12-09 Thread ian.pilborough
Tomislav,

Error 500 is a Server error, for example if your page contains some bad Java in a 
scriptlet then the page won't compile and the server will return to you a server 
error. If you are seeing this it could be that the server is unable to compile your 
page or some such server related issue.

Are you getting this error when you try to hit a specific page that you have written? 
What exactly is the error? If you're not trying to access a page that you've written 
yourself, what page is it?

From the error message you've given me, you're not getting much back from Internet 
Explorer to help you, I.E. hides error messages from users, but you want to look at 
the whole error message. In the advanced settings of Internet Explorer 
(Tools-Internet Options-Advanced) you should uncheck the Show Friendly HTTP Error 
Messages option. This will give you the full error that Tomcat is sending back to 
your browser and that will help you understand what is going on further. Hopefully 
this will tell you that you've misspelt something on your page and you can correct 
that and it will run fine. 

I hope this helps.

Ian


 



-Original Message-
From:   Tomislav Miladinovic [EMAIL PROTECTED]
Sent:   09 December 2002 17:42
To: Tomcat Users List [EMAIL PROTECTED]
Subject:Re: Custom Error 500 Page Is Not Displayed

Hi Ian,

I am pretty new in this area so I can't help with your question but if you don't mind 
I have question for you. I recently installed Tomcat 4.1.12 and at startup I am 
getting error you are talking about.

The page cannot be displayed

HTTP 500 - Internal server error 
Internet Explorer 

So, I am not able to see Tomcat home page. If you can help or give me some clue/idea I 
will appreciate that.

Thanks,
Tomislav
 

- Original Message - 
From: [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Monday, December 09, 2002 6:04 AM
Subject: Custom Error 500 Page Is Not Displayed


Hi,

I have an installation of Tomcat 4.0.6 running on Win 2k Advanced Server, JDK 1.3.1_01 
using IIS 5.0 as web server. I have set-up custom error pages in web.xml for both 404 
and 500 to display helpful messages relevant to the application I've built. Any 404s 
are nicely displayed using the 404 error page defined in web.xml, but any 500s are not 
and I get the Tomcat default Internal Server error displayed, which isn't nice for my 
users.

I can't understand why the 404 works and 500 doesn't. Should the type of error that is 
coming back, e.g. an undefined variable or NullPointerException affect the error page 
I've chosen being displayed? If it's a NullPointerException that's a runtime error, 
but an undefined variable is a compile time error does this affect the redirection to 
the error page I've added?

I hope I'm not missing something basic because all examples, FAQs and other sites I've 
visited show that I'm doing the right thing and the fact that the 404 works further 
proves that. Any help is greatly appreciated.

Ian

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Tomcat 4.1, DBCP and Oracle

2002-12-09 Thread Thomas Achleitner
Hi!
I think paraemter driverClassName is missing. Try:
parameternamedriverClassName/namevalueoracle.jdbc.OracleDriver/value/parameter

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:

Context path=/inventoryServer docBase=inventoryServer debug=5 
reloadable=false crossContext=false
  Resource name=jdbc/inventoryPool 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/
  ResourceParams name=jdbc/inventoryPool
parameter
  namefactory/name
  valueoracle.jdbc.pool.OracleDataSourceFactory/value
/parameter
parameter
  nameurl/name
  valuejdbc:oracle:thin:@myNode:1521:myIstance/value
/parameter
parameter
  nameuser/name
  valuemyUser/value
/parameter
parameter
  namepassword/name
  valuemyPass/value
/parameter
parameter
  namemaxLimit/name
  value10/value
/parameter
parameter
  nameminLimit/name
  value5/value
/parameter
parameter
  namecacheScheme/name
  value1/value
/parameter
  /ResourceParams
/Context



Any ideas?

~ t r o y ~

-Original Message-
From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]] 
Sent: Monday, December 09, 2002 10:11 AM
To: Campano, Troy
Subject: R: Tomcat 4.1, DBCP and Oracle


No,
they suggest to use an oracle.jdbc.pool.OracleConnectionCacheImpl
and an oracle.jdbc.pool.OracleDataSourceFactory
look in chapter 5 
It's an old post, I don't know its validity 8-?

-


 Oracle JDBC DataSource Example
This example shows how to configure Tomcat to use Oracle's JDBC connection cache data 
source.

First ensure the Oracle JDBC driver is installed correctly. The Oracle drivers can 
typically be located in the $ORACLE_HOME/jdbc/lib directory:

The Oracle JDBC driver must be added to the $CATALINA_HOME/common/lib directory, so 
that it can be loaded as a JNDI Resource. 
Ensure the driver file(s) has a .jar extension, so that it can be automatically loaded 
by Tomcat's class loader. 
Add a Tomcat Resource and ResourceParams element to the web application's Context in 
the $CATALINA_HOME/conf/server.xml file:

Context ... ... Resource name=jdbc/EmployeeDB 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/ ResourceParams 
name=jdbc/EmployeeDB parameter namefactory/name 
valueoracle.jdbc.pool.OracleDataSourceFactory/value /parameter parameter 
nameurl/name valuejdbc:oracle:thin:@localhost:1521:EmployeeDB/value 
/parameter parameter nameuser/name valuedbusername/value /parameter 
parameter namepassword/name valuedbpassword/value /parameter parameter 
namemaxLimit/name value10/value /parameter parameter nameminLimit/name 
value5/value /parameter parameter namecacheScheme/name value1/value 
/parameter /ResourceParams ... /Context 
The configuration properties for Oracle's connection cache data source resource 
factory (oracle.jdbc.pool.OracleDataSourceFactory) are as follows:

cacheScheme - The connection caching scheme: 1 - Dynamic Scheme; creates connections 
as required beyond maxLimit, but will close additional connections beyond maxLimit 
when they become available. 2 - Fixed Return Null Scheme; returns null when no spare 
connections are available. 3 - Fixed Wait Scheme; blocks waiting until a spare 
connection becomes available. database login password. The default value is Dynamic 
Scheme. 
maxLimit - The maximum number of connections in the pool. The default value is 10. 
minLimit - The minimum number of connections in the pool. The default value is 0. 
password - The database login password. 
url - The JDBC connection URL. 
user - The database login username. 
Add a corresponding resource-env-ref element in the web application's web.xml file:

resource-env-ref resource-env-ref-name jdbc/EmployerDB /resource-env-ref-name 
resource-env-ref-type oracle.jdbc.pool.OracleConnectionCacheImpl 
/resource-env-ref-type resource-env-ref 
Note the OracleConnectionCacheImpl class implements the javax.sql.DataSource 
interface, and should be used like a regular data source.

 -Messaggio originale-
 Da: Campano, Troy [mailto:[EMAIL PROTECTED]]
 Inviato: lunedì 9 dicembre 2002 16.08
 A: Balzarotti Paolo
 Oggetto: RE: Tomcat 4.1, DBCP and Oracle
 
 
 Is that the same thing as this?
 
 http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasourc
 e-examples-howto.html
 
 
 -Original Message-
 From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 10:02 AM
 To: Campano, Troy
 Subject: R: Tomcat 4.1, DBCP and Oracle
 
 
 Hello Troy,
 look at this
 http://www.mail-archive.com/tomcat-dev@jakarta.apache.org/msg2
 7217.html
 
  -Messaggio originale-
  Da: Campano, Troy [mailto:[EMAIL PROTECTED]]
  Inviato: lunedì 9 

Can't read POST parameters in a Servlet

2002-12-09 Thread Ivan Venuti
Hi,

I have this problem: from an HTML page I call a Servlet via a form like this:

form name=richiesta method=post action=servletName

input type=hidden name=in_file value=9177.doc

...

input type=hidden name=port value=8787

/form

In the Servlet I retrieve the parameters with request.getParameter(paramName);

With Tomcat3.x everithing goes well, but with Tomcat 4.0.3 I can't retrieve the 
parameters in the Servlet: every getParameter returns null, and printing all with

for (Enumeration namesList = request.getParameterNames(); namesList.hasMoreElements();)

{

String curName =(String)namesList.nextElement();

System.out.println(Param +curName+ value: '+request.getParameter(curName)+');

}

prints nothing!

I really can't figure out where to look for a solution. Any help is welcome!

-- Ivan Venuti --




Advice please: Apache doesn't seem to resolve Tomcat symbolic links

2002-12-09 Thread Sarah Grimley

Inside my WEBAPP my subfolders 'ICONS' and 'TEMPLATES' are actually symbolic links to 
folders elsewhere.
I have enabled them to be accessed by my WebApp, by placing this code inside the 
Tomcat server.xml:
!-- Tomcat MY_APP Context --
Context path=/MY_APP docBase=MY_APP debug=0
reloadable=true crossContext=true
Logger className=org.apache.catalina.logger.FileLogger
prefix=MY_APP_log. suffix=.txt
timestamp=true/
Resources className =org.apache.naming.resources.FileDirContext
allowLinking=true/
/Context

I can then refer to gifs in my HTML as:   ../icons/mypicture.gif

This all works fine when I used Tomcat as standalone.

Now I want to use Apache with Tomcat as the webserver.

I configure Apache as follows:

IfModule mod_webapp.c

  WebAppConnection warpConnection warp localhost:8008
  WebAppDeploy examples warpConnection /examples/
  WebAppInfo   /webapp-info

  WebAppDeploy seqreq warpConnection /MY_APP/
/IfModule


I also include following in the Tomcat server.xml:

 Service name=Tomcat-Apache

Connector className=org.apache.catalina.connector.warp.WarpConnector
 port=8008 minProcessors=5 maxProcessors=75
 enableLookups=true appBase=webapps
 acceptCount=10 debug=0/

Engine className=org.apache.catalina.connector.warp.WarpEngine
 name=Apache debug=0

  Logger className=org.apache.catalina.logger.FileLogger
  prefix=apache_log. suffix=.txt
  timestamp=true/

  Realm className=org.apache.catalina.realm.MemoryRealm /

/Engine

  /Service

Now my problem is that the symbolic links no longer resolve... so my gifs are not 
found.  The rest of the files can be accesses no problem, so I am sure it is because 
of the 'virtual' links to the icon folder.

Can anybody help me to solve this problem?  Thank you.




-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits your needs



Q: How do I install a jar file and reference it with a jsp page?

2002-12-09 Thread Brian O. Bozarth

Having trouble using this jar file which has code for an Equifax interface (credit 
check).   I've been given a jar file with sample code.   Where do I put in the tomcat 
directory and how do I reference it in a jsp page?   Do I need to do anything on the 
server to configure?

The package is called package com.equifax.rcas.tools;   

I am using Apache Tomcat/4.1.12

Brian Bozarth
Chief Technical Officer
Labwerks
3618 Penn Avenue
Pittsburgh, PA 15201
P. 412-621-9375
F. 412-621-6082
http://www.labwerks.com

A Marketing Communications Company








WebDav and Symbolic Links in 4.1.12!!!

2002-12-09 Thread Paolo Scaffardi
I upgraded Tomcat from old 4.0.6 to 4.1.12 and now i have problems with
WebDav support:symbolic links on the webdav directory cannot be
inspected/followed from any client (HTTP error: could not do a PROPFIND
on file /webdav/mydir froms server myserver (404)). I work on Linux.
 
I modified my server.xml adding the following lines inside host tags, to
make allowLinking parameter true for every existing application. But it
seems not work.
 
DefaultContext
Resources className=org.apache.naming.resources.FileDirContext
allowLinking=true caseSensitive=false/
/DefaultContext

Any help for me? This is the only problem i have

 

Thank you,

Paolo Scaffardi

Ufficio Giotto - Airvent SAM S.p.A. - Rimini

Tel. 0541 383294

 



RE: Tomcat 4.1, DBCP and Oracle

2002-12-09 Thread Campano, Troy
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: 
parameternamedriverClassName/namevalueoracle.jdbc.OracleDriver/value/parameter

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:

Context path=/inventoryServer docBase=inventoryServer debug=5 
reloadable=false crossContext=false
  Resource name=jdbc/inventoryPool 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/
  ResourceParams name=jdbc/inventoryPool
parameter
  namefactory/name
  valueoracle.jdbc.pool.OracleDataSourceFactory/value
/parameter
parameter
  nameurl/name
  valuejdbc:oracle:thin:@myNode:1521:myIstance/value
/parameter
parameter
  nameuser/name
  valuemyUser/value
/parameter
parameter
  namepassword/name
  valuemyPass/value
/parameter
parameter
  namemaxLimit/name
  value10/value
/parameter
parameter
  nameminLimit/name
  value5/value
/parameter
parameter
  namecacheScheme/name
  value1/value
/parameter
  /ResourceParams
/Context



Any ideas?

~ t r o y ~

-Original Message-
From: Balzarotti Paolo [mailto:[EMAIL PROTECTED]] 
Sent: Monday, December 09, 2002 10:11 AM
To: Campano, Troy
Subject: R: Tomcat 4.1, DBCP and Oracle


No,
they suggest to use an oracle.jdbc.pool.OracleConnectionCacheImpl
and an oracle.jdbc.pool.OracleDataSourceFactory
look in chapter 5 
It's an old post, I don't know its validity 8-?

-


 Oracle JDBC DataSource Example
This example shows how to configure Tomcat to use Oracle's JDBC connection cache data 
source.

First ensure the Oracle JDBC driver is installed correctly. The Oracle drivers can 
typically be located in the $ORACLE_HOME/jdbc/lib directory:

The Oracle JDBC driver must be added to the $CATALINA_HOME/common/lib directory, so 
that it can be loaded as a JNDI Resource. 
Ensure the driver file(s) has a .jar extension, so that it can be automatically loaded 
by Tomcat's class loader. 
Add a Tomcat Resource and ResourceParams element to the web application's Context in 
the $CATALINA_HOME/conf/server.xml file:

Context ... ... Resource name=jdbc/EmployeeDB 
type=oracle.jdbc.pool.OracleConnectionCacheImpl/ ResourceParams 
name=jdbc/EmployeeDB parameter namefactory/name 
valueoracle.jdbc.pool.OracleDataSourceFactory/value /parameter parameter 
nameurl/name valuejdbc:oracle:thin:@localhost:1521:EmployeeDB/value 
/parameter parameter nameuser/name valuedbusername/value /parameter 
parameter namepassword/name valuedbpassword/value /parameter parameter 
namemaxLimit/name value10/value /parameter parameter nameminLimit/name 
value5/value /parameter parameter namecacheScheme/name value1/value 
/parameter /ResourceParams ... /Context 
The configuration properties for Oracle's connection cache data source resource 
factory (oracle.jdbc.pool.OracleDataSourceFactory) are as follows:

cacheScheme - The connection caching scheme: 1 - Dynamic Scheme; creates connections 
as required beyond maxLimit, but will close additional connections beyond maxLimit 
when they become available. 2 - Fixed Return Null Scheme; returns null when no spare 
connections are available. 3 - Fixed Wait Scheme; blocks waiting until a spare 
connection becomes available. database login password. The default value is Dynamic 
Scheme. 
maxLimit - The maximum number of connections in the pool. The default value is 10. 
minLimit - The minimum number of connections in the pool. The default value is 0. 
password - The database login password. 
url - The JDBC connection URL. 
user - The database login username. 
Add a corresponding resource-env-ref element in the web application's web.xml file:

resource-env-ref resource-env-ref-name jdbc/EmployerDB /resource-env-ref-name 
resource-env-ref-type oracle.jdbc.pool.OracleConnectionCacheImpl 
/resource-env-ref-type resource-env-ref 
Note the OracleConnectionCacheImpl class implements the javax.sql.DataSource 
interface, and should be used like a regular data source.

 -Messaggio originale-
 Da: Campano, Troy [mailto:[EMAIL PROTECTED]]
 Inviato: lunedì 9 dicembre 2002 16.08
 A: Balzarotti Paolo
 Oggetto: RE: Tomcat 4.1, DBCP and Oracle
 
 
 Is that the same thing as this?
 
 

RE: Connection Pooling Help

2002-12-09 Thread Manavendra Gupta
Thanks for the reply. How do i make it a global resource? Just declare the
resource in the global section?



-Original Message-
From: Bodycombe, Andrew [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 8:09 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Connection Pooling Help


I've not done it myself in tomcat, only in EJB containers, but as a starting
point, I would suggest trying to get it to work by setting the connection
pool as a global resource instead of a resource specific to your context.

Then try and get your context-specific connection pool working.

I too am surprised by the number of people facing this problem.

Andy.

-Original Message-
From: Manavendra Gupta
To: Tomcat Users List
Sent: 09/12/2002 14:14
Subject: RE: Connection Pooling Help

I am surprised with the number of ppl facing this problem, including
myself.
And it makes me wonder how others on this list have been able to use
DataSource/Connection Pooling with tomcat. It seems to be one feature
where
majority of ppl have been facing problems, yet there is not much of
information on this (including the JNDI HOW-TO). It would be interesting
to
hear from someone who had faced and subsequently resolved this problem.

Manav.

-Original Message-
From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 7:27 PM
To: Tomcat Users List
Subject: RE: Connection Pooling Help



Try changing the following parameter value in server.xml file

valuejdbc:as400://10.0.0.1/value

valuejdbc:as400://{name of your machine} /value instead of the ip
address of the as400

Hari

-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 8:40 AM
To: 'Tomcat Users List'
Subject: RE: Connection Pooling Help

Eric,

It's the same - DS == null. :-(

Thanks anyway.

Kevin

-Original Message-
From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
Sent: 09 December 2002 13:33
To: Tomcat Users List
Subject: RE: Connection Pooling Help


Kevin,

Try:

  Context ctx = new InitialContext();
Context envCtx = (Context) ctx.lookup(java:/comp/env/);
DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


-Original Message-
From: Kevin Passey [mailto:[EMAIL PROTECTED]]
Sent: Montag, 09. Dezember 2002 14:25
To: Tomcat Users List (E-mail)
Subject: Connection Pooling Help


Hi,

Can somebody point out my mistake for me - I'm starting to bang my
head..

I am trying to get connection pooling working on my AS/400 using the
Commons-DBCP.

I have placed this JAR in TOMCAT_HOME/common/lib along with the
JT400.JAR

I have added the context entries to my server.xml file - thus:-

!-- AS400 Connection Pooling Test --
Context path=/shilton docBase=shilton debug=5
reloadable=true crossContext=true
   Resource name=jdbc/shiltonDB auth=Container
type=javax.sql.DataSource /

   ResourceParams name=jdbc/shiltonDB
  parameter
 namefactory/name


valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
  /parameter

  parameter
 namemaxActive/name

 value100/value
  /parameter

  parameter
 namemaxIdle/name

 value3/value
  /parameter

  parameter
 namemaxWait/name

 value100/value
  /parameter

  parameter
 nameusername/name

 valueINTERNET/value
  /parameter

  parameter
 namepassword/name

 valueINTERNET/value
  /parameter

  parameter
 namedriverClassName/name

 valuecom.ibm.as400.access.AS400JDBCDriver/value
  /parameter

  parameter
 nameurl/name

 valuejdbc:as400://10.0.0.1/value
  /parameter
   /ResourceParams
/Context

I have added this to my WEB-INF web.xml file:-

resource-ref

description

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.

/description

res-ref-name

jdbc/shiltonDB

/res-ref-name

res-type

javax.sql.DataSource

/res-type

res-auth

Container

/res-auth

/resource-ref

And I have this java program to test the connection

import javax.naming.*;
import javax.sql.*;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.ServletOutputStream;
import java.sql.*;

public class DBCPServlet 

RE: oracle+tomcat 4.1.x+dbcp = driverClassName is required!

2002-12-09 Thread Pedro Salazar
Greetings,

Eric, I'm getting a javax.naming.NameNotFoundException: Name jdbc is
not bound in this Context exception!

I have a resource link inside my context (no resource here or
resource-ref in web.xml):

resourceLink name=jdbc/ngincaredb
global=jdbc/ngincaredb_global
type=javax.sql.DataSource /

and I'm doing a lookup in my code for jdbc/ngincaredb:

Context initCtx = new InitialContext();
Context envCtx = (Context)initCtx.lookup(java:comp/env);
this.ds = (DataSource)envCtx.lookup(/jdbc/ngincaredb);

So, what's wrong here?

thanks,
Pedro Salazar.

On Mon, 2002-12-09 at 13:06, Roberts, Eric wrote:
 Pedro,
 
 You need javax.sql - that is the package containing DataSource.
 Your Resource type should be: type=javax.sql.DataSource
 You need these parameters in addition to url, username and password:
   parameter
 namedriverClassName/name
 valueoracle.jdbc.driver.OracleDriver/value
   /parameter
   parameter
 namefactory/name
 valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
   /parameter
 
 In the Context the ResourceLink type should be: type=javax.sql.DataSource
 
 You do not need any resource-ref in your web.xml - just use your ResourceLink name 
as follows:
   Context ctx = new InitialContext();
   Context envCtx = (Context) ctx.lookup(java:/comp/env/);
   DataSource ds = (DataSource) envCtx.lookup(/{name_of_resource_link});
 
   if (ds != null) {
   DbCon = ds.getConnection();
   }
 
 Hope this helps.

-- 
pedro salazar (pt-inovacao) [EMAIL PROTECTED]
key id: D803BC61


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Connection Pooling Help

2002-12-09 Thread Manavendra Gupta
No, i am not using apache - its a standalone version of tomcat.

To be honest, I find it rather awkward to be worried about the mod_jk
versions, or whether i have a paricular module installed or using a
particular connector, etc. With a tool being into such a wide use, I'm sure
there are people who have done this before, but somehow, either I am missing
something significant, or maybe others went through the same ordeal and have
been unable to reproduce what they did, or maybe its just dumb hard luck!

-Original Message-
From: Roberto Bouza [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 8:19 PM
To: Tomcat Users List; [EMAIL PROTECTED]
Subject: RE: Connection Pooling Help



 The main problem if you are using apache or not, is the connector. I
don't
know if you are using apache but if you are using apache with tomcat DON'T
USE
the WebApp connector, is not maintained anymore and does not work correctly
with
apache 1.*, 2.*. USE mod_jk2 it works fine with the pool connection. I had
the
same problem a few days ago and I resolve the problem changing connectors.

 I hope this help.

Quoting Manavendra Gupta [EMAIL PROTECTED]:

 I am surprised with the number of ppl facing this problem, including
 myself.
 And it makes me wonder how others on this list have been able to use
 DataSource/Connection Pooling with tomcat. It seems to be one feature
where
 majority of ppl have been facing problems, yet there is not much of
 information on this (including the JNDI HOW-TO). It would be interesting
to
 hear from someone who had faced and subsequently resolved this problem.

 Manav.

 -Original Message-
 From: Hari Venkatesan [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 7:27 PM
 To: Tomcat Users List
 Subject: RE: Connection Pooling Help



 Try changing the following parameter value in server.xml file

 valuejdbc:as400://10.0.0.1/value

 valuejdbc:as400://{name of your machine} /value instead of the ip
 address of the as400

 Hari

 -Original Message-
 From: Kevin Passey [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 8:40 AM
 To: 'Tomcat Users List'
 Subject: RE: Connection Pooling Help

 Eric,

 It's the same - DS == null. :-(

 Thanks anyway.

 Kevin

 -Original Message-
 From: Roberts, Eric [mailto:[EMAIL PROTECTED]]
 Sent: 09 December 2002 13:33
 To: Tomcat Users List
 Subject: RE: Connection Pooling Help


 Kevin,

 Try:

   Context ctx = new InitialContext();
   Context envCtx = (Context) ctx.lookup(java:/comp/env/);
   DataSource ds = (DataSource) envCtx.lookup(/jdbc/shiltonDB);


 -Original Message-
 From: Kevin Passey [mailto:[EMAIL PROTECTED]]
 Sent: Montag, 09. Dezember 2002 14:25
 To: Tomcat Users List (E-mail)
 Subject: Connection Pooling Help


 Hi,

 Can somebody point out my mistake for me - I'm starting to bang my
 head..

 I am trying to get connection pooling working on my AS/400 using the
 Commons-DBCP.

 I have placed this JAR in TOMCAT_HOME/common/lib along with the
 JT400.JAR

 I have added the context entries to my server.xml file - thus:-

 !-- AS400 Connection Pooling Test --
 Context path=/shilton docBase=shilton debug=5
 reloadable=true crossContext=true
Resource name=jdbc/shiltonDB auth=Container
 type=javax.sql.DataSource /

ResourceParams name=jdbc/shiltonDB
   parameter
  namefactory/name


 valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
   /parameter

   parameter
  namemaxActive/name

  value100/value
   /parameter

   parameter
  namemaxIdle/name

  value3/value
   /parameter

   parameter
  namemaxWait/name

  value100/value
   /parameter

   parameter
  nameusername/name

  valueINTERNET/value
   /parameter

   parameter
  namepassword/name

  valueINTERNET/value
   /parameter

   parameter
  namedriverClassName/name

  valuecom.ibm.as400.access.AS400JDBCDriver/value
   /parameter

   parameter
  nameurl/name

  valuejdbc:as400://10.0.0.1/value
   /parameter
/ResourceParams
 /Context

 I have added this to my WEB-INF web.xml file:-

 resource-ref

 description

 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.

 /description

 res-ref-name

 jdbc/shiltonDB

 

RE: How do I install a jar file and reference it with a jsp page?

2002-12-09 Thread Hamilton, Andrew
This may not be the only or best way to do this but I put my jar files in
WEB-INF/lib directory where my webapp is.  Then in the jsp at the top I put
this line:

%@ page import=java.util.*, esg.b3.* errorPage=error.jsp %

and it works for me.

Regards,

Drew

-Original Message-
From: Brian O. Bozarth [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 10:50 AM
To: [EMAIL PROTECTED]
Subject: Q: How do I install a jar file and reference it with a jsp
page?



Having trouble using this jar file which has code for an Equifax interface
(credit check).   I've been given a jar file with sample code.   Where do I
put in the tomcat directory and how do I reference it in a jsp page?   Do I
need to do anything on the server to configure?

The package is called package com.equifax.rcas.tools;   

I am using Apache Tomcat/4.1.12

Brian Bozarth
Chief Technical Officer
Labwerks
3618 Penn Avenue
Pittsburgh, PA 15201
P. 412-621-9375
F. 412-621-6082
http://www.labwerks.com

A Marketing Communications Company






--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Apache1.3/mod_jk (unix) Tomcat 4 No processor available, rejectingthis connection

2002-12-09 Thread xchen

Hi Glenn, I had the same problem as you described for
Apache1.3/mod_jk(linux)  Tomcat 4  No processor available, rejecting
this connection. Your message is very helpful and make me feel better
about this environment. I am trying to reconfigure the environment, but
not sure what I did is right. Could you let me know if what I did is
right or not? The following are what I did for the problem following
your instruction:

1. in tomcat's server.xml, change the maxProcessors to 200 for the
non-SSL HTTP/1.1 Connector on port 8080
2. in httpd.conf of Apache 1.3, change the MaxClient to 170.

Thanks for your time and help.

Xiaofeng Chen
 University of Nebraska-Lincoln



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: How do I install a jar file and reference it with a jsp page?

2002-12-09 Thread Reynir Hübner
I would tell you to put the jar file under WEB-INF/lib/ under your webapplication. 
This means the jar file along with all it's classes and what ever is in it, is in the 
classpath. 

Now, I don't kow what is inside the jar file (might be some javabeans as well as 
servlets). 
If I was you, I would ask for documentation about the interface. 

Hope it helps
-reynir. 


 -Original Message-
 From: Brian O. Bozarth [mailto:[EMAIL PROTECTED]] 
 Sent: 9. desember 2002 15:50
 To: [EMAIL PROTECTED]
 Subject: Q: How do I install a jar file and reference it with 
 a jsp page?
 
 
 
 Having trouble using this jar file which has code for an 
 Equifax interface (credit check).   I've been given a jar 
 file with sample code.   Where do I put in the tomcat 
 directory and how do I reference it in a jsp page?   Do I 
 need to do anything on the server to configure?
 
 The package is called package com.equifax.rcas.tools;   
 
 I am using Apache Tomcat/4.1.12
 
 Brian Bozarth
 Chief Technical Officer
 Labwerks
 3618 Penn Avenue
 Pittsburgh, PA 15201
 P. 412-621-9375
 F. 412-621-6082
 http://www.labwerks.com
 
 A Marketing Communications Company
 
 
 
 
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: oracle+tomcat 4.1.x+dbcp = driverClassName is required!

2002-12-09 Thread Manavendra Gupta
Hi Pedro,

Welcome to the club - there are a number of ppl facing the exact same
problem, but are unable to find answer.

Do let me know what you did if you find a solution.

Manav.

-Original Message-
From: Pedro Salazar [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 09, 2002 9:12 PM
To: Tomcat Users List
Subject: RE: oracle+tomcat 4.1.x+dbcp = driverClassName is required!


Greetings,

Eric, I'm getting a javax.naming.NameNotFoundException: Name jdbc is
not bound in this Context exception!

I have a resource link inside my context (no resource here or
resource-ref in web.xml):

resourceLink name=jdbc/ngincaredb
global=jdbc/ngincaredb_global
type=javax.sql.DataSource /

and I'm doing a lookup in my code for jdbc/ngincaredb:

Context initCtx = new InitialContext();
Context envCtx = (Context)initCtx.lookup(java:comp/env);
this.ds = (DataSource)envCtx.lookup(/jdbc/ngincaredb);

So, what's wrong here?

thanks,
Pedro Salazar.

On Mon, 2002-12-09 at 13:06, Roberts, Eric wrote:
 Pedro,

 You need javax.sql - that is the package containing DataSource.
 Your Resource type should be: type=javax.sql.DataSource
 You need these parameters in addition to url, username and password:
   parameter
 namedriverClassName/name
 valueoracle.jdbc.driver.OracleDriver/value
   /parameter
   parameter
 namefactory/name
 valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
   /parameter

 In the Context the ResourceLink type should be:
type=javax.sql.DataSource

 You do not need any resource-ref in your web.xml - just use your
ResourceLink name as follows:
   Context ctx = new InitialContext();
   Context envCtx = (Context) ctx.lookup(java:/comp/env/);
   DataSource ds = (DataSource) envCtx.lookup(/{name_of_resource_link});

   if (ds != null) {
   DbCon = ds.getConnection();
   }

 Hope this helps.

--
pedro salazar (pt-inovacao) [EMAIL PROTECTED]
key id: D803BC61


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: How do I install a jar file and reference it with a jsp page?

2002-12-09 Thread Turner, John

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html

If it's a class or group of classes, /WEB-INF/classes.

If it's a JAR file, /WEB-INF/lib.

John

 -Original Message-
 From: Brian O. Bozarth [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 09, 2002 10:50 AM
 To: [EMAIL PROTECTED]
 Subject: Q: How do I install a jar file and reference it with a jsp
 page?
 
 
 
 Having trouble using this jar file which has code for an 
 Equifax interface (credit check).   I've been given a jar 
 file with sample code.   Where do I put in the tomcat 
 directory and how do I reference it in a jsp page?   Do I 
 need to do anything on the server to configure?
 
 The package is called package com.equifax.rcas.tools;   
 
 I am using Apache Tomcat/4.1.12
 
 Brian Bozarth
 Chief Technical Officer
 Labwerks
 3618 Penn Avenue
 Pittsburgh, PA 15201
 P. 412-621-9375
 F. 412-621-6082
 http://www.labwerks.com
 
 A Marketing Communications Company
 
 
 
 
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




REPOST: SSL and setContentType() and secure and nonsecure items

2002-12-09 Thread Chris Parker
Greetings all,

Apologies in advance for the blatant repost; I originally posted Friday
afternoon, and I'm not sure if I got lost in the 'it's Friday - let's go
home' shuffle or if nobody knows how/wants to help.

--Original Message---

No doubt there's a simple way around this, but I can't find it.  I have some
dynamic content that is being sent to the user's browser as PDF on an SSL
enabled page.  When the user goes to the page, she gets the message This
page contains both secure and nonsecure items.

I've traced the problem to this method call:
response.setContentType(application/pdf);

When I set the content type, I get the error message.  When I don't set the
content type, the user is prompted to download the file as an http download
(which is obviously correct behavior).  Is there another way to set the
header?  Do I need to encode the header into the ByteArrayOutputStream by
hand?

-- A somewhat truncated code snippet --

ByteArrayOutputStream baos = GoSomeplace.getPdfContent();
ServletOutputStream out = response.getOutputStream();
response.setContentLength( baos.size() );
response.setContentType(application/pdf); //Causes error message
baos.writeTo( out );
out.flush();



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




  1   2   3   4   >