Re: Get Virtual Path in INIT() function

2001-08-07 Thread Diu Lee Lo Mo

Sorry about that.. I just discover it now.

--- Dick Poon [EMAIL PROTECTED] wrote:
 Just a word to the sender:
 
 Would you please to respect the people of this group
 and consider to change
 your name?
 Although most of the users in this group are not
 Chinese(Cantonese) and thus
 propably do not understand the meaning of your name,
 it's still a matter of
 mutual respect.
 
 P.S. the sender name's meaning is the same as
 f***king Mother.
 
 - Original Message -
 From: Diu Lee Lo Mo [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, August 07, 2001 12:52 PM
 Subject: Re: Get Virtual Path in INIT() function
 
 
  Dear Craig,
 
That means, there is no way to get the virtual
 path
  of current project. Instead, conf/server.xml or
  WEB_INF/web.xml should be read so as to get the
 path
  configuration.
 
if project APPLE, define a docBase /APPLE/
I should do some hard coding in web.xml like
  web-app
servlet-mapping
  servlet-name
programMain
  /servlet-name
  url-pattern
/program/*
  /url-pattern
/servlet-mapping
 
servlet
 servlet-nameIndex/servlet-name
 servlet-classprogramMain/servlet-class
 init-param
param-namepath/param-name
param-value/APPLE/program//param-value
 /init-param
/servlet
  /web-app
 
  if I want to change docBase from APPLE to ORANGE,
 then
  I should also change
  param-value/APPLE/program//param-value to
  param-value/ORANGE/program//param-value
 
  It is not adaptable when docBase path change.
 
  Thx.
 
  M.T.
 
 
  --- Craig R. McClanahan [EMAIL PROTECTED]
 wrote:
  
  
   On Mon, 6 Aug 2001, Diu Lee Lo Mo wrote:
  
Dear Craig,
   
   Is that the servlet instance will be
 created
   once a
request is coming in ? The target class will
 call
init() when it is called at first time ?
   
  
   That is correct.  See the servlet spec for more
   details:
  

 http://java.sun.com/products/servlet/download.html
  
   My whole picture is :
   request - target class - init()
   
  
   Almost, but not quite, complete.  The way I
 think of
   it is:
  
 request -- servlet definition -- init() if
   needed -- service()
  
   The differences from your picture:
  
   * Which servlet definition is selected is based
 on
   the various
 servlet-mapping elements in your web.xml
 file.
   See the rules
 in the servlet spec for how this is
 determined.
  
   * There will be an instance of a servlet
   *per-servlet-definition*
 (i.e. per servlet element in your web.xml
 file),
   unless your
 servlet implements SingleThreadModel -- in
 which
   case the container
 might create more than one instance.  (Tomcat
   doesn't do this.)
  
   * The very first time a particular servlet
   definition is accessed,
 the instance will be created and init() will
 be
   called.  Alternatively,
 you can declare a load-on-startup element
 inside
   the servlet
 definition to cause the servlet to be loaded
 when
   the web application
 is first started.  This is quite handy when
 the
   initialization process
 is time consuming, because you can make it
 happen
   before the first
 request to the servlet.
  
   * For each request (including the first),
 service()
   will be called.
  
   * Tomcat supports a non-spec-defined (but very
   common) feature called
 the invoker, where you can execute a URL
 that
   includes
 /servlet/{classname}.  In essence, Tomcat
   creates a servlet
 definition on the fly the first time this is
   encountered, and the
 rest of the rules defined above are applied.
  
   Thx.
   
M.T.
   
  
   Craig
  
 
 
  __
  Do You Yahoo!?
  Make international calls for as low as $.04/minute
 with Yahoo! Messenger
  http://phonecard.yahoo.com/
 
 


__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



Virtual Host with DHCP

2001-08-07 Thread cib

Hi
I tried this message on comp.text.xml, but nobody could answer. I guess I
should have start by here. Please, give me some help.

I've got an adress via DHCP, that mean that the IP numbers change.
My localhost is cib.domain.com, but I'd like to have another xxx.domain.com
adress, to get two sites distinguished from one another.
How to do that on Tomcat4 with Cocoon2 on Win95.?

I've tried to put some stuff inside Tomcat server.xml, but first of all,
- I 'm not really sure where to put that in the file (inside or outside the
main Host /Host ), and then,
- I 'am not sure if I'm putting it the right way, and at last
- I'am not sure where to put my files, and how to request them from browser

Here is what I've put:

Host name=xxx.cib.domain.fr Context path= docBase=/ROOT/xxx1
reloadable=true debug=0 / /Host

or I also tried combination of

Host name=xxx.cib.domain.fr 
  Context path=/
   docBase=webapps/ROOT/vendo
   crossContext=false
   debug=0
   reloadable=true /
/Host

Please, if someone know how Tomcat4 works, (I 've already read the Host page
on the catalina docs) or where to find docs for really
newbies, thanks for any help.
Cib

France, Bordeaux, xml and gay pride.




Re: tomcat on mac os 10 with virtual PC

2001-08-07 Thread Pier P. Fumagalli

Adam Wildavsky at [EMAIL PROTECTED] wrote:
 
 I couldn't figure out what to set JAVA_HOME to, so I didn't set it,
 and all seems well.

/System/Library/Frameworks/JavaVM.framework/Home

 I did have to chmod 755 the *.sh scripts after installation.

? Using a zip?

 I found that I could run the scripts as a user if I wanted to listen
 on port 8080, but I had to use sudo when I changed the configuration
 file to listen on port 80. I expect the same is true on other
 platforms.

All unix based platforms.

 One puzzling aspect occurred after I first installed Tomcat on the
 default port. Internet Explorer [v5.1b1 (3408)] crashed when I tried
 to access http://localhost:8080. Changing this to
 http://localhost:8080/index.html worked, as did using the OmniWeb
 browser. Moving Tomcat to port 80 eliminated the crash entirely.

3408 doesn't give me any problem on port 80/8080/800 or whatever... Must be
some kind of weird header 3.2.3 sets and that 4.0 doesn't.

Pier




I don't see the output under Linux

2001-08-07 Thread Stefano Bonnin

I am a new linux user and I have just installed Tomcat under linux.
I have developed an application and now I am testing it.

Tomcat is installed on a linux server and I try to access it (at my
application) with a windows 98 PC.

I have introduced a System.out.println lines in my application (for the
testing phase), but I don't see theirs output.
I have tried to do this (every time that tomcat is started):

 ./tomcat start  tomcat.out

without success.

How can I do a right redirect?

Thanks in advance.

Stefano




Installation issues with Tomcat 4.0-b6 on W2K

2001-08-07 Thread Nandkumar Kesavan

Hi,

I tried installing Tomcat 4.0-b6 on my W2K laptop and had a couple of 
issues:
1. The URL http://localhost:8080 , under Netscape 6.0 does not bring up 
the  Tomcat page indicating successful installation, although the logs 
don't show anything to have failed. Also, the console shows the services 
starting up just fine.
2. The same holds true for IE5.5 , except that, on IE5.5, when I try the 
URL http://127.0.0.1:8080, it brings up the Tomcat page indicating 
successful installation.

I checked the Hosts file  under %SYSTEM_ROOT%/System32/Drivers/etc and 
it does have the right entry mapping localhost to 127.0.0.1, so how come 
I am not seeing the page come up when typing in localhost instead of 
127.0.0.1 and why doesn't it work at all for Netscape 6.0?

Btw, the only environment variables I am setting are JAVA_HOME and 
CATALINA_HOME? Do I need anything else for a successful installation?

Please let me know a workaround, if it exists, for this behavior? Any 
help would be greatly appreciated.

Thanks,
nandu

P.S: Am not yet subscribed to this list. Kindly CC me on your replies.




RE: File upload using jsp

2001-08-07 Thread TSzacon



At http://www.jspsmart.com/ there is simple and free java class with examples
(jspSmartUpload) wnich allows file uploading

Olo





Re: Package nesting levels restriction???

2001-08-07 Thread Vinay Menon

No!
That is what I thought as well. But the .class and the .java files from
jasper ARE being created!

Vinay
- Original Message -
From: Michael Wentzel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, August 06, 2001 12:15 PM
Subject: RE: Package nesting levels restriction???


  Hello,
  Has anyone faced any package nesting levels limit with
  Tomcat? I am
  running Tomcat 3.2.2 and am having problems when I exceed 7
  folders. The
  excpetion I get is
 
  Error: 500
  Location:
  /frfr-commerce/uk/co/isesolutions/apps/commerce/frfr/fulfilmen
  t/ui/thisismys
  hoppingcart.jsp
  Internal Servlet Error:
 
  org.apache.jasper.JasperException: Unable to compile class
  for JSPerror:
  Can't write:
  D:\Applications\JBoss\tomcat\work\localhost_8080%2Ffrfr-commer
  ce\uk\co\iseso
  lutions\apps\commerce\frfr\fulfilment\ui\_0002fuk_0002fco_0002
  fisesolutions_
  0002fapps_0002fcommerce_0002ffrfr_0002ffulfilment_0002fui_0002
  fthisismyshopp
  ingcart_0002ejspthisismyshoppingcart_jsp_0.class
  1 error


 This seems to me like a filename length limit in your OS.


_0002fuk_0002fco_0002fisesolutions_0002fapps_0002fcommerce_0002ffrfr_0002ffu

lfilment_0002fui_0002fthisismyshoppingcart_0002ejspthisismyshoppingcart_jsp_
 0.class

 Seems like a VERY long name.  I believe if you tried shorting each
 directory name to 1 or 2 chars and the same with the jsp name then
 try it again I bet it would work.



 ---
 Michael Wentzel
 Software Developer
 Software As We Think - http://www.aswethink.com




RE: I don't see the output under Linux

2001-08-07 Thread Loïc Lefèvre

in your server.xml file, add the attibut path to:

Logger name=tc_log
path=/tmp/tomcat.log    here
verbosityLevel = INFORMATION
/

;)

-Message d'origine-
De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
Envoyé : mardi 7 août 2001 09:39
À : [EMAIL PROTECTED]
Objet : I don't see the output under Linux


I am a new linux user and I have just installed Tomcat under linux.
I have developed an application and now I am testing it.

Tomcat is installed on a linux server and I try to access it (at my
application) with a windows 98 PC.

I have introduced a System.out.println lines in my application (for the
testing phase), but I don't see theirs output.
I have tried to do this (every time that tomcat is started):

 ./tomcat start  tomcat.out

without success.

How can I do a right redirect?

Thanks in advance.

Stefano




meta search

2001-08-07 Thread Arik Levin


I'm looking for an open source Meta Search.

If anybody out there know a good one please get back to me...


Thanks...
Arik




Supported Configuration for Tomcat and IIS on windows 2000

2001-08-07 Thread Darryl Chanin

Hi,

In your web site
(http://jakarta.apache.org/tomcat/tomcat-3.2-doc/tomcat-iis-howto.html
http://jakarta.apache.org/tomcat/tomcat-3.2-doc/tomcat-iis-howto.html ) in
the Supported Configuration section it is mentioned :
The IIS-Tomcat redirector was developed and tested on: 
WinNT4.0-i386 SP4/SP5/SP6a (it should be able to work on
other versions of the NT service pack.) and Win98 
IIS4.0 and PWS4.0 
Tomcat3.0 - Tomcat3.2

Do you plan in officially supporting Win2000 and IIS5 in the near future?

u Darryl Chanin
  Technical Manager, Extranet Tools
* Business Objects
157/159, rue Anatole France, 92309 Levallois-Perret, France
Telephone:  +33 (0)1 41 25 21 81
mailto:[EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] 

STRICTLY PERSONAL AND CONFIDENTIAL
This message may contain confidential and proprietary material for the sole
use of the intended recipient. Any review or distribution by others is
strictly prohibited.  If you are not the intended recipient please contact
the sender and delete all copies. 




Re: meta search

2001-08-07 Thread Kenneth Westelinck

Arik,

Maybe you can use HTDig, from
http://www.htdig.org/


hope this helps,

Kenneth



From: Arik Levin [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: meta search
Date: Tue, 7 Aug 2001 13:35:26 +0200


   I'm looking for an open source Meta Search.

   If anybody out there know a good one please get back to me...


   Thanks...
   Arik



_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp




RE: I don't see the output under Linux

2001-08-07 Thread Jacek Prucia


 in your server.xml file, add the attibut path to:
 
 Logger name=tc_log
 path=/tmp/tomcat.log    here
 verbosityLevel = INFORMATION
 /
 
 ;)

That's not going to help. Adding path attribute just makes Tomcat write
info to log file, but nothing more. Every damn System.out.println() call
writes to console from which Tomcat has been started. This problem is
probably more related to JVM rather than Tomcat.

-- 
Jacek Prucia
7bulls.com S.A.





Apache + Tomcat + mod_perl, Can these apps work t

2001-08-07 Thread c cw288

Hi all,

I have installed apache 1.3.19 and Tomcat on Solaris 5.8. They work fine 
together.

Now I try to install mod_perl integrated with the apache that I had 
installed it for Tomcat,

but it generates some errors indicated that can not create the following 
Makefile in the src directory:

Creating Makefile in src/support
Creating Makefile in src/os/unix
Creating Makefile in src/ap
Creating Makefile in src/main
Creating Makefile in src/modules/standard
Creating Makefile in src/modules/perl


Can Tomcat and mod_perl integrated with one Apache?

Thanks in advance.

Connie



_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp




RE: meta search

2001-08-07 Thread Arik Levin


I know this one.. 
but thanks anyway.

-Original Message-
From: Kenneth Westelinck [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 1:12 PM
To: [EMAIL PROTECTED]
Subject: Re: meta search


Arik,

Maybe you can use HTDig, from
http://www.htdig.org/


hope this helps,

Kenneth



From: Arik Levin [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: meta search
Date: Tue, 7 Aug 2001 13:35:26 +0200


   I'm looking for an open source Meta Search.

   If anybody out there know a good one please get back to me...


   Thanks...
   Arik



_
Get your FREE download of MSN Explorer at
http://explorer.msn.com/intl.asp



RE: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Holscher, David M

 
 Holscher, David M at [EMAIL PROTECTED] wrote:
 
  You're relying on a platform specific feature that is *not* in the
  spec.
 
  Putting stuff in the $CATALINA_HOME\lib directory relies on stuff that
 is
  not in the spec. Yet there is provision for that.
 
 Correct, that's why it's not advisable to put it there. $CATALINA_HOME/lib
 is there just because sometimes you want to have libraries accessible by
 all
 your web applications WITHOUT putting them in $JAVA_HOME/jre/lib/ext.

Yes, there are lots of things that are not advisable. I'm just saying that
having a way to extend the places where I look for jar files for a web-app
is no worse than existence of the $CATALINA_HOME/lib. 

 Also that location is not specified but merely a behavior of the Sun JDK
 (that had been inherited by most of the others, but not _all_ :)
 
  Also, doesn't relying on this violate your first statement about
 wouldn't
  ship a web app that relies on anything outside the war file?
 
  My original question was removed from your reply but if you go back a
  re-read it, I said I wanted to do it in my current development
 environment.
  We I release code to production it is in a self-contained war file.
 
 Yes, but at this point I don't quite get WHY you have to have a JAR file
 specifically tied to a single Web Application in a directory != from your
 WEB-INF/lib... It there a solid explanation on why you need this behavior?
 
 Pier

We have a set of jar files used by several programs which are not web
applications. We have a single web app which uses some of the jar files. It
does not make sense for the programs that are not web applications to use
jar files in the WEB-INF/lib directory nor does it make sense for the web
application to use files outside that directory. So when we build a
production release we make sure we have copies of the jar files in the right
places. However, in development when I make a change to a source file there
is much less pain involved if I don't have to make sure to copy the
resulting change to the jar file into all of the places it is needed. It is
simply easier to point the applications that need it to the central
location. Please don't answer that I should have the build script make extra
copies of the jar files (which will cause configuration management issues)
and please don't answer that the central location be the WEB-INF/lib
directory because most of our developers don't see that directory. I simply
want to know if it is possible to extend the library path for a web
application. At this point, I'm sure the answer is no.

Dave Holscher




PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Holscher, David M [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 7:51 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Moving /WEB-INF/lib or adding to it in TC 4.0


 
 Holscher, David M at [EMAIL PROTECTED] wrote:
 
  You're relying on a platform specific feature that is *not* in the
  spec.
 
  Putting stuff in the $CATALINA_HOME\lib directory relies on stuff that
 is
  not in the spec. Yet there is provision for that.
 
 Correct, that's why it's not advisable to put it there. $CATALINA_HOME/lib
 is there just because sometimes you want to have libraries accessible by
 all
 your web applications WITHOUT putting them in $JAVA_HOME/jre/lib/ext.

Yes, there are lots of things that are not advisable. I'm just saying that
having a way to extend the places where I look for jar files for a web-app
is no worse than existence of the $CATALINA_HOME/lib. 

 Also that location is not specified but merely a behavior of the Sun JDK
 (that had been inherited by most of the others, but not _all_ :)
 
  Also, doesn't relying on this violate your first statement about
 wouldn't
  ship a web app that relies on anything outside the war file?
 
  My original question was removed from your reply but if you go back a
  re-read it, I said I wanted to do it in my current development
 environment.
  We I release code to production it is in a self-contained war file.
 
 Yes, but at this point I don't quite get WHY you have to have a JAR file
 specifically tied to a single Web Application in a directory != from your
 WEB-INF/lib... It there a solid explanation on why you need this behavior?
 
 Pier

We have a set of jar files used by several programs which are not web
applications. We have a single web app which uses some of the jar files. It
does not make sense for the programs that are not web applications to use
jar files in the WEB-INF/lib directory nor does it make sense for the web
application to use files outside that directory. So when we build a
production release we make sure we have copies of the jar files in the right
places. However, in development when I make a change to a source file there
is much less pain involved if I don't have to make sure to copy the
resulting change to the jar file into all of the places it is needed. It is
simply easier to point the applications that need it to the central
location. Please don't answer that I should have the build script make extra
copies of the jar files (which will cause configuration management issues)
and please don't answer that the central location be the WEB-INF/lib
directory because most of our developers don't see that directory. I simply
want to know if it is possible to extend the library path for a web
application. At this point, I'm sure the answer is no.

Dave Holscher



PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Michael Weissenbacher [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 7:51 AM
To: '[EMAIL PROTECTED]'
Subject: RE: I don't see the output under Linux


i use to following command in startup.sh to write the output of tomcat into
a log file:

$BASEDIR/tomcat.sh start $@ /path/to/system-out.log 21

this way also the error stream goes into the same file as the stdout and
tomcat is quiet (not writing stuff to my console as it starts up).

michael

-Original Message-
From: Stefano Bonnin [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 9:39 AM
To: [EMAIL PROTECTED]
Subject: I don't see the output under Linux


I am a new linux user and I have just installed Tomcat under linux.
I have developed an application and now I am testing it.

Tomcat is installed on a linux server and I try to access it (at my
application) with a windows 98 PC.

I have introduced a System.out.println lines in my application (for the
testing phase), but I don't see theirs output.
I have tried to do this (every time that tomcat is started):

 ./tomcat start  tomcat.out

without success.

How can I do a right redirect?

Thanks in advance.

Stefano



PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Arik Levin [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 8:45 AM
To: [EMAIL PROTECTED]
Subject: RE: meta search



I know this one.. 
but thanks anyway.

-Original Message-
From: Kenneth Westelinck [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 1:12 PM
To: [EMAIL PROTECTED]
Subject: Re: meta search


Arik,

Maybe you can use HTDig, from
http://www.htdig.org/


hope this helps,

Kenneth



From: Arik Levin [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: meta search
Date: Tue, 7 Aug 2001 13:35:26 +0200


   I'm looking for an open source Meta Search.

   If anybody out there know a good one please get back to me...


   Thanks...
   Arik



_
Get your FREE download of MSN Explorer at
http://explorer.msn.com/intl.asp



PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Jacek Prucia [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 7:32 AM
To: [EMAIL PROTECTED]
Subject: RE: I don't see the output under Linux



 in your server.xml file, add the attibut path to:
 
 Logger name=tc_log
 path=/tmp/tomcat.log    here
 verbosityLevel = INFORMATION
 /
 
 ;)

That's not going to help. Adding path attribute just makes Tomcat write
info to log file, but nothing more. Every damn System.out.println() call
writes to console from which Tomcat has been started. This problem is
probably more related to JVM rather than Tomcat.

-- 
Jacek Prucia
7bulls.com S.A.




PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Kenneth Westelinck [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 7:12 AM
To: [EMAIL PROTECTED]
Subject: Re: meta search


Arik,

Maybe you can use HTDig, from
http://www.htdig.org/


hope this helps,

Kenneth



From: Arik Levin [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: meta search
Date: Tue, 7 Aug 2001 13:35:26 +0200


   I'm looking for an open source Meta Search.

   If anybody out there know a good one please get back to me...


   Thanks...
   Arik



_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp



PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Jockel, Jeff



-Original Message-
From: Beth Kelly [mailto:[EMAIL PROTECTED]]
Sent: Monday, August 06, 2001 6:19 PM
To: [EMAIL PROTECTED]
Subject: Re: JDBC Realms


Actually, I see why you would not want the passwords in memory.

Kyle Wayne Kelly
(504)391-3985
http://www.cs.uno.edu/~kkelly
- Original Message - 
From: Michael Wentzel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, August 06, 2001 12:13 PM
Subject: RE: JDBC Realms


   Advantage: You don't lose existing session data
   Disadv   : You're not actually re-authenticating
  (not really authenticating, you lost me)
 
 After looking at some code I figured something out...
 I was thinking about this architecture wrong.  Kyle was
 right just using:
 
 session.setAttribute(j_password, sPassword);
 
 will provide a hook for password changes.
 
 
 ---
 Michael Wentzel
 Software Developer
 Software As We Think - http://www.aswethink.com
 




RE: PLEASE UNSUBSCRIBE ME

2001-08-07 Thread Olivier LAUDREN

This could be found in the mail's header:
list-unsubscribe: mailto:[EMAIL PROTECTED]

-Message d'origine-
De : Jockel, Jeff [mailto:[EMAIL PROTECTED]]
Envoyé : mardi 7 août 2001 14:11
À : [EMAIL PROTECTED]
Objet : PLEASE UNSUBSCRIBE ME




-Original Message-
From: Beth Kelly [mailto:[EMAIL PROTECTED]]
Sent: Monday, August 06, 2001 6:19 PM
To: [EMAIL PROTECTED]
Subject: Re: JDBC Realms


Actually, I see why you would not want the passwords in memory.

Kyle Wayne Kelly
(504)391-3985
http://www.cs.uno.edu/~kkelly
- Original Message - 
From: Michael Wentzel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, August 06, 2001 12:13 PM
Subject: RE: JDBC Realms


   Advantage: You don't lose existing session data
   Disadv   : You're not actually re-authenticating
  (not really authenticating, you lost me)
 
 After looking at some code I figured something out...
 I was thinking about this architecture wrong.  Kyle was
 right just using:
 
 session.setAttribute(j_password, sPassword);
 
 will provide a hook for password changes.
 
 
 ---
 Michael Wentzel
 Software Developer
 Software As We Think - http://www.aswethink.com
 




tomcat default page

2001-08-07 Thread bastian . wagner

hi,

if  i link onto a directory wihtout a index.html, tomcat uses a default
page to display the containing files of the directory. is it possible to
edit this page? if yes, where can i find it?

thx

bastian




RE: Tomcat 3.2 or 4.0 standalone, which is better to use now?

2001-08-07 Thread Michael Weissenbacher

if it's for stability then coose a apache/tomcat combination. it's
definately more stable and also faster than using tomcat standalone.
i know this wasn't your question, but i definately didn't have good
experiences with tomcat standalone. i think it's main purpose is for
testing.

-Original Message-
From: Laurens Fridael [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 3:33 PM
To: Tomcat mailing list
Subject: Tomcat 3.2 or 4.0 standalone, which is better to use now?


Hi,


Which is better for standalone usage? Tomcat 3.2 or 4.0 beta6 ? Stability is
my most important consideration.

I know Tomcat 4 is still beta but I read that it already performs well. I'm
currently experimenting with a Apache/Tomcat 3.2 combination but I find the
Apache URL mapping configuration too much work.


Regards
-Laurens




Re: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Pier P. Fumagalli

Holscher, David M at [EMAIL PROTECTED] wrote:
 
 Correct, that's why it's not advisable to put it there. $CATALINA_HOME/lib
 is there just because sometimes you want to have libraries accessible by
 all your web applications WITHOUT putting them in $JAVA_HOME/jre/lib/ext.
 
 Yes, there are lots of things that are not advisable. I'm just saying that
 having a way to extend the places where I look for jar files for a web-app
 is no worse than existence of the $CATALINA_HOME/lib.

I tend to disagree with you. If you consider the fact that everything under
$JAVA_HOME/jre/lib/ext is considered trusted code by the VM when you
install a SecurityManager, while code in $CATALINA_HOME/lib is not.

$CATALINA_HOME/lib is there for a reason...

 Yes, but at this point I don't quite get WHY you have to have a JAR file
 specifically tied to a single Web Application in a directory != from your
 WEB-INF/lib... It there a solid explanation on why you need this behavior?
 
 We have a set of jar files used by several programs which are not web
 applications. We have a single web app which uses some of the jar files. It
 does not make sense for the programs that are not web applications to use
 jar files in the WEB-INF/lib directory nor does it make sense for the web
 application to use files outside that directory. So when we build a
 production release we make sure we have copies of the jar files in the right
 places. However, in development when I make a change to a source file there
 is much less pain involved if I don't have to make sure to copy the
 resulting change to the jar file into all of the places it is needed. It is
 simply easier to point the applications that need it to the central
 location. Please don't answer that I should have the build script make extra
 copies of the jar files (which will cause configuration management issues)
 and please don't answer that the central location be the WEB-INF/lib
 directory because most of our developers don't see that directory. I simply
 want to know if it is possible to extend the library path for a web
 application. At this point, I'm sure the answer is no.

Well, the answer IS of course no... :) If you imply such a configuration
mechanism (like specify a classpath for every web-application) there might
be issues from when you move stuff around (like, from your classpath, to
WEB-INF/lib), especially in terms of security and class loading issues.
I believe that it can be easily solved by putting down some symlinks in your
WEB-INF/lib, so that when you jar up the final release you don't even care
what you need to copy over or not...

Pier




Re: Virtual Host with DHCP

2001-08-07 Thread Pier P. Fumagalli

cib at [EMAIL PROTECTED] wrote:
 
 Hi
 I tried this message on comp.text.xml, but nobody could answer. I guess I
 should have start by here. Please, give me some help.
 
 I've got an adress via DHCP, that mean that the IP numbers change.
 My localhost is cib.domain.com, but I'd like to have another xxx.domain.com
 adress, to get two sites distinguished from one another.
 How to do that on Tomcat4 with Cocoon2 on Win95.?

You ask your administrator to put in a CNAME record on the DNS.

 Please, if someone know how Tomcat4 works, (I 've already read the Host page
 on the catalina docs) or where to find docs for really newbies, thanks for any
 help.

First of all you need to set up your names on your machine/dns server... Ask
your sysadm...

Pier




Re: I don't see the output under Linux

2001-08-07 Thread Stefano Bonnin

 Can you send your workers.properties file?

Yes. This is my workers.properties:

**
workers.tomcat_home=c:\jakarta-tomcat

workers.java_home=c:\jdk1.2.2

ps=\

worker.list=ajp12, ajp13

worker.ajp12.port=8007
worker.ajp12.host=localhost
worker.ajp12.type=ajp12
worker.ajp12.lbfactor=1

worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
worker.ajp13.lbfactor=1

worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp12, ajp13

worker.inprocess.type=jni

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)classes

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jaxp.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)parser.jar

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jasper.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)servlet.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)webserver.jar

worker.inprocess.class_path=$(workers.java_home)$(ps)lib$(ps)tools.jar

worker.inprocess.cmd_line=-config
worker.inprocess.cmd_line=$(workers.tomcat_home)/conf/jni_server.xml
worker.inprocess.cmd_line=-home
worker.inprocess.cmd_line=$(workers.tomcat_home)

worker.inprocess.jvm_lib=$(workers.java_home)$(ps)jre$(ps)bin$(ps)classic$(p
s)jvm.dll


#
# Setting the place for the stdout and stderr of tomcat
#
worker.inprocess.stdout=$(workers.tomcat_home)$(ps)inprocess.stdout
worker.inprocess.stderr=$(workers.tomcat_home)$(ps)inprocess.stderr



worker.inprocess.sysprops=tomcat.home=$(workers.tomcat_home)



Thanks (I wait your help).

- Original Message -
From: Loïc Lefèvre [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 3:07 PM
Subject: RE: I don't see the output under Linux



 -Message d'origine-
 De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
 Envoyé : mardi 7 août 2001 14:47
 À : [EMAIL PROTECTED]
 Objet : Re: I don't see the output under Linux


 Yes, if I add this attribute the tomcat.log (when I start tomcat) become:

 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /examples )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /admin )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /cocoon )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx(  )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /test )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /Cocoon )

 but no message other this are printed on this file.
 (All System.out.println are not printed!!)

 Thanks.

 - Original Message -
 From: Loïc Lefèvre [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, August 07, 2001 12:23 PM
 Subject: RE: I don't see the output under Linux


  in your server.xml file, add the attibut path to:
 
  Logger name=tc_log
  path=/tmp/tomcat.log    here
  verbosityLevel = INFORMATION
  /
 
  ;)
 
  -Message d'origine-
  De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
  Envoyé : mardi 7 août 2001 09:39
  À : [EMAIL PROTECTED]
  Objet : I don't see the output under Linux
 
 
  I am a new linux user and I have just installed Tomcat under linux.
  I have developed an application and now I am testing it.
 
  Tomcat is installed on a linux server and I try to access it (at my
  application) with a windows 98 PC.
 
  I have introduced a System.out.println lines in my application (for the
  testing phase), but I don't see theirs output.
  I have tried to do this (every time that tomcat is started):
 
   ./tomcat start  tomcat.out
 
  without success.
 
  How can I do a right redirect?
 
  Thanks in advance.
 
  Stefano
 





Getting the user environment variable::Need help

2001-08-07 Thread Nilanjan Das

Hi,

I am on HP-UX and trying to access one user environment varaible from
the Java code using
System.getProperty() method but it is returning NULL. Can anyone point
out why? This is what I did:

$export TEST=testing
$echo $TEST
testing

But when I execute System.getProperty(TEST) from my code, it returns
NULL.

Can any of you help?

Thanks,
Nilanjan





Re: Tomcat 3.2 or 4.0 standalone, which is better to use now?

2001-08-07 Thread Pier P. Fumagalli

Laurens Fridael at [EMAIL PROTECTED] wrote:
 
 Hi,
 
 Which is better for standalone usage? Tomcat 3.2 or 4.0 beta6 ? Stability is
 my most important consideration.
 I know Tomcat 4 is still beta but I read that it already performs well.

Without ANY whatsoever doubt... 4.0.

 I'm currently experimenting with a Apache/Tomcat 3.2 combination but I find
 the Apache URL mapping configuration too much work.

Try mod_webapp... It's a one-line configuration solution...

Pier




Running Tomcat as a Windows service

2001-08-07 Thread Bryan Hendricks

Hello,

I installed Tomcat as a Windows (NT) service using jk_nt_service and set the service's 
startup type as automatic, but when I log off, the service shuts down.  Is this a bug 
(in Tomcat, jk_nt_service, or the JRE) and, if so, do you know if the problem is being 
addressed?  If it's not a bug, are there instructions that outline additional steps 
required to keep the service running?

Thank you.



How to disable servlet response buffering ?

2001-08-07 Thread Hector Adolfo Alonso

Hi:
   does anybody knows how to disable servlet response buffering ?
I've tried ServletResponse.setBufferSize(0), but it doesn't work.
It seems that the BufferedServletOutputStream cannot be lesser
than 8192 bytes !
   Thanks in advance.

Hector Adolfo Alonso
Consist Teleinformatica S. A.




RE: I don't see the output under Linux

2001-08-07 Thread Loïc Lefèvre

Okay, this file stands in the conf directory of Tomcat on your LINUX server?
If the answer is true, replace
workers.tomcat_home=c:\jakarta-tomcat

workers.java_home=c:\jdk1.2.2

ps=\

with the good parameters:

especially:  ps=/ (Path separator for Linux is equals to / not \)

Try and tell me...

-Message d'origine-
De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
Envoyé : mardi 7 août 2001 16:04
À : [EMAIL PROTECTED]
Objet : Re: I don't see the output under Linux


 Can you send your workers.properties file?

Yes. This is my workers.properties:

**
workers.tomcat_home=c:\jakarta-tomcat

workers.java_home=c:\jdk1.2.2

ps=\

worker.list=ajp12, ajp13

worker.ajp12.port=8007
worker.ajp12.host=localhost
worker.ajp12.type=ajp12
worker.ajp12.lbfactor=1

worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
worker.ajp13.lbfactor=1

worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp12, ajp13

worker.inprocess.type=jni

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)classes

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jaxp.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)parser.jar

worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)jasper.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)servlet.jar
worker.inprocess.class_path=$(workers.tomcat_home)$(ps)lib$(ps)webserver.jar

worker.inprocess.class_path=$(workers.java_home)$(ps)lib$(ps)tools.jar

worker.inprocess.cmd_line=-config
worker.inprocess.cmd_line=$(workers.tomcat_home)/conf/jni_server.xml
worker.inprocess.cmd_line=-home
worker.inprocess.cmd_line=$(workers.tomcat_home)

worker.inprocess.jvm_lib=$(workers.java_home)$(ps)jre$(ps)bin$(ps)classic$(p
s)jvm.dll


#
# Setting the place for the stdout and stderr of tomcat
#
worker.inprocess.stdout=$(workers.tomcat_home)$(ps)inprocess.stdout
worker.inprocess.stderr=$(workers.tomcat_home)$(ps)inprocess.stderr



worker.inprocess.sysprops=tomcat.home=$(workers.tomcat_home)



Thanks (I wait your help).

- Original Message -
From: Loïc Lefèvre [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 3:07 PM
Subject: RE: I don't see the output under Linux



 -Message d'origine-
 De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
 Envoyé : mardi 7 août 2001 14:47
 À : [EMAIL PROTECTED]
 Objet : Re: I don't see the output under Linux


 Yes, if I add this attribute the tomcat.log (when I start tomcat) become:

 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /examples )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /admin )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /cocoon )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx(  )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /test )
 2001-08-07 01:40:57 - ContextManager: Adding context Ctx( /Cocoon )

 but no message other this are printed on this file.
 (All System.out.println are not printed!!)

 Thanks.

 - Original Message -
 From: Loïc Lefèvre [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, August 07, 2001 12:23 PM
 Subject: RE: I don't see the output under Linux


  in your server.xml file, add the attibut path to:
 
  Logger name=tc_log
  path=/tmp/tomcat.log    here
  verbosityLevel = INFORMATION
  /
 
  ;)
 
  -Message d'origine-
  De : Stefano Bonnin [mailto:[EMAIL PROTECTED]]
  Envoyé : mardi 7 août 2001 09:39
  À : [EMAIL PROTECTED]
  Objet : I don't see the output under Linux
 
 
  I am a new linux user and I have just installed Tomcat under linux.
  I have developed an application and now I am testing it.
 
  Tomcat is installed on a linux server and I try to access it (at my
  application) with a windows 98 PC.
 
  I have introduced a System.out.println lines in my application (for the
  testing phase), but I don't see theirs output.
  I have tried to do this (every time that tomcat is started):
 
   ./tomcat start  tomcat.out
 
  without success.
 
  How can I do a right redirect?
 
  Thanks in advance.
 
  Stefano
 





Re: tomcat on mac os 10 with virtual PC

2001-08-07 Thread Adam Wildavsky

At 8:28 AM +0100 8/7/01, Pier P. Fumagalli wrote:
Adam Wildavsky at [EMAIL PROTECTED] wrote:

  I couldn't figure out what to set JAVA_HOME to, so I didn't set it,
  and all seems well.

/System/Library/Frameworks/JavaVM.framework/Home

Thanks! That will come in handy.

   I did have to chmod 755 the *.sh scripts after installation.

? Using a zip?

Doh! Yes, I used the zip downloaded from the Tomcat page, but I 
allowed StuffIt Expander to extract the files. Next time I'll use 
unzip from the command line.

AW



Tomcat Connection Problem

2001-08-07 Thread nilesh patankar

Hi,
I have a serious problem, sometimes my JSPs stop
getting rendered while static pages are working fine.
I am using Apache 1.3.20 with Tomcat 3.2.2 on Linux
Kernel 2.4.2-2 for a production server. When I
encountered the problem for the first time I thought
that it was the java heap problem so now I am starting
Tomcat with JVM parameters 96MB initial heap size and
256MB max size. Things were working fine for a while
but it again happened, now I am constantly monitoring
my application. My server has 512MB RAM which seems OK
for the hosted application. But even with a small load
this error happened. My static pages keep getting
served properly but JSPs don't get rendered at all and
after a restart things get fine again. When I examined
the mod_jk.log the following errors appear when the
JSPs stopped getting served. Please help me with some
solution whereby I don't have to keep monitoring and
restarting apache and tomcat whenever such errors
occur, I am always restarting apache after a tomcat
restart which was mentioned in one of the mailing
lists as a possible reason for the problem. Till now I
am not even sure if this is a JVM problem or what???
Excerpt from mod_jk.log :
  
[jk_ajp13_worker.c (325)]: Error
ajp13_process_callback - write failed
[jk_ajp13_worker.c (203)]: connection_tcp_get_message:
Error - jk_tcp_socket_recvfull failed
[jk_ajp13_worker.c (621)]: Error reading request
[jk_ajp13_worker.c (203)]: connection_tcp_get_message:
Error - jk_tcp_socket_recvfull failed
[jk_ajp13_worker.c (621)]: Error reading request
[jk_ajp13_worker.c (203)]: connection_tcp_get_message:
Error - jk_tcp_socket_recvfull failed
[jk_ajp13_worker.c (621)]: Error reading request 
 
Thanking you in anticipation.
 
Nilesh

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



RE: Getting the user environment variable::Need help

2001-08-07 Thread William Kaufman

1) This isn't a Tomcat question: if you'd done the same in a java
application, you'd have found the same thing.  There are forums, newsgroups,
and mailing lists for Java questions.

2) You're confusing environment variables with properties.  Properties are
defined either by loading them from a properties file, or by specifying them
on java's command line (with -D).

3) There is a method, System.getenv(), to get environment variables, but
it's deprecated (the whole concept of environment variables is incredibly
OS-specific).  So you really _should_ be using properties, or
context-param elements defined in your application's web.xml.  Look at
java.util.Properties for the former, and the servlet spec for the latter.

-- Bill K. 

 -Original Message-
 From: Nilanjan Das [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 7:12 AM
 To: tomcat jakarta
 Subject: Getting the user environment variable::Need help
 
 
 Hi,
 
 I am on HP-UX and trying to access one user environment varaible from
 the Java code using
 System.getProperty() method but it is returning NULL. Can anyone point
 out why? This is what I did:
 
 $export TEST=testing
 $echo $TEST
 testing
 
 But when I execute System.getProperty(TEST) from my code, it returns
 NULL.
 
 Can any of you help?
 
 Thanks,
 Nilanjan
 
 



RE: Running Tomcat as a Windows service

2001-08-07 Thread Randy Layman


This is a (very widely discussed) bug in Sun's 1.3 JVM for NT.
There is a fix in 1.3.1 and the 1.2.x JVMs did not possess this bug.  You
can search the mailing list archives, or Sun's BugParade, for more
information.

Randy


 -Original Message-
 From: Bryan Hendricks [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 10:20 AM
 To: '[EMAIL PROTECTED]'
 Subject: Running Tomcat as a Windows service
 
 
 Hello,
 
 I installed Tomcat as a Windows (NT) service using 
 jk_nt_service and set the service's startup type as 
 automatic, but when I log off, the service shuts down.  Is 
 this a bug (in Tomcat, jk_nt_service, or the JRE) and, if so, 
 do you know if the problem is being addressed?  If it's not a 
 bug, are there instructions that outline additional steps 
 required to keep the service running?
 
 Thank you.
 



AW: Antwort: Re: tomcat default page

2001-08-07 Thread Kai Kaapke

try this:

welcome-file-list
welcome-file
your_own_welcome_file.html

a_file_for_case_your_own_welcome_file_does_not_exist_and_to_prevent_tomcat_f
rom_listing_the_directory.html
/welcome-file
welcome-file-list

in your server.xml


Kai Kaapke

jPartner Software GmbH  Co. KG
   - Ihre Java Partner -




-Ursprungliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Gesendet: Dienstag, 7. August 2001 14:56
An: [EMAIL PROTECTED]
Betreff: Antwort: Re: tomcat default page


i know about that...

but what if there is not any of this default files in the directory. in
this case tomcat automatically displays all the files in the directory. my
question is how to manipulate this, how to design my own tomcat default
page

know what i mean ?



 --
  Externe MailDavid Treves [EMAIL PROTECTED]07.08.2001
  15:41
 --




An:   [EMAIL PROTECTED]
cc:

Thema:Re: tomcat default page

in server.xml file you will find a list of the default names

David.

- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 2:29 PM
Subject: tomcat default page


 hi,

 if  i link onto a directory wihtout a index.html, tomcat uses a default
 page to display the containing files of the directory. is it possible to
 edit this page? if yes, where can i find it?

 thx

 bastian









RE: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Holscher, David M

  Correct, that's why it's not advisable to put it there.
 $CATALINA_HOME/lib
  is there just because sometimes you want to have libraries accessible
 by
  all your web applications WITHOUT putting them in
 $JAVA_HOME/jre/lib/ext.
 
  Yes, there are lots of things that are not advisable. I'm just saying
 that
  having a way to extend the places where I look for jar files for a web-
 app
  is no worse than existence of the $CATALINA_HOME/lib.
 
 I tend to disagree with you. If you consider the fact that everything
 under
 $JAVA_HOME/jre/lib/ext is considered trusted code by the VM when you
 install a SecurityManager, while code in $CATALINA_HOME/lib is not.
 
 $CATALINA_HOME/lib is there for a reason...

I'm not suggesting putting stuff in the ext directory. I'm suggesting adding
stuff to the classpath for a single web application and treat it as if it
were in the WEB-INF/lib directory.

  Yes, but at this point I don't quite get WHY you have to have a JAR
 file
  specifically tied to a single Web Application in a directory != from
 your
  WEB-INF/lib... It there a solid explanation on why you need this
 behavior?
 
  We have a set of jar files used by several programs which are not web
  applications. We have a single web app which uses some of the jar files.
 It
  does not make sense for the programs that are not web applications to
 use
  jar files in the WEB-INF/lib directory nor does it make sense for the
 web
  application to use files outside that directory. So when we build a
  production release we make sure we have copies of the jar files in the
 right
  places. However, in development when I make a change to a source file
 there
  is much less pain involved if I don't have to make sure to copy the
  resulting change to the jar file into all of the places it is needed. It
 is
  simply easier to point the applications that need it to the central
  location. Please don't answer that I should have the build script make
 extra
  copies of the jar files (which will cause configuration management
 issues)
  and please don't answer that the central location be the WEB-INF/lib
  directory because most of our developers don't see that directory. I
 simply
  want to know if it is possible to extend the library path for a web
  application. At this point, I'm sure the answer is no.
 
 Well, the answer IS of course no... :) If you imply such a configuration
 mechanism (like specify a classpath for every web-application) there
 might

Thanks.

 be issues from when you move stuff around (like, from your classpath, to
 WEB-INF/lib), especially in terms of security and class loading issues.
 I believe that it can be easily solved by putting down some symlinks in
 your
 WEB-INF/lib, so that when you jar up the final release you don't even
 care
 what you need to copy over or not...
 
 Pier

We're using Windows (yes too bad for us) so symlinks are out. I'll probably
just add a build target to make copies of the required jar files in the
WEB-INF\lib directory.

Dave Holscher




RE: Running Tomcat as a Windows service

2001-08-07 Thread Ronald G. Louzon

If I remember correctly, this is due to a bug in the JDK and you can read
all about it in the jakarta tomcat-user archives as well as in the bug
reports on the Sun site (www.javasoft.com).  I used the Alexandria Software
companies Java service wrapper JavaService.exe .  It is free, distributable
and it works well.  I am sure there are other service wrappers out there
too.  



-Original Message-
From: Bryan Hendricks [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 10:20 AM
To: '[EMAIL PROTECTED]'
Subject: Running Tomcat as a Windows service


Hello,

I installed Tomcat as a Windows (NT) service using jk_nt_service and set the
service's startup type as automatic, but when I log off, the service shuts
down.  Is this a bug (in Tomcat, jk_nt_service, or the JRE) and, if so, do
you know if the problem is being addressed?  If it's not a bug, are there
instructions that outline additional steps required to keep the service
running?

Thank you.



Cookie name is a reserved token

2001-08-07 Thread Gareth Coltman

I am  getting the following error trying to load test my app.

I am looked at the bug database:

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=231

and it claims this bug is fixed in Tomcat 3.3 

I am using tomcat 3.3/mod_jk with the pooled tcp connector,and I still get it.

I have no idea why? Could be it be a threading issue? The server seems to have enough 
free resources...

Please help




java.lang.IllegalArgumentException: Cookie name
Path is a reserved token
at javax.servlet.http.Cookie.init(Cookie.java:185)
at
org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
at
org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:494)
at
org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSess
ionInterceptor.java:143)
at
org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:820
)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:77
1)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection
(Ajp12ConnectionHandler.java:166)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)

-- 
Mike Scott
Head of Technology Operations
rightmove.co.uk
Tel: 020 7821 9661  Mobile: 07941 576326  Email: [EMAIL PROTECTED] 



Re: tomcat on mac os 10 with virtual PC

2001-08-07 Thread Pier P. Fumagalli

Adam Wildavsky at [EMAIL PROTECTED] wrote:

 I did have to chmod 755 the *.sh scripts after installation.
 
 ? Using a zip?
 
 Doh! Yes, I used the zip downloaded from the Tomcat page, but I
 allowed StuffIt Expander to extract the files. Next time I'll use
 unzip from the command line.

Nah, download the .tar.gz one and use gnutar -zxvf. The .ZIP format doesn't
contain information such as file permissions (the ones changed by chmod)

Pier




RE: Running Tomcat as a Windows service

2001-08-07 Thread Bryan Hendricks

Hello,

Please ignore my last post.  I found the following resource, which helped me to 
resolve the problem (I needed to include -Xrs on the Java command line):

http://www.jguru.com/faq/view.jsp?EID=131217

Thanks.

-Original Message-
From: Bryan Hendricks 
Sent: Tuesday, August 07, 2001 10:20 AM
To: '[EMAIL PROTECTED]'
Subject: Running Tomcat as a Windows service


Hello,

I installed Tomcat as a Windows (NT) service using jk_nt_service and set the service's 
startup type as automatic, but when I log off, the service shuts down.  Is this a bug 
(in Tomcat, jk_nt_service, or the JRE) and, if so, do you know if the problem is being 
addressed?  If it's not a bug, are there instructions that outline additional steps 
required to keep the service running?

Thank you.



PLEASE - HELP PLEASE

2001-08-07 Thread Nance, Michael

This is a repostMy connectors won't start this is from my server.xml

Connector className=org.apache.tomcat.service.PoolTcpConnector
Parameter name=handler
value=org.apache.tomcat.service.connector.Ajp12ConnectionHandler/
Parameter name=port value=8007/
Parameter name=max_threads value=500/
Parameter name=max_spare_threads value=200/
Parameter name=min_spare_threads value=100 /
/Connector

Connector className=org.apache.tomcat.service.PoolTcpConnector
   Parameter name=handler
value=org.apache.tomcat.service.connector.Ajp13ConnectionHandler/
   Parameter name=port value=8009/
   Parameter name=max_threads value=500/
   Parameter name=max_spare_threads value=200/
   Parameter name=min_spare_threads value=100 /
/Connector

Context path= docBase=../../../../src/public_html debug=0
reloadable=true 
/Context





Second

are dir structure is something like this

../src/common/...  path to all classes etc
../src/public_html/..   path to all jsp's

in my server.xml I have a line
Context path= docBase=.. /src/public_html ...


I believe that will take care of my jsps but not a path to my Servlets
How can I fix this?

Thanks




Re: Cookie name is a reserved token

2001-08-07 Thread Fernando_Salazar


Does your cookie have a name that corresponds to a Java language token, or
is one of the following:

if (!isToken(name)
  || name.equalsIgnoreCase(Comment)  // rfc2019
  || name.equalsIgnoreCase(Discard)  // 2019++
  || name.equalsIgnoreCase(Domain)
  || name.equalsIgnoreCase(Expires)  // (old cookies)
  || name.equalsIgnoreCase(Max-Age)  // rfc2019
  || name.equalsIgnoreCase(Path)
  || name.equalsIgnoreCase(Secure)
  || name.equalsIgnoreCase(Version)

If so, you are supposed to be getting this exception -- the fix is to use a
different name.

- Fernando



|+
||  Gareth Coltman  |
||  gareth_coltman@majorb|
||  and.co.uk|
|||
||  08/07/2001 11:03 AM   |
||  Please respond to |
||  tomcat-user   |
|||
|+
  
---|
  |
   |
  |  To: [EMAIL PROTECTED]  
   |
  |  cc: (bcc: Fernando Salazar/CAM/Lotus) 
   |
  |  Subject: Cookie name is a reserved token  
   |
  
---|




I am  getting the following error trying to load test my app.

I am looked at the bug database:

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=231

and it claims this bug is fixed in Tomcat 3.3

I am using tomcat 3.3/mod_jk with the pooled tcp connector,and I still get
it.

I have no idea why? Could be it be a threading issue? The server seems to
have enough free resources...

Please help




java.lang.IllegalArgumentException: Cookie name
Path is a reserved token
at javax.servlet.http.Cookie.init(Cookie.java:185)
at
org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
at
org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:494)
at
org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSess

ionInterceptor.java:143)
at
org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:820

)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:77

1)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection

(Ajp12ConnectionHandler.java:166)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)

--
Mike Scott
Head of Technology Operations
rightmove.co.uk
Tel: 020 7821 9661  Mobile: 07941 576326  Email: [EMAIL PROTECTED]








RE: Getting the user environment variable::Need help

2001-08-07 Thread Tim O'Neil

That said, do this:

Properties props = System.getProperties();
props.put(MYVAR, MYVALUE);
System.setProperties(props);

Then later on in your program you can get the value
to your hearts content. Or even in another class or
package.

Or use a wrapper to load shell variables. But if all
you want to do load your own defined variables use the
above code.

At 07:33 AM 8/7/2001, you wrote:
1) This isn't a Tomcat question: if you'd done the same in a java
application, you'd have found the same thing.  There are forums, newsgroups,
and mailing lists for Java questions.

2) You're confusing environment variables with properties.  Properties are
defined either by loading them from a properties file, or by specifying them
on java's command line (with -D).

3) There is a method, System.getenv(), to get environment variables, but
it's deprecated (the whole concept of environment variables is incredibly
OS-specific).  So you really _should_ be using properties, or
context-param elements defined in your application's web.xml.  Look at
java.util.Properties for the former, and the servlet spec for the latter.

 -- Bill K.

  -Original Message-
  From: Nilanjan Das [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 7:12 AM
  To: tomcat jakarta
  Subject: Getting the user environment variable::Need help
 
 
  Hi,
 
  I am on HP-UX and trying to access one user environment varaible from
  the Java code using
  System.getProperty() method but it is returning NULL. Can anyone point
  out why? This is what I did:
 
  $export TEST=testing
  $echo $TEST
  testing
 
  But when I execute System.getProperty(TEST) from my code, it returns
  NULL.
 
  Can any of you help?
 
  Thanks,
  Nilanjan
 
 




Tomcat/4.0-b6: ERROR reading java.io.FileInputStream

2001-08-07 Thread Cyril Bouteille

Hello,

Apologies for the repost, but I'm still having my Apache Tomcat/4.0-b6
error:
ERROR reading java.io.FileInputStream@fa6f
At Line 25 /web-app/servlet/ 
and I would really appreciate some help.

Could someone please tell me what this error message mean?
If not, can I hope for the next version of Tomcat/4.0 to be more
explicit?

Thanks,


Hi,

I installed Tomcat/4.0-b6 and tried to set it up in our environment, but
I get a startup error:

Starting Tomcat with -server -ms128m -mx512m
-Djava.util.logging.config.file=/export/home/cyril/p4/phoenix/main/deploy/dev/logging.properties
-cp
/export/home/cyril/p4/java/sunos-sparc/1.4b/lib/tools.jar:/export/home/cyril/p4/apache/tomcat/4.0b6/bin/bootstrap.jar
-Dcatalina.home=/export/home/cyril/p4/apache/tomcat/4.0b6
-Dhotwire.props=/export/home/cyril/p4/phoenix/main/deploy/dev/hotwire.view.props
-f /export/home/cyril/p4/phoenix/main/deploy/dev/tomcat/conf/server.xml
Starting service Tomcat-Standalone
Apache Tomcat/4.0-b6
ERROR reading java.io.FileInputStream@fa6f
At Line 25 /web-app/servlet/ 

I believe this error refers to the first servlet node in my web.xml,
but I don't find anything wrong with it and am not sure what this error
message means.

Any idea what is configured wrong?
I attach to this message my web.xml and server.xml file.

Thanks,

?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/dtd/web-app_2_3.dtd;

web-app

  !-- Mappings in this file are the defaults for all Contexts --

  !-- The default servlet that serves static resources --
  servlet
servlet-namedefault/servlet-name
servlet-classorg.apache.catalina.servlets.DefaultServlet/servlet-class
init-param
  param-namedebug/param-name
  param-value0/param-value
/init-param
init-param
  param-namelistings/param-name
  param-valuetrue/param-value
/init-param
load-on-startup1/load-on-startup
  /servlet

  !-- The invoker servlet that executes non-registered servlets --
  servlet
servlet-nameinvoker/servlet-name
servlet-classorg.apache.catalina.servlets.InvokerServlet/servlet-class
init-param
  param-namedebug/param-name
  param-value0/param-value
/init-param
load-on-startup2/load-on-startup
  /servlet

  !-- The JSP page compiler and execution servlet --
  servlet
servlet-namejsp/servlet-name
servlet-classorg.apache.jasper.servlet.JspServlet/servlet-class
init-param
  !-- An alternate java encoding --
  param-namejavaEncoding/param-name
  param-valueUTF-8/param-value
/init-param
init-param
  !-- Levels: FATAL ERROR WARNING INFORMATION DEBUG --
  param-namelogVerbosityLevel/param-name
  param-valueWARNING/param-value
/init-param
load-on-startup4/load-on-startup
  /servlet

  servlet
servlet-namesystem/servlet-name
servlet-classhotwire.view.web.servlet.SystemServlet/servlet-class
load-on-startup1/load-on-startup
  /servlet

  servlet
servlet-namecontroller/servlet-name
servlet-classhotwire.view.web.servlet.ControllerServlet/servlet-class
load-on-startup2/load-on-startup
  /servlet
  
  !-- The mappings for the servlets --

  servlet-mapping
servlet-namedefault/servlet-name
url-pattern//url-pattern
  /servlet-mapping
  servlet-mapping
servlet-namejsp/servlet-name
url-pattern/jsp/*/url-pattern
/servlet-mapping
  servlet-mapping
servlet-namesystem/servlet-name
url-pattern/system/url-pattern
  /servlet-mapping
  servlet-mapping
servlet-namecontroller/servlet-name
url-pattern*.jsp/url-pattern
  /servlet-mapping
 
  !-- Set the default session timeout (in seconds) --
  session-config
session-timeout30/session-timeout
  /session-config

  !-- Establish the default list of welcome files --
  welcome-file-list
welcome-fileindex.html/welcome-file
welcome-fileindex.jsp/welcome-file
  /welcome-file-list

  error-page
error-code404/error-code
location/jsp/error.jsp/location
  /error-page

  taglib
taglib-urihttp://www.hotwire.com/taglib-1.0/taglib-uri
taglib-location/WEB-INF/hotwire.tld/taglib-location
  /taglib

/web-app


!-- Example Server Configuration File --
!-- Note that component elements are nested corresponding to their
 parent-child relationships with each other --

!-- A Server is a singleton element that represents the entire JVM,
 which may contain one or more Service instances.  The Server
 listens for a shutdown command on the indicated port.

 Note:  A Server is not itself a Container, so you may not
 define subcomponents such as Valves or Loggers at this level.
 --

Server port=8005 shutdown=SHUTDOWN debug=0


  !-- A Service is a collection of one or more Connectors that share
   a single Container (and therefore the web applications visible
   within that Container).  Normally, that Container is an Engine,
   but this is not required.

   

Servlet/ Database Conenction Persists Question

2001-08-07 Thread A.L.

I have developed a servlet web application which
connects to a database to retrieve information.  I
noticed that if within my servlet I destroy the
connection to the database there is no way to
reconnect to the database .  In other words I need to
keep my connection to the database at all times that
tomcat is up.  My questions include:

 Is this correct that there is no way to reconnect to
the database?  If this is not correct, how does one
reconnect, and or reinitialize the servlet?
 Is keeping the persistent connection to the database
a heavy burden on tomcat?  In other words, is it o.k.
to design an application which never releases its
conenction to the database?
 

  I don't believe my question pertains specifically to
Tomcat, so I was wondering whether or not any of you
knew where there are list servers which deal with
servlets in general.

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



Re: Package nesting levels restriction???

2001-08-07 Thread Vinay Menon

Hello,
Yes. Checked the file. It looks good. The .class file looks good as
well. Which is surprising why it displays a can't write file error! After
writing it! I am running Tomcat 3.2.2 on Win2kProf, using JDK1.3.1 and have
tried this without Apache [and with Apache 1.3.20].
Looks like one for the code doctor! I'm probably just going to look at
the tomcat source code now.

Thanks!

Vinay

- Original Message -
From: Michael Wentzel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 1:11 PM
Subject: RE: Package nesting levels restriction???


  No!
  That is what I thought as well. But the .class and the
  .java files from
  jasper ARE being created!

 Have you gone through the java code generated and looked
 for any suspicious code?

 I tried creating a file located at /admin/1/2/3/4/5/6/7/index.jsp and the
 page loaded correctly.

 What version of Tomcat, OS, are you using Apache or IIS, what JVM...?


 ---
 Michael Wentzel
 Software Developer
 Software As We Think - http://www.aswethink.com




Can't get the webpages, although can ping the server

2001-08-07 Thread JIAN XU

I installed a Tomcat server in a WINDOWS 2000 warkstation 
using part 8080.  
I can access the webpages through the computer in the same 
office. 
But I can't get the webpages from other computers,  
even if I can ping the WINDOWS 2000 warkstation from them. 
There should be no firewall exist.
I used http://xxx.xxx.xxx.xxx:8080 to access.  
please help.Thanks!  




Re: tomcat apache

2001-08-07 Thread Nikola Milutinovic

- Original Message -
From: alexus [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, August 03, 2001 8:05 PM
Subject: Re: tomcat  apache


 where would i find

 mod_jserv (i hope its not same thing as jserv)
 mod_jk
 and mod_webapp?

mod_jk and mod_jserv come with Tomcat source, under ./src/native/jk and
./src/native/jserv

Nix.




IllegalStateException: Can't happen

2001-08-07 Thread Terry Westley

I know this is a repeat.  The archives and FAQ offer explanations, but
not much help with eliminating this intermittent error.

I'm using Tomcat 3.2.1 on WinXP Pro RC2 with MS IE6.  Should I move on to
Tomcat 3.2.3 or 4.0?  Will that help?  As noted previously, stopping and
restarting tomcat makes the problem go away for awhile, until I make some
change to a servlet.

Although I have no way of knowing for sure, I hope it's not WinXP.  So far,
the beta and RC1 haven't been a problem.

--
Terry Westley
[EMAIL PROTECTED]

--
Error: 500
Location: /sigada2001/index.html
Internal Servlet Error:

java.lang.IllegalStateException: Can't happen - classname is null, who added this ?
at org.apache.tomcat.core.ServletWrapper.loadServlet(ServletWrapper.java:261)
at org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:289)
at org.apache.tomcat.core.Handler.service(Handler.java:254)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at 
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at 
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)





unsubscribe!!!

2001-08-07 Thread matt mills

i've sent a few unsubscribe emails to the tomcat-user unsubscribe address to 
no avail.  unsubscribe me!!!


_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp




RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread William Kaufman

 I have developed a servlet web application which
 connects to a database to retrieve information.  I
 noticed that if within my servlet I destroy the
 connection to the database there is no way to
 reconnect to the database .

Maybe this is a JSP thing (I'm not too familiar with those), and JSPs have
some weird JDBC cover methods.  But you _should_ be able to disconnect, by
calling Connection.close(); and to reconnect, the same way you connected the
first time.

Why can't you reconnect?  Are you getting an exception from
DriverManager.getConnection()?

  Is keeping the persistent connection to the database
 a heavy burden on tomcat?

Persistent connections aren't a burden on Tomcat, but might be on your
database, especially if the modifications aren't committed immediately.  You
should always try to close connections (and other resources) if you don't
think you'll be using it again in a few seconds.

   I don't believe my question pertains specifically to
 Tomcat, so I was wondering whether or not any of you
 knew where there are list servers which deal with
 servlets in general.

This mailing list is fine for general servlet questions.  But this seems to
be a JDBC question,...

-- Bill K. 

 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 9:07 AM
 To: [EMAIL PROTECTED]
 Subject: Servlet/ Database Conenction Persists Question
 
 
 I have developed a servlet web application which
 connects to a database to retrieve information.  I
 noticed that if within my servlet I destroy the
 connection to the database there is no way to
 reconnect to the database .  In other words I need to
 keep my connection to the database at all times that
 tomcat is up.  My questions include:
 
  Is this correct that there is no way to reconnect to
 the database?  If this is not correct, how does one
 reconnect, and or reinitialize the servlet?
  Is keeping the persistent connection to the database
 a heavy burden on tomcat?  In other words, is it o.k.
 to design an application which never releases its
 conenction to the database?
  
 
   I don't believe my question pertains specifically to
 Tomcat, so I was wondering whether or not any of you
 knew where there are list servers which deal with
 servlets in general.
 
 __
 Do You Yahoo!?
 Make international calls for as low as $.04/minute with 
 Yahoo! Messenger
 http://phonecard.yahoo.com/
 



Re: Getting the user environment variable::Need help

2001-08-07 Thread Nilanjan Das

Hi,

I basically want to load the shell variables. Can you tell me how I can do that?
What is the wrapper class all about you mentioned?

Thanks for your help.

Thanks,
Nilanjan
***

Tim O'Neil wrote:

 That said, do this:

 Properties props = System.getProperties();
 props.put(MYVAR, MYVALUE);
 System.setProperties(props);

 Then later on in your program you can get the value
 to your hearts content. Or even in another class or
 package.

 Or use a wrapper to load shell variables. But if all
 you want to do load your own defined variables use the
 above code.

 At 07:33 AM 8/7/2001, you wrote:
 1) This isn't a Tomcat question: if you'd done the same in a java
 application, you'd have found the same thing.  There are forums, newsgroups,
 and mailing lists for Java questions.
 
 2) You're confusing environment variables with properties.  Properties are
 defined either by loading them from a properties file, or by specifying them
 on java's command line (with -D).
 
 3) There is a method, System.getenv(), to get environment variables, but
 it's deprecated (the whole concept of environment variables is incredibly
 OS-specific).  So you really _should_ be using properties, or
 context-param elements defined in your application's web.xml.  Look at
 java.util.Properties for the former, and the servlet spec for the latter.
 
  -- Bill K.
 
   -Original Message-
   From: Nilanjan Das [mailto:[EMAIL PROTECTED]]
   Sent: Tuesday, August 07, 2001 7:12 AM
   To: tomcat jakarta
   Subject: Getting the user environment variable::Need help
  
  
   Hi,
  
   I am on HP-UX and trying to access one user environment varaible from
   the Java code using
   System.getProperty() method but it is returning NULL. Can anyone point
   out why? This is what I did:
  
   $export TEST=testing
   $echo $TEST
   testing
  
   But when I execute System.getProperty(TEST) from my code, it returns
   NULL.
  
   Can any of you help?
  
   Thanks,
   Nilanjan
  
  




Mailing lists for calling Java from Xalan?

2001-08-07 Thread Richard Heintze

Hi folks!

Enke, a developer, kindly responded to my query about
how to convert dates with XALAN.

I still have a more general question, however: How to
manipulate DOM using Java from XSLT/Xalan.
 I believe I sent out another query about how I could
not get any of the examples of calling Java code from
Xalan to work. I tried the examples in xalan-j_2_2_D6
distribution  as well has the ones from Micheal Kay's
book XSLT Reference. (I could call javascript from
Xalan, however).

Perhaps the reason I received no response is that I
used the wrong mailing lists? I could not find a
[EMAIL PROTECTED] discussed on
xml.apache.org. Did I miss something? Where do I post
such a query? 

I would also be interested in learning how to
manipulate DOM from Javascript inside of Xalan/XSLT. I
assume I need to check out the rhino documentation on
mozilla.org for that. 

   Thanks,
 Siegfried

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



IIS+Tomcat Port issue

2001-08-07 Thread Ratnakar Palle

Hi Tomcat-Users,

I've the following scenario...
IIS listening on port 80. 
Tomcat listening on port 8080.

How do I restrict the users accessing Tomcat directly? 
What configuration changes do I've to do in order to accomplish this?

Hope, I was clear on my question

Thanks in advance,
-Ranker



Re: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Craig R. McClanahan



On Tue, 7 Aug 2001, Pier P. Fumagalli wrote:

 Holscher, David M at [EMAIL PROTECTED] wrote:
  
  Correct, that's why it's not advisable to put it there. $CATALINA_HOME/lib
  is there just because sometimes you want to have libraries accessible by
  all your web applications WITHOUT putting them in $JAVA_HOME/jre/lib/ext.
  
  Yes, there are lots of things that are not advisable. I'm just saying that
  having a way to extend the places where I look for jar files for a web-app
  is no worse than existence of the $CATALINA_HOME/lib.
 
 I tend to disagree with you. If you consider the fact that everything under
 $JAVA_HOME/jre/lib/ext is considered trusted code by the VM when you
 install a SecurityManager, while code in $CATALINA_HOME/lib is not.
 
 $CATALINA_HOME/lib is there for a reason...
 
  Yes, but at this point I don't quite get WHY you have to have a JAR file
  specifically tied to a single Web Application in a directory != from your
  WEB-INF/lib... It there a solid explanation on why you need this behavior?
  
  We have a set of jar files used by several programs which are not web
  applications. We have a single web app which uses some of the jar files. It
  does not make sense for the programs that are not web applications to use
  jar files in the WEB-INF/lib directory nor does it make sense for the web
  application to use files outside that directory. So when we build a
  production release we make sure we have copies of the jar files in the right
  places. However, in development when I make a change to a source file there
  is much less pain involved if I don't have to make sure to copy the
  resulting change to the jar file into all of the places it is needed. It is
  simply easier to point the applications that need it to the central
  location. Please don't answer that I should have the build script make extra
  copies of the jar files (which will cause configuration management issues)
  and please don't answer that the central location be the WEB-INF/lib
  directory because most of our developers don't see that directory. I simply
  want to know if it is possible to extend the library path for a web
  application. At this point, I'm sure the answer is no.
 
 Well, the answer IS of course no... :) If you imply such a configuration
 mechanism (like specify a classpath for every web-application) there might
 be issues from when you move stuff around (like, from your classpath, to
 WEB-INF/lib), especially in terms of security and class loading issues.
 I believe that it can be easily solved by putting down some symlinks in your
 WEB-INF/lib, so that when you jar up the final release you don't even care
 what you need to copy over or not...
 
 Pier
 
 

I find that a deploy target in my build.xml file, which assembles the
web app in Tomcat's webapps directory (including copying JARs that are
needed) solves this kind of pain for me.

You're absolutely right that the author of a non-web JAR that you're using
shouldn't be responsible for pushing JAR files to wherever they are
being used -- it should be the responsibility of the user of that JAR to
pull as needed.  Ant's copy task is smart enough to skip the copying
if the JAR file didn't change, so it's still pretty fast.

Now, my webapp development loop goes like this:
* Edit
* ant compile
* Fix compiler errors and loop back
* ant deploy
* Restart the webapp in Tomcat (manually or automatically)
* Test

And I never have to worry about getting the most recent JAR files -- the
deploy target took care of that for me as it was copying all my stuff into
the webapps directory.

It's even easy to parameterize build.xml so that developers can pick and
choose which version of dependent JARs they want, or use defaults.  The
process of building Tomcat itself (with lots of external dependencies) has
convinced me that it's scalable to larger projects as well.

One final benefit -- creating the production distribution is now just a
matter of JARing up the deployed webapp directory into a WAR file, since
you've been developing all along in the same directory structure that
you're going to deploy.

Craig





jsp:plugin

2001-08-07 Thread James, Stuart

Hi,

Can Anybody out there help the issue relates to the JSP:plugin feature.

I want access the applet from a client side script,

APPLET name=myApplet
code=MyApplet.class 
codebase=/test
width=350 
height=200 
alt=not working
/APPLET   

This applet code allows me to access the object in a script as such,

script for=window event=onload
myApplet.InvokeMethod(aparameter);
/script   

The problem occurs if I change the code to use the new jsp:plugin mechanism,

jsp:plugin name=myApplet
type=applet
code=MyApplet.class 
codebase=/test
width=350 
height=200
/jsp:plugin

While the applet is still downloaded, the object can not be accessed via a
script. (vbscript or jscript). Looking at the html generated the name
parameter is ignored.

Thanks to anyone who can assist.

Stuart James.


___
Email Disclaimer

This communication is for the attention of the
named recipient only and should not be passed
on to any other person. Information relating to
any company or security, is for information
purposes only and should not be interpreted as
a solicitation or offer to buy or sell any security.
The information on which this communication is based
has been obtained from sources we believe to be reliable,
but we do not guarantee its accuracy or completeness.
All expressions of opinion are subject to change
without notice.  All e-mail messages, and associated attachments,
are subject to interception and monitoring for lawful business purposes.
___



tomcat -- which version

2001-08-07 Thread Ling Wang


We are on solaris 8, and we want tomcat and apache work together.
which version of tomcat works better with apache on unix platform?

Many thanks in advance!!!


Ling 






Re: Mailing lists for calling Java from Xalan?

2001-08-07 Thread Pier P. Fumagalli

Richard Heintze at [EMAIL PROTECTED] wrote:
 
 Perhaps the reason I received no response is that I
 used the wrong mailing lists? I could not find a
 [EMAIL PROTECTED] discussed on
 xml.apache.org. Did I miss something? Where do I post
 such a query? 

Exactly... It's [EMAIL PROTECTED] :)

Pier




Re: Getting the user environment variable::Need help

2001-08-07 Thread Tim O'Neil

You write a shell script that loads the variable into a
java parameter to the jvm;

#!/bin/sh
java -DMYVAR=$MYVAR myCoolClass

Use the root shell if possible, not the k shell, your code
below looked like K Shell parlance.

At 09:41 AM 8/7/2001, you wrote:
Hi,

I basically want to load the shell variables. Can you tell me how I can do 
that?
What is the wrapper class all about you mentioned?

Thanks for your help.

Thanks,
Nilanjan
***

Tim O'Neil wrote:

  That said, do this:
 
  Properties props = System.getProperties();
  props.put(MYVAR, MYVALUE);
  System.setProperties(props);
 
  Then later on in your program you can get the value
  to your hearts content. Or even in another class or
  package.
 
  Or use a wrapper to load shell variables. But if all
  you want to do load your own defined variables use the
  above code.
 
  At 07:33 AM 8/7/2001, you wrote:
  1) This isn't a Tomcat question: if you'd done the same in a java
  application, you'd have found the same thing.  There are forums, 
 newsgroups,
  and mailing lists for Java questions.
  
  2) You're confusing environment variables with properties.  Properties are
  defined either by loading them from a properties file, or by 
 specifying them
  on java's command line (with -D).
  
  3) There is a method, System.getenv(), to get environment variables, but
  it's deprecated (the whole concept of environment variables is incredibly
  OS-specific).  So you really _should_ be using properties, or
  context-param elements defined in your application's web.xml.  Look at
  java.util.Properties for the former, and the servlet spec for the latter.
  
   -- Bill K.
  
-Original Message-
From: Nilanjan Das [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 7:12 AM
To: tomcat jakarta
Subject: Getting the user environment variable::Need help
   
   
Hi,
   
I am on HP-UX and trying to access one user environment varaible from
the Java code using
System.getProperty() method but it is returning NULL. Can anyone point
out why? This is what I did:
   
$export TEST=testing
$echo $TEST
testing
   
But when I execute System.getProperty(TEST) from my code, it returns
NULL.
   
Can any of you help?
   
Thanks,
Nilanjan
   
   




[NOTICE] Please read...

2001-08-07 Thread Pier P. Fumagalli

Guys, when posting to this mailing list, can you please _ALWAYS_ specify
what version of Tomcat you're using (3.x 4.0)? Some of the developers (read:
me) are involved only with one particular version, and when seeing something
like I installed Tomcat and... I seriously don't know whether I know that
or not...

Personally I'm doing 4.0, and know nothing about 3.x, so, please, if you
want an answer, just include always the version number (it might be worth
also putting in the subject of your emails, something like [TC3] balblabla
or [TC4] this is my subject)..

Thanks..

Pier




RE: tomcat -- which version

2001-08-07 Thread Bryan Rood

Ling

they all do! All the version of tomcat that is, just download 4.0b6 or a
prod 3.2.x and you will be fine.


-- Bryan

-Original Message-
From: Ling Wang [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 10:00 AM
To: [EMAIL PROTECTED]
Subject: tomcat -- which version 



We are on solaris 8, and we want tomcat and apache work together.
which version of tomcat works better with apache on unix platform?

Many thanks in advance!!!


Ling 





Re: tomcat -- which version

2001-08-07 Thread Mike McGuinness

I'm running  with apache 1.3.20 and Tomcat 3.2.3 and it runs fine.

Ling Wang wrote:

 We are on solaris 8, and we want tomcat and apache work together.
 which version of tomcat works better with apache on unix platform?
 
 Many thanks in advance!!!
 
 
 Ling 
 
 




RE: IIS+Tomcat Port issue

2001-08-07 Thread Michael Wentzel

 I've the following scenario...
 IIS listening on port 80. 
 Tomcat listening on port 8080.
 
 How do I restrict the users accessing Tomcat directly? 
 What configuration changes do I've to do in order to 
 accomplish this?

As long as your IIS-Tomcat connector is configured correctly you can simply
remove the HttpConnectionHandler from your server.xml.


---
Michael Wentzel
Software Developer
Software As We Think - http://www.aswethink.com



RE: IIS+Tomcat Port issue

2001-08-07 Thread Jeff Rancier

Do you mean on port 8080?
Jeff

-Original Message-
From: Ratnakar Palle [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 12:47 PM
To: [EMAIL PROTECTED]
Subject: IIS+Tomcat Port issue


Hi Tomcat-Users,

I've the following scenario...
IIS listening on port 80. 
Tomcat listening on port 8080.

How do I restrict the users accessing Tomcat directly? 
What configuration changes do I've to do in order to accomplish this?

Hope, I was clear on my question

Thanks in advance,
-Ranker



RE: [NOTICE] Please read...

2001-08-07 Thread Bryan Rood

what a good idea!

you guys are full of good ideas!

-Original Message-
From: Pier P. Fumagalli [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 10:08 AM
To: [EMAIL PROTECTED]
Subject: [NOTICE] Please read...


Guys, when posting to this mailing list, can you please _ALWAYS_ specify
what version of Tomcat you're using (3.x 4.0)? Some of the developers (read:
me) are involved only with one particular version, and when seeing something
like I installed Tomcat and... I seriously don't know whether I know that
or not...

Personally I'm doing 4.0, and know nothing about 3.x, so, please, if you
want an answer, just include always the version number (it might be worth
also putting in the subject of your emails, something like [TC3] balblabla
or [TC4] this is my subject)..

Thanks..

Pier



RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread A.L.

This is not really a jdbc issue.  What is happening is
that my code specifies that the conenction to the
database is made only during the init of the servlet
and the conenction is closed after the servlet is
destroyed.  I think that my problem is that once I
destroy the servlet, I can't figure a way to re
initialize it.  Simply refreshing the servlet page
doesn;t seem to work.
--- William Kaufman [EMAIL PROTECTED] wrote:
  I have developed a servlet web application
 which
  connects to a database to retrieve information.  I
  noticed that if within my servlet I destroy the
  connection to the database there is no way to
  reconnect to the database .
 
 Maybe this is a JSP thing (I'm not too familiar with
 those), and JSPs have
 some weird JDBC cover methods.  But you _should_ be
 able to disconnect, by
 calling Connection.close(); and to reconnect, the
 same way you connected the
 first time.
 
 Why can't you reconnect?  Are you getting an
 exception from
 DriverManager.getConnection()?
 
   Is keeping the persistent connection to the
 database
  a heavy burden on tomcat?
 
 Persistent connections aren't a burden on Tomcat,
 but might be on your
 database, especially if the modifications aren't
 committed immediately.  You
 should always try to close connections (and other
 resources) if you don't
 think you'll be using it again in a few seconds.
 
I don't believe my question pertains
 specifically to
  Tomcat, so I was wondering whether or not any of
 you
  knew where there are list servers which deal with
  servlets in general.
 
 This mailing list is fine for general servlet
 questions.  But this seems to
 be a JDBC question,...
 
 -- Bill K. 
 
  -Original Message-
  From: A.L. [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 9:07 AM
  To: [EMAIL PROTECTED]
  Subject: Servlet/ Database Conenction Persists
 Question
  
  
  I have developed a servlet web application
 which
  connects to a database to retrieve information.  I
  noticed that if within my servlet I destroy the
  connection to the database there is no way to
  reconnect to the database .  In other words I need
 to
  keep my connection to the database at all times
 that
  tomcat is up.  My questions include:
  
   Is this correct that there is no way to reconnect
 to
  the database?  If this is not correct, how does
 one
  reconnect, and or reinitialize the servlet?
   Is keeping the persistent connection to the
 database
  a heavy burden on tomcat?  In other words, is it
 o.k.
  to design an application which never releases its
  conenction to the database?
   
  
I don't believe my question pertains
 specifically to
  Tomcat, so I was wondering whether or not any of
 you
  knew where there are list servers which deal with
  servlets in general.
  
  __
  Do You Yahoo!?
  Make international calls for as low as $.04/minute
 with 
  Yahoo! Messenger
  http://phonecard.yahoo.com/
  


__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



RE: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread James, Stuart

so what is the best option

where should you place database jar's, ibm queue jar's etc..., surely you
would not copy them into your applications web-inf area? additionaly I would
not want them in the tomcat classpath?

what is the prefered solution ? 

I need to consider that more than the web server mayuse the jar files so I
do not want to copy them into the web server area, additionaly I don't like
the idea of changing the supplied tomcat.sh or the global CLASSPATH
environment.

Can you not add .jars to the application configuration ?

-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 5:48 PM
To: [EMAIL PROTECTED]
Subject: Re: Moving /WEB-INF/lib or adding to it in TC 4.0




On Tue, 7 Aug 2001, Pier P. Fumagalli wrote:

 Holscher, David M at [EMAIL PROTECTED] wrote:
  
  Correct, that's why it's not advisable to put it there.
$CATALINA_HOME/lib
  is there just because sometimes you want to have libraries accessible
by
  all your web applications WITHOUT putting them in
$JAVA_HOME/jre/lib/ext.
  
  Yes, there are lots of things that are not advisable. I'm just saying
that
  having a way to extend the places where I look for jar files for a
web-app
  is no worse than existence of the $CATALINA_HOME/lib.
 
 I tend to disagree with you. If you consider the fact that everything
under
 $JAVA_HOME/jre/lib/ext is considered trusted code by the VM when you
 install a SecurityManager, while code in $CATALINA_HOME/lib is not.
 
 $CATALINA_HOME/lib is there for a reason...
 
  Yes, but at this point I don't quite get WHY you have to have a JAR
file
  specifically tied to a single Web Application in a directory != from
your
  WEB-INF/lib... It there a solid explanation on why you need this
behavior?
  
  We have a set of jar files used by several programs which are not web
  applications. We have a single web app which uses some of the jar files.
It
  does not make sense for the programs that are not web applications to
use
  jar files in the WEB-INF/lib directory nor does it make sense for the
web
  application to use files outside that directory. So when we build a
  production release we make sure we have copies of the jar files in the
right
  places. However, in development when I make a change to a source file
there
  is much less pain involved if I don't have to make sure to copy the
  resulting change to the jar file into all of the places it is needed. It
is
  simply easier to point the applications that need it to the central
  location. Please don't answer that I should have the build script make
extra
  copies of the jar files (which will cause configuration management
issues)
  and please don't answer that the central location be the WEB-INF/lib
  directory because most of our developers don't see that directory. I
simply
  want to know if it is possible to extend the library path for a web
  application. At this point, I'm sure the answer is no.
 
 Well, the answer IS of course no... :) If you imply such a configuration
 mechanism (like specify a classpath for every web-application) there
might
 be issues from when you move stuff around (like, from your classpath, to
 WEB-INF/lib), especially in terms of security and class loading issues.
 I believe that it can be easily solved by putting down some symlinks in
your
 WEB-INF/lib, so that when you jar up the final release you don't even
care
 what you need to copy over or not...
 
 Pier
 
 

I find that a deploy target in my build.xml file, which assembles the
web app in Tomcat's webapps directory (including copying JARs that are
needed) solves this kind of pain for me.

You're absolutely right that the author of a non-web JAR that you're using
shouldn't be responsible for pushing JAR files to wherever they are
being used -- it should be the responsibility of the user of that JAR to
pull as needed.  Ant's copy task is smart enough to skip the copying
if the JAR file didn't change, so it's still pretty fast.

Now, my webapp development loop goes like this:
* Edit
* ant compile
* Fix compiler errors and loop back
* ant deploy
* Restart the webapp in Tomcat (manually or automatically)
* Test

And I never have to worry about getting the most recent JAR files -- the
deploy target took care of that for me as it was copying all my stuff into
the webapps directory.

It's even easy to parameterize build.xml so that developers can pick and
choose which version of dependent JARs they want, or use defaults.  The
process of building Tomcat itself (with lots of external dependencies) has
convinced me that it's scalable to larger projects as well.

One final benefit -- creating the production distribution is now just a
matter of JARing up the deployed webapp directory into a WAR file, since
you've been developing all along in the same directory structure that
you're going to deploy.

Craig



___
Email Disclaimer

This communication is for the attention 

RE: IIS+Tomcat Port issue

2001-08-07 Thread Jeff Rancier

Comment out the following:

Connector className=org.apache.tomcat.service.PoolTcpConnector
Parameter name=handler

value=org.apache.tomcat.service.http.HttpConnectionHandler/
Parameter name=port
value=8080/
/Connector

And restart Tomcat.

Jeff

-Original Message-
From: Ratnakar Palle [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 12:47 PM
To: [EMAIL PROTECTED]
Subject: IIS+Tomcat Port issue


Hi Tomcat-Users,

I've the following scenario...
IIS listening on port 80.
Tomcat listening on port 8080.

How do I restrict the users accessing Tomcat directly?
What configuration changes do I've to do in order to accomplish this?

Hope, I was clear on my question

Thanks in advance,
-Ranker




Re: tomcat -- which version

2001-08-07 Thread Pier P. Fumagalli

Well, the connector between Apache and Tomcat 4.0 (mod_webapp) has not yet
been tested thoroughly, and there's not yet a release for it. It works, it
passed all Watchdog compliancy tests this Sunday, but... :)

Pier

Bryan Rood at [EMAIL PROTECTED] wrote:
 
 Ling
 
 they all do! All the version of tomcat that is, just download 4.0b6 or a
 prod 3.2.x and you will be fine.
 
 -Original Message-
 From: Ling Wang [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 10:00 AM
 To: [EMAIL PROTECTED]
 Subject: tomcat -- which version
 
 We are on solaris 8, and we want tomcat and apache work together.
 which version of tomcat works better with apache on unix platform?
 
 Many thanks in advance!!!




[TEST] please ignore...

2001-08-07 Thread Pier P. Fumagalli

I'm adding a few features to the mailing list... You can simply ignore this
message...

Pier




RE: IIS+Tomcat Port issue

2001-08-07 Thread Michael Wentzel

 Do you mean on port 8080?
 Jeff

That's the only HttpConnector you mentioned you
were using


---
Michael Wentzel
Software Developer
Software As We Think - http://www.aswethink.com



RE: [NOTICE] Please read...

2001-08-07 Thread Noll, Jeff HS

So quickly we forget! Wheres the version number!

mine is 3.1


 -Original Message-
 From: Bryan Rood [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 1:23 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: [NOTICE] Please read...
 
 
 what a good idea!
 
 you guys are full of good ideas!
 
 -Original Message-
 From: Pier P. Fumagalli [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 10:08 AM
 To: [EMAIL PROTECTED]
 Subject: [NOTICE] Please read...
 
 
 Guys, when posting to this mailing list, can you please 
 _ALWAYS_ specify
 what version of Tomcat you're using (3.x 4.0)? Some of the 
 developers (read:
 me) are involved only with one particular version, and when 
 seeing something
 like I installed Tomcat and... I seriously don't know 
 whether I know that
 or not...
 
 Personally I'm doing 4.0, and know nothing about 3.x, so, 
 please, if you
 want an answer, just include always the version number (it 
 might be worth
 also putting in the subject of your emails, something like 
 [TC3] balblabla
 or [TC4] this is my subject)..
 
 Thanks..
 
 Pier
 



RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread William Kaufman

 This is not really a jdbc issue.  What is happening is
 that my code specifies that the conenction to the
 database is made only during the init of the servlet
 and the conenction is closed after the servlet is
 destroyed.

Ah, OK.  Don't do that.

init() is called exactly once, when the servlet gets loaded.

If you want to close and re-allocate the connection, do it in your
doGet()/doPost()/doWhatever() methods (if you've overridden those) or in
your service() method (if you didn't): connect at the beginning,
commit/rollback and close at the end (preferrably in a finally block, to
make sure it gets done).

-- Bill K. 

 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 10:27 AM
 To: [EMAIL PROTECTED]
 Subject: RE: Servlet/ Database Conenction Persists Question
 
 
 This is not really a jdbc issue.  What is happening is
 that my code specifies that the conenction to the
 database is made only during the init of the servlet
 and the conenction is closed after the servlet is
 destroyed.  I think that my problem is that once I
 destroy the servlet, I can't figure a way to re
 initialize it.  Simply refreshing the servlet page
 doesn;t seem to work.
 --- William Kaufman [EMAIL PROTECTED] wrote:
   I have developed a servlet web application
  which
   connects to a database to retrieve information.  I
   noticed that if within my servlet I destroy the
   connection to the database there is no way to
   reconnect to the database .
  
  Maybe this is a JSP thing (I'm not too familiar with
  those), and JSPs have
  some weird JDBC cover methods.  But you _should_ be
  able to disconnect, by
  calling Connection.close(); and to reconnect, the
  same way you connected the
  first time.
  
  Why can't you reconnect?  Are you getting an
  exception from
  DriverManager.getConnection()?
  
Is keeping the persistent connection to the
  database
   a heavy burden on tomcat?
  
  Persistent connections aren't a burden on Tomcat,
  but might be on your
  database, especially if the modifications aren't
  committed immediately.  You
  should always try to close connections (and other
  resources) if you don't
  think you'll be using it again in a few seconds.
  
 I don't believe my question pertains
  specifically to
   Tomcat, so I was wondering whether or not any of
  you
   knew where there are list servers which deal with
   servlets in general.
  
  This mailing list is fine for general servlet
  questions.  But this seems to
  be a JDBC question,...
  
  -- Bill K. 
  
   -Original Message-
   From: A.L. [mailto:[EMAIL PROTECTED]]
   Sent: Tuesday, August 07, 2001 9:07 AM
   To: [EMAIL PROTECTED]
   Subject: Servlet/ Database Conenction Persists
  Question
   
   
   I have developed a servlet web application
  which
   connects to a database to retrieve information.  I
   noticed that if within my servlet I destroy the
   connection to the database there is no way to
   reconnect to the database .  In other words I need
  to
   keep my connection to the database at all times
  that
   tomcat is up.  My questions include:
   
Is this correct that there is no way to reconnect
  to
   the database?  If this is not correct, how does
  one
   reconnect, and or reinitialize the servlet?
Is keeping the persistent connection to the
  database
   a heavy burden on tomcat?  In other words, is it
  o.k.
   to design an application which never releases its
   conenction to the database?

   
 I don't believe my question pertains
  specifically to
   Tomcat, so I was wondering whether or not any of
  you
   knew where there are list servers which deal with
   servlets in general.
   
   __
   Do You Yahoo!?
   Make international calls for as low as $.04/minute
  with 
   Yahoo! Messenger
   http://phonecard.yahoo.com/
   
 
 
 __
 Do You Yahoo!?
 Make international calls for as low as $.04/minute with 
 Yahoo! Messenger
 http://phonecard.yahoo.com/
 



RE: IIS+Tomcat Port issue

2001-08-07 Thread Jeff Rancier

That's in your server.xml file.

-Original Message-
From: Jeff Rancier [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 1:34 PM
To: [EMAIL PROTECTED]
Subject: RE: IIS+Tomcat Port issue


Comment out the following:

Connector className=org.apache.tomcat.service.PoolTcpConnector
Parameter name=handler

value=org.apache.tomcat.service.http.HttpConnectionHandler/
Parameter name=port
value=8080/
/Connector

And restart Tomcat.

Jeff

-Original Message-
From: Ratnakar Palle [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 12:47 PM
To: [EMAIL PROTECTED]
Subject: IIS+Tomcat Port issue


Hi Tomcat-Users,

I've the following scenario...
IIS listening on port 80.
Tomcat listening on port 8080.

How do I restrict the users accessing Tomcat directly?
What configuration changes do I've to do in order to accomplish this?

Hope, I was clear on my question

Thanks in advance,
-Ranker



RE: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Craig R. McClanahan



On Tue, 7 Aug 2001, James, Stuart wrote:

 so what is the best option
 
 where should you place database jar's, ibm queue jar's etc..., surely
 you would not copy them into your applications web-inf area?
 additionaly I would not want them in the tomcat classpath?
 
 what is the prefered solution ? 
 
 I need to consider that more than the web server mayuse the jar files
 so I do not want to copy them into the web server area, additionaly I
 don't like the idea of changing the supplied tomcat.sh or the global
 CLASSPATH environment.
 
 Can you not add .jars to the application configuration ?
 

What do do depends on the visibility your JAR needs:

* To make a JAR file available to a single web app only, put it in the
  /WEB-INF/lib directory of that webapp.

* To make a JAR file available to all web apps, put it in the
  $TOMCAT_HOME/lib directory.  These JAR files automatically get added to
  the CLASSPATH (for 3.2) or placed in a parent classloader (4.0), so that
  they are visible to all of your apps.

You never have to mess with CLASSPATH.

Craig




Re: autoencoding issue

2001-08-07 Thread Eric Boo

Hi, the meta charset tags don't work.

I've found that this works for jsp:
%@ page contentType=text/html; charset=gb2312 %
Change gb2312 to Big5 if u need it.

Regards.



Re: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread D. Jay Newman

If you're using Java 1.2+ you should be able to put these sorts of shared
jars in the $JAVA_HOME/jre/lib/ext directory.

It works for me.

 so what is the best option
 
 where should you place database jar's, ibm queue jar's etc..., surely you
 would not copy them into your applications web-inf area? additionaly I would
 not want them in the tomcat classpath?
 
 what is the prefered solution ? 
 
 I need to consider that more than the web server mayuse the jar files so I
 do not want to copy them into the web server area, additionaly I don't like
 the idea of changing the supplied tomcat.sh or the global CLASSPATH
 environment.
 
 Can you not add .jars to the application configuration ?
 
 -Original Message-
 From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 5:48 PM
 To: [EMAIL PROTECTED]
 Subject: Re: Moving /WEB-INF/lib or adding to it in TC 4.0
 
 
 
 
 On Tue, 7 Aug 2001, Pier P. Fumagalli wrote:
 
  Holscher, David M at [EMAIL PROTECTED] wrote:
   
   Correct, that's why it's not advisable to put it there.
 $CATALINA_HOME/lib
   is there just because sometimes you want to have libraries accessible
 by
   all your web applications WITHOUT putting them in
 $JAVA_HOME/jre/lib/ext.
   
   Yes, there are lots of things that are not advisable. I'm just saying
 that
   having a way to extend the places where I look for jar files for a
 web-app
   is no worse than existence of the $CATALINA_HOME/lib.
  
  I tend to disagree with you. If you consider the fact that everything
 under
  $JAVA_HOME/jre/lib/ext is considered trusted code by the VM when you
  install a SecurityManager, while code in $CATALINA_HOME/lib is not.
  
  $CATALINA_HOME/lib is there for a reason...
  
   Yes, but at this point I don't quite get WHY you have to have a JAR
 file
   specifically tied to a single Web Application in a directory != from
 your
   WEB-INF/lib... It there a solid explanation on why you need this
 behavior?
   
   We have a set of jar files used by several programs which are not web
   applications. We have a single web app which uses some of the jar files.
 It
   does not make sense for the programs that are not web applications to
 use
   jar files in the WEB-INF/lib directory nor does it make sense for the
 web
   application to use files outside that directory. So when we build a
   production release we make sure we have copies of the jar files in the
 right
   places. However, in development when I make a change to a source file
 there
   is much less pain involved if I don't have to make sure to copy the
   resulting change to the jar file into all of the places it is needed. It
 is
   simply easier to point the applications that need it to the central
   location. Please don't answer that I should have the build script make
 extra
   copies of the jar files (which will cause configuration management
 issues)
   and please don't answer that the central location be the WEB-INF/lib
   directory because most of our developers don't see that directory. I
 simply
   want to know if it is possible to extend the library path for a web
   application. At this point, I'm sure the answer is no.
  
  Well, the answer IS of course no... :) If you imply such a configuration
  mechanism (like specify a classpath for every web-application) there
 might
  be issues from when you move stuff around (like, from your classpath, to
  WEB-INF/lib), especially in terms of security and class loading issues.
  I believe that it can be easily solved by putting down some symlinks in
 your
  WEB-INF/lib, so that when you jar up the final release you don't even
 care
  what you need to copy over or not...
  
  Pier
  
  
 
 I find that a deploy target in my build.xml file, which assembles the
 web app in Tomcat's webapps directory (including copying JARs that are
 needed) solves this kind of pain for me.
 
 You're absolutely right that the author of a non-web JAR that you're using
 shouldn't be responsible for pushing JAR files to wherever they are
 being used -- it should be the responsibility of the user of that JAR to
 pull as needed.  Ant's copy task is smart enough to skip the copying
 if the JAR file didn't change, so it's still pretty fast.
 
 Now, my webapp development loop goes like this:
 * Edit
 * ant compile
 * Fix compiler errors and loop back
 * ant deploy
 * Restart the webapp in Tomcat (manually or automatically)
 * Test
 
 And I never have to worry about getting the most recent JAR files -- the
 deploy target took care of that for me as it was copying all my stuff into
 the webapps directory.
 
 It's even easy to parameterize build.xml so that developers can pick and
 choose which version of dependent JARs they want, or use defaults.  The
 process of building Tomcat itself (with lots of external dependencies) has
 convinced me that it's scalable to larger projects as well.
 
 One final benefit -- creating the production distribution is now just a
 matter of JARing up 

RE: [NOTICE] Please read...

2001-08-07 Thread Larry Isaacs

For Tomcat 3.x, when you have renamed the installation
directory to remove the version or are using a version
prior to 3.2, check the readme file in the TOMCAT_HOME/doc
directory.  The version appears very near the top of the file.

Cheers,
Larry

 -Original Message-
 From: Noll, Jeff HS [mailto:[EMAIL PROTECTED]]
 Sent: None
 To: '[EMAIL PROTECTED]'
 Subject: RE: [NOTICE] Please read...
 
 
 So quickly we forget! Wheres the version number!
 
 mine is 3.1
 
 
  -Original Message-
  From: Bryan Rood [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 1:23 PM
  To: '[EMAIL PROTECTED]'
  Subject: RE: [NOTICE] Please read...
  
  
  what a good idea!
  
  you guys are full of good ideas!
  
  -Original Message-
  From: Pier P. Fumagalli [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 10:08 AM
  To: [EMAIL PROTECTED]
  Subject: [NOTICE] Please read...
  
  
  Guys, when posting to this mailing list, can you please 
  _ALWAYS_ specify
  what version of Tomcat you're using (3.x 4.0)? Some of the 
  developers (read:
  me) are involved only with one particular version, and when 
  seeing something
  like I installed Tomcat and... I seriously don't know 
  whether I know that
  or not...
  
  Personally I'm doing 4.0, and know nothing about 3.x, so, 
  please, if you
  want an answer, just include always the version number (it 
  might be worth
  also putting in the subject of your emails, something like 
  [TC3] balblabla
  or [TC4] this is my subject)..
  
  Thanks..
  
  Pier
  
 



web app in root directory

2001-08-07 Thread Zhi Shen

Hi,

I'm interested in putting my web app in the root directory so that people
can get to it via http://x.com/index.html instead of
http://x.com/myapp/index.html


Whenever I change the server.xml file:

Context path= 
  docBase=webapps/myapp 
  crossContext=true
  debug=0 
  reloadable=true  
/Context

Some of my subdirectories are not found, http:/x.com/images/index.html and
also whenever I goto admin http://x.com/admin/ I get the Tomcat admin pages.


Does anyone know how to configure this correctly? Thanks in advance.



RE: PLEASE - HELP PLEASE

2001-08-07 Thread Nance, Michael

My version of Tomcat is 3.2.2 and apache 1.1.19
Any help on even where to look would be appreciated

-Original Message-
From: Nance, Michael [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 8:25 AM
To: '[EMAIL PROTECTED]'
Subject: PLEASE - HELP PLEASE


This is a repostMy connectors won't start this is from my server.xml

Connector className=org.apache.tomcat.service.PoolTcpConnector
Parameter name=handler
value=org.apache.tomcat.service.connector.Ajp12ConnectionHandler/
Parameter name=port value=8007/
Parameter name=max_threads value=500/
Parameter name=max_spare_threads value=200/
Parameter name=min_spare_threads value=100 /
/Connector

Connector className=org.apache.tomcat.service.PoolTcpConnector
   Parameter name=handler
value=org.apache.tomcat.service.connector.Ajp13ConnectionHandler/
   Parameter name=port value=8009/
   Parameter name=max_threads value=500/
   Parameter name=max_spare_threads value=200/
   Parameter name=min_spare_threads value=100 /
/Connector

Context path= docBase=../../../../src/public_html debug=0
reloadable=true 
/Context





Second

are dir structure is something like this

../src/common/...  path to all classes etc
../src/public_html/..   path to all jsp's

in my server.xml I have a line
Context path= docBase=.. /src/public_html ...


I believe that will take care of my jsps but not a path to my Servlets
How can I fix this?

Thanks



RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread A.L.

William,
   thanks.  IOt turns out that after looking at my
problem in a little more detail, I figured this must
be the issue.  I guess this leads to another question.
 Once you destroy a servlet, can you reinitialize it. 
If so how?

thanks,
   -Amos
--- William Kaufman [EMAIL PROTECTED] wrote:
  This is not really a jdbc issue.  What is
 happening is
  that my code specifies that the conenction to the
  database is made only during the init of the
 servlet
  and the conenction is closed after the servlet is
  destroyed.
 
 Ah, OK.  Don't do that.
 
 init() is called exactly once, when the servlet gets
 loaded.
 
 If you want to close and re-allocate the connection,
 do it in your
 doGet()/doPost()/doWhatever() methods (if you've
 overridden those) or in
 your service() method (if you didn't): connect at
 the beginning,
 commit/rollback and close at the end (preferrably in
 a finally block, to
 make sure it gets done).
 
 -- Bill K. 
 
  -Original Message-
  From: A.L. [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 10:27 AM
  To: [EMAIL PROTECTED]
  Subject: RE: Servlet/ Database Conenction Persists
 Question
  
  
  This is not really a jdbc issue.  What is
 happening is
  that my code specifies that the conenction to the
  database is made only during the init of the
 servlet
  and the conenction is closed after the servlet is
  destroyed.  I think that my problem is that once I
  destroy the servlet, I can't figure a way to re
  initialize it.  Simply refreshing the servlet page
  doesn;t seem to work.
  --- William Kaufman [EMAIL PROTECTED] wrote:
I have developed a servlet web application
   which
connects to a database to retrieve
 information.  I
noticed that if within my servlet I destroy
 the
connection to the database there is no way to
reconnect to the database .
   
   Maybe this is a JSP thing (I'm not too familiar
 with
   those), and JSPs have
   some weird JDBC cover methods.  But you _should_
 be
   able to disconnect, by
   calling Connection.close(); and to reconnect,
 the
   same way you connected the
   first time.
   
   Why can't you reconnect?  Are you getting an
   exception from
   DriverManager.getConnection()?
   
 Is keeping the persistent connection to the
   database
a heavy burden on tomcat?
   
   Persistent connections aren't a burden on
 Tomcat,
   but might be on your
   database, especially if the modifications aren't
   committed immediately.  You
   should always try to close connections (and
 other
   resources) if you don't
   think you'll be using it again in a few seconds.
   
  I don't believe my question pertains
   specifically to
Tomcat, so I was wondering whether or not any
 of
   you
knew where there are list servers which deal
 with
servlets in general.
   
   This mailing list is fine for general servlet
   questions.  But this seems to
   be a JDBC question,...
   
   -- Bill
 K. 
   
-Original Message-
From: A.L. [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 9:07 AM
To: [EMAIL PROTECTED]
Subject: Servlet/ Database Conenction Persists
   Question


I have developed a servlet web application
   which
connects to a database to retrieve
 information.  I
noticed that if within my servlet I destroy
 the
connection to the database there is no way to
reconnect to the database .  In other words I
 need
   to
keep my connection to the database at all
 times
   that
tomcat is up.  My questions include:

 Is this correct that there is no way to
 reconnect
   to
the database?  If this is not correct, how
 does
   one
reconnect, and or reinitialize the servlet?
 Is keeping the persistent connection to the
   database
a heavy burden on tomcat?  In other words, is
 it
   o.k.
to design an application which never releases
 its
conenction to the database?
 

  I don't believe my question pertains
   specifically to
Tomcat, so I was wondering whether or not any
 of
   you
knew where there are list servers which deal
 with
servlets in general.

   
 __
Do You Yahoo!?
Make international calls for as low as
 $.04/minute
   with 
Yahoo! Messenger
http://phonecard.yahoo.com/

  
  
  __
  Do You Yahoo!?
  Make international calls for as low as $.04/minute
 with 
  Yahoo! Messenger
  http://phonecard.yahoo.com/
  


__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/



Re: [repost] Re: Limitations in using a different Ajp port than the standard ? (WAS Re: SAAAAAAAM! :))

2001-08-07 Thread Vincent Massol

ok, as no one is interested by the subject, I'll reply to my own question
  :)
By looking at the source code, I have found a workaround to stop Tomcat 3.3
on a custom AJP12 port and with a ContextManager home different from
tomcat.home :

Instead of using java -classpath tomcat.jar
org.apache.tomcat.Main -stop 
use: java -classpath stop-tomcat.jar org.apache.tomcatStopTomcat -ajp12
path to ajp file

I still find it strange that the behaviour changed as Tomcat 3.2.2 and
Tomcat 4.0 behave the same. Only 3.3 is different. I still don't know if it
is a bug or a feature ... :)

Thanks
-Vincent

- Original Message -
From: Vincent Massol [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: Pier P. Fumagalli [EMAIL PROTECTED]; [EMAIL PROTECTED]; Sam
Ruby [EMAIL PROTECTED]
Sent: Sunday, August 05, 2001 9:24 PM
Subject: [repost] Re: Limitations in using a different Ajp port than the
standard ? (WAS Re: SAAAM! :))


 Hi,
 I would like to use different ports than the standard Tomcat ones. For the
 HTTP listener, it works fine. However I am having trouble for the Ajp
 listener which is used to stop tomcat. The issue is the following :
 * When I start Tomcat I use my own server.xml file which is located in my
 own directory (I start Tomcat using the -config switch). In server.xml I
 also set the ContextManager home to be my own directory. So Tomcat
generates
 an ajp12.id file in _that_ directory (and not into Tomcat home directory,
 which is normal and fine). The tomcat home directory is set to be the
 directory where I have installed Tomcat.
 * No, when I want to stop Tomcat, it seems Tomcat looks for an ajp12.id
file
 but in the ${tomcat.home}/conf and _not_ in the directory defined in the
 ContextManager home or where my server.xml file is.

 In other words, it seems it is not possible to start 2 instances of Tomcat
 and only stop one running instance (the one with the different ajp port)
by
 using only one Tomcat installation ?

 Is that a bug, a feature or have I forgotten something ?

 Please note that it only fails on Tomcat 3.3 (I have tried it on 3.3-b1
and
 on the nighlty build of 2/8/2001). It works fine on Tomcat 3.2.1 and on
 Tomcat 4.0.

 Find below my start, stop scripts and relevant portion of server.xml

 Thanks a lot.
 -Vincent

  start script ---

 target name=start_tomcat_33

 java classname=org.apache.tomcat.startup.Main fork=yes
 jvmarg value=-Dtomcat.home=${tomcat.home.33}/
 arg value=-config/
 arg value=${out.tomcat33.full.dir}/conf/server.xml/
 classpath
 pathelement location=${java.home}/../lib/tools.jar/
 fileset dir=${tomcat.home.33}/lib
 include name=tomcat.jar/
 /fileset
 /classpath
 /java

 /target

  stop script ---

 target name=stop_tomcat_33

 java classname=org.apache.tomcat.startup.Main fork=yes
 jvmarg value=-Dtomcat.home=${tomcat.home.33}/
 arg value=-stop/
 arg value=-config/
 arg value=${out.tomcat33.full.dir}/conf/server.xml/
 classpath
 pathelement location=${java.home}/../lib/tools.jar/
 fileset dir=${tomcat.home.33}/lib
 include name=tomcat.jar/
 /fileset
 /classpath
 /java

 /target

  server.xml 

 [...]
 RequestInterceptor
  className=org.apache.tomcat.modules.server.Ajp12Interceptor
  tomcatAuthentication=false
  port=8777 /




 - Original Message -
 From: Sam Ruby [EMAIL PROTECTED]
 To: Pier P. Fumagalli [EMAIL PROTECTED]
 Cc: Vincent Massol [EMAIL PROTECTED]
 Sent: Thursday, August 02, 2001 2:27 AM
 Subject: Re: SAAAM! :)


  Vincent, can you take a look at changing the port numbers from 8080 to
  something unique?  Preferably, something controlable via a property?
 
  Pier - I was doing a test build of some changes to cactus...sorry.
 
  - Sam Ruby
 
 
  Pier P. Fumagalli [EMAIL PROTECTED] on 08/01/2001 09:23:49 PM
 
  To:   Sam Ruby/Raleigh/IBM@IBMUS
  cc:
  Subject:  SAAAM! :)
 
 
 
  What's going on on Nagoya and Tomcat 4.0? Huh? :)
  You little brat binding to my network ports and giving me BindExceptions
 :)
  Can you remove the config for the WARP connector from your TC4
  configuration?
  Cheers :)
 
  Pier
 
 
 
 








Re: Moving /WEB-INF/lib or adding to it in TC 4.0

2001-08-07 Thread Craig R. McClanahan



On Tue, 7 Aug 2001, D. Jay Newman wrote:

 If you're using Java 1.2+ you should be able to put these sorts of shared
 jars in the $JAVA_HOME/jre/lib/ext directory.
 
 It works for me.
 

Here are a few things to think about with this approach.

* Tomcat 3.2 (and above) let you run web apps under the control of a
  Java security manager, so you can grant fine-grained access to system
  facilities to your apps.  Any JAR files that are placed in the Java
  extensions directory ($JAVA_HOME/jre/lib/ext) receive the same
  permissions as all the core JDK classes -- something you may or may not
  want for application classes.

* (This issue applies to JARs in $TOMCAT_HOME/lib as well).  Not all
  JAR files will work when installed in a shared directory.  In general,
  containers will create a classloader that makes these classes visible,
  and then make that classloader a parent of the classloader for each
  webapp (the one that loads classes from /WEB-INF/classes and
  /WEB-INF/lib).  The problem happens when the shared JAR needs to create
  a new object of a class that is in your webapp's classloader -- unless
  it is programmed specifically to deal with this situation, the shared
  class will get ClassNotFoundException errors.

* In some environments, web apps need to use different versions of the
  same classes (for example, different versions of the same XML parser
  or JDBC driver) within the same VM.  Placing JAR files here makes it
  difficult or impossible to support different versions.

* If you are developing web apps to be packaged and deployed as WARs,
  you should prefer to include all required JARs inside (so that it is
  self contained).  This will minimize install hassles for your users.
  Depending on the user to also install external JARs in the right place
  makes life harder for them.

* On the other hand, if you need these classes in more than one web app,
  placing the JARs in $TOMCAT_HOME/lib or the extensions directory
  does save a little bit of memory.

Everything in life is a tradeoff ... there's no free lunch :-)

Craig




RE: web app in root directory

2001-08-07 Thread Larry Isaacs

Since you are not including a port in the URL, it
would appear that you are using Tomcat with Apache
or some other web server.  If so, which one?

Both Tomcat and the other web server have their own
idea of what the root context is.  This can cause
resources to not be visible because the wrong root
context is being accessed.

Please provide more detail about how Tomcat and
possibly the other web server are configured.

Cheers,
Larry

 -Original Message-
 From: Zhi Shen [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 2:44 PM
 To: '[EMAIL PROTECTED]'
 Subject: web app in root directory
 
 
 Hi,
 
 I'm interested in putting my web app in the root directory so 
 that people
 can get to it via http://x.com/index.html instead of
 http://x.com/myapp/index.html
 
 
 Whenever I change the server.xml file:
 
 Context path= 
   docBase=webapps/myapp 
   crossContext=true
   debug=0 
   reloadable=true  
 /Context
 
 Some of my subdirectories are not found, 
 http:/x.com/images/index.html and
 also whenever I goto admin http://x.com/admin/ I get the 
 Tomcat admin pages.
 
 
 Does anyone know how to configure this correctly? Thanks in advance.
 



RE: all those *-auto files

2001-08-07 Thread cmanolache

On Mon, 6 Aug 2001, Klaas van der Ploeg wrote:

 It is not yet optional (at least not in 3.2.3), but it is marked in the
 source with XXX to make it optional.

 You can comment it out and recompile Tomcat.java if you really want to get
 rid of those files.

It is optional in 3.3 ( and disabled by default ). You need to add
ApacheConfig ( or IISConfig, etc ) if you want them generated.

Also, in order to avoid mixing user-configuration and automaticly
generated files, all generated files go to conf/auto/

( there are other issues/ideas on this, but for now this should be the
first step ).

Costin




Re: Virtual Hosts on IIS Tomcat

2001-08-07 Thread cmanolache

On Fri, 3 Aug 2001, Knaggs, George R wrote:

 Mr Shachor / Tomcat-User,

 I hope you don't mind this email but I've been unable to find any
 information on how to configure IIS with Tomcat using a Virtual Host where
 the context path / URI is the root (http://one.domain.com/ and
 http://two.domain.com/).  I have more than one virtual host on this server
 and the uriworkermap.properties doesn't mention anything about configuring
 more than one host using the same uri /servlet/*.  The tomcat-iis-howto
 discusses a similar setup but the contexts have different URIs (/examples/*
 and /webpages/*).


There is work going on to fix this in jakarta-tomcat-connectors. One
workaround is to just forward all /servlet/* to tomcat, and configure
virtual host on tomcat.

Of course, the problems are very complex if you want static files served
by IIS, it can't be done without few fixes in mod_jk.


 I've also had trouble installing the isapi filter for an additional web site
 using the IIS management console.  It doesn't seem to be able load the
 filter a second time.  Is there anything that has to be configured
 differently for installing the filter on a second web-site on the same web
 server.

AFAIK you need a single instance of the isapi filter. The filter should
deal with virtual hosts - unfortunately the code is not yet completed. If
you know some C - you're wellcome to contribute :-)



 Can you please tell me if this is possible and if there is any documentation
 on how to set this up.  I've configured this many times with Apache but I'm
 locked into using IIS4.0 inorder to use a different ISAPI filter that
 provides single-signon features used at my company.

Sorry, I don't use windows. Integrating authentication mechanisms of
server and tomcat is very difficult, planned for a future version of jk.
( probably ajp14 )


Costin




RE: web app in root directory

2001-08-07 Thread Zhi Shen

I'm using IIS4.0 with Tomcat using isapi_redirect.

-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 3:03 PM
To: '[EMAIL PROTECTED]'
Subject: RE: web app in root directory


Since you are not including a port in the URL, it
would appear that you are using Tomcat with Apache
or some other web server.  If so, which one?

Both Tomcat and the other web server have their own
idea of what the root context is.  This can cause
resources to not be visible because the wrong root
context is being accessed.

Please provide more detail about how Tomcat and
possibly the other web server are configured.

Cheers,
Larry

 -Original Message-
 From: Zhi Shen [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 2:44 PM
 To: '[EMAIL PROTECTED]'
 Subject: web app in root directory
 
 
 Hi,
 
 I'm interested in putting my web app in the root directory so 
 that people
 can get to it via http://x.com/index.html instead of
 http://x.com/myapp/index.html
 
 
 Whenever I change the server.xml file:
 
 Context path= 
   docBase=webapps/myapp 
   crossContext=true
   debug=0 
   reloadable=true  
 /Context
 
 Some of my subdirectories are not found, 
 http:/x.com/images/index.html and
 also whenever I goto admin http://x.com/admin/ I get the 
 Tomcat admin pages.
 
 
 Does anyone know how to configure this correctly? Thanks in advance.
 



RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread Andrew Robson

Amos,
  Forgive if I've misunderstood but I get the impression you 
are not clear about the servlet lifecycle. 
The init method will be called once. (when exactly is dependant
on your servlet engine but it will be before any client requests)
You then have a single servlet instance which handles multiple requests
- each of which will be handled by a seperate thread.
(I'm simplifying a bit because some servlet engines will 
create a servlet instance per request in implementing 
the SingleThreadModel but leave that to one side just now)
It is the responsibility of the servlet engine to call destroy()
Typically when the servlet engine is shutdown.
So basically your servlet is running for the same period
of time as the servlet engine. For the lifetime of your servlet
engine you would only expect init and destroy to be called once
for each servlet.
It is not like CGI where each request fires up a process 
to run a new instance of your program.

Hope this helps and apologies if I'm telling you something
you already know.

andrew

On Tue, 07 Aug 2001, you wrote:
 William,
thanks.  IOt turns out that after looking at my
 problem in a little more detail, I figured this must
 be the issue.  I guess this leads to another question.
  Once you destroy a servlet, can you reinitialize it. 
 If so how?
 
 thanks,
-Amos
 --- William Kaufman [EMAIL PROTECTED] wrote:
   This is not really a jdbc issue.  What is
  happening is
   that my code specifies that the conenction to the
   database is made only during the init of the
  servlet
   and the conenction is closed after the servlet is
   destroyed.
  
  Ah, OK.  Don't do that.
  
  init() is called exactly once, when the servlet gets
  loaded.
  
  If you want to close and re-allocate the connection,
  do it in your
  doGet()/doPost()/doWhatever() methods (if you've
  overridden those) or in
  your service() method (if you didn't): connect at
  the beginning,
  commit/rollback and close at the end (preferrably in
  a finally block, to
  make sure it gets done).
  
  -- Bill K. 
  
   -Original Message-
   From: A.L. [mailto:[EMAIL PROTECTED]]
   Sent: Tuesday, August 07, 2001 10:27 AM
   To: [EMAIL PROTECTED]
   Subject: RE: Servlet/ Database Conenction Persists
  Question
   
   
   This is not really a jdbc issue.  What is
  happening is
   that my code specifies that the conenction to the
   database is made only during the init of the
  servlet
   and the conenction is closed after the servlet is
   destroyed.  I think that my problem is that once I
   destroy the servlet, I can't figure a way to re
   initialize it.  Simply refreshing the servlet page
   doesn;t seem to work.
   --- William Kaufman [EMAIL PROTECTED] wrote:
 I have developed a servlet web application
which
 connects to a database to retrieve
  information.  I
 noticed that if within my servlet I destroy
  the
 connection to the database there is no way to
 reconnect to the database .

Maybe this is a JSP thing (I'm not too familiar
  with
those), and JSPs have
some weird JDBC cover methods.  But you _should_
  be
able to disconnect, by
calling Connection.close(); and to reconnect,
  the
same way you connected the
first time.

Why can't you reconnect?  Are you getting an
exception from
DriverManager.getConnection()?

  Is keeping the persistent connection to the
database
 a heavy burden on tomcat?

Persistent connections aren't a burden on
  Tomcat,
but might be on your
database, especially if the modifications aren't
committed immediately.  You
should always try to close connections (and
  other
resources) if you don't
think you'll be using it again in a few seconds.

   I don't believe my question pertains
specifically to
 Tomcat, so I was wondering whether or not any
  of
you
 knew where there are list servers which deal
  with
 servlets in general.

This mailing list is fine for general servlet
questions.  But this seems to
be a JDBC question,...

-- Bill
  K. 

 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 9:07 AM
 To: [EMAIL PROTECTED]
 Subject: Servlet/ Database Conenction Persists
Question
 
 
 I have developed a servlet web application
which
 connects to a database to retrieve
  information.  I
 noticed that if within my servlet I destroy
  the
 connection to the database there is no way to
 reconnect to the database .  In other words I
  need
to
 keep my connection to the database at all
  times
that
 tomcat is up.  My questions include:
 
  Is this correct that there is no way to
  reconnect
to
 the database?  If this is not correct, how
  does
one
 reconnect, and or 

RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread A.L.

Andrew,
   Thank you for your response.  I appreciate you
clarifying the topic, nevertheless it seems to me a
little troubling to assume that the servlet should
only be destroyed by the servlet.   (I'm new to
servlets, but by servlet engine, I am assuming you
mean tomcat).

   Here is why.  Lets say there is an application
whose web interface is run by servlets, while the
desktop app isn't.  If there is a problem with the
database which needs to be fixed I would ahave to stop
tomcat so that I may gain complete access to the
database.  In Microsoft Access for example I cannot
enter design view if a servlet has an existing
connection.  Which means I will have to stop the
complete web application even though the only part
which needs to be destroyed is the servlet with the db
connection.   i would like to destroy the servlet
temporarily, and then reinitialize it via the web.
Would this be possible?



--- Andrew Robson [EMAIL PROTECTED]
wrote:
 Amos,
   Forgive if I've misunderstood but I get the
 impression you 
 are not clear about the servlet lifecycle. 
 The init method will be called once. (when exactly
 is dependant
 on your servlet engine but it will be before any
 client requests)
 You then have a single servlet instance which
 handles multiple requests
 - each of which will be handled by a seperate
 thread.
 (I'm simplifying a bit because some servlet engines
 will 
 create a servlet instance per request in
 implementing 
 the SingleThreadModel but leave that to one side
 just now)
 It is the responsibility of the servlet engine to
 call destroy()
 Typically when the servlet engine is shutdown.
 So basically your servlet is running for the same
 period
 of time as the servlet engine. For the lifetime of
 your servlet
 engine you would only expect init and destroy to be
 called once
 for each servlet.
 It is not like CGI where each request fires up a
 process 
 to run a new instance of your program.
 
 Hope this helps and apologies if I'm telling you
 something
 you already know.
 
 andrew
 
 On Tue, 07 Aug 2001, you wrote:
  William,
 thanks.  IOt turns out that after looking at my
  problem in a little more detail, I figured this
 must
  be the issue.  I guess this leads to another
 question.
   Once you destroy a servlet, can you reinitialize
 it. 
  If so how?
  
  thanks,
 -Amos
  --- William Kaufman [EMAIL PROTECTED] wrote:
This is not really a jdbc issue.  What is
   happening is
that my code specifies that the conenction to
 the
database is made only during the init of the
   servlet
and the conenction is closed after the servlet
 is
destroyed.
   
   Ah, OK.  Don't do that.
   
   init() is called exactly once, when the servlet
 gets
   loaded.
   
   If you want to close and re-allocate the
 connection,
   do it in your
   doGet()/doPost()/doWhatever() methods (if you've
   overridden those) or in
   your service() method (if you didn't): connect
 at
   the beginning,
   commit/rollback and close at the end
 (preferrably in
   a finally block, to
   make sure it gets done).
   
   -- Bill
 K. 
   
-Original Message-
From: A.L. [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 10:27 AM
To: [EMAIL PROTECTED]
Subject: RE: Servlet/ Database Conenction
 Persists
   Question


This is not really a jdbc issue.  What is
   happening is
that my code specifies that the conenction to
 the
database is made only during the init of the
   servlet
and the conenction is closed after the servlet
 is
destroyed.  I think that my problem is that
 once I
destroy the servlet, I can't figure a way to
 re
initialize it.  Simply refreshing the servlet
 page
doesn;t seem to work.
--- William Kaufman [EMAIL PROTECTED]
 wrote:
  I have developed a servlet web
 application
 which
  connects to a database to retrieve
   information.  I
  noticed that if within my servlet I
 destroy
   the
  connection to the database there is no way
 to
  reconnect to the database .
 
 Maybe this is a JSP thing (I'm not too
 familiar
   with
 those), and JSPs have
 some weird JDBC cover methods.  But you
 _should_
   be
 able to disconnect, by
 calling Connection.close(); and to
 reconnect,
   the
 same way you connected the
 first time.
 
 Why can't you reconnect?  Are you getting an
 exception from
 DriverManager.getConnection()?
 
   Is keeping the persistent connection to
 the
 database
  a heavy burden on tomcat?
 
 Persistent connections aren't a burden on
   Tomcat,
 but might be on your
 database, especially if the modifications
 aren't
 committed immediately.  You
 should always try to close connections (and
   other
 resources) if you don't
 think you'll be using it again in a few
 seconds.
 
I don't believe my question pertains
 specifically 

Servlet Through Apache Slow only on local machine

2001-08-07 Thread Baker, Gary


 Hi,
 
I just installed apache 1.3.20 and tomcat 3.2.3 on a 
Windows 2000 machine. The tomcat servlet examples are
fast if I access them  directly through tomcat ( port 8080 ),
but extremely slow when I access them through Apache.  The 
funny thing is that it is only slow when accessed from browser
on  the same machine, it works fine when accessed from
another machine.  I checked the mail archives and saw something
about changing the log level to error in mod_jk.conf but that  didn't
make any difference. Any Ideas?
 
Thanks, Gary
[EMAIL PROTECTED]



Sharing dll btwn two webapps (Unsatisfied Link Error)

2001-08-07 Thread Mariam Tariq

I have a  webapp in which I am getting the following error:

java.lang.UnsatisfiedLinkError:
 Native Library D:\Program
Files\Project\MT\servletd\bin\com_mt_sharedutils100.dll already loaded in
another classloader
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1346)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1306)
at java.lang.Runtime.loadLibrary0(Runtime.java:749)
at java.lang.System.loadLibrary(System.java:820)


Another webapp has already loaded this dll. I found a related issue on Sun's
website where it says A workaround would be to have the class that loads a
native library
be loaded by a shared classloader (through the parenting mechanism of
ClassLoaders in 1.2).

I can't find any info on how to set up a shared classloader. Basically this
dll
which I am trying to access sits in $TOMCAT_HOME/bin. The webapps sit in
different
location NOT under $TOMCAT_HOME.

Any help would be greatly apprecited.

Mariam




RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread Randy Layman



 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 4:23 PM
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: RE: Servlet/ Database Conenction Persists Question
 
 
 Andrew,
Thank you for your response.  I appreciate you
 clarifying the topic, nevertheless it seems to me a
 little troubling to assume that the servlet should
 only be destroyed by the servlet.   (I'm new to
 servlets, but by servlet engine, I am assuming you
 mean tomcat).
 
Here is why.  Lets say there is an application
 whose web interface is run by servlets, while the
 desktop app isn't.  If there is a problem with the
 database which needs to be fixed I would ahave to stop
 tomcat so that I may gain complete access to the
 database.  In Microsoft Access for example I cannot
 enter design view if a servlet has an existing
 connection.  Which means I will have to stop the
 complete web application even though the only part
 which needs to be destroyed is the servlet with the db
 connection.   i would like to destroy the servlet
 temporarily, and then reinitialize it via the web.
 Would this be possible?
 
 

Your problem seems to be more of a lack of distributed systems and
client/server programming knowledge in general rather than the specifics of
Servlet programming.  A desktop application is just that, it runs on a
desktop when a user needs it, etc.  A web SERVER, however, is always on,
always waiting for users to give it actions to perform.

I've dealt with this type of problem in two different ways (and
there are probably others out there).  

The first is to shut down Tomcat.  Generally if I'm changing the
schema then I'm performing a long lasting update that might take a few
minutes to a few hours.  During that time I don't want users working with a
partially updated database, usually with either new or old code.

The second way that I have dealt with this problem (and possibly
more applicable in your case) it to encapsulate the database access into an
underlying component with static fields.  Then, I create a database
controller servlet.  This servlet usually takes request like
controller?action=startup or controller?action=stop that would create the
database connection pool, drop all the actives (you need to think about what
to do if something is using the database here), reload configuration, etc.

Another thing you need to be warned about is using Access.  I assume
you are using it because you mention it.  This is a pretty bad choice for a
server-based product for a number of reasons, not the least of which deals
with the concurrency problems of the JDBC-0DBC bridge (you can find more
information about that either in the archives or on Sun's Bug Parade).

Randy



RE: Servlet/ Database Conenction Persists Question

2001-08-07 Thread William Kaufman

If you don't want a database connection to persist, just don't keep it
around.

Your first option is to create it each time in your service routine, and
close it before you return.

A second option would be to keep it around (e.g., in a session attribute),
and create it in your service routine only if it doesn't already exist.
Then, you define a particular URL parameter: when you get that parameter,
close the connection and null out the reference.

There's no reason to change the definition of init() for this particular
case.

-- Bill K. 

 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 1:23 PM
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: RE: Servlet/ Database Conenction Persists Question
 
 
 Andrew,
Thank you for your response.  I appreciate you
 clarifying the topic, nevertheless it seems to me a
 little troubling to assume that the servlet should
 only be destroyed by the servlet.   (I'm new to
 servlets, but by servlet engine, I am assuming you
 mean tomcat).
 
Here is why.  Lets say there is an application
 whose web interface is run by servlets, while the
 desktop app isn't.  If there is a problem with the
 database which needs to be fixed I would ahave to stop
 tomcat so that I may gain complete access to the
 database.  In Microsoft Access for example I cannot
 enter design view if a servlet has an existing
 connection.  Which means I will have to stop the
 complete web application even though the only part
 which needs to be destroyed is the servlet with the db
 connection.   i would like to destroy the servlet
 temporarily, and then reinitialize it via the web.
 Would this be possible?
 
 
 
 --- Andrew Robson [EMAIL PROTECTED]
 wrote:
  Amos,
Forgive if I've misunderstood but I get the
  impression you 
  are not clear about the servlet lifecycle. 
  The init method will be called once. (when exactly
  is dependant
  on your servlet engine but it will be before any
  client requests)
  You then have a single servlet instance which
  handles multiple requests
  - each of which will be handled by a seperate
  thread.
  (I'm simplifying a bit because some servlet engines
  will 
  create a servlet instance per request in
  implementing 
  the SingleThreadModel but leave that to one side
  just now)
  It is the responsibility of the servlet engine to
  call destroy()
  Typically when the servlet engine is shutdown.
  So basically your servlet is running for the same
  period
  of time as the servlet engine. For the lifetime of
  your servlet
  engine you would only expect init and destroy to be
  called once
  for each servlet.
  It is not like CGI where each request fires up a
  process 
  to run a new instance of your program.
  
  Hope this helps and apologies if I'm telling you
  something
  you already know.
  
  andrew
  
  On Tue, 07 Aug 2001, you wrote:
   William,
  thanks.  IOt turns out that after looking at my
   problem in a little more detail, I figured this
  must
   be the issue.  I guess this leads to another
  question.
Once you destroy a servlet, can you reinitialize
  it. 
   If so how?
   
   thanks,
  -Amos
   --- William Kaufman [EMAIL PROTECTED] wrote:
 This is not really a jdbc issue.  What is
happening is
 that my code specifies that the conenction to
  the
 database is made only during the init of the
servlet
 and the conenction is closed after the servlet
  is
 destroyed.

Ah, OK.  Don't do that.

init() is called exactly once, when the servlet
  gets
loaded.

If you want to close and re-allocate the
  connection,
do it in your
doGet()/doPost()/doWhatever() methods (if you've
overridden those) or in
your service() method (if you didn't): connect
  at
the beginning,
commit/rollback and close at the end
  (preferrably in
a finally block, to
make sure it gets done).

-- Bill
  K. 

 -Original Message-
 From: A.L. [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 10:27 AM
 To: [EMAIL PROTECTED]
 Subject: RE: Servlet/ Database Conenction
  Persists
Question
 
 
 This is not really a jdbc issue.  What is
happening is
 that my code specifies that the conenction to
  the
 database is made only during the init of the
servlet
 and the conenction is closed after the servlet
  is
 destroyed.  I think that my problem is that
  once I
 destroy the servlet, I can't figure a way to
  re
 initialize it.  Simply refreshing the servlet
  page
 doesn;t seem to work.
 --- William Kaufman [EMAIL PROTECTED]
  wrote:
   I have developed a servlet web
  application
  which
   connects to a database to retrieve
information.  I
   noticed that if within my servlet I
  destroy
the
   connection to the database there 

RE: web app in root directory

2001-08-07 Thread Larry Isaacs

I assume your IIS Home Directory is set to something other
than TOMCAT_HOME\webapps\ROOT, such as the IIS default
C:\Inetpub\wwwroot.  Since IIS will serve static resources,
a URL like http:/x.com/images/index.html will look for a
file named C:\Inetpub\wwwroot\images\index.html which
likely doesn't exist.

I'm not familiar with IIS enough to know how well
isapi_redirect can take control of the root context.
You can try pointing IIS's Home Directory to
TOMCAT_HOME\webapps\ROOT, which should allow those
missing pages to be found.

I can't tell if http://x.com/admin/ showing Tomcat's admin
webapp should be expected without seeing the uriworkermap
file you are using.  If the right statements are present
this behavior would be normal.

Note, the comments above makes some assumptions about your
configuration that haven't actually been specified. For
example, I am assuming you are using a version of
Tomcat 3.2.x.

Cheers,
Larry

 -Original Message-
 From: Zhi Shen [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:37 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 I'm using IIS4.0 with Tomcat using isapi_redirect.
 
 -Original Message-
 From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:03 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 Since you are not including a port in the URL, it
 would appear that you are using Tomcat with Apache
 or some other web server.  If so, which one?
 
 Both Tomcat and the other web server have their own
 idea of what the root context is.  This can cause
 resources to not be visible because the wrong root
 context is being accessed.
 
 Please provide more detail about how Tomcat and
 possibly the other web server are configured.
 
 Cheers,
 Larry
 
  -Original Message-
  From: Zhi Shen [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 2:44 PM
  To: '[EMAIL PROTECTED]'
  Subject: web app in root directory
  
  
  Hi,
  
  I'm interested in putting my web app in the root directory so 
  that people
  can get to it via http://x.com/index.html instead of
  http://x.com/myapp/index.html
  
  
  Whenever I change the server.xml file:
  
  Context path= 
docBase=webapps/myapp 
crossContext=true
debug=0 
reloadable=true  
  /Context
  
  Some of my subdirectories are not found, 
  http:/x.com/images/index.html and
  also whenever I goto admin http://x.com/admin/ I get the 
  Tomcat admin pages.
  
  
  Does anyone know how to configure this correctly? Thanks in advance.
  
 



PLEASE UNSUBSCRIBE ME FROM THIS LIST

2001-08-07 Thread Jockel, Jeff

PLEASE PLEASE UNSUBSCRIBE FROM THIS LIST

-Original Message-
From: Felix Guerrero [mailto:[EMAIL PROTECTED]]
Sent: Thursday, August 02, 2001 9:11 PM
To: [EMAIL PROTECTED]
Subject: Newbie: Problem integrating with IIS


Hi,

Tomcat runs fine on its own port. However, when the request is made through 
IIS this is the output in the isapi log file:
[jk_isapi_plugin.c (408)]: HttpFilterProc started
[jk_isapi_plugin.c (429)]: In HttpFilterProc test redirection of 
/examples/jsp/index.jsp
[jk_uri_worker_map.c (345)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (407)]: jk_uri_worker_map_t::map_uri_to_worker, Found a

match ajp12
[jk_isapi_plugin.c (439)]: HttpFilterProc [/examples/jsp/index.jsp] is a 
servlet url - should redirect to ajp12
[jk_isapi_plugin.c (461)]: HttpFilterProc check if [/examples/jsp/index.jsp]

is points to the web-inf directory

I am simply trying to execute the examples application.
Any help will be greatly appreciated.

Felix.



_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp



RE: web app in root directory

2001-08-07 Thread Zhi Shen

Hi all,

Thanks for helping me out.  Found the problem with the subdirectories not
found.

The problem was in IIS the pages are case-insensitive but in Tomcat it is
case-sensitive.

-zhi

-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 4:49 PM
To: '[EMAIL PROTECTED]'
Subject: RE: web app in root directory


I assume your IIS Home Directory is set to something other
than TOMCAT_HOME\webapps\ROOT, such as the IIS default
C:\Inetpub\wwwroot.  Since IIS will serve static resources,
a URL like http:/x.com/images/index.html will look for a
file named C:\Inetpub\wwwroot\images\index.html which
likely doesn't exist.

I'm not familiar with IIS enough to know how well
isapi_redirect can take control of the root context.
You can try pointing IIS's Home Directory to
TOMCAT_HOME\webapps\ROOT, which should allow those
missing pages to be found.

I can't tell if http://x.com/admin/ showing Tomcat's admin
webapp should be expected without seeing the uriworkermap
file you are using.  If the right statements are present
this behavior would be normal.

Note, the comments above makes some assumptions about your
configuration that haven't actually been specified. For
example, I am assuming you are using a version of
Tomcat 3.2.x.

Cheers,
Larry

 -Original Message-
 From: Zhi Shen [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:37 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 I'm using IIS4.0 with Tomcat using isapi_redirect.
 
 -Original Message-
 From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:03 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 Since you are not including a port in the URL, it
 would appear that you are using Tomcat with Apache
 or some other web server.  If so, which one?
 
 Both Tomcat and the other web server have their own
 idea of what the root context is.  This can cause
 resources to not be visible because the wrong root
 context is being accessed.
 
 Please provide more detail about how Tomcat and
 possibly the other web server are configured.
 
 Cheers,
 Larry
 
  -Original Message-
  From: Zhi Shen [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 2:44 PM
  To: '[EMAIL PROTECTED]'
  Subject: web app in root directory
  
  
  Hi,
  
  I'm interested in putting my web app in the root directory so 
  that people
  can get to it via http://x.com/index.html instead of
  http://x.com/myapp/index.html
  
  
  Whenever I change the server.xml file:
  
  Context path= 
docBase=webapps/myapp 
crossContext=true
debug=0 
reloadable=true  
  /Context
  
  Some of my subdirectories are not found, 
  http:/x.com/images/index.html and
  also whenever I goto admin http://x.com/admin/ I get the 
  Tomcat admin pages.
  
  
  Does anyone know how to configure this correctly? Thanks in advance.
  
 



RE: web app in root directory

2001-08-07 Thread Zhi Shen

I have my IIS pointing to TOMCAT_HOME\webapps\myapp and also set
server.xml to 

Context path=/ 
   docBase=webapps/myapp 
   crossContext=true
   debug=0 
   reloadable=true  
/Context

But there are some subfolders that are unreachable.  I will try to point
everything to ROOT and see what happens.

-zhi


-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 4:49 PM
To: '[EMAIL PROTECTED]'
Subject: RE: web app in root directory


I assume your IIS Home Directory is set to something other
than TOMCAT_HOME\webapps\ROOT, such as the IIS default
C:\Inetpub\wwwroot.  Since IIS will serve static resources,
a URL like http:/x.com/images/index.html will look for a
file named C:\Inetpub\wwwroot\images\index.html which
likely doesn't exist.

I'm not familiar with IIS enough to know how well
isapi_redirect can take control of the root context.
You can try pointing IIS's Home Directory to
TOMCAT_HOME\webapps\ROOT, which should allow those
missing pages to be found.

I can't tell if http://x.com/admin/ showing Tomcat's admin
webapp should be expected without seeing the uriworkermap
file you are using.  If the right statements are present
this behavior would be normal.

Note, the comments above makes some assumptions about your
configuration that haven't actually been specified. For
example, I am assuming you are using a version of
Tomcat 3.2.x.

Cheers,
Larry

 -Original Message-
 From: Zhi Shen [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:37 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 I'm using IIS4.0 with Tomcat using isapi_redirect.
 
 -Original Message-
 From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 3:03 PM
 To: '[EMAIL PROTECTED]'
 Subject: RE: web app in root directory
 
 
 Since you are not including a port in the URL, it
 would appear that you are using Tomcat with Apache
 or some other web server.  If so, which one?
 
 Both Tomcat and the other web server have their own
 idea of what the root context is.  This can cause
 resources to not be visible because the wrong root
 context is being accessed.
 
 Please provide more detail about how Tomcat and
 possibly the other web server are configured.
 
 Cheers,
 Larry
 
  -Original Message-
  From: Zhi Shen [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, August 07, 2001 2:44 PM
  To: '[EMAIL PROTECTED]'
  Subject: web app in root directory
  
  
  Hi,
  
  I'm interested in putting my web app in the root directory so 
  that people
  can get to it via http://x.com/index.html instead of
  http://x.com/myapp/index.html
  
  
  Whenever I change the server.xml file:
  
  Context path= 
docBase=webapps/myapp 
crossContext=true
debug=0 
reloadable=true  
  /Context
  
  Some of my subdirectories are not found, 
  http:/x.com/images/index.html and
  also whenever I goto admin http://x.com/admin/ I get the 
  Tomcat admin pages.
  
  
  Does anyone know how to configure this correctly? Thanks in advance.
  
 



RE: Catalina: How to specify factory class name for a Resource inserver.xml

2001-08-07 Thread Roytman, Alex

Craig,

Thank you very much for your help. I have one more question. Why new
instance of my factory gets created every time I lookup for a resource
created by this factory?


-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 5:05 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: Catalina: How to specify factory class name for a Resource
inserver.xml




On Tue, 7 Aug 2001, Roytman, Alex wrote:

 
 
 Hello,
 
 I am writing several jndi factories for catalina's JNDI implementation
 and I am trying to figure out how to specify factory class for a
 resource. The only sample I found was
 Resource name=jdbc/usorg auth=CONTAINER
 type=javax.sql.DataSource/
 and factory class for type=javax.sql.DataSource is hard coded. 
 How do I specify factory class for my resource?
 

In server.xml, you configure the actual resource with a
ResourceParams,
which can have nested parameter entries.  Use a parameter named
FACTORY
to define the fully qualified clas name of the resource factory class
itself.

Alternatively, you can pass system properties that define the factory
for
a particular resource type.  For example, to set the factory class name
for a resource type com.mycompany.Foo, you could say:

  export \
 
CATALINA_OPTS=-Dcom.mycompany.Foo.Factory=com.mycompany.MyFooFactory

before starting Tomcat 4.

 Thank you very much
 
 Alex Roytman
 

Craig





  1   2   >