Re: Tomcat, webapp, SSL, and index files?

2002-04-03 Thread Gary McGowan

 there is actually a setting where you can force it to say
 'https'.

What is this setting?

and please do kep me informed of your progress.
- Original Message -
From: Joseph Molnar [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 9:14 AM
Subject: Re: Tomcat, webapp, SSL, and index files?


 I am actually in the process of doing just that.  I currently have it
 partially working (I at least have directory browsing and simple serving
 working through Tomcat);  I am using Tomcat 4.0.3. There are really no
docs
 on the Apache site (as of yesterday), but been getting through it thus far
 tonight.

 In terms of Tomcat returning back that it is actually 'https' vs 'http'
for
 the protocol, there is actually a setting where you can force it to say
 'https'. This was purposely done since Apache (the web server :),
obviously
 handles the SSL side and to Tomcat it is nothing more than standard web
 serving.

 If you would like I can fill you in as I get going on it.

 
 Joseph Molnar
 http://www.codesta.com/



 - Original Message -
 From: Gary McGowan [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Sent: Tuesday, April 02, 2002 11:59 PM
 Subject: Re: Tomcat, webapp, SSL, and index files?


  Yea - 'intended' being the key word here...
 
  From my experience, mod_webapp isn't as flexible as mod_jk
 
  I may be wrong, but I have not yet seen a solution for mod_webapp and
 https
  redirects.
 
  Gary
  - Original Message -
  From: Ralph Einfeldt [EMAIL PROTECTED]
  To: Tomcat Users List [EMAIL PROTECTED]
  Sent: Wednesday, April 03, 2002 8:41 AM
  Subject: AW: Tomcat, webapp, SSL, and index files?
 
 
  Although that sounds like a good explanation, what makes you
  think that this applies to tomcat 4 and mod_webapp ?
 
  At the time this was written mod_webapp didn't even exist. This
  remark is about mod_jserv vs. mod_jk.
 
  (As mod_webapp is intended as the successor of mod_jk it's
   a 'downgrade')
 
   -Ursprüngliche Nachricht-
   Von: Gary McGowan [mailto:[EMAIL PROTECTED]]
   Gesendet: Mittwoch, 3. April 2002 09:11
   An: Tomcat Users List
   Betreff: Re: Tomcat, webapp, SSL, and index files?
  snip/
   Looking at the tomcat-apache how to :
   http://jakarta.apache.org/tomcat/tomcat-3.2-doc/tomcat-apache-
   howto.html
  snip/
   mod_ssl - getScheme() always returns HTTP!
  snip/
   So in short - you need to upgrade from webapp to mod_jk.
  snip/
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
 
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
 

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




problem with large servlets( classes )?

2002-04-03 Thread Mikkel Lindhard

We are having a not so fun problem with the size of our controller servlet
class loaded( could be file size, could be other size problems )
basically were getting this error when adding one more line of code( of any
kind ) in our controller servlet:

java.lang.VerifyError: (class: ServletName, method: function signature:
(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletRespo
nse;)V) Illegal instruction found at offset XX
at java.lang.Class.newInstance0(Native Method)
at java.lang.Class.newInstance(Class.java:237)
at
org.apache.tomcat.core.ServletWrapper.loadServlet(ServletWrapper.java:268)


We stumpled across this error, but that isnt the case in our situation so i
guess something else can trigger this error.
http://developer.java.sun.com/developer/bugParade/bugs/4223705.html

the servlet is around 93 kb compiled now and works.

setup:
Tomcat 3.2.1
JDK build 1.3.1_02-b02
Win2k Server

thanks in advance
Mikkel


---
[Denne E-mail blev scannet for virus af Declude Virus]
[This E-mail was scanned for viruses by Declude Virus]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Deployment Question

2002-04-03 Thread Neo Gigs

Hi there,

How does I can deploy a EAR, WAR or JAR file into Tomcat server? Does there have any 
deployment tools available like deploytool that can deploy applications into J2EE 
server?

Thanks

Neo



Tomcat and JWSDP

2002-04-03 Thread Lenhart Stefan

Hi everyone!

I'm trying to develop a small WebService example and therefore use Sun's
Java WebService Development Pack which has a Tomcat version 4.something
distribution included.

Packaging the service class into a war file is no problem, and on startup
Tomcat extracts the war archive to the appropriate subdirectory of webapps.
No problem so far. But when I'm trying to access the webapp in my browser
(http://localhost:8080/kredit) I get a 404 error message although I've got
an index.html file in the /kredit directory.

I checked the log file, and found that on startup this error occurs:

2002-04-03 09:58:25 ContextConfig[/kredit] Parse error in application
web.xml
java.lang.Exception: Can't open config file:
java.io.ByteArrayInputStream@2ae94f due to: java.io.UTFDataFormatException:
invalid byte 1 of 1-byte UTF-8 sequence (0xfc)
at
org.apache.catalina.util.xml.XmlMapper.readXml(XmlMapper.java:282)
at
org.apache.catalina.startup.ContextConfig.applicationConfig(ContextConfig.ja
va:256)
at
org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:824)
at
org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:
224)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor
t.java:155)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1131)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:3345)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:785)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:454)
at
org.apache.catalina.core.StandardHost.install(StandardHost.java:714)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:324)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:389)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:232)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor
t.java:155)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1131)
at
org.apache.catalina.core.StandardHost.start(StandardHost.java:614)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1123)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:307)
at
org.apache.catalina.core.StandardService.start(StandardService.java:388)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:505)
at org.apache.catalina.startup.Catalina.start(Catalina.java:781)
at org.apache.catalina.startup.Catalina.execute(Catalina.java:681)
at org.apache.catalina.startup.Catalina.process(Catalina.java:179)
at java.lang.reflect.Method.invoke(Native Method)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)


Anybody had this problem before? Any ideas?

Thx in advance!


Mit freundlichen Gruessen

Stefan Lenhart

R. Boeker Consulting GmbH
Ein Unternehmen der R. Boeker Unternehmensgruppe AG
RBU AG Zweigniederlassung Frankfurt
Mergenthalerallee 77
D-65760 Eschborn

Tel.:+49 (61 96) 4 70-883
Fax.:+49 (61 96) 4 70-8 90
E-Mail:  mailto:[EMAIL PROTECTED]
Internet: http://www.rbu.de

Diese eMail enthält möglicherweise vertrauliche und/oder rechtlich
geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder
diese eMail irrtümlich erhalten haben, informieren Sie bitte sofort den
Absender und vernichten diese eMail. Das unerlaubte Kopieren sowie die
unbefugte Weitergabe dieser eMail ist nicht gestattet.

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorised copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




AW: Deployment Question

2002-04-03 Thread Lenhart Stefan

Hi Neo!

If you haven't set the unpackWars attribute of your host element in
server.xml to false, Tomcat should be extracting the archives automatically
on startup. Just copy the archive file to your webapps directory and TC will
create a subdirectory with the archive's name in the work directory as soon
as you restart.

Cheers
Stefan

 -Ursprüngliche Nachricht-
 Von:  Neo Gigs [SMTP:[EMAIL PROTECTED]]
 Gesendet am:  Mittwoch, 3. April 2002 10:54
 An:   Tomcat Users List
 Betreff:  Deployment Question
 
 Hi there,
 
 How does I can deploy a EAR, WAR or JAR file into Tomcat server? Does
 there have any deployment tools available like deploytool that can
 deploy applications into J2EE server?
 
 Thanks
 
 Neo

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: sessions, security, and the RFCs

2002-04-03 Thread Anders Rundgren

Ralph,
I could not find anything that disallow switching between https and http
in any order while maintaining.  Although not a particularly good
idea, it is anyhow used out there to protect passwords but be
less protective about the session.

I think that security issues should be dealt with as options to not outlaw
schemes that actually are used.

cheers,
Anders

- Original Message -
From: Ralph Einfeldt [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 09:28
Subject: AW: AW: AW: sessions, security, and the RFCs



I can't find in the spec that the session shall
be maintained if you switch from http to https.

Can you provide a reference?

Wouldn't this be as dangerous as to keep the
session after you go back from SSL to non-SSL ?
As I see it, this would open the door to anyone
who could listen to the http network traffic to
steel the secure session.

| SRV.7.1.2 SSL Sessions
| Secure Sockets Layer, the encryption technology
| used in the HTTPS protocol, has a mechanism built
| into it allowing multiple requests from a client
| to be unambiguously identified as being part of a
| session. A servlet container can easily use this
| data to define a session.

| 12.8 ...
| The container must at least use SSL to respond to
| requests to resources marked integral or confidential.
| If the original request was over HTTP, the container
| must redirect the client to the HTTPS port.

 -Ursprüngliche Nachricht-
 Von: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
 Gesendet: Dienstag, 2. April 2002 18:47
 An: Tomcat Users List
 Betreff: Re: AW: AW: sessions, security, and the RFCs
snip/
 Servlet 2.3 (basis for Tomcat 4.x) added some specific
 requirements (such as the ability to redirect from the
 non-SSL port to the SSL port and maintain the session).
snip/
 Note -- anyone who goes from the SSL port back to the
 non-SSL port has just created a security hole.

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: JSP and MYSQL: Connection Sample??

2002-04-03 Thread yilmaz

Hi subceero,
Obviously you need to establish your own mysql database and table,
here is a simple sample jsp file to give you some hints to get you started.
Change the connection parameters in connect.jsp file, and create a sample
table
according to sample jsp (test.jsp) parameters.
Hope it helps .
Cheers :)
(note: put test.jsp and connect.jsp in the same directory)
- Original Message -
From: subceero [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 5:47 AM
Subject: JSP and MYSQL: Connection Sample??


Hi everyone,

Does anyone of you have a sample SMALL code of a mysql-connection from jsp?
just to check if the connection can be established.

Thanks in advance

Subceero




connect.jsp
Description: Binary data


test.jsp
Description: Binary data

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


How to configure MySql ( mm.mysql-2.0.4-bin.jar ) in Tomcat v4

2002-04-03 Thread Chuck Amadi

How to configure MySql   ( mm.mysql-2.0.4-bin.jar ) in Tomcat v4 i have 
a copy of the jar file in my /WEB-INF/lib dir.

Thus i tried to create a tld.file and a tag element none worked so is 
there a correct procedure as PostgreSql worked ok with the dbtags.jar.

So Plz reply as this is severly holding me up as i have choice of MySql 
or PostgreSql back-end Db i prefer Mysql look and feel.

So any suggestions welcome
Cheers
Chuc Amadi
Systems Programmer



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Connection Apache - Tomcat

2002-04-03 Thread [EMAIL PROTECTED]

Hi,

the root of my webapplication is:
/home/my-user/public_html/docroot/my-app/

I tried to configure Apache and Tomcat to serv the web form this path without success.
Apache is recognizing that webapplication when I access files within the docroot 
folder but not within the wwa-m/ folder (as supposed!)
Tomcat is working fine with the servic running the 8080 port.
But I am getting an 404 Error wenn I directly access the wwa-m folder.

server.xml:

Service name=Tomcat-Apache

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

!-- Replace localhost with what your Apache
ServerName is set to --
   Engine className=org.apache.catalina.connector.warp.WarpEngine
   name=apache.nandgate.com debug=0
   appBase=webapps !-- ich denke hier muß es passieren --

  !-- Global logger unless overridden at
  lower levels --
  Logger className=
  org.apache.catalina.logger.FileLogger
  prefix=apache_log. suffix=.txt
  timestamp=true/

  !-- Because this Realm is here, an instance
  will be shared globally --
  Realm className=
 org.apache.catalina.realm.MemoryRealm /

/Engine

  /Service


httpd.conf:
DocumentRoot /home/wwa-m/public_html/docroot/wwa-m/

WebAppConnection warpConnection warp localhost:8080
WebAppDeploy wwa-m warpConnection /wwa-m/
WebAppInfo /webapp-info

in the Apache logfile I am getting an error:
Cannot find /usr/local/tomcat/webapps/wwa-m for appl. wwa-m host 
www.wasserwirtschaftsamt-muenchen.de
Where does Apache get this old path from ?

Any ideas ??

thanx Rainer




Re: Tomcat, webapp, SSL, and index files?

2002-04-03 Thread Joseph Molnar

  there is actually a setting where you can force it to say
  'https'.

 What is this setting?

Hmm, so far it isn't working (just tried it now). I had presumed that you
could set the scheme attribute in the connector to https and have secure
set to false...didn't work that way in my first test anyhow.

I do, however ,have the examples operational by basically using the
instructions listed in the server.xml. I have the connector working on port
8008 and Apache now setup to take SSL and then forward to the examples. The
harder part was the Apache certificate setup :).

Here is what I did:

In the server.xml I just changed the connector for WARP (at the bottom of
the file and already there for use) by putting in scheme=https (again this
didn't appear to do a thing in terms of request.getScheme()).

In Apache you put this (I put it globally):

-

LoadModule webapp_module  libexec/mod_webapp.so
AddModule  mod_webapp.c

-

Then I have the virtual host for the ssl location:

---

VirtualHost 192.168.120.91:443

#  General setup for the virtual host
ServerName www.myservername.com
ServerAdmin [EMAIL PROTECTED]

DocumentRoot /httpd/www/intranet/site

#   SSL Engine Switch:
#   Enable/Disable SSL for this virtual host.
SSLEngine on

#   SSL Cipher Suite:
#   List the ciphers that the client is permitted to negotiate.
#   See the mod_ssl documentation for a complete list.
SSLCipherSuite
ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL

#   Server Certificate:
SSLCertificateFile /httpd/conf/ssl.crt/server.crt

#   Server Private Key:
SSLCertificateKeyFile /httpd/conf/ssl.key/server1.key

#   SSL Engine Options:
Files ~ \.(shtml)$
SSLOptions +StdEnvVars
/Files

#   SSL Protocol Adjustments:
SetEnvIf User-Agent .*MSIE.* \
 nokeepalive ssl-unclean-shutdown \
 downgrade-1.0 force-response-1.0

#
# Tomcat WARP connector
#
WebAppConnection conn  warp  localhost:8008
WebAppDeploy examples  conn  /examples
WebAppInfo /webapp-info


Directory /httpd/www/intranet/site
Options FollowSymLinks

AllowOverride AuthConfig

order allow,deny
allow from all
/Directory

/VirtualHost
---

So running the sample JSP (which dumps request info), the following results
come out (I added showing the request type, as you can see it does say
'http', not 'https') :

---
Request Information
JSP Request Method: GET
Request URI: /examples/jsp/snp/snoop.jsp
Request Protocol: HTTP/1.1
Servlet path: /jsp/snp/snoop.jsp
Path info: null
Path translated: null
Query string: test=a
Content length: -1
Content type: null
Server name: www.myservername.com
Server port: 443
Remote user: null
Remote address: 192.168.110.66
Remote host:
Authorization scheme: null
HTTP Scheme: http
Locale: en_US
---

So it is showing that communication 'appears' to come across 443, not 8008.
If nothing else you can use that to check. I am sure there is a way, but I
just got this up tonight and I should head until the morning. I will start
digging back at it tomorrow.  Until then...



Joseph Molnar
http://www.codesta.com/


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Help with ClassLoading

2002-04-03 Thread John Wadkin

All,

Tomcat 4.0.1
Apache 1.3
mod_WebApp
Java 1.2

I've got a servlet that uses Eteks PJA ToolKit. I've set CATALINA_OPTS to
include the environment variables:

-Dawt.toolkit=com.eteks.awt.PJAToolkit
-Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment
-Djava.awt.fonts=font directory

but the servlet catches and reports that the
com.eteks.java2d.PJAGraphicsEnvironment class couldn't be found:

java.lang.Error: Could not find class:
com.eteks.java2d.PJAGraphicsEnvironment

The pja jars were originally in WEB-INF/lib. I moved them to common/lib - no
change. I still get the exception. Any ideas? Is anyone successfully using
the PJA ToolKit?

Thanks,

John

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Connection Apache - Tomcat

2002-04-03 Thread Joseph Molnar


Your connector (server.xml) is actually set to serve from the webapps
directory (which is presumably found at /usr/local/tomcat/)  There is your
problem.  You have to change the connector appBase.


Joseph Molnar
http://www.codesta.com/



- Original Message -
From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 1:23 AM
Subject: Connection Apache - Tomcat


Hi,

the root of my webapplication is:
/home/my-user/public_html/docroot/my-app/

I tried to configure Apache and Tomcat to serv the web form this path
without success.
Apache is recognizing that webapplication when I access files within the
docroot folder but not within the wwa-m/ folder (as supposed!)
Tomcat is working fine with the servic running the 8080 port.
But I am getting an 404 Error wenn I directly access the wwa-m folder.

server.xml:

Service name=Tomcat-Apache

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

!-- Replace localhost with what your Apache
ServerName is set to --
   Engine className=org.apache.catalina.connector.warp.WarpEngine
   name=apache.nandgate.com debug=0
   appBase=webapps !-- ich denke hier muß es passieren --

  !-- Global logger unless overridden at
  lower levels --
  Logger className=
  org.apache.catalina.logger.FileLogger
  prefix=apache_log. suffix=.txt
  timestamp=true/

  !-- Because this Realm is here, an instance
  will be shared globally --
  Realm className=
 org.apache.catalina.realm.MemoryRealm /

/Engine

  /Service


httpd.conf:
DocumentRoot /home/wwa-m/public_html/docroot/wwa-m/

WebAppConnection warpConnection warp localhost:8080
WebAppDeploy wwa-m warpConnection /wwa-m/
WebAppInfo /webapp-info

in the Apache logfile I am getting an error:
Cannot find /usr/local/tomcat/webapps/wwa-m for appl. wwa-m host
www.wasserwirtschaftsamt-muenchen.de
Where does Apache get this old path from ?

Any ideas ??

thanx Rainer



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




N/w Problem (Puneet Sachar)

2002-04-03 Thread puneet sachar

Hi friends

Plz find with the word file along with this mail(virus
scanned )


and help me if u have solutions for this 


Puneet 

__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/


DIAGRAM.doc
Description: DIAGRAM.doc

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


Re: Connection Apache - Tomcat

2002-04-03 Thread [EMAIL PROTECTED]


Ho Joseph,

thanks for your idea!
I was trying that before. (appBase=/home/wwa-m/public_html/docroot/wwa-m/)
but without success!
I of course restartet Tomact after changing server.xml and restartet Apache
as well.
In the error log there is still the same (old) adress listed!!

Any further ideas?
Rainer

 Your connector (server.xml) is actually set to serve from the webapps
 directory (which is presumably found at /usr/local/tomcat/)  There is
your
 problem.  You have to change the connector appBase.

 
 Joseph Molnar
 http://www.codesta.com/



 - Original Message -
 From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 1:23 AM
 Subject: Connection Apache - Tomcat


 Hi,

 the root of my webapplication is:
 /home/my-user/public_html/docroot/my-app/

 I tried to configure Apache and Tomcat to serv the web form this path
 without success.
 Apache is recognizing that webapplication when I access files within the
 docroot folder but not within the wwa-m/ folder (as supposed!)
 Tomcat is working fine with the servic running the 8080 port.
 But I am getting an 404 Error wenn I directly access the wwa-m folder.

 server.xml:

 Service name=Tomcat-Apache

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

 !-- Replace localhost with what your Apache
 ServerName is set to --
Engine className=org.apache.catalina.connector.warp.WarpEngine
name=apache.nandgate.com debug=0
appBase=webapps !-- ich denke hier muß es passieren --

   !-- Global logger unless overridden at
   lower levels --
   Logger className=
   org.apache.catalina.logger.FileLogger
   prefix=apache_log. suffix=.txt
   timestamp=true/

   !-- Because this Realm is here, an instance
   will be shared globally --
   Realm className=
  org.apache.catalina.realm.MemoryRealm /

 /Engine

   /Service


 httpd.conf:
 DocumentRoot /home/wwa-m/public_html/docroot/wwa-m/

 WebAppConnection warpConnection warp localhost:8080
 WebAppDeploy wwa-m warpConnection /wwa-m/
 WebAppInfo /webapp-info

 in the Apache logfile I am getting an error:
 Cannot find /usr/local/tomcat/webapps/wwa-m for appl. wwa-m host
 www.wasserwirtschaftsamt-muenchen.de
 Where does Apache get this old path from ?

 Any ideas ??

 thanx Rainer



 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Connection Apache - Tomcat

2002-04-03 Thread Gary McGowan

Rainer

I think tomcat4 uses the $CATALINA_HOME environment to get to your context

What I did to get round it was to create a symbolic link in the tomcat
webapps directory to point to the actual directory.

So in your case:

ln -s /home/wwa-m/public_html/docroot/wwa-m  /usr/local/tomcat/webapps/wwa-m
(or something like that)

Worked for me!


- Original Message -
From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 11:30 AM
Subject: Re: Connection Apache - Tomcat



 Ho Joseph,

 thanks for your idea!
 I was trying that before.
(appBase=/home/wwa-m/public_html/docroot/wwa-m/)
 but without success!
 I of course restartet Tomact after changing server.xml and restartet
Apache
 as well.
 In the error log there is still the same (old) adress listed!!

 Any further ideas?
 Rainer

  Your connector (server.xml) is actually set to serve from the webapps
  directory (which is presumably found at /usr/local/tomcat/)  There is
 your
  problem.  You have to change the connector appBase.
 
  
  Joseph Molnar
  http://www.codesta.com/
 
 
 
  - Original Message -
  From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
  To: Tomcat Users List [EMAIL PROTECTED]
  Sent: Wednesday, April 03, 2002 1:23 AM
  Subject: Connection Apache - Tomcat
 
 
  Hi,
 
  the root of my webapplication is:
  /home/my-user/public_html/docroot/my-app/
 
  I tried to configure Apache and Tomcat to serv the web form this path
  without success.
  Apache is recognizing that webapplication when I access files within the
  docroot folder but not within the wwa-m/ folder (as supposed!)
  Tomcat is working fine with the servic running the 8080 port.
  But I am getting an 404 Error wenn I directly access the wwa-m folder.
 
  server.xml:
 
  Service name=Tomcat-Apache
 
  Connector className=
  org.apache.catalina.connector.warp.WarpConnector
  port=8008 minProcessors=5
  maxProcessors=75 enableLookups=true
  acceptCount=10 debug=0/
 
  !-- Replace localhost with what your Apache
  ServerName is set to --
 Engine className=org.apache.catalina.connector.warp.WarpEngine
 name=apache.nandgate.com debug=0
 appBase=webapps !-- ich denke hier muß es
passieren --
 
!-- Global logger unless overridden at
lower levels --
Logger className=
org.apache.catalina.logger.FileLogger
prefix=apache_log. suffix=.txt
timestamp=true/
 
!-- Because this Realm is here, an instance
will be shared globally --
Realm className=
   org.apache.catalina.realm.MemoryRealm /
 
  /Engine
 
/Service
 
 
  httpd.conf:
  DocumentRoot /home/wwa-m/public_html/docroot/wwa-m/
 
  WebAppConnection warpConnection warp localhost:8080
  WebAppDeploy wwa-m warpConnection /wwa-m/
  WebAppInfo /webapp-info
 
  in the Apache logfile I am getting an error:
  Cannot find /usr/local/tomcat/webapps/wwa-m for appl. wwa-m host
  www.wasserwirtschaftsamt-muenchen.de
  Where does Apache get this old path from ?
 
  Any ideas ??
 
  thanx Rainer
 
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: N/w Problem (Puneet Sachar)

2002-04-03 Thread John Burgess

Hi Puneet

This is off topic but
If your structured cabling is already connected to the panel (usually called
a patch panel) then its all very easy on the hardware side.
Just make sure that the switching hub you are using is an UNMANAGED one --
if the ADCOM is managed then it requires setting up and will be a total pain
for a tiny network like yours -- a 24 port unmanaged switching hub should
only cost around £60 for a 10Mbs one, maybe £120 for a 10/100 autosensing
one that will work with both 10Mbs and 100Mbs network interface card.
Assuming you have an unmanaged hub then no setup is required.  All you need
are short patch cables (i.e. 40cm say lengths of cable with an rj45 jack at
each end).  You can buy tools for making the cables up but its a serious
pain and quite expensive when you can buy them ready made for £1 or less
each.  You just take a patch cable from each socket on the patch panel into
a socket on the switch and all is done.  

All the client machines need is a similar cable (but longer - 2M is probably
good) to go from their network interface card (NIC) to the wall or floor box
where each length of structured cabling comes out.

If the panel isn't wired up or if you don't have any floor boxes wired up
then the simplest thing is just to forget it and simply use an unmanaged
switch on its own.  All you need is a length of network cable for each
machine and you just connect the machine's NIC to any port on the hub.
That's it!  The only problem with this is getting the cable neatly arranged
and then working out which cable is which when machines move around --
structured cabling helps by hiding all the mess under the floor :(

To begin with why not start simply peer to peer with the built in windows
networking- you can add a dedicated server and make it Primary Domain
Controller (PDC) later, once you're happy with the cabling etc..

Setting up the client machines could be as simple as installing the netbeui
protocol on each one, giving it a unique name and setting the workgroup name
to be the same for all machines (by default, windows uses a workgroup name
of WORKGROUP -- there's no reason why you shouldn't stick with that. )  If
however, you want shared internet access or to set up a workgroup web
browser then you will have to use TCP/IP.  You can use both TCP/IP and
Netbeui but its probably better to just install tcp/ip in this case.  The
simplest way of doing this is then to create a text file called hosts with
no suffix and put in it one line for each machine giving its name and a
unique tcp/ip address.  There are a number of ranges of numbers available
for use by internal networks that you should choose from for example
192.168.x.y  where x and y are arbitrary numbers between 1 and 222. So,
assuming you use planets as your machine names, the file might look like

127.0.0.1   localhost ##always a good idea
192.168.1.1 mercury
192.168.1.2 venus
192.168.1.3 earth
192.168.1.4 mars
192.168.1.5 jupiter

etc...

Then set up each machine by installing tcp/ip protocol and configuring it to
not use DNS and not use WINS and to have a fixed ip address, using the
address for each machine assigned in the hosts file.  Give the machine the
correct name and put it in the workgroup.  Then copy the hosts file to
c:\winnt\system32\drivers\etc  (for NT, 2000 and XP)
or to
c:\windows  (for 95, 98, and ME)

At a command prompt you should then be able to type
ping localhost 
and see a list of replies received from the machine you typed the command
on.  Then try
ping venus
and you should see text to the effect of

Pinging venus[192.168.1.2] with 32 bytes of data
Reply from 192.168.1.2 bytes=32 time10ms TTL=128
Reply from 192.168.1.2 bytes=32 time10ms TTL=128
Reply from 192.168.1.2 bytes=32 time10ms TTL=128
Reply from 192.168.1.2 bytes=32 time10ms TTL=128

If so, then all should be well

If not, promise your network knowledgeable friend a large drink if he'll
help you out!!!  Or start by uninstalling tCP/IP and installing netbeui
which will almost certainly just work and let people use that for a time
while you read up on simple tcp/ip installations.. It's really not
difficult.

Best Wishes
John Burgess
[EMAIL PROTECTED]
Tel: 01865 718666 
Fax: 01865 718600


-Original Message-
From: puneet sachar [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 10:50 AM
To: Tomcat Users List; Tom Drake
Subject: N/w Problem (Puneet Sachar)


Hi friends

Plz find with the word file along with this mail(virus
scanned )


and help me if u have solutions for this 


Puneet 

__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.343 / Virus Database: 190 - Release Date: 22/03/02
 


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 

error 404

2002-04-03 Thread Yunce Gunawan


hi all,

i have added this charakters to my configuration on httpd.conf
IfModule mod_webapp.c
 WebAppConnection conn warp picard:8080
 WebAppDeploy tomcat conn /
 WebAppDeploy cocoon conn /cocoon
 WebAppInfo /webapp-info
/IfModule

and than on my browser i always see this error.

WebApp: Error 404
(File: wa_request.c Line: 205)
Web-application not yet deployed 

can anybody help me ?




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: error 404

2002-04-03 Thread John Burgess

If 8080 is what you actually put in httpd.conf, are you sure that is the
port the warp connector is on. 8008 is more usual, with 8080 being the http
port for standalone tomcat.

Best Wishes
John Burgess
[EMAIL PROTECTED]
Tel: 01865 718666 
Fax: 01865 718600


-Original Message-
From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 1:22 PM
To: Tomcat Users List
Subject: error 404



hi all,

i have added this charakters to my configuration on httpd.conf
IfModule mod_webapp.c
 WebAppConnection conn warp picard:8080
 WebAppDeploy tomcat conn /
 WebAppDeploy cocoon conn /cocoon
 WebAppInfo /webapp-info
/IfModule

and than on my browser i always see this error.

WebApp: Error 404
(File: wa_request.c Line: 205)
Web-application not yet deployed 

can anybody help me ?




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.343 / Virus Database: 190 - Release Date: 22/03/02
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.343 / Virus Database: 190 - Release Date: 22/03/02
 

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error 404

2002-04-03 Thread Yunce Gunawan

i'm not sure ...
where can i check this warp connector ?

-- if i use 8008, i see the same error


On Wednesday 03 April 2002 14:29, you wrote:
 If 8080 is what you actually put in httpd.conf, are you sure that is the
 port the warp connector is on. 8008 is more usual, with 8080 being the http
 port for standalone tomcat.

 Best Wishes
 John Burgess
 [EMAIL PROTECTED]
 Tel: 01865 718666
 Fax: 01865 718600


 -Original Message-
 From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 1:22 PM
 To: Tomcat Users List
 Subject: error 404



 hi all,

 i have added this charakters to my configuration on httpd.conf
 IfModule mod_webapp.c
  WebAppConnection conn warp picard:8080
  WebAppDeploy tomcat conn /
  WebAppDeploy cocoon conn /cocoon
  WebAppInfo /webapp-info
 /IfModule

 and than on my browser i always see this error.

 WebApp: Error 404
 (File: wa_request.c Line: 205)
 Web-application not yet deployed

 can anybody help me ?

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: error 404

2002-04-03 Thread Chris Newland

Hi,

Did you restart Apache after you started Tomcat?

Regards,

Chris

 -Original Message-
 From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
 Sent: 03 April 2002 13:22
 To: Tomcat Users List
 Subject: error 404
 
 
 
 hi all,
 
 i have added this charakters to my configuration on httpd.conf
 IfModule mod_webapp.c
  WebAppConnection conn warp picard:8080
  WebAppDeploy tomcat conn /
  WebAppDeploy cocoon conn /cocoon
  WebAppInfo /webapp-info
 /IfModule
 
 and than on my browser i always see this error.
 
 WebApp: Error 404
 (File: wa_request.c Line: 205)
 Web-application not yet deployed 
 
 can anybody help me ?
 
 
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 
 


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error 404

2002-04-03 Thread Yunce Gunawan

of course


On Wednesday 03 April 2002 14:30, you wrote:
 Hi,

 Did you restart Apache after you started Tomcat?

 Regards,

 Chris

  -Original Message-
  From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
  Sent: 03 April 2002 13:22
  To: Tomcat Users List
  Subject: error 404
 
 
 
  hi all,
 
  i have added this charakters to my configuration on httpd.conf
  IfModule mod_webapp.c
   WebAppConnection conn warp picard:8080
   WebAppDeploy tomcat conn /
   WebAppDeploy cocoon conn /cocoon
   WebAppInfo /webapp-info
  /IfModule
 
  and than on my browser i always see this error.
 
  WebApp: Error 404
  (File: wa_request.c Line: 205)
  Web-application not yet deployed
 
  can anybody help me ?
 
 
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




order of files in directory listing strange

2002-04-03 Thread Meinolf . Klement . extern

We are using tomcat 3.2.2 and everthing worked fine. But now the order in
which files appear isn't chronological anymore (nor alphabetic); there seems
to be no order at all.
I haven't found anything in the bug database.

Any clue what this might be?

Regards
Meinolf


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




error page customization

2002-04-03 Thread Julien OIX

hi everyone,

I'm using Tomcat4 and Apache (mod_webapp connector) on a Linux RedHat
7.1;

If I want to define templates for 404 or 403 errors, where do I have to
configure this stuff ?

If Apache, with ErrorDocument directives in my virtual host

If Tomcat, where can I configure this ? (I'm using the default web.xml
for my application)

thanks in advance.

-- 
Julien OIX
Service Informatique de Gestion
Tél: 02 40 99 83 65
mail: [EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: package org.apache.jasper.runtime does not exist

2002-04-03 Thread Chuck Amadi

hatem zanaty wrote:

Include jasper-runtime, jasper-compiler to your class path and logoff/login your 
computer then try agin
Have luck 
  Chuck Amadi [EMAIL PROTECTED] wrote: Hi any takers . All my previous 
work no longer functions due to this 
error . Note unfortunatley i don't run cvs
and it's been while that i worked on my jsp's/javabeans as at the moment 
i have created my work project under a html application and is working 
prior to converting to jsp , session beans  actions .

I don't have a jasper.jar file in my tomcat4.lib dir only 
jasper-runtime.jar  jasper-compiler.jar in my tomcat4lib dir.
i have checked my web.xml and my tld's and suggestions .


Error log below
**
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [10:1] package 
org.apache.jasper.runtime does not exist
import org.apache.jasper.runtime.*;
^
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [12:1] cannot resolve symbol
symbol : class JasperException 
location: package jasper
import org.apache.jasper.JasperException;
^
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [15:1] cannot resolve symbol
symbol : class HttpJspBase 
location: class _0002fwiseGuy_0002ejspwiseGuy_jsp_0
public class _0002fwiseGuy_0002ejspwiseGuy_jsp_0 extends HttpJspBase {
^
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [25:1] cannot resolve symbol
symbol : class JasperException 
location: class _0002fwiseGuy_0002ejspwiseGuy_jsp_0
public final void _jspx_init() throws JasperException {
^
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [37:1] incompatible types
found : _0002fwiseGuy_0002ejspwiseGuy_jsp_0
required: java.lang.Object
Object page = this;
^
_0002fwiseGuy_0002ejspwiseGuy_jsp_0.java [47:1] 
getPageContext(javax.servlet.Servlet,javax.servlet.ServletRequest,javax.servlet.ServletResponse,java.lang.String,boolean,int,boolean)
 
in javax.servlet.jsp.JspFactory cannot be applied to 
(_0002fwiseGuy_0002ejspwiseGuy_jsp_0,javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse,java.lang.String,boolean,int,boolean)
pageContext = _jspxFactory.getPageContext(this, request, 
response,
^
6 errors
Errors compiling wiseGuy.


Cheers Chuck Amadi
Systems Programmer



--
To unsubscribe: 
For additional commands: 
Troubles with the list: 



-
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax

As below

set within my classpath - jasper-runtime, jasper-compiler to my class path .
Plz confirm anyway i'll find out soon enough.



set PATH=C:\JDK1.3\bin;
set CATALINA_HOME=C:\jakarta-tomcat-4.0.2
set CATALINA_HOME=C:\jakarta-tomcat-4.0.2\lib\jasper-compiler.jar
set CATALINA_HOME=C:\jakarta-tomcat-4.0.2\lib\jasper-runtime.jar







--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error page customization

2002-04-03 Thread Gary McGowan

In the web.xml file you can define error pages

Example:

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

And so on

You can also define error pages for any exceptions: (again in web.xml)

Example :

 error-page

exception-typejava.lang.ArrayIndexOutOfBoundsException/exception-type
location/error.html/location
 /error-page

Gary
- Original Message -
From: Julien OIX [EMAIL PROTECTED]
To: Tomcat list [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 2:06 PM
Subject: error page customization


 hi everyone,

 I'm using Tomcat4 and Apache (mod_webapp connector) on a Linux RedHat
 7.1;

 If I want to define templates for 404 or 403 errors, where do I have to
 configure this stuff ?

 If Apache, with ErrorDocument directives in my virtual host

 If Tomcat, where can I configure this ? (I'm using the default web.xml
 for my application)

 thanks in advance.

 --
 Julien OIX
 Service Informatique de Gestion
 Tél: 02 40 99 83 65
 mail: [EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error page customization

2002-04-03 Thread Julien OIX

Gary McGowan a écrit :
 
 In the web.xml file you can define error pages
 
 Example:
 
 error-page
 error-code404/error-code
 location/missing.jsp/location
 /error-page
 
 And so on
 
 You can also define error pages for any exceptions: (again in web.xml)
 
 Example :
 
  error-page
 
 exception-typejava.lang.ArrayIndexOutOfBoundsException/exception-type
 location/error.html/location
  /error-page
 
 Gary


thanks a lot :-)

 - Original Message -
 From: Julien OIX [EMAIL PROTECTED]
 To: Tomcat list [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 2:06 PM
 Subject: error page customization
 
  hi everyone,
 
  I'm using Tomcat4 and Apache (mod_webapp connector) on a Linux RedHat
  7.1;
 
  If I want to define templates for 404 or 403 errors, where do I have to
  configure this stuff ?
 
  If Apache, with ErrorDocument directives in my virtual host
 
  If Tomcat, where can I configure this ? (I'm using the default web.xml
  for my application)
 
  thanks in advance.
 
  --
  Julien OIX
  Service Informatique de Gestion
  Tél: 02 40 99 83 65
  mail: [EMAIL PROTECTED]
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

-- 
Julien OIX
Service Informatique de Gestion
Tél: 02 40 99 83 65
mail: [EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




How to manage log files?

2002-04-03 Thread Mike Millson

What is the philosophy behind managing Tomcat log files? Why is it that log
files can only be created with the date attached? This makes it impossible
to manage the files using logrotate like you can w/ Apache. Instead of a
single log file name that you can rotate, you get a file for every day of
the year.

Is it set up this way because the logging is only for development purposes?
Is it expected that tomcat logging will be turned off and Apache logging
used instead? What is the reason for having the log files have the date
attached so they cannot be logrotated?

Or, if the log files are meant for production use, how are people managing
these files? Surely the way isn't to have hundreds of log files. Is there
some tool that aggregates them so they can be logrotated?

Thank you,
Mike Millson
Web Systems Engineer
Sun Certified Programmer for Java2 Platform

AableTech Solutions, Inc.
770.414.8834
404.219.3177 cell
770.414.8206 fax
http://www.atsga.com



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error 404

2002-04-03 Thread rsequeira


1) What's the URL you are using?
2) check the tomcat logs to see if there were any errors when deploying the
cocoon and tomcat web applications.
3) The port in your WebAppConnection line should match port defined in
server.xml. By default the WarpConnector listens on port 8008. See
server.xml
snip
Connector className=org.apache.catalina.connector.warp.WarpConnector
 port=8008/
/snip
4) And again as others have already said, start Tomcat first and once you
know that Tomcat has started, start Apache.

Thanks.
RS





Yunce Gunawan [EMAIL PROTECTED] on 04/03/2002 06:35:57 AM

Please respond to Tomcat Users List [EMAIL PROTECTED]

To:   Tomcat Users List [EMAIL PROTECTED]
cc:

Subject:  Re: error 404

of course


On Wednesday 03 April 2002 14:30, you wrote:
 Hi,

 Did you restart Apache after you started Tomcat?

 Regards,

 Chris

  -Original Message-
  From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
  Sent: 03 April 2002 13:22
  To: Tomcat Users List
  Subject: error 404
 
 
 
  hi all,
 
  i have added this charakters to my configuration on httpd.conf
  IfModule mod_webapp.c
   WebAppConnection conn warp picard:8080
   WebAppDeploy tomcat conn /
   WebAppDeploy cocoon conn /cocoon
   WebAppInfo /webapp-info
  /IfModule
 
  and than on my browser i always see this error.
 
  WebApp: Error 404
  (File: wa_request.c Line: 205)
  Web-application not yet deployed
 
  can anybody help me ?
 
 
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]









--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




session time out

2002-04-03 Thread Mahesh Agarwal

Hi All

What is the default value of session timeout in tomcat if we dont provide
any value in web.xml file. I am using JBoss-2.4.1_Tomcat-3.2.3.

Is the session timeout is total of activity+inactivity?

Thanks in advance
Mahesh
-Original Message-
From: kelly, Burrowa [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 10:23 AM
To: [EMAIL PROTECTED]
Subject: About reloading of classes


I use tomcat 4.0.1. I have reloadable=true for my 
context in server.xml. But when I compile 4 classes,
only one class is getting loaded - atleast that
is what is shown in the tomcat runtime window. I am
not sure if all the classes have been reloaded.

What are others observations on this?   

__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error 404

2002-04-03 Thread Yunce Gunawan

On Wednesday 03 April 2002 15:23, you wrote:
 1) What's the URL you are using?

i use picard.rz.hu-berlin.de

 2) check the tomcat logs to see if there were any errors when deploying the
 cocoon and tomcat web applications.

i don't see any errors 
just this .

..
2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:597   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration. 
New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:604   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration. 
New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:608   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration. 
New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:621   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category core.xscript not defined in configuration. New Logger 
created and returned

2002-04-03 15:46:33 StandardWrapper[/cocoon:default]: Loading container 
servlet default
2002-04-03 15:46:33 default: init
2002-04-03 15:46:33 StandardWrapper[/cocoon:invoker]: Loading container 
servlet invoker
2002-04-03 15:46:33 invoker: init
2002-04-03 15:46:33 jsp: init

i don't understand, whats mean  Unknown-URI) Unknown-thread/LogKitLogger  , 
may u can help me...

 3) The port in your WebAppConnection line should match port defined in
 server.xml. By default the WarpConnector listens on port 8008. See
 server.xml
 snip
 Connector className=org.apache.catalina.connector.warp.WarpConnector
  port=8008/
 /snip

i have done


 4) And again as others have already said, start Tomcat first and once you
 know that Tomcat has started, start Apache.

i have done too...
but  this error always come :(

i don't know now, what must i do  
thanks anyway...

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Tyrex/Warp JDBC NamingContext problem

2002-04-03 Thread @Basebeans.com

Subject: Tyrex/Warp JDBC NamingContext problem
From: Hermod Opstvedt [EMAIL PROTECTED]
 ===
Hi all

I have looked all over the place, and come across several people that are
experiencing the same as me. When I access my .jsp's directly to TC, a
lookup of the JDBC that I configured in server.xml works fine. When starting
up Apache and hence warp, it stops working. I have stepped through it, and
confirmed that the JDBC entry is in the naming context, but the cast
(through Tyrex) doesn't seem to work so it returns null. Hasn't anybody come
across a solution for this ?


Hermod



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Connection Apache - Tomcat

2002-04-03 Thread [EMAIL PROTECTED]

thanks Gary,

that worked. (together with the docBase of course)!

Rainer


 Rainer

 I think tomcat4 uses the $CATALINA_HOME environment to get to your context

 What I did to get round it was to create a symbolic link in the tomcat
 webapps directory to point to the actual directory.

 So in your case:

 ln -s /home/wwa-m/public_html/docroot/wwa-m
/usr/local/tomcat/webapps/wwa-m
 (or something like that)

 Worked for me!


 - Original Message -
 From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 11:30 AM
 Subject: Re: Connection Apache - Tomcat


 
  Ho Joseph,
 
  thanks for your idea!
  I was trying that before.
 (appBase=/home/wwa-m/public_html/docroot/wwa-m/)
  but without success!
  I of course restartet Tomact after changing server.xml and restartet
 Apache
  as well.
  In the error log there is still the same (old) adress listed!!
 
  Any further ideas?
  Rainer
 
   Your connector (server.xml) is actually set to serve from the
webapps
   directory (which is presumably found at /usr/local/tomcat/)  There
is
  your
   problem.  You have to change the connector appBase.
  
   
   Joseph Molnar
   http://www.codesta.com/
  
  
  
   - Original Message -
   From: Jünger @ projektINTER.NET [EMAIL PROTECTED]
   To: Tomcat Users List [EMAIL PROTECTED]
   Sent: Wednesday, April 03, 2002 1:23 AM
   Subject: Connection Apache - Tomcat
  
  
   Hi,
  
   the root of my webapplication is:
   /home/my-user/public_html/docroot/my-app/
  
   I tried to configure Apache and Tomcat to serv the web form this path
   without success.
   Apache is recognizing that webapplication when I access files within
the
   docroot folder but not within the wwa-m/ folder (as supposed!)
   Tomcat is working fine with the servic running the 8080 port.
   But I am getting an 404 Error wenn I directly access the wwa-m folder.
  
   server.xml:
  
   Service name=Tomcat-Apache
  
   Connector className=
   org.apache.catalina.connector.warp.WarpConnector
   port=8008 minProcessors=5
   maxProcessors=75 enableLookups=true
   acceptCount=10 debug=0/
  
   !-- Replace localhost with what your Apache
   ServerName is set to --
  Engine className=org.apache.catalina.connector.warp.WarpEngine
  name=apache.nandgate.com debug=0
  appBase=webapps !-- ich denke hier muß es
 passieren --
  
 !-- Global logger unless overridden at
 lower levels --
 Logger className=
 org.apache.catalina.logger.FileLogger
 prefix=apache_log. suffix=.txt
 timestamp=true/
  
 !-- Because this Realm is here, an instance
 will be shared globally --
 Realm className=
org.apache.catalina.realm.MemoryRealm /
  
   /Engine
  
 /Service
  
  
   httpd.conf:
   DocumentRoot /home/wwa-m/public_html/docroot/wwa-m/
  
   WebAppConnection warpConnection warp localhost:8080
   WebAppDeploy wwa-m warpConnection /wwa-m/
   WebAppInfo /webapp-info
  
   in the Apache logfile I am getting an error:
   Cannot find /usr/local/tomcat/webapps/wwa-m for appl. wwa-m host
   www.wasserwirtschaftsamt-muenchen.de
   Where does Apache get this old path from ?
  
   Any ideas ??
  
   thanx Rainer
  
  
  
   --
   To unsubscribe:   mailto:[EMAIL PROTECTED]
   For additional commands: mailto:[EMAIL PROTECTED]
   Troubles with the list: mailto:[EMAIL PROTECTED]
  
  
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




writing logfile in webappfolder

2002-04-03 Thread [EMAIL PROTECTED]

Hi,

we try to have the logfiles in the webapp-folder WEB-INF/log
my appBase is /home/wwa-m/public_html/docroot/

How to I have to set up the Logger/  of the server.xml to work?

I tried:

Context path=/
docBase=/home/wwa-m/public_html/docroot debug=0
reloadable=true
Logger className=org.apache.catalina.ogger.FileLogger
   prefix=/home/wwa-m/public_html/docroot/WEB-INF/log/wwa-m. suffix=.log
timestamp=true/
/Context

and: prefix=WEB-INF/log/wwa-m. suffix=.log
and prefix=WEB-INF/log/wwa-m suffix=.log

but something is wrong since the logfile is not beeing written.

Rainer



Make, won't create mod_webapp.so

2002-04-03 Thread David Parham

I'm trying to link apache-2.0.32 to tomcat-4.0.3 using
webapp-module-1.0.1-tc401.  On a RS/6000 with AIX4.3.3

I run the ./configure --with-apxs=/app/apache-2/bin/apxs.
This appears to run correctly, no errors are returned.
I then run the make command.  It returns the following data, again no
errors.

# make

make[]: Entering directory lib
make[]: Invoking make  build
make[]: Generating pr_warp_defs.h from
/download/webapp-module-1.0.1-tc401/java/Constants.java

make[]: Creating library libwebapp.la
/app/apache-2/build/libtool /usr/bin/gcc -rpath
/download/webapp-module-1.0.1-tc401/lib -
static -o libwebapp.la wa_main.lo  wa_config.lo  wa_request.lo pr_info.lo
pr_warp.lo  pr_warp_pa
cket.lo  pr_warp_network.lo  pr_warp_config.lo
rm -fr .libs/libwebapp.la .libs/libwebapp.* .libs/libwebapp.*
ar cru .libs/libwebapp.a  wa_main.o wa_config.o wa_request.o pr_info.o
pr_warp.o pr_warp_packet.o
 pr_warp_network.o pr_warp_config.o
ranlib .libs/libwebapp.a
creating libwebapp.la
(cd .libs  rm -f libwebapp.la  ln -s ../libwebapp.la libwebapp.la)
/app/apache-2/build/libtool --silent --mode=install
/download/webapp-module-1.0.1-tc401/
support/install.sh -c  libwebapp.la  /download/webapp-module-1.0.1-tc401/lib
--
Libraries have been installed in:
   /download/webapp-module-1.0.1-tc401/lib

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the `LIBPATH' environment variable
 during execution
   - use the `-Wl,-blibpath:LIBDIR:/usr/lib:/lib' linker flag

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
--
/app/apache-2/build/libtool --silent --mode=finish
/download/webapp-module-1.0.1-tc401/l
ib
Target build is up to date.
make[]: Exiting directory lib

make[]: Entering directory apache-2.0
make[]: Invoking make  build
Target build is up to date.
make[]: Exiting directory apache-2.0
Target all is up to date.

I've tried running the ./configure commands with various different flags.
But always the same result.  There is never a mod_webapp.so file in the
apache-2.0 dir.

If anyone has any insight they'd like to share I would be very hapy to hear
it.

thanks
David
[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: error 404

2002-04-03 Thread John Burgess

Yunce

Assuming a default tomcat setup-
can you connect to http://localhost:8080/tomcat/your_file.jsp_here or
http://localhost:8080/cocoon/your_file.jsp_here
or http://picard.rz.hu-berlin.de:8080/tomcat/your_file.jsp_here

If you first get tomcat standalone working then you have a firm foundation
for getting apache/tomcat integration going

Best Wishes
John Burgess
[EMAIL PROTECTED]
Tel: 01865 718666 
Fax: 01865 718600


-Original Message-
From: Yunce Gunawan [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 3:08 PM
To: Tomcat Users List
Subject: Re: error 404


On Wednesday 03 April 2002 15:23, you wrote:
 1) What's the URL you are using?

i use picard.rz.hu-berlin.de

 2) check the tomcat logs to see if there were any errors when deploying
the
 cocoon and tomcat web applications.

i don't see any errors 
just this .

..
2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:597   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration.

New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:604   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration.

New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:608   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category sitemap.serializer.html not defined in configuration.

New Logger created and returne
d

2002-04-03 15:46:33 DEBUG   (2002-04-03) 15:46.33:621   [] 
(Unknown-URI) Unknown-thread/LogKitLogge
r: Logger for category core.xscript not defined in configuration. New Logger

created and returned

2002-04-03 15:46:33 StandardWrapper[/cocoon:default]: Loading container 
servlet default
2002-04-03 15:46:33 default: init
2002-04-03 15:46:33 StandardWrapper[/cocoon:invoker]: Loading container 
servlet invoker
2002-04-03 15:46:33 invoker: init
2002-04-03 15:46:33 jsp: init

i don't understand, whats mean  Unknown-URI) Unknown-thread/LogKitLogger
, 
may u can help me...

 3) The port in your WebAppConnection line should match port defined in
 server.xml. By default the WarpConnector listens on port 8008. See
 server.xml
 snip
 Connector className=org.apache.catalina.connector.warp.WarpConnector
  port=8008/
 /snip

i have done


 4) And again as others have already said, start Tomcat first and once you
 know that Tomcat has started, start Apache.

i have done too...
but  this error always come :(

i don't know now, what must i do  
thanks anyway...

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.343 / Virus Database: 190 - Release Date: 22/03/02
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.343 / Virus Database: 190 - Release Date: 22/03/02
 

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Can't run tomcat 4.0.2 examples anymore nothing will compile- package org.apache.jasper.runtime does not exist

2002-04-03 Thread Chuck Amadi

Hi im having problems with getting my examples to work . Somehow i have 
done something as i was able to run everthing ie my own work projects , 
thus i have been trying to get the MySql Jar File working and all hell 
has broke loss.

Any Suggestions Error clipboard below
Cheers Chuck Amadi
Systems Programmer




jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [12:1] 
package org.apache.jasper.runtime does not exist
import org.apache.jasper.runtime.*;
^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [14:1] 
cannot resolve symbol
symbol  : class JasperException  
location: package jasper
import org.apache.jasper.JasperException;
 ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [17:1] 
cannot resolve symbol
symbol  : class HttpJspBase  
location: class jsp.cal._0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0
public class _0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0 
extends HttpJspBase {
  ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [29:1] 
cannot resolve symbol
symbol  : class JasperException  
location: class jsp.cal._0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0
public final void _jspx_init() throws JasperException {
  ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [41:1] 
incompatible types
found   : jsp.cal._0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0
required: java.lang.Object
Object page = this;
  ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [51:1] 
getPageContext(javax.servlet.Servlet,javax.servlet.ServletRequest,javax.servlet.ServletResponse,java.lang.String,boolean,int,boolean)
 
in javax.servlet.jsp.JspFactory cannot be applied to 
(jsp.cal._0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0,javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse,java.lang.String,boolean,int,boolean)
pageContext = _jspxFactory.getPageContext(this, request, 
response,
  ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [75:1] 
cannot resolve symbol
symbol  : class TableBean  
location: package cal
cal.TableBean table = null;
   ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [78:1] 
cannot resolve symbol
symbol  : class TableBean  
location: package cal
table= (cal.TableBean)
   ^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [83:1] 
cannot resolve symbol
symbol  : class TableBean  
location: package cal
table = (cal.TableBean) 
Beans.instantiate(this.getClass().getClassLoader(), cal.TableBean);
^
jsp/cal/_0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0.java [83:1] 
cannot resolve symbol
symbol  : method getClass  ()
location: class jsp.cal._0002fjsp_0002fcal_0002fcal_00032_0002ejspcal2_jsp_0
table = (cal.TableBean) 
Beans.instantiate(this.getClass().getClassLoader(), cal.TableBean);
  ^
10 errors
Errors compiling cal2.



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Working Directory

2002-04-03 Thread Sanjay Bahal

I am trying to read a properties file from my servlet.
It always comes back saying file not found. I have
tried placing the file in
classes/web-inf/context-path. Ideally I would like to
lace it in my classes directory- How do I achieve it.
Thanks
Sanjay

__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Servlet Destroy Method....

2002-04-03 Thread Mark Diggory

Hi all,

Is there a way I can test if the Servlet is being destroy()ed because 
the tomcat server is being shutdown as opposed to the Servlet being 
reloaded?

-Mark Diggory


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Wagoner, Mark

I place my properties files in the WEB-INF directory and do the following to
find them -

String webInfFolder = getServletContext().getRealPath(/WEB-INF)

-Original Message-
From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 11:34 AM
To: tomcat
Subject: Working Directory


I am trying to read a properties file from my servlet.
It always comes back saying file not found. I have
tried placing the file in
classes/web-inf/context-path. Ideally I would like to
lace it in my classes directory- How do I achieve it.
Thanks
Sanjay

__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Saving Userid under Form-based Security

2002-04-03 Thread @Basebeans.com

Subject: Saving Userid under Form-based Security
From: Dave Butler [EMAIL PROTECTED]
 ===
For convenience, I wish to save the userid in a cookie when the form-based
login.jsp is processed. I have tried a few different approaches, without
success. My current effort is to use a Filter, which includes the following
methods:

(The environment is Tomcat 4.0.2 running on AIX 4.3.3. The browser is IE 6.0
under Windows 2000)

//--
---
   public void doFilter(ServletRequest request, ServletResponse response,
FilterChain chain)
throws IOException, ServletException {

  if (filterConfig == null)
 return;

  chain.doFilter(request, response);

  HttpSession session = ((HttpServletRequest)request).getSession();
  if (session.getAttribute(savedUserid) == null) {
 saveUserid(request, response);
 session.setAttribute(savedUserid, Boolean.TRUE);
  }
   }

   public void init(FilterConfig filterConfig) {
  this.filterConfig = filterConfig;
   }

   public void destroy() {}

   private void saveUserid(ServletRequest request, ServletResponse response)
{
  String userid = ((HttpServletRequest)request).getRemoteUser();
  System.out.println(In Filter, saving userid ( + userid + ));

  if ((userid != null)  (userid.length() != 0)) {
 Cookie frswebCookie = new LongLivedCookie(userid, userid);
 ((HttpServletResponse)response).addCookie(frswebCookie);
  }

   }
//--
---

My Catalina.out log shows In Filter, saving userid (name), but it does not
seem to be working. I find no evidence of a cookie being created. A couple
of questions:

1) Is this the best approach for what I am trying to accomplish?
2) Why does this approach not work? Any debugging suggestions?

Thanks,

Dave Butler



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




weird behaviour with jsp pages

2002-04-03 Thread Alex Sauve

Hi all,

I have a tomcat that is performing a little weird and I am sure that it 
is a configuration issue, but I have spent days trying to pin-point the 
problem with little effect.  So here is the scenario, I am running 
Tomcat with Apache and the Apache server that connects to the Tomcat 
server is a proxy server in front of another Apache server (don't know 
if that is important information???).  So you are probably wondering by 
now what is the weird behaviour?  Well the thing is that I have written 
some jsp pages to be used with the Tomcat server, they will only execute 
when located within a jsp directory.  Yup, the jsp pages will only 
execute when located under a jsp directory, but they can be in another 
directory under the jsp directory and they will work again as long as in 
their directory tree there is a directory called jsp.  Don't quite 
understand why this is, and I have checked everywhere for some behaviour 
similar to this and nothing.  I don't believe that jsp pages have to be 
located in a jsp directory, so I would like to rectify this problem.  So 
here is the configuration of Apache and Tomcat...

The Apache conf file extract: (don't forget this is the proxy server in 
front of the backend Apache server)

#INCLUDE_SECTION_TOMCAT
Include /usr/local/jakarta-tomcat-3.3a/conf/mod_jk.conf
#END_INCLUDE_SECTION_TOMCAT

VirtualHost _default_:443
  SSLEngine on
  RewriteEngine on
  RewriteLog /home/xlink/logs/RewriteLog.proxy
  RewriteLogLevel 2

  # this directive is set in order to avoid access
  # to directory listing in the portal
  Directory /home/portal/html
Options -Indexes
  /Directory

  #SECTION_TOMCAT
  JkMount /*.jsp ajp13
  JkMount /sso/* ajp13
  #END_SECTION_TOMCAT

  ProxyPass /xlink http://localhost:9442/xlink
  ProxyPass /authapi http://localhost:9442/authapi

  ProxyPass /portal http://localhost:9303/
  ProxyPass /portal/ http://localhost:9303/
  ProxyPass / http://localhost:9303/

  RewriteRule /portal/images(.*) /home/portal/html/images$1
  RewriteRule /portal/js(.*) /home/portal/html/js$1
  RewriteRule /images(.*) /home/portal/html/images$1
  RewriteRule /js(.*) /home/portal/html/js$1
  RewriteRule /css(.*) /home/portal/html/css$1

  ProxyPassReverse /portal/ http://localhost:9303/
  ProxyPassReverse / http://localhost:9303/
/VirtualHost

There is a similar entry for the port 80 virtual host.

The tomcat configuration file is as follows:## Auto generated on 
Mon Jan 28 19:17:37 EST 2002##

IfModule !mod_jk.c
  LoadModule jk_module libexec/mod_jk.so
  AddModule mod_jk.c
/IfModule

JkWorkersFile /usr/local/jakarta-tomcat-3.3a/conf/jk/workers.properties
JkLogFile /usr/local/jakarta-tomcat-3.3a/logs/mod_jk.log

JkLogLevel debug

#JkMount /admin ajp13
#JkMount /admin/* ajp13

#JkMount /examples ajp13
#JkMount /examples/* ajp13

#JkMount /sso ajp13
#JkMount /sso/* ajp13

The project containing the jsp's that I wrote is obviously the sso 
project, but the same behaviour occurs when I try to move one of the 
example jsp pages from the jsp directory.
If you need anymore information, please just let me know and thanks for 
your help...

Alex




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Joseph Molnar

Hi Mark.

Easiest way would be write something to disk (file/log-file).



Joseph Molnar
http://www.codesta.com/


- Original Message - 
From: Mark Diggory [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 8:33 AM
Subject: Servlet Destroy Method


 Hi all,
 
 Is there a way I can test if the Servlet is being destroy()ed because
 the tomcat server is being shutdown as opposed to the Servlet being
 reloaded?
 
 -Mark Diggory
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Mark Diggory

I'm looking for something more explicit, like a Servlet Engine status 
code or something... that identifies the state of the Servlet Engine.

-thanks for the reply,
Mark Diggory

Joseph Molnar wrote:

 Hi Mark.
 
 Easiest way would be write something to disk (file/log-file).
 
 
 
 Joseph Molnar
 http://www.codesta.com/
 
 
 - Original Message - 
 From: Mark Diggory [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 8:33 AM
 Subject: Servlet Destroy Method
 
 
 
Hi all,

Is there a way I can test if the Servlet is being destroy()ed because
the tomcat server is being shutdown as opposed to the Servlet being
reloaded?

-Mark Diggory


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: error 404

2002-04-03 Thread Joseph Molnar

Hi Yunce.

If this two work one of two things needs to happen

a) The module needs to be statically link to Apache.

You can check this by doing httpd -l, it will list all modules
(this is most likely what you need to do unless you built apache
yourself)

b) You need to specifically load the module

To do this, I am using the following lines:

LoadModule webapp_module  libexec/mod_webapp.so
AddModule  mod_webapp.c


I am guessing you will need to do the later.

Joe

- Original Message -
From: Yunce Gunawan [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:21 AM
Subject: error 404



 hi all,

 i have added this charakters to my configuration on httpd.conf
 IfModule mod_webapp.c
  WebAppConnection conn warp picard:8080
  WebAppDeploy tomcat conn /
  WebAppDeploy cocoon conn /cocoon
  WebAppInfo /webapp-info
 /IfModule

 and than on my browser i always see this error.

 WebApp: Error 404
 (File: wa_request.c Line: 205)
 Web-application not yet deployed

 can anybody help me ?




 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Joseph Molnar

Are you looking to take different action during the actual destroy call
itself?

Joe

- Original Message -
From: Mark Diggory [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 9:08 AM
Subject: Re: Servlet Destroy Method


 I'm looking for something more explicit, like a Servlet Engine status
 code or something... that identifies the state of the Servlet Engine.

 -thanks for the reply,
 Mark Diggory

 Joseph Molnar wrote:

  Hi Mark.
 
  Easiest way would be write something to disk (file/log-file).
 
 
  
  Joseph Molnar
  http://www.codesta.com/
 
 
  - Original Message -
  From: Mark Diggory [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Wednesday, April 03, 2002 8:33 AM
  Subject: Servlet Destroy Method
 
 
 
 Hi all,
 
 Is there a way I can test if the Servlet is being destroy()ed because
 the tomcat server is being shutdown as opposed to the Servlet being
 reloaded?
 
 -Mark Diggory
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 



 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Mark Diggory

Yes I was looking to not do something in the destroy() method if its 
just the case that the servlet is being reloaded by the server. 
Otherwise, if the server was actually going through a shutdown process 
then I want my destroy() method to do something.

-Mark



Joseph Molnar wrote:

 Are you looking to take different action during the actual destroy call
 itself?
 
 Joe
 
 - Original Message -
 From: Mark Diggory [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 9:08 AM
 Subject: Re: Servlet Destroy Method
 
 
 
I'm looking for something more explicit, like a Servlet Engine status
code or something... that identifies the state of the Servlet Engine.

-thanks for the reply,
Mark Diggory

Joseph Molnar wrote:


Hi Mark.

Easiest way would be write something to disk (file/log-file).



Joseph Molnar
http://www.codesta.com/


- Original Message -
From: Mark Diggory [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 8:33 AM
Subject: Servlet Destroy Method




Hi all,

Is there a way I can test if the Servlet is being destroy()ed because
the tomcat server is being shutdown as opposed to the Servlet being
reloaded?

-Mark Diggory


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Unable to make Tomcat work with localhost

2002-04-03 Thread Kairam, Raj

 Installed Tomcat on a HP machine running HP-UX 11. Also running Netscape
 Navigator 4.x
 Set required environment variables ( TOMCAT_HOME and JAVA_HOME ) in the
 start up .profile file and verified.
 Not able to see Tomcat welcome page and facing problems not mentioned in
 any of the books I read.
Installation and the ability to start Tomcat to work with JSPs and servlets,
was easy I thought. 
Another user suggested I check if any other process is using port 8080. I
could not figure that out in the absence of 'lsof' which had to be built for
my HP and I did not have the build tools. But I essentially am trying to
work locally.

Not that easy, I guess.  Can any one help me with this, please ?
 Please Help
 
In Netscape browser's -  preferences | Advanced | proxies | View - set No
proxy for 158.57.*.* and HTTP Proxy as webgate, port as 80 ( which are our
standard settings ). Also our firewall administrator says there is nothing
wrong with the firewall.

 root@m020plts:/meta1/jakarta-tomcat-4.0.3 startup.sh 
 Using CATALINA_BASE: /meta1/jakarta-tomcat-4.0.3
 Using CATALINA_HOME: /meta1/jakarta-tomcat-4.0.3
 Using CATALINA_TMPDIR: /meta1/jakarta-tomcat-4.0.3/temp ( Note I did not
 create myself this temp directory, yet )
 Using JAVA_HOME: /opt/java1.3
 
After I type the url as below, I am getting these errors in the Netscape
browser
  http://158.57.4.220:8080/index.html
Failed to connect, Host could not be contacted
http://127.0.0.1:8080/index.html
Same error as above
http://localhost:8080/index.html
Forbidden, You are not permitted to access the remote system 

 Thanks
 Raj
 
 
 
 
 

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: reading html-form parameters within servlet filter on tomcat4.0.3

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Alexander Thomas wrote:

 Date: Wed, 03 Apr 2002 00:17:55 +0200
 From: Alexander Thomas [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Subject: Re: reading html-form parameters within servlet filter on tomcat
 4.0.3

 Dear Craig,

 thanks for your swift reply! As you suggested I tried to foist the
 servlet a new instatnce of the BufferedReader class.
 The codesection in the doFilter method of my filter class looks like this:


 HttpServletRequestWrapper httpServletRequestWrapper = new
 HttpServletRequestWrapper() {

 public BufferedReader getReader() {
 return new BufferedReader(new
 StringReader(testparameter=testvalue));
 }

 }

 chain.doFilter(httpServletRequestWrapper, response)

 However, this approach does not have an impact on the parameters present
 in the servlet!!


If you want to change the parameters that the servlet sees, just override
the getParameter(), getParameterNames() (and so on) methods in your
wrapper also.  You can fake pretty much anything.

 I am not very familiar with the debug option in catalina. Nevertheless,
 I used it and came to the conclusion that the servlet actually does not
 use the HttpServletRequest object while evaluating the getParameter method.


That's not really true, because your servlet really calls the
getParameter() method on the request object passed to doGet() or doPost().
But, I believe, your real question is how does the parameter lookup
*really* happen?

 Can you confir that?


In the absence of any application-provided wrappers or request dispatcher
calls, the request object that is passed to a servlet's doGet() or
doPost() method is:
- An instance of org.apache.catalina.connector.HttpRequestFacade,
  which has a reference to ...
- An instance of org.apache.catalina.connector.http.HttpRequestImpl
  (assuming the standard HTTP connector in 4.0), which subclasses ...
- The org.apache.catalina.connector.HttpRequestBase class, which
  in turn subclasses ...
- The org.apache.catalina.connector.RequestBase base class that
  is the lowest-level piece of Catalina directly related to the
  incoming request.

Generally, calls like getParameter() simply get delegated down the chain
until someone actually implements them.  In this particular case, the
standard implementation of getParameter() is in HttpRequestBase, where the
incoming parameters are parsed into a Map (if this hasn't been done yet)
and then used to retrieve the requested value.

Things change when you do things like a RequestDispatcher.include() call.
In that scenario, Catalina creates what amounts to a request wrapper in
order to implement the extra request attributes that an included servlet
sees (without modifying the underlying request at all).  When the include
returns, the wrapper is simply removed, thus restoring the previous
request.

The same sort of thing happens when you write your own request and
response wrappers.  By default, all of the methods are simply delegated to
the actual request (or response) you are wrapping.  But, you can override
the getParameter() method yourself if you need to -- and the servlet that
is actually called will never know the difference.  In this way, a filter
can (for example) make some actual parameters disappear, or add some new
ones -- simply by customizing what really happens when getParameter() is
called.  But what actually happens is totally up to you as the author of
the wrapper class.

 Regards,

 Alexander Thomas


Craig


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Images and STRUTS

2002-04-03 Thread Craig R. McClanahan



On Tue, 2 Apr 2002, Micael Padraig Og mac Grene wrote:

 Date: Tue, 02 Apr 2002 22:29:28 -0800
 From: Micael Padraig Og mac Grene [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Images and STRUTS

 I tried to do an ordinary image tag with the struts application, and could
 not.  What is happening with that?  I could not get the index.jsp page to
 reference an image in the same location.  I used the same page without
 struts, and it worked.  I am just getting the clue on struts.  I am
 familiar with the whole of Model 2 architectures, just not struts.  Is it
 the forwarding mechanism that is calling the problem?

You probably want to ask this sort of question on the STRUTS-USER list
instead of here, but here's a common scenario that can cause Struts users
(or anyone else using an architecture that uses RequestDispatcher.forward)
grief:  if you are using relative path references for your images, those
paths get resolved against the request URI that the browser submitted to
-- not the URI of the page itself.  This is because the browser has no
clue that a RequestDispatcher.forward() call was done on the server side.

Example:

- Your app is installed at http://localhost:8080/myapp;

- You have a main page index.jsp, which therefore has the absolute URI
  http://localhost:8080/myapp/index.jsp;.

- You have an image in an images subdirectory, which therefore has the
  absolute URI http://localhost:8080/myapp/images/logo.gif;.

- You have Struts set up to use path based mapping to the controller
  servlet, so you get URIs like http://localhost:8080/myapp/do/getCustomer;
  in it (to execute the getCustomer action).

Now, consider what happens if you have the following tag in index.jsp:

  img src=images/logo.gif

and you execute http://localhost:8080/myapp/do/mainMenu;.  This fails to
retrieve the image.  Why?  Because the *browser* is the one that resolves
the absolute URI of the image -- and it resolves it against the URI that
it submitted for this request:

  http://localhost:8080/myapp/do/images/logo.gif

which is obviously wrong.  Ways to get around this:

- (Struts-specific) Use extension mapping instead of path mapping
  for the controller.  Then, all requests and pages are in the same
  directory level and relative references work as expected.

- (Struts-specific) Use the html:base/ tag in the head section
  of your index.jsp page.  This creates an HTML base tag that tells
  the browser to base relative references on *this* page, instead of
  the request URI of the submit.

- (Struts-specific) Use the Struts html:img tag instead, which knows
  all about this problem and generates the correct URI automatically.

- (General) Use a relative path like ../images/logo.gif to convince
  the browser to do the path correctly.

- (General) Include your own base tag to tell the browser what the
  absolute URL of this page is.


 Micael


Craig


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: problem with large servlets( classes )?

2002-04-03 Thread Craig R. McClanahan

Java has a maximum size of 64kb on any particular method.  There might
also be other limits on the overall size of the class, but I've had no
problems with some pretty large classes.

However, I would consider a class this large to be a warning sign that you
really need to look at your architecture, and divide things up.
Monolithic large classes are very hard to maintain and enhance.

Just as a comparison, I did a quick scan of all the classes in Tomcat 4 --
the largest single class in the entire server is around 28k (it's the
class that dynamically deploys a new webapp, called by the Manager
servlet).  The vast majority of the classes are under 6k.  The same
thing will happen for you if you use an application framework like Struts
(http://jakarta.apache.org/struts), which encourages you to divide your
processing logic up into lots of little single-purpose pieces.  They are
also *much* easier to maintain, test, and enhance.

Craig


On Wed, 3 Apr 2002, Mikkel Lindhard wrote:

 Date: Wed, 3 Apr 2002 10:30:47 +0200
 From: Mikkel Lindhard [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: 'Tomcat Users List' (E-mail) [EMAIL PROTECTED]
 Subject: problem with large servlets( classes )?

 We are having a not so fun problem with the size of our controller servlet
 class loaded( could be file size, could be other size problems )
 basically were getting this error when adding one more line of code( of any
 kind ) in our controller servlet:

 java.lang.VerifyError: (class: ServletName, method: function signature:
 (Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletRespo
 nse;)V) Illegal instruction found at offset XX
   at java.lang.Class.newInstance0(Native Method)
   at java.lang.Class.newInstance(Class.java:237)
   at
 org.apache.tomcat.core.ServletWrapper.loadServlet(ServletWrapper.java:268)


 We stumpled across this error, but that isnt the case in our situation so i
 guess something else can trigger this error.
 http://developer.java.sun.com/developer/bugParade/bugs/4223705.html

 the servlet is around 93 kb compiled now and works.

 setup:
 Tomcat 3.2.1
 JDK build 1.3.1_02-b02
 Win2k Server

 thanks in advance
 Mikkel


 ---
 [Denne E-mail blev scannet for virus af Declude Virus]
 [This E-mail was scanned for viruses by Declude Virus]


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Tomcat and JWSDP

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Lenhart Stefan wrote:

 Date: Wed, 3 Apr 2002 10:45:29 +0200
 From: Lenhart Stefan [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Tomcat and JWSDP

 Hi everyone!

 I'm trying to develop a small WebService example and therefore use Sun's
 Java WebService Development Pack which has a Tomcat version 4.something
 distribution included.


The version of Tomcat in JWSDP is pretty much what is available in recent
nightly builds of Tomcat 4.

 Packaging the service class into a war file is no problem, and on startup
 Tomcat extracts the war archive to the appropriate subdirectory of webapps.
 No problem so far. But when I'm trying to access the webapp in my browser
 (http://localhost:8080/kredit) I get a 404 error message although I've got
 an index.html file in the /kredit directory.

 I checked the log file, and found that on startup this error occurs:

Are you sure you're trying to run this webapp on the JWSDP version of
Tomcat, and not some separate one?  The reason I ask is that the
org.apache.catalina.util.xml.XmlMapper class (used to parse web.xml and
TLD files) only exists in Tomcat 4.0.x -- it doesn't exist in the version
of Tomcat included in JWSDP.  The stack trace implies that you're trying
this on a standard 4.0.x version of Tomcat.

The other thing I would do is look at your web.xml file itself, and make
sure there are no wierd characters in it.

Craig



 2002-04-03 09:58:25 ContextConfig[/kredit] Parse error in application
 web.xml
 java.lang.Exception: Can't open config file:
 java.io.ByteArrayInputStream@2ae94f due to: java.io.UTFDataFormatException:
 invalid byte 1 of 1-byte UTF-8 sequence (0xfc)
   at
 org.apache.catalina.util.xml.XmlMapper.readXml(XmlMapper.java:282)
   at
 org.apache.catalina.startup.ContextConfig.applicationConfig(ContextConfig.ja
 va:256)
   at
 org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:824)
   at
 org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:
 224)
   at
 org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor
 t.java:155)
   at
 org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1131)
   at
 org.apache.catalina.core.StandardContext.start(StandardContext.java:3345)
   at
 org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:785)
   at
 org.apache.catalina.core.StandardHost.addChild(StandardHost.java:454)
   at
 org.apache.catalina.core.StandardHost.install(StandardHost.java:714)
   at
 org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:324)
   at org.apache.catalina.startup.HostConfig.start(HostConfig.java:389)
   at
 org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:232)
   at
 org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor
 t.java:155)
   at
 org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1131)
   at
 org.apache.catalina.core.StandardHost.start(StandardHost.java:614)
   at
 org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1123)
   at
 org.apache.catalina.core.StandardEngine.start(StandardEngine.java:307)
   at
 org.apache.catalina.core.StandardService.start(StandardService.java:388)
   at
 org.apache.catalina.core.StandardServer.start(StandardServer.java:505)
   at org.apache.catalina.startup.Catalina.start(Catalina.java:781)
   at org.apache.catalina.startup.Catalina.execute(Catalina.java:681)
   at org.apache.catalina.startup.Catalina.process(Catalina.java:179)
   at java.lang.reflect.Method.invoke(Native Method)
   at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)


 Anybody had this problem before? Any ideas?

 Thx in advance!


 Mit freundlichen Gruessen

 Stefan Lenhart

 R. Boeker Consulting GmbH
 Ein Unternehmen der R. Boeker Unternehmensgruppe AG
 RBU AG Zweigniederlassung Frankfurt
 Mergenthalerallee 77
 D-65760 Eschborn

 Tel.:  +49 (61 96) 4 70-883
 Fax.:  +49 (61 96) 4 70-8 90
 E-Mail:mailto:[EMAIL PROTECTED]
 Internet: http://www.rbu.de

 Diese eMail enthält möglicherweise vertrauliche und/oder rechtlich
 geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder
 diese eMail irrtümlich erhalten haben, informieren Sie bitte sofort den
 Absender und vernichten diese eMail. Das unerlaubte Kopieren sowie die
 unbefugte Weitergabe dieser eMail ist nicht gestattet.

 This e-mail may contain confidential and/or privileged information. If you
 are not the intended recipient (or have received this e-mail in error)
 please notify the sender immediately and destroy this e-mail. Any
 unauthorised copying, disclosure or distribution of the material in this
 e-mail is strictly forbidden.



 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   

Re: Deployment Question

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Neo Gigs wrote:

 Date: Wed, 3 Apr 2002 16:54:13 +0800
 From: Neo Gigs [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Subject: Deployment Question

 Hi there,

 How does I can deploy a EAR, WAR or JAR file into Tomcat server? Does
 there have any deployment tools available like deploytool that can
 deploy applications into J2EE server?


Tomcat 4.0.x can accept WAR files, by using the Manager webapp (or by
placing them in the webapps subdirectory), but does not support
deploytool from the J2EE RI server.

The Java Web Services Developer Pack (JWSDP) *does* include a version of
deploytool that knows how to deploy webapps to Tomcat (in particular, to
the version that is included in the Pack).  This was one of the new
features in the EA2 release a couple of weeks ago:

  http://java.sun.com/webservices

 Thanks

 Neo


Craig



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: session object [urgent!]

2002-04-03 Thread Huy K Dung

I have exactly the same problem. I am working on a solution but still no
luck. This problem happens to me only when i am using Netscape 4.79. IE 5.5
and Netscape 6.2.2 are OK.

I find that IE 5.5 creates a new session in a new window when IE 5.5 is run
by clicking on its icon. However, if a new IE 5.5 window is opened by
javascript from another IE 5.5 window, the same session is maintained.

As for Netscape 6.2.2, it doesn't matter if a new windows is opened by
clicking on its icon or by javascript from another Netscape window.

As for Netscape 4.79, the session is also maintained if another window is
opened ny clicking on its icon. However, if a new window is opened by
javascript from another window, the new window is able to access the session
to render the info for display but when an action is done on the new window,
a new session kicks in and the old session is unknown. Somehow, Netscape
4.79 pops up a new window as a different process.

Please HELP!!! I hope my description of the problem is clear enough.

-Original Message-
From: Nancy Crisostomo Martinez [mailto:[EMAIL PROTECTED]]
Sent: Saturday, March 02, 2002 02:56 PM
To: Tomcat Users List
Subject: Re: session object [urgent!]


I have found a kind of bug or I don't know what
I tried to access to the session's attributes, with another servlet-engine
and it works perferct!
So... I think Tomcat 3.3 (I'm using) has a bug or maybe it is a cause of a
bad configuration because the
track is lost

What do you think about it?
Does any of you have the same problem with sessions?



Nancy Crisostomo Martinez wrote:

 Hi everybody!

 I need your help..
 I'm trying to track some attributes I added to the session object, but I
 can't...

 I have an html file (main.htm) which opens a new window browser
 (validate.jsp) when you press a button to access to one service...
 Then when the user is validated in the validate.jsp file, I added two
 attributes to the session object like this:

  ...
  %
  if (validUser(id_Usuario)){
 session.setAttribute(numero,id_Usuario);
 session.setAttribute(edad,num);
  ...

 and finally the window is closed and another new window is opened (
 portal.jsp ).

  %
  script


window.open(portal.jsp,,top=0,left=0,width=791,height=520,scrollbars=ye
s,resizable=yes,status=yes)

  return eval('close()')
  /script
  %
  }
  %

 The portal.jsp file is formed by frames:

   HTML
   FRAMESET rows=75,250* frameborder=0 border=0
 framespacing=0
   FRAME name=FrameArriba scrolling=NO noresize
 marginwidth=0 marginheight=0 SRC=arriba.htm frameborder=0

  FRAMESET cols=128,127*  border=0 framespacing=0
 frameborder=0
  FRAME name=FrameIzquierda scrolling=NO
 marginwidth=0 marginheight=0 noresize SRC=izquierda.jsp
   frameborder=NO
  FRAME name=FrameServicio marginwidth=0
 marginheight=0 noresize SRC=blanco.jsp frameborder=NO 
  /FRAMESET

  NOFRAMES
Su browser no acepta Frames.
  /NOFRAMES
   /FRAMESET
   /HTML

 In the left frame (FrameIzquierda) I have a jsp file (izquierda.jsp)
 that reads the new session's attributes (numero,edad) and they are
 displayed perfectly when the
 portal.jsp file is opened. Moreover, in the right frame I put a jsp file
 (blanco.jsp) that also reads the attributes 'id' and 'ag' and they are
 perfectly displayed too.
 But the problem becomes when I click a link placed in the izquierda.jsp
 file :

  .
  a href=top.jsptest/a
  or
  a href=top.jsp target=FrameServicio test/a
  .

 The top.jsp file also reads the attributes (numero, edad)...
 In both cases the session's attributes are not displayed, they only
 return a null value,  and the session id (session.getId()) is
 differtent because when the link is
 pressed, a new session object is createdso.. I don't know how to fix
 this
 I really need to get the two attributes I stored previously in the
 session object...

 Could you please help me???
 I'm desperate!!

 Thank you in advance..
 Nancy.

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



Re: Images and STRUTS

2002-04-03 Thread Micael Padraig Og mac Grene

THNX Craig

At 10:12 AM 4/3/02 -0800, you wrote:


On Tue, 2 Apr 2002, Micael Padraig Og mac Grene wrote:

  Date: Tue, 02 Apr 2002 22:29:28 -0800
  From: Micael Padraig Og mac Grene [EMAIL PROTECTED]
  Reply-To: Tomcat Users List [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Subject: Images and STRUTS
 
  I tried to do an ordinary image tag with the struts application, and could
  not.  What is happening with that?  I could not get the index.jsp page to
  reference an image in the same location.  I used the same page without
  struts, and it worked.  I am just getting the clue on struts.  I am
  familiar with the whole of Model 2 architectures, just not struts.  Is it
  the forwarding mechanism that is calling the problem?

You probably want to ask this sort of question on the STRUTS-USER list
instead of here, but here's a common scenario that can cause Struts users
(or anyone else using an architecture that uses RequestDispatcher.forward)
grief:  if you are using relative path references for your images, those
paths get resolved against the request URI that the browser submitted to
-- not the URI of the page itself.  This is because the browser has no
clue that a RequestDispatcher.forward() call was done on the server side.

Example:

- Your app is installed at http://localhost:8080/myapp;

- You have a main page index.jsp, which therefore has the absolute URI
   http://localhost:8080/myapp/index.jsp;.

- You have an image in an images subdirectory, which therefore has the
   absolute URI http://localhost:8080/myapp/images/logo.gif;.

- You have Struts set up to use path based mapping to the controller
   servlet, so you get URIs like http://localhost:8080/myapp/do/getCustomer;
   in it (to execute the getCustomer action).

Now, consider what happens if you have the following tag in index.jsp:

   img src=images/logo.gif

and you execute http://localhost:8080/myapp/do/mainMenu;.  This fails to
retrieve the image.  Why?  Because the *browser* is the one that resolves
the absolute URI of the image -- and it resolves it against the URI that
it submitted for this request:

   http://localhost:8080/myapp/do/images/logo.gif

which is obviously wrong.  Ways to get around this:

- (Struts-specific) Use extension mapping instead of path mapping
   for the controller.  Then, all requests and pages are in the same
   directory level and relative references work as expected.

- (Struts-specific) Use the html:base/ tag in the head section
   of your index.jsp page.  This creates an HTML base tag that tells
   the browser to base relative references on *this* page, instead of
   the request URI of the submit.

- (Struts-specific) Use the Struts html:img tag instead, which knows
   all about this problem and generates the correct URI automatically.

- (General) Use a relative path like ../images/logo.gif to convince
   the browser to do the path correctly.

- (General) Include your own base tag to tell the browser what the
   absolute URL of this page is.

 
  Micael
 

Craig


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Mark Diggory wrote:

 Date: Wed, 03 Apr 2002 12:24:31 -0500
 From: Mark Diggory [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED],
  [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Subject: Re: Servlet Destroy Method

 Yes I was looking to not do something in the destroy() method if its
 just the case that the servlet is being reloaded by the server.
 Otherwise, if the server was actually going through a shutdown process
 then I want my destroy() method to do something.


Java doesn't have any means to replace an existing class.  So, when Tomcat
does a reload to reflect your updated servlet or bean class, it has to:
- Shut down the entire webapp
- Throw away the webapp class loader and all the classes
  that were previously loaded from /WEB-INF/classes and /WEB-INF/lib
- Restart the entire webapp

Given this, there is basically no difference between what Tomcat does on a
reload versus a normal shutdown (except, of course, for the fact that the
app is not restarted again).  There also isn't anything you could really
do differently even if you knew which kind of shutdown it was, because the
rest of the webapp is getting thrown away as well as the class you just
recompiled.

 -Mark


Craig


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: session object [urgent!]

2002-04-03 Thread Huy K Dung

Hi Nancy,

I don't think it's Tomcat's problem. It's a problem with the browsers
themselves.

This problem happens to me even with Tomcat 3.2.3. At first I thought it's a
problem with Tomcat 3.3.1 but I ran the same app with Tomcat 3.2.3 and the
problem still persists.

A workaround or some tricks will solve this problem I hope. For those who
have come up with a fix for this problem, I appreciate very much if you read
this message. Thanks.

-Original Message-
From: Nancy Crisostomo Martinez [mailto:[EMAIL PROTECTED]]
Sent: Saturday, March 02, 2002 02:56 PM
To: Tomcat Users List
Subject: Re: session object [urgent!]


I have found a kind of bug or I don't know what
I tried to access to the session's attributes, with another servlet-engine
and it works perferct!
So... I think Tomcat 3.3 (I'm using) has a bug or maybe it is a cause of a
bad configuration because the
track is lost

What do you think about it?
Does any of you have the same problem with sessions?



Nancy Crisostomo Martinez wrote:

 Hi everybody!

 I need your help..
 I'm trying to track some attributes I added to the session object, but I
 can't...

 I have an html file (main.htm) which opens a new window browser
 (validate.jsp) when you press a button to access to one service...
 Then when the user is validated in the validate.jsp file, I added two
 attributes to the session object like this:

  ...
  %
  if (validUser(id_Usuario)){
 session.setAttribute(numero,id_Usuario);
 session.setAttribute(edad,num);
  ...

 and finally the window is closed and another new window is opened (
 portal.jsp ).

  %
  script


window.open(portal.jsp,,top=0,left=0,width=791,height=520,scrollbars=ye
s,resizable=yes,status=yes)

  return eval('close()')
  /script
  %
  }
  %

 The portal.jsp file is formed by frames:

   HTML
   FRAMESET rows=75,250* frameborder=0 border=0
 framespacing=0
   FRAME name=FrameArriba scrolling=NO noresize
 marginwidth=0 marginheight=0 SRC=arriba.htm frameborder=0

  FRAMESET cols=128,127*  border=0 framespacing=0
 frameborder=0
  FRAME name=FrameIzquierda scrolling=NO
 marginwidth=0 marginheight=0 noresize SRC=izquierda.jsp
   frameborder=NO
  FRAME name=FrameServicio marginwidth=0
 marginheight=0 noresize SRC=blanco.jsp frameborder=NO 
  /FRAMESET

  NOFRAMES
Su browser no acepta Frames.
  /NOFRAMES
   /FRAMESET
   /HTML

 In the left frame (FrameIzquierda) I have a jsp file (izquierda.jsp)
 that reads the new session's attributes (numero,edad) and they are
 displayed perfectly when the
 portal.jsp file is opened. Moreover, in the right frame I put a jsp file
 (blanco.jsp) that also reads the attributes 'id' and 'ag' and they are
 perfectly displayed too.
 But the problem becomes when I click a link placed in the izquierda.jsp
 file :

  .
  a href=top.jsptest/a
  or
  a href=top.jsp target=FrameServicio test/a
  .

 The top.jsp file also reads the attributes (numero, edad)...
 In both cases the session's attributes are not displayed, they only
 return a null value,  and the session id (session.getId()) is
 differtent because when the link is
 pressed, a new session object is createdso.. I don't know how to fix
 this
 I really need to get the two attributes I stored previously in the
 session object...

 Could you please help me???
 I'm desperate!!

 Thank you in advance..
 Nancy.

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



RE: Working Directory

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Wagoner, Mark wrote:

 Date: Wed, 3 Apr 2002 11:38:31 -0500
 From: Wagoner, Mark [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: 'Tomcat Users List' [EMAIL PROTECTED]
 Subject: RE: Working Directory

 I place my properties files in the WEB-INF directory and do the following to
 find them -

 String webInfFolder = getServletContext().getRealPath(/WEB-INF)


This only works if the app is run from an unpacked directory, which is not
guaranteed to be portable (not every server supports running this way).
The best way to read a properties file is to put it in the WEB-INF
subdirectory and use something like:

  Properties props = new Properties();
  InputStream stream =
getServletContext().getResourceAsStream(/WEB-INF/myprops.properties);
  props.load(stream);
  stream.close();

which is guaranteed to be portable to any server.

Craig


 -Original Message-
 From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 11:34 AM
 To: tomcat
 Subject: Working Directory


 I am trying to read a properties file from my servlet.
 It always comes back saying file not found. I have
 tried placing the file in
 classes/web-inf/context-path. Ideally I would like to
 lace it in my classes directory- How do I achieve it.
 Thanks
 Sanjay

 __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with TurboTax
 http://taxes.yahoo.com/

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




SOAP-ENV:Server.BadTargetObjectURI

2002-04-03 Thread Paul Kelly

hi,
no matter what i try i keep getting SOAP-ENV:Server.BadTargetObjectURI /
Unable to resolve target object when trying to run soap tests using tomcat
to serve the requests.

I have tried putting my service classfiles in %CATALINA_HOME%/classes, im
using the IBM xerces xml parser, its first in my classpath. ive copied the
soap webapps dir into the tomcat webapps dir and then tried adding a project
under the soap/WEB-INF/classes dir nothing works. i can deploy using
Deployment Descriptors just fine. this is driving me crazy.

Help!
Paul


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Servlet Destroy Method....

2002-04-03 Thread Mark Diggory

Wow, mine eye's have been opened! I had always thought it was just 
individual servlets that were reloaded. In this case I guess I can live 
with destroying everything on reload, because the stuff I wanted to keep 
up is stored in the ServletContext.

Thanks for the clarification,
Mark


Craig R. McClanahan wrote:

 
 On Wed, 3 Apr 2002, Mark Diggory wrote:
 
 
Date: Wed, 03 Apr 2002 12:24:31 -0500
From: Mark Diggory [EMAIL PROTECTED]
Reply-To: Tomcat Users List [EMAIL PROTECTED],
 [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Subject: Re: Servlet Destroy Method

Yes I was looking to not do something in the destroy() method if its
just the case that the servlet is being reloaded by the server.
Otherwise, if the server was actually going through a shutdown process
then I want my destroy() method to do something.


 
 Java doesn't have any means to replace an existing class.  So, when Tomcat
 does a reload to reflect your updated servlet or bean class, it has to:
 - Shut down the entire webapp
 - Throw away the webapp class loader and all the classes
   that were previously loaded from /WEB-INF/classes and /WEB-INF/lib
 - Restart the entire webapp
 
 Given this, there is basically no difference between what Tomcat does on a
 reload versus a normal shutdown (except, of course, for the fact that the
 app is not restarted again).  There also isn't anything you could really
 do differently even if you knew which kind of shutdown it was, because the
 rest of the webapp is getting thrown away as well as the class you just
 recompiled.
 
 
-Mark


 
 Craig
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: session from URL/Cookie

2002-04-03 Thread Huy K Dung

How do i encode URLs in Velocity Macro? I am using Tomcat and Turbine.

-Original Message-
From: Jeff Larsen [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 10:36 AM
To: Tomcat Users List
Subject: Re: session from URL/Cookie


I'm not entirely sure I understand your problem, but I'll
take a stab at it anyway

Typically, you don't need to worry about where the sessionid comes
from. Anywhere you send a redirect or put a link in a JSP or servlet
generated html, you should ALWAYS use HttpServletResponse.encodeURL() or
HttpServletResponse.encodeRedirectURL(). Once tomcat knows whether or
not the browser is using cookies, it will encode the URL as needed. If
cookies are enabled, the URL will be unchanged. If no cookies, the session
ID will be inserted. Tomcat does this for you. You don't need to worry about
it, just encode ALL URLs.

Jeff

- Original Message -
From: Michael [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 28, 2002 4:16 AM
Subject: session from URL/Cookie



 Hi!

 (tomcat 3.3.1)

 *** please help! ***

 my question (short version;-):
 client supports cookies and makes a request with session-encoded URL:
 request: http://myserver/testservlet;jsessionid=12121212
 isRequestedSessionIdFromURL() is false
 isRequestedSessionIdFromCookie() is true
 and
 getRequestURI() won't show the encoded sessionid!!!

 so how to find out, that the URL is encoded???


 question (long version):

 If a client request comes with no session (or an invalid session) I do:

 session = request.getSession(true); //create session
 result.sendRedirect(result.encodeRedirectURL(request.getRequestURI()));
//redirect to
the same page, so the next request comes with valid session

 - tomcat can't know, whether my browser supports cookies the time it
creates the session
or not
 - so it encodes the sessionid into the URL
 - after the redirect, I can check, if the client's browser supports
cookies
(isRequestedSessionIdFromURL() /Cookie()) - this works in any case, because
the URL is
encoded!!!
 my problem:
 - now I would like to make another redirect, if the browser supports
cookies (so the
sessionid won't be visible in the URL again) or leave the session id in the
encoded URL
(if it doesn't support cookies)

 BUT how to check, if the sessionid is encoded into the URL, when the
browser supports
cookies???
 isRequestedSessionIdFromURL() is false
 isRequestedSessionIdFromCookie() is true
 and
 getRequestURI() won't show the encoded sessionid!!!

 an example:
 client request: http://myserver/testservlet (no session)
 - create new session - redirect to same page
 client request: http://myserver/testservlet;jsessionid=12121212
 - now tomcat sees if the browser supports cookies or not - but how do I
recognize, that
the URL is encoded?
 another redirect to the same page would do
 request: http://myserver/testservlet;jsessionid=12121212
 request: http://myserver/testservlet


 thanks
 michi






 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



RE: session from URL/Cookie

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Huy K Dung wrote:

 Date: Wed, 3 Apr 2002 13:55:33 -0500
 From: Huy K Dung [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED],
  [EMAIL PROTECTED]
 To: 'Tomcat Users List' [EMAIL PROTECTED]
 Subject: RE: session from URL/Cookie

 How do i encode URLs in Velocity Macro? I am using Tomcat and Turbine.

Sounds like a question for the VELOCITY-USER mailing list.  (And since I
don't know the answer, I can't expand on it anyway :-).  Subscription
instructions for all Jakarta mailing lists is at

  http://jakarta.apache.org/site/mail.html

Craig



 -Original Message-
 From: Jeff Larsen [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, March 28, 2002 10:36 AM
 To: Tomcat Users List
 Subject: Re: session from URL/Cookie


 I'm not entirely sure I understand your problem, but I'll
 take a stab at it anyway

 Typically, you don't need to worry about where the sessionid comes
 from. Anywhere you send a redirect or put a link in a JSP or servlet
 generated html, you should ALWAYS use HttpServletResponse.encodeURL() or
 HttpServletResponse.encodeRedirectURL(). Once tomcat knows whether or
 not the browser is using cookies, it will encode the URL as needed. If
 cookies are enabled, the URL will be unchanged. If no cookies, the session
 ID will be inserted. Tomcat does this for you. You don't need to worry about
 it, just encode ALL URLs.

 Jeff

 - Original Message -
 From: Michael [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, March 28, 2002 4:16 AM
 Subject: session from URL/Cookie


 
  Hi!
 
  (tomcat 3.3.1)
 
  *** please help! ***
 
  my question (short version;-):
  client supports cookies and makes a request with session-encoded URL:
  request: http://myserver/testservlet;jsessionid=12121212
  isRequestedSessionIdFromURL() is false
  isRequestedSessionIdFromCookie() is true
  and
  getRequestURI() won't show the encoded sessionid!!!
 
  so how to find out, that the URL is encoded???
 
 
  question (long version):
 
  If a client request comes with no session (or an invalid session) I do:
 
  session = request.getSession(true); //create session
  result.sendRedirect(result.encodeRedirectURL(request.getRequestURI()));
 //redirect to
 the same page, so the next request comes with valid session
 
  - tomcat can't know, whether my browser supports cookies the time it
 creates the session
 or not
  - so it encodes the sessionid into the URL
  - after the redirect, I can check, if the client's browser supports
 cookies
 (isRequestedSessionIdFromURL() /Cookie()) - this works in any case, because
 the URL is
 encoded!!!
  my problem:
  - now I would like to make another redirect, if the browser supports
 cookies (so the
 sessionid won't be visible in the URL again) or leave the session id in the
 encoded URL
 (if it doesn't support cookies)
 
  BUT how to check, if the sessionid is encoded into the URL, when the
 browser supports
 cookies???
  isRequestedSessionIdFromURL() is false
  isRequestedSessionIdFromCookie() is true
  and
  getRequestURI() won't show the encoded sessionid!!!
 
  an example:
  client request: http://myserver/testservlet (no session)
  - create new session - redirect to same page
  client request: http://myserver/testservlet;jsessionid=12121212
  - now tomcat sees if the browser supports cookies or not - but how do I
 recognize, that
 the URL is encoded?
  another redirect to the same page would do
  request: http://myserver/testservlet;jsessionid=12121212
  request: http://myserver/testservlet
 
 
  thanks
  michi


 
 


  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: session object [urgent!] [solution]

2002-04-03 Thread Nancy Crisostomo Martinez

Hi everybody and thank you for your answers

I have found the solution to my problem...
Actually there were no errors in my code neither in Tomcat 3.3.

The problem was that the Jsp file called in the left side of the frames, was in
the Security context ($TOMCAT_HOME/webapps/security) and the jsp file called
in the right side by the link was  in the Other context
($TOMCAT_HOME/webapps/other), so, the only one thing  I did is to place the
jsp's of the Other context  in the Security context, so It is working now!!!

I don't know why, but I had those contexts because I wanted to have all the
files organized by their own nature.. so now, I need to have only one
context... It will look awful when I add more files!!

Now, do you know why the session change only for calling another file placed in
other context?? I think it must have a solution.!

If you know how to fix it, please let me know, OK?

Thank you!
Regards,
Nancy


Huy K Dung wrote:

 Hi Nancy,

 I don't think it's Tomcat's problem. It's a problem with the browsers
 themselves.

 This problem happens to me even with Tomcat 3.2.3. At first I thought it's a
 problem with Tomcat 3.3.1 but I ran the same app with Tomcat 3.2.3 and the
 problem still persists.

 A workaround or some tricks will solve this problem I hope. For those who
 have come up with a fix for this problem, I appreciate very much if you read
 this message. Thanks.

 -Original Message-
 From: Nancy Crisostomo Martinez [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, March 02, 2002 02:56 PM
 To: Tomcat Users List
 Subject: Re: session object [urgent!]

 I have found a kind of bug or I don't know what
 I tried to access to the session's attributes, with another servlet-engine
 and it works perferct!
 So... I think Tomcat 3.3 (I'm using) has a bug or maybe it is a cause of a
 bad configuration because the
 track is lost

 What do you think about it?
 Does any of you have the same problem with sessions?

 Nancy Crisostomo Martinez wrote:

  Hi everybody!
 
  I need your help..
  I'm trying to track some attributes I added to the session object, but I
  can't...
 
  I have an html file (main.htm) which opens a new window browser
  (validate.jsp) when you press a button to access to one service...
  Then when the user is validated in the validate.jsp file, I added two
  attributes to the session object like this:
 
   ...
   %
   if (validUser(id_Usuario)){
  session.setAttribute(numero,id_Usuario);
  session.setAttribute(edad,num);
   ...
 
  and finally the window is closed and another new window is opened (
  portal.jsp ).
 
   %
   script
 
 
 window.open(portal.jsp,,top=0,left=0,width=791,height=520,scrollbars=ye
 s,resizable=yes,status=yes)
 
   return eval('close()')
   /script
   %
   }
   %
 
  The portal.jsp file is formed by frames:
 
HTML
FRAMESET rows=75,250* frameborder=0 border=0
  framespacing=0
FRAME name=FrameArriba scrolling=NO noresize
  marginwidth=0 marginheight=0 SRC=arriba.htm frameborder=0
 
   FRAMESET cols=128,127*  border=0 framespacing=0
  frameborder=0
   FRAME name=FrameIzquierda scrolling=NO
  marginwidth=0 marginheight=0 noresize SRC=izquierda.jsp
frameborder=NO
   FRAME name=FrameServicio marginwidth=0
  marginheight=0 noresize SRC=blanco.jsp frameborder=NO 
   /FRAMESET
 
   NOFRAMES
 Su browser no acepta Frames.
   /NOFRAMES
/FRAMESET
/HTML
 
  In the left frame (FrameIzquierda) I have a jsp file (izquierda.jsp)
  that reads the new session's attributes (numero,edad) and they are
  displayed perfectly when the
  portal.jsp file is opened. Moreover, in the right frame I put a jsp file
  (blanco.jsp) that also reads the attributes 'id' and 'ag' and they are
  perfectly displayed too.
  But the problem becomes when I click a link placed in the izquierda.jsp
  file :
 
   .
   a href=top.jsptest/a
   or
   a href=top.jsp target=FrameServicio test/a
   .
 
  The top.jsp file also reads the attributes (numero, edad)...
  In both cases the session's attributes are not displayed, they only
  return a null value,  and the session id (session.getId()) is
  differtent because when the link is
  pressed, a new session object is createdso.. I don't know how to fix
  this
  I really need to get the two attributes I stored previously in the
  session object...
 
  Could you please help me???
  I'm desperate!!
 
  Thank you in advance..
  Nancy.
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles 

Re: problem with large servlets( classes )?

2002-04-03 Thread Christopher K. St. John

Craig R. McClanahan wrote:
 
 Just as a comparison, I did a quick scan of all the classes in Tomcat 4 --
 the largest single class in the entire server is around 28k (it's the
 class that dynamically deploys a new webapp, called by the Manager
 servlet).  


 $ cd catalina/build/server/classes/org/apache/catalina/
 $ find . -name \*.class | xargs -n1 wc | sort -n
...
199 668   17268 ./connector/http/HttpProcessor.class
209 746   22466 ./loader/WebappClassLoader.class
219 701   15975 ./mbeans/MBeanFactory.class
2281029   26567 ./servlets/WebdavServlet.class
2721066   27051 ./servlets/DefaultServlet.class
4461569   40736 ./core/StandardContext.class

 
 That's jikes w/debug off. Big classes for big jobs? 
Size-of-the-source-file winners are:

 $ find . -name \*.java | xargs -n1 wc | sort -n
   ...

   16585480   55897 ./mbeans/MBeanUtils.java
   17846245   66032 ./servlets/CGIServlet.java
   20787040   64420 ./loader/WebappClassLoader.java
   23877284   77344 ./servlets/DefaultServlet.java
   30658006  106698 ./servlets/WebdavServlet.java
   3942   11181  113685 ./core/StandardContext.java


-- 
Christopher St. John [EMAIL PROTECTED]
DistribuTopia http://www.distributopia.com



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: How to manage log files?

2002-04-03 Thread Jeff Larsen

I share your frustrations, but at this time I believe 
that our only recourse is to write our own subclass of 
org.apache.catalin.logger.FileLogger. At this point, I've
got bigger fish to fry, so I haven't even looked at this
yet. If you come up with something, post it!

Jeff

- Original Message - 
From: Mike Millson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 7:25 AM
Subject: How to manage log files?


 What is the philosophy behind managing Tomcat log files? Why is it that log
 files can only be created with the date attached? This makes it impossible
 to manage the files using logrotate like you can w/ Apache. Instead of a
 single log file name that you can rotate, you get a file for every day of
 the year.
 
 Is it set up this way because the logging is only for development purposes?
 Is it expected that tomcat logging will be turned off and Apache logging
 used instead? What is the reason for having the log files have the date
 attached so they cannot be logrotated?
 
 Or, if the log files are meant for production use, how are people managing
 these files? Surely the way isn't to have hundreds of log files. Is there
 some tool that aggregates them so they can be logrotated?
 
 Thank you,
 Mike Millson
 Web Systems Engineer
 Sun Certified Programmer for Java2 Platform
 
 AableTech Solutions, Inc.
 770.414.8834
 404.219.3177 cell
 770.414.8206 fax
 http://www.atsga.com
 
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




[Coyote] Coyote 1.0 Beta 5 available

2002-04-03 Thread Remy Maucherat

Coyote 1.0 Beta 5 is now available, and includes:
- A high performance HTTP/1.1 processor
- An adapter for Tomcat 3.3.x
- An adapter for Tomcat 4.0.x

Changes over Beta 4 include:
- Optimized host header parsing.
- Add code to prevent filter loops.
- Fix NPE with some header values.
- Other small fixes.

Binaries can be downloaded at:
http://jakarta.apache.org/builds/jakarta-tomcat-connectors/coyote/release/v1
.0-b5/

Installation instructions for both 3.3.x and 4.0.x are given on the download
page. The Tomcat 4 nighly builds already include this new connector.

Remy


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Sanjay Bahal

Thanks Mark  Craig.
My situation is slightly different. I am trying to
read the property file from a Java class on the
server(not the servlet). I would think there would be
a way around to do this- else I can work around to
pass a param to the helper class.
Thanks
Sanjay
--- Craig R. McClanahan [EMAIL PROTECTED] wrote:
 
 
 On Wed, 3 Apr 2002, Wagoner, Mark wrote:
 
  Date: Wed, 3 Apr 2002 11:38:31 -0500
  From: Wagoner, Mark [EMAIL PROTECTED]
  Reply-To: Tomcat Users List
 [EMAIL PROTECTED]
  To: 'Tomcat Users List'
 [EMAIL PROTECTED]
  Subject: RE: Working Directory
 
  I place my properties files in the WEB-INF
 directory and do the following to
  find them -
 
  String webInfFolder =
 getServletContext().getRealPath(/WEB-INF)
 
 
 This only works if the app is run from an unpacked
 directory, which is not
 guaranteed to be portable (not every server supports
 running this way).
 The best way to read a properties file is to put it
 in the WEB-INF
 subdirectory and use something like:
 
   Properties props = new Properties();
   InputStream stream =


getServletContext().getResourceAsStream(/WEB-INF/myprops.properties);
   props.load(stream);
   stream.close();
 
 which is guaranteed to be portable to any server.
 
 Craig
 
 
  -Original Message-
  From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
  Sent: Wednesday, April 03, 2002 11:34 AM
  To: tomcat
  Subject: Working Directory
 
 
  I am trying to read a properties file from my
 servlet.
  It always comes back saying file not found. I have
  tried placing the file in
  classes/web-inf/context-path. Ideally I would like
 to
  lace it in my classes directory- How do I achieve
 it.
  Thanks
  Sanjay
 
  __
  Do You Yahoo!?
  Yahoo! Tax Center - online filing with TurboTax
  http://taxes.yahoo.com/
 
  --
  To unsubscribe:  
 mailto:[EMAIL PROTECTED]
  For additional commands:
 mailto:[EMAIL PROTECTED]
  Troubles with the list:
 mailto:[EMAIL PROTECTED]
 
  --
  To unsubscribe:  
 mailto:[EMAIL PROTECTED]
  For additional commands:
 mailto:[EMAIL PROTECTED]
  Troubles with the list:
 mailto:[EMAIL PROTECTED]
 
 
 
 
 --
 To unsubscribe:  
 mailto:[EMAIL PROTECTED]
 For additional commands:
 mailto:[EMAIL PROTECTED]
 Troubles with the list:
 mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Configuration problems

2002-04-03 Thread Robertwhadcock

My hosting company are having problems configuring Tomcat on their server, i 
wondered if you can help, as im really in need of JSP support. here is the 
last email i got from them:

We keep running into problems when runnin jsp that it won't parse the
code:

root@global [/usr/local/apache/conf]# /usr/local/apache/bin/apachectl
start
[Tue Apr  2 14:34:29 2002] [warn] module jk_module is already loaded,
skipping
Syntax error on line 7 of
/usr/local/jakarta/jakarta-tomcat-4.0.3-src/build/conf/a
uto/mod_jk.conf:
Invalid command 'JkWorkersFile', perhaps mis-spelled or defined by a
module not in
cluded in the server configuration
/usr/local/apache/bin/apachectl start: httpd could not be started
root@global [/usr/local/apache/conf]#


Any ideas?

Thanks in anticipation,

Robert Whadcock 



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: XXX Assert failed, buff too small

2002-04-03 Thread John Roth

After two weeks, I am still troubleshooting the same problem uploading files
via https where the filesize is greater than 10.7MB.  I am not having much
luck determining the order in which to problem flows, but the following
things are happening:

1. stdout.log records XXX Assert failed, buff too small after which
ajp13Packet.class exceptions with AIOOBE.
2. isapi_redirect gets a ReadClient failed, followed shortly by
ServerSupportFunction failed.
3. IIS sends a reset flag to the client.
4. Socket timeout as client acks the reset flag.

I am not able to determine the chain of events, ie: IIS reset/Client
reset-ReadClient fails-AIOOBE or AIOOBE-ReadClient fails-IIS
reset/Client reset.
We are using the O'Reilly multipart upload servlet, and it has been upgraded
to the latest version.  The same thing happens when testing with other JSP
based solutions (such as JSPSmartUpload) but not with ASP-based uploads.

The next series of questions is this:
1. I noticed that 4.0.3 includes a significantly changed ajp connector.  Had
anyone been using is successfully or know if the changes address this issue?
2. Any ideas on how to more closely determine to order of the described
order of events? Some of the logs reports milliseconds, most don't, so I
can't seem to absolutely determine the order of events.
3. I have adjusted several TCP parameters in the Windows registry, but
nothing seems to change the fact that the error always occurs on the 1365th
AJP packet.  None of the buffers within isapi_redirect.dll appear to
correlate to this number.  Anyone familiar with the inner workings of
isapi_redirect (dated feb 14, 2002)?

Any desperately needed help would be appreciated.

Thanks,
john


-Original Message-
From: John Roth [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 20, 2002 4:39 PM
To: Tomcat User Group (E-mail)
Subject: XXX Assert failed, buff too small


We are having a problem with Tomcat using an upload servlet to upload
potentially large files (up to 100MB).  The servlet works fine for all file
sizes in the following instances:
http://servername/app/UploadFiles.jsp
http://servername:8080/app/UploadFiles.jsp
but when using https (ie: https://servername/app/UploadFiles.jsp, we get
'Page Cannot Be Displayed'.  A summary of the error logs is below:

IIS_Redirect.Log

 [Wed Mar 20 15:49:20 2002]  [jk_ajp13_worker.c (206)]: sending to ajp13
#8192
 [Wed Mar 20 15:49:20 2002]  [jk_ajp13_worker.c (258)]: received from ajp13
#3
 [Wed Mar 20 15:49:20 2002]  [jk_isapi_plugin.c (426)]: Into
jk_ws_service_t::read
 [Wed Mar 20 15:49:20 2002]  [jk_isapi_plugin.c (426)]: Into
jk_ws_service_t::read

 ... this repeats 1364 times, everytime, before the following: ...

 [Wed Mar 20 15:49:20 2002]  [jk_ajp13_worker.c (206)]: sending to ajp13
#8192
 [Wed Mar 20 15:49:20 2002]  [jk_ajp13_worker.c (258)]: received from ajp13
#3
 [Wed Mar 20 15:49:20 2002]  [jk_isapi_plugin.c (426)]: Into
jk_ws_service_t::read
 [Wed Mar 20 15:49:20 2002]  [jk_isapi_plugin.c (426)]: Into
jk_ws_service_t::read
 [Wed Mar 20 15:49:20 2002]  [jk_isapi_plugin.c (460)]:
jk_ws_service_t::read, ReadClient failed

stdout.log
--
 Starting service Tomcat-Standalone-(Staging)
 Apache Tomcat/4.0.1
 [Ajp13] bad read: -103
 XXX Assert failed, buff too small

Note: Yes, I have been following the list, and I don't know what causes -103
either, but with the exception of this servlet, our app has been running
great for months, with several dozen -103's a day.  The XXX Assert Failed is
new.

tomcat_log.log
--
2002-03-20 15:34:02 UploadFiles: init
2002-03-20 15:34:15 jsp: init
2002-03-20 15:34:15 Ajp13Processor[8009][6] process: invoke
java.net.SocketException: Connection aborted by peer: socket write error
at java.net.SocketOutputStream.socketWrite(Native Method)
at java.net.SocketOutputStream.write(SocketOutputStream.java:83)
at org.apache.ajp.Ajp13.send(Ajp13.java:959)
at org.apache.ajp.Ajp13.finish(Ajp13.java:808)
at
org.apache.ajp.tomcat4.Ajp13Response.finishResponse(Ajp13Response.java:192)
at org.apache.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:373)
at org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:424)
at java.lang.Thread.run(Thread.java:484)

Application Log
---
2002-03-20 15:34:03,253 [Ajp13Processor[8009][6]] DEBUG
com.psc.ams.servlets.PSCUploadFilesByExtension - clearing dir
e://staging\jroth
2002-03-20 15:34:03,253 [Ajp13Processor[8009][6]] DEBUG
com.psc.ams.servlets.PSCUploadFilesByExtension - attempting to delete file
e:\\staging\jroth\11MB.txt
2002-03-20 15:34:15,190 [Ajp13Processor[8009][6]] ERROR
com.psc.ams.servlets.PSCUploadFilesByExtension - Unexpected Exception
occured in PSCUploadFiles.doPost().
java.lang.ArrayIndexOutOfBoundsException
at java.lang.System.arraycopy(Native Method)
at org.apache.ajp.Ajp13Packet.getBytes(Ajp13Packet.java:459)
at 

Strange bean problem in JSP

2002-04-03 Thread Nikola Milutinovic

Hi all.

I have a strange bean problem in my JSP page.

The bean in question has several properties, most of them are R/W. Anyway, those 
that I'm trying to set from the request parameters are R/W.

My problem is that one of the properties *refuses* to be set. That is eMail. 
Others, like name, surname and mailBox are set just fine.

These are the tests I've tried:

--
jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
/jsp:useBean
--

This sets all properties except eMail

--
jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
   jsp:setProperty name=dataBean property=eMail/
/jsp:useBean
--

This produces an exception:

2002-04-03 13:01:46 StandardWrapperValve[jsp]: Servlet.service() for servlet jsp 
threw exception org.apache.jasper.JasperException: Cannot find any information 
on property 'eMail' in a bean of type 'EUserBean'
 at 
org.apache.jasper.runtime.JspRuntimeLibrary.internalIntrospecthelper(JspRuntimeLibrary.java,
 
Compiled Code)
 at 
org.apache.jasper.runtime.JspRuntimeLibrary.introspecthelper(JspRuntimeLibrary.java, 
Compiled Code)


However, this succedes and produces the desired result (setting of eMail 
property):

jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
/jsp:useBean
%
dataBean.setEMail( request.getParameter( eMail ) );
%

I know I can use this as a workaround, but I'd like to know what the real 
problem is.

TYIA,
Nix.


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Strange bean problem in JSP

2002-04-03 Thread Sayre Robert

You should check the capitalization of your bean properties:
is it eMail or EMail? 

the jsp tag: jsp:setProperty name=dataBean property=eMail/
calling the set method: dataBean.setEMail( request.getParameter( eMail )
);

I would try jsp:setProperty name=dataBean property=EMail/.

Robert Sayre



-Original Message-
From: Nikola Milutinovic [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 3:46 PM
To: Tomcat Users List
Subject: Strange bean problem in JSP


Hi all.

I have a strange bean problem in my JSP page.

The bean in question has several properties, most of them are R/W. Anyway,
those 
that I'm trying to set from the request parameters are R/W.

My problem is that one of the properties *refuses* to be set. That is
eMail. 
Others, like name, surname and mailBox are set just fine.

These are the tests I've tried:

--
jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
/jsp:useBean
--

This sets all properties except eMail

--
jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
   jsp:setProperty name=dataBean property=eMail/
/jsp:useBean
--

This produces an exception:

2002-04-03 13:01:46 StandardWrapperValve[jsp]: Servlet.service() for servlet
jsp 
threw exception org.apache.jasper.JasperException: Cannot find any
information 
on property 'eMail' in a bean of type 'EUserBean'
 at 
org.apache.jasper.runtime.JspRuntimeLibrary.internalIntrospecthelper(JspRunt
imeLibrary.java, 
Compiled Code)
 at 
org.apache.jasper.runtime.JspRuntimeLibrary.introspecthelper(JspRuntimeLibra
ry.java, 
Compiled Code)


However, this succedes and produces the desired result (setting of eMail 
property):

jsp:useBean id=dataBean class=EUserBean scope=request
   jsp:setProperty name=dataBean property=*/
/jsp:useBean
%
dataBean.setEMail( request.getParameter( eMail ) );
%

I know I can use this as a workaround, but I'd like to know what the real 
problem is.

TYIA,
Nix.


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



Re: Strange bean problem in JSP

2002-04-03 Thread Nikola Milutinovic

Sayre Robert wrote:

 You should check the capitalization of your bean properties:
 is it eMail or EMail? 
 
 the jsp tag: jsp:setProperty name=dataBean property=eMail/
 calling the set method: dataBean.setEMail( request.getParameter( eMail )
 );
 
 I would try jsp:setProperty name=dataBean property=EMail/.
 
 Robert Sayre

 From the bean class:


protected String eMail;

public void setEMail(String EMail) {
   this.eMail = EMail;
}

public String getEMail() {
   return eMail;
}


The capitalization seams OK. I'll try your suggestion.

Nix.


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Craig R. McClanahan



On Wed, 3 Apr 2002, Sanjay Bahal wrote:

 Date: Wed, 3 Apr 2002 12:00:17 -0800 (PST)
 From: Sanjay Bahal [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Subject: RE: Working Directory

 Thanks Mark  Craig.
 My situation is slightly different. I am trying to
 read the property file from a Java class on the
 server(not the servlet). I would think there would be
 a way around to do this- else I can work around to
 pass a param to the helper class.

Consider using getClass().getResourceAsStream(myprops.properties) for
this kind of purpose.  This looks for myprops.properties on your class
path, and loads it from wherever the classes themselves are found (either
an unpacked directory or a JAR file).

 Thanks
 Sanjay

Craig


 --- Craig R. McClanahan [EMAIL PROTECTED] wrote:
 
 
  On Wed, 3 Apr 2002, Wagoner, Mark wrote:
 
   Date: Wed, 3 Apr 2002 11:38:31 -0500
   From: Wagoner, Mark [EMAIL PROTECTED]
   Reply-To: Tomcat Users List
  [EMAIL PROTECTED]
   To: 'Tomcat Users List'
  [EMAIL PROTECTED]
   Subject: RE: Working Directory
  
   I place my properties files in the WEB-INF
  directory and do the following to
   find them -
  
   String webInfFolder =
  getServletContext().getRealPath(/WEB-INF)
  
 
  This only works if the app is run from an unpacked
  directory, which is not
  guaranteed to be portable (not every server supports
  running this way).
  The best way to read a properties file is to put it
  in the WEB-INF
  subdirectory and use something like:
 
Properties props = new Properties();
InputStream stream =
 
 
 getServletContext().getResourceAsStream(/WEB-INF/myprops.properties);
props.load(stream);
stream.close();
 
  which is guaranteed to be portable to any server.
 
  Craig
 
 
   -Original Message-
   From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
   Sent: Wednesday, April 03, 2002 11:34 AM
   To: tomcat
   Subject: Working Directory
  
  
   I am trying to read a properties file from my
  servlet.
   It always comes back saying file not found. I have
   tried placing the file in
   classes/web-inf/context-path. Ideally I would like
  to
   lace it in my classes directory- How do I achieve
  it.
   Thanks
   Sanjay
  
   __
   Do You Yahoo!?
   Yahoo! Tax Center - online filing with TurboTax
   http://taxes.yahoo.com/
  
   --
   To unsubscribe:
  mailto:[EMAIL PROTECTED]
   For additional commands:
  mailto:[EMAIL PROTECTED]
   Troubles with the list:
  mailto:[EMAIL PROTECTED]
  
   --
   To unsubscribe:
  mailto:[EMAIL PROTECTED]
   For additional commands:
  mailto:[EMAIL PROTECTED]
   Troubles with the list:
  mailto:[EMAIL PROTECTED]
  
  
 
 
  --
  To unsubscribe:
  mailto:[EMAIL PROTECTED]
  For additional commands:
  mailto:[EMAIL PROTECTED]
  Troubles with the list:
  mailto:[EMAIL PROTECTED]
 


 __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with TurboTax
 http://taxes.yahoo.com/

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: session object [urgent!] [solution]

2002-04-03 Thread rsequeira


Set the crossContext attribute of the Context tag to true. This way you
eliminate redundancy. And I think your session info will be preserved too.

RS




Nancy Crisostomo Martinez [EMAIL PROTECTED] on 04/03/2002
01:20:00 PM

Please respond to Tomcat Users List [EMAIL PROTECTED]

To:   Tomcat Users List [EMAIL PROTECTED]
cc:

Subject:  Re: session object [urgent!] [solution]

Hi everybody and thank you for your answers

I have found the solution to my problem...
Actually there were no errors in my code neither in Tomcat 3.3.

The problem was that the Jsp file called in the left side of the frames,
was in
the Security context ($TOMCAT_HOME/webapps/security) and the jsp file
called
in the right side by the link was  in the Other context
($TOMCAT_HOME/webapps/other), so, the only one thing  I did is to place the
jsp's of the Other context  in the Security context, so It is working
now!!!

I don't know why, but I had those contexts because I wanted to have all the
files organized by their own nature.. so now, I need to have only one
context... It will look awful when I add more files!!

Now, do you know why the session change only for calling another file
placed in
other context?? I think it must have a solution.!

If you know how to fix it, please let me know, OK?

Thank you!
Regards,
Nancy


Huy K Dung wrote:

 Hi Nancy,

 I don't think it's Tomcat's problem. It's a problem with the browsers
 themselves.

 This problem happens to me even with Tomcat 3.2.3. At first I thought
it's a
 problem with Tomcat 3.3.1 but I ran the same app with Tomcat 3.2.3 and
the
 problem still persists.

 A workaround or some tricks will solve this problem I hope. For those who
 have come up with a fix for this problem, I appreciate very much if you
read
 this message. Thanks.

 -Original Message-
 From: Nancy Crisostomo Martinez [mailto:[EMAIL PROTECTED]]
 Sent: Saturday, March 02, 2002 02:56 PM
 To: Tomcat Users List
 Subject: Re: session object [urgent!]

 I have found a kind of bug or I don't know what
 I tried to access to the session's attributes, with another
servlet-engine
 and it works perferct!
 So... I think Tomcat 3.3 (I'm using) has a bug or maybe it is a cause of
a
 bad configuration because the
 track is lost

 What do you think about it?
 Does any of you have the same problem with sessions?

 Nancy Crisostomo Martinez wrote:

  Hi everybody!
 
  I need your help..
  I'm trying to track some attributes I added to the session object, but
I
  can't...
 
  I have an html file (main.htm) which opens a new window browser
  (validate.jsp) when you press a button to access to one service...
  Then when the user is validated in the validate.jsp file, I added two
  attributes to the session object like this:
 
   ...
   %
   if (validUser(id_Usuario)){
  session.setAttribute(numero,id_Usuario);
  session.setAttribute(edad,num);
   ...
 
  and finally the window is closed and another new window is opened (
  portal.jsp ).
 
   %
   script
 
 
 window.open
(portal.jsp,,top=0,left=0,width=791,height=520,scrollbars=ye
 s,resizable=yes,status=yes)
 
   return eval('close()')
   /script
   %
   }
   %
 
  The portal.jsp file is formed by frames:
 
HTML
FRAMESET rows=75,250* frameborder=0 border=0
  framespacing=0
FRAME name=FrameArriba scrolling=NO noresize
  marginwidth=0 marginheight=0 SRC=arriba.htm frameborder=0
 
   FRAMESET cols=128,127*  border=0 framespacing=0
  frameborder=0
   FRAME name=FrameIzquierda scrolling=NO
  marginwidth=0 marginheight=0 noresize SRC=izquierda.jsp
frameborder=NO
   FRAME name=FrameServicio marginwidth=0
  marginheight=0 noresize SRC=blanco.jsp frameborder=NO 
   /FRAMESET
 
   NOFRAMES
 Su browser no acepta Frames.
   /NOFRAMES
/FRAMESET
/HTML
 
  In the left frame (FrameIzquierda) I have a jsp file (izquierda.jsp)
  that reads the new session's attributes (numero,edad) and they are
  displayed perfectly when the
  portal.jsp file is opened. Moreover, in the right frame I put a jsp
file
  (blanco.jsp) that also reads the attributes 'id' and 'ag' and they are
  perfectly displayed too.
  But the problem becomes when I click a link placed in the izquierda.jsp
  file :
 
   .
   a href=top.jsptest/a
   or
   a href=top.jsp target=FrameServicio test/a
   .
 
  The top.jsp file also reads the attributes (numero, edad)...
  In both cases the session's attributes are not displayed, they only
  return a null value,  and the session id (session.getId()) is
  differtent because when the link is
  pressed, a new session object is createdso.. I don't know how to
fix
  this
  I really need to get the two attributes I stored 

Re: how to store a document file?

2002-04-03 Thread rsequeira


How about a BLOB type

RS




Nancy Crisostomo Martinez [EMAIL PROTECTED] on 04/03/2002
03:18:32 PM

Please respond to Tomcat Users List [EMAIL PROTECTED]

To:   [EMAIL PROTECTED] [EMAIL PROTECTED],
  [EMAIL PROTECTED] [EMAIL PROTECTED],
  Tomcat Users List [EMAIL PROTECTED]
cc:

Subject:  how to store a document file?

Hi!
Does any of you know how to store a formatted document (text with bolds,
italics, etc) just like a Word document or html file in an Oracle
database?
Do you know what datatype the record must have?
And how does it is stored in programming (Java Code)? you could give me
a trick (Java code) to do it ...

Thanks in advance!!
Nancy.


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]









--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: how to store a document file?

2002-04-03 Thread Jason Johnston

If you want to store an actual Word file, you should do it as a BLOB (Binary Large 
OBject or Binary Logical OBject depending on your school of thought).  I don't have 
any code examples but Java does have some tools for storing and retreiving BLOB's from 
an Oracle database.



Tomcat won't find my web.xml files.

2002-04-03 Thread Jason Johnston

I've been working with Tomcat 4.0.1 and I'm running into a major stumbling block.  I 
can run servlets and jsp's letting tomcat default to the default web.xml but I can't 
make my own.

I have the following web.xml:

?xml version=1.0 encoding=ISO-8859-1?

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


web-app

  servlet
  servlet-namelogin/servlet-name
  servlet-classcom.onjava.login/servlet-class
  /servlet

  taglib
 taglib-uri/onjava/taglib-uri
  taglib-location/WEB-INF/lib/taglib.tld/taglib-location
  /taglib

/web-app


Located at TOMCAT_HOME/webapps/onjava/WEB-INF/web.xml

The custom tags fail and I see this in the logs:

2002-04-03 13:10:37 ContextConfig[/onjava]: Missing application web.xml, using 
defaults only

Am I missing something? I'm running on NT4.0 Server Sp6a.  I've seen other people 
mention this problem but I haven't found any solutions.

PLEASE. IF ANYONE KNOWS ANYTHING THAT COULD HELP, LET ME KNOW  This is a major 
stumbling block.  I basically can't build webapps if I can't get it to recognize me 
web.xml files.



TOMCAT STOPS!

2002-04-03 Thread Bob Swerdlow

We're in trouble.

We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
stops servicing requests.

We know it is Tomcat because we can still get to the machine on other ports.
We can SSH to it and everything seems fine.

We know it is not just one project since we cannot get to any projects that
Tomcat should be running.  Not even /manager/list.

If we are patient enough, it sometimes comes back after 4 or 5 minutes.
Then everything seems normal again.  Usually we don't wait because our site
is down, so we just stop and restart it.  However, it often takes several
restarts to get it going again.

I'm not even sure where to start looking!  Any help would be greatly
appreciated!

Bob Swerdlow
Chief Operating Officer
Transpose, LLC
[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: TOMCAT STOPS!

2002-04-03 Thread Bob Swerdlow

One more detail, which may be important:
If we use lynx on the server running Tomcat, we CAN access the pages.  I
can't figure that out at all.

Please help if you can.

- Original Message -
From: Bob Swerdlow [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:51 PM
Subject: TOMCAT STOPS!


 We're in trouble.

 We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
 stops servicing requests.

 We know it is Tomcat because we can still get to the machine on other
ports.
 We can SSH to it and everything seems fine.

 We know it is not just one project since we cannot get to any projects
that
 Tomcat should be running.  Not even /manager/list.

 If we are patient enough, it sometimes comes back after 4 or 5 minutes.
 Then everything seems normal again.  Usually we don't wait because our
site
 is down, so we just stop and restart it.  However, it often takes several
 restarts to get it going again.

 I'm not even sure where to start looking!  Any help would be greatly
 appreciated!

 Bob Swerdlow
 Chief Operating Officer
 Transpose, LLC
 [EMAIL PROTECTED]


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: TOMCAT STOPS!

2002-04-03 Thread Nancy Crisostomo Martinez

Hi Bob!
I don't know if this could help you,but before I had the same problem when I
started Tomcat 3.3 from a Telnet window and close it...
Tomcat was only alive when the telnet window was opened, so now I started as
follows and everything is OK:

nohup tomcat.sh start  nohup.out

Then you could see all the console messages in the nohup.out file

Hope this helps you!

Nancy.


Bob Swerdlow wrote:

 We're in trouble.

 We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
 stops servicing requests.

 We know it is Tomcat because we can still get to the machine on other ports.
 We can SSH to it and everything seems fine.

 We know it is not just one project since we cannot get to any projects that
 Tomcat should be running.  Not even /manager/list.

 If we are patient enough, it sometimes comes back after 4 or 5 minutes.
 Then everything seems normal again.  Usually we don't wait because our site
 is down, so we just stop and restart it.  However, it often takes several
 restarts to get it going again.

 I'm not even sure where to start looking!  Any help would be greatly
 appreciated!

 Bob Swerdlow
 Chief Operating Officer
 Transpose, LLC
 [EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: TOMCAT STOPS!

2002-04-03 Thread Dahnke, Eric


If this is true:

If we use lynx on the server running Tomcat, we CAN access the
pages.

then Tomcat is not your problem, and it is more likely a networking /
firewall issue. When it goes down what does telnetting to port 80 show you?
How about traceroute?

could also be a hostname dns thing. when you run lynx do you use localhost?
What is the  exact URL you use in lynx?



-Original Message-
From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 4:58 PM
To: Tomcat Users List
Cc: [EMAIL PROTECTED]
Subject: Re: TOMCAT STOPS!


One more detail, which may be important:
If we use lynx on the server running Tomcat, we CAN access the pages.  I
can't figure that out at all.

Please help if you can.

- Original Message -
From: Bob Swerdlow [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:51 PM
Subject: TOMCAT STOPS!


 We're in trouble.

 We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
 stops servicing requests.

 We know it is Tomcat because we can still get to the machine on other
ports.
 We can SSH to it and everything seems fine.

 We know it is not just one project since we cannot get to any projects
that
 Tomcat should be running.  Not even /manager/list.

 If we are patient enough, it sometimes comes back after 4 or 5 minutes.
 Then everything seems normal again.  Usually we don't wait because our
site
 is down, so we just stop and restart it.  However, it often takes several
 restarts to get it going again.

 I'm not even sure where to start looking!  Any help would be greatly
 appreciated!

 Bob Swerdlow
 Chief Operating Officer
 Transpose, LLC
 [EMAIL PROTECTED]


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: TOMCAT STOPS!

2002-04-03 Thread Bob Swerdlow

Hi, Eric -

That is what I thought, too (I was not the one to see lynx working, but I'll
try it myself the next time).  Unfortunately, I don't know whether it was to
localHost or www.emergentmusic.com (that's the URL we're having trouble
with).  I'll asked the engineer who did that testing, but he's out for a
while.

tracert showed a complete trace.

Did not try telnet.

What is interesting is that we have another server running another copy of
Tomcat for development.  The firewall is set up to forward port 8080 to that
server and port 80 to the main server (the one that failed).  Accessing the
other server works fine, so DNS does not seem to be the issue and the
firewall seems to be up.

Thanks for your help!
- Bob

- Original Message -
From: Dahnke, Eric [EMAIL PROTECTED]
To: 'Tomcat Users List' [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:53 PM
Subject: RE: TOMCAT STOPS!



 If this is true:

 If we use lynx on the server running Tomcat, we CAN access the
 pages.

 then Tomcat is not your problem, and it is more likely a networking /
 firewall issue. When it goes down what does telnetting to port 80 show
you?
 How about traceroute?

 could also be a hostname dns thing. when you run lynx do you use
localhost?
 What is the  exact URL you use in lynx?



 -Original Message-
 From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 4:58 PM
 To: Tomcat Users List
 Cc: [EMAIL PROTECTED]
 Subject: Re: TOMCAT STOPS!


 One more detail, which may be important:
 If we use lynx on the server running Tomcat, we CAN access the pages.  I
 can't figure that out at all.

 Please help if you can.

 - Original Message -
 From: Bob Swerdlow [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 4:51 PM
 Subject: TOMCAT STOPS!


  We're in trouble.
 
  We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
  stops servicing requests.
 
  We know it is Tomcat because we can still get to the machine on other
 ports.
  We can SSH to it and everything seems fine.
 
  We know it is not just one project since we cannot get to any projects
 that
  Tomcat should be running.  Not even /manager/list.
 
  If we are patient enough, it sometimes comes back after 4 or 5 minutes.
  Then everything seems normal again.  Usually we don't wait because our
 site
  is down, so we just stop and restart it.  However, it often takes
several
  restarts to get it going again.
 
  I'm not even sure where to start looking!  Any help would be greatly
  appreciated!
 
  Bob Swerdlow
  Chief Operating Officer
  Transpose, LLC
  [EMAIL PROTECTED]
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: TOMCAT STOPS!

2002-04-03 Thread Bob Swerdlow

It just happened again.  Latest about 3 minutes and then went back to
normal, with no intervention.

I was able to access the real URL from lynx on that server, through SSH,
even during the blackout.

Is there somewhere that such network problems might be logged?

Thanks,
Bob

- Original Message -
From: Dahnke, Eric [EMAIL PROTECTED]
To: 'Tomcat Users List' [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:53 PM
Subject: RE: TOMCAT STOPS!



 If this is true:

 If we use lynx on the server running Tomcat, we CAN access the
 pages.

 then Tomcat is not your problem, and it is more likely a networking /
 firewall issue. When it goes down what does telnetting to port 80 show
you?
 How about traceroute?

 could also be a hostname dns thing. when you run lynx do you use
localhost?
 What is the  exact URL you use in lynx?



 -Original Message-
 From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 4:58 PM
 To: Tomcat Users List
 Cc: [EMAIL PROTECTED]
 Subject: Re: TOMCAT STOPS!


 One more detail, which may be important:
 If we use lynx on the server running Tomcat, we CAN access the pages.  I
 can't figure that out at all.

 Please help if you can.

 - Original Message -
 From: Bob Swerdlow [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 4:51 PM
 Subject: TOMCAT STOPS!


  We're in trouble.
 
  We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
  stops servicing requests.
 
  We know it is Tomcat because we can still get to the machine on other
 ports.
  We can SSH to it and everything seems fine.
 
  We know it is not just one project since we cannot get to any projects
 that
  Tomcat should be running.  Not even /manager/list.
 
  If we are patient enough, it sometimes comes back after 4 or 5 minutes.
  Then everything seems normal again.  Usually we don't wait because our
 site
  is down, so we just stop and restart it.  However, it often takes
several
  restarts to get it going again.
 
  I'm not even sure where to start looking!  Any help would be greatly
  appreciated!
 
  Bob Swerdlow
  Chief Operating Officer
  Transpose, LLC
  [EMAIL PROTECTED]
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Sanjay Bahal

Carig,
I tried this it does not work. I can't get the stream.
I have a property file in the classes directory- where
I all my classes are. My code is:
MyClass thisInstance  = new MyClass();
InputStream stream =
thisInstance.getClass().getResourceAsStream(propFile);
if ( stream != null) {
  props.load(stream);
  stream.close();
}else System.out.println(The stream null);

Thanks
Sanjay


--- Craig R. McClanahan [EMAIL PROTECTED] wrote:
 
 
 On Wed, 3 Apr 2002, Sanjay Bahal wrote:
 
  Date: Wed, 3 Apr 2002 12:00:17 -0800 (PST)
  From: Sanjay Bahal [EMAIL PROTECTED]
  Reply-To: Tomcat Users List
 [EMAIL PROTECTED]
  To: Tomcat Users List
 [EMAIL PROTECTED]
  Subject: RE: Working Directory
 
  Thanks Mark  Craig.
  My situation is slightly different. I am trying to
  read the property file from a Java class on the
  server(not the servlet). I would think there would
 be
  a way around to do this- else I can work around to
  pass a param to the helper class.
 
 Consider using
 getClass().getResourceAsStream(myprops.properties)
 for
 this kind of purpose.  This looks for
 myprops.properties on your class
 path, and loads it from wherever the classes
 themselves are found (either
 an unpacked directory or a JAR file).
 
  Thanks
  Sanjay
 
 Craig
 
 
  --- Craig R. McClanahan [EMAIL PROTECTED]
 wrote:
  
  
   On Wed, 3 Apr 2002, Wagoner, Mark wrote:
  
Date: Wed, 3 Apr 2002 11:38:31 -0500
From: Wagoner, Mark
 [EMAIL PROTECTED]
Reply-To: Tomcat Users List
   [EMAIL PROTECTED]
To: 'Tomcat Users List'
   [EMAIL PROTECTED]
Subject: RE: Working Directory
   
I place my properties files in the WEB-INF
   directory and do the following to
find them -
   
String webInfFolder =
   getServletContext().getRealPath(/WEB-INF)
   
  
   This only works if the app is run from an
 unpacked
   directory, which is not
   guaranteed to be portable (not every server
 supports
   running this way).
   The best way to read a properties file is to put
 it
   in the WEB-INF
   subdirectory and use something like:
  
 Properties props = new Properties();
 InputStream stream =
  
  
 

getServletContext().getResourceAsStream(/WEB-INF/myprops.properties);
 props.load(stream);
 stream.close();
  
   which is guaranteed to be portable to any
 server.
  
   Craig
  
  
-Original Message-
From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 11:34 AM
To: tomcat
Subject: Working Directory
   
   
I am trying to read a properties file from my
   servlet.
It always comes back saying file not found. I
 have
tried placing the file in
classes/web-inf/context-path. Ideally I would
 like
   to
lace it in my classes directory- How do I
 achieve
   it.
Thanks
Sanjay
   
   
 __
Do You Yahoo!?
Yahoo! Tax Center - online filing with
 TurboTax
http://taxes.yahoo.com/
   
--
To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
For additional commands:
   mailto:[EMAIL PROTECTED]
Troubles with the list:
   mailto:[EMAIL PROTECTED]
   
--
To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
For additional commands:
   mailto:[EMAIL PROTECTED]
Troubles with the list:
   mailto:[EMAIL PROTECTED]
   
   
  
  
   --
   To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
   For additional commands:
   mailto:[EMAIL PROTECTED]
   Troubles with the list:
   mailto:[EMAIL PROTECTED]
  
 
 
  __
  Do You Yahoo!?
  Yahoo! Tax Center - online filing with TurboTax
  http://taxes.yahoo.com/
 
  --
  To unsubscribe:  
 mailto:[EMAIL PROTECTED]
  For additional commands:
 mailto:[EMAIL PROTECTED]
  Troubles with the list:
 mailto:[EMAIL PROTECTED]
 
 
 
 
 --
 To unsubscribe:  
 mailto:[EMAIL PROTECTED]
 For additional commands:
 mailto:[EMAIL PROTECTED]
 Troubles with the list:
 mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Chapman, Carl


 This code actually works for me. 

  getClass().getResourceAsStream(Configuration.xml);

  I did dump the Configuration.xml file into the same directory where this
code exists and jar'ed them all up.

com/blort/packagename/Configuration.class
com/blort/packagename/Configuration.xml

   You can start this simple and then get fancy.



 -Original Message-
 From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 2:28 PM
 To: Tomcat Users List
 Subject: RE: Working Directory
 
 
 Carig,
 I tried this it does not work. I can't get the stream.
 I have a property file in the classes directory- where
 I all my classes are. My code is:
 MyClass thisInstance  = new MyClass();
 InputStream stream =
 thisInstance.getClass().getResourceAsStream(propFile);
 if ( stream != null) {
   props.load(stream);
   stream.close();
 }else System.out.println(The stream null);
 
 Thanks
 Sanjay
 
 
 --- Craig R. McClanahan [EMAIL PROTECTED] wrote:
  
  
  On Wed, 3 Apr 2002, Sanjay Bahal wrote:
  
   Date: Wed, 3 Apr 2002 12:00:17 -0800 (PST)
   From: Sanjay Bahal [EMAIL PROTECTED]
   Reply-To: Tomcat Users List
  [EMAIL PROTECTED]
   To: Tomcat Users List
  [EMAIL PROTECTED]
   Subject: RE: Working Directory
  
   Thanks Mark  Craig.
   My situation is slightly different. I am trying to
   read the property file from a Java class on the
   server(not the servlet). I would think there would
  be
   a way around to do this- else I can work around to
   pass a param to the helper class.
  
  Consider using
  getClass().getResourceAsStream(myprops.properties)
  for
  this kind of purpose.  This looks for
  myprops.properties on your class
  path, and loads it from wherever the classes
  themselves are found (either
  an unpacked directory or a JAR file).
  
   Thanks
   Sanjay
  
  Craig
  
  
   --- Craig R. McClanahan [EMAIL PROTECTED]
  wrote:
   
   
On Wed, 3 Apr 2002, Wagoner, Mark wrote:
   
 Date: Wed, 3 Apr 2002 11:38:31 -0500
 From: Wagoner, Mark
  [EMAIL PROTECTED]
 Reply-To: Tomcat Users List
[EMAIL PROTECTED]
 To: 'Tomcat Users List'
[EMAIL PROTECTED]
 Subject: RE: Working Directory

 I place my properties files in the WEB-INF
directory and do the following to
 find them -

 String webInfFolder =
getServletContext().getRealPath(/WEB-INF)

   
This only works if the app is run from an
  unpacked
directory, which is not
guaranteed to be portable (not every server
  supports
running this way).
The best way to read a properties file is to put
  it
in the WEB-INF
subdirectory and use something like:
   
  Properties props = new Properties();
  InputStream stream =
   
   
  
 
 getServletContext().getResourceAsStream(/WEB-INF/myprops.prop
 erties);
  props.load(stream);
  stream.close();
   
which is guaranteed to be portable to any
  server.
   
Craig
   
   
 -Original Message-
 From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 11:34 AM
 To: tomcat
 Subject: Working Directory


 I am trying to read a properties file from my
servlet.
 It always comes back saying file not found. I
  have
 tried placing the file in
 classes/web-inf/context-path. Ideally I would
  like
to
 lace it in my classes directory- How do I
  achieve
it.
 Thanks
 Sanjay


  __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with
  TurboTax
 http://taxes.yahoo.com/

 --
 To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
 For additional commands:
mailto:[EMAIL PROTECTED]
 Troubles with the list:
mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
 For additional commands:
mailto:[EMAIL PROTECTED]
 Troubles with the list:
mailto:[EMAIL PROTECTED]


   
   
--
To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
For additional commands:
mailto:[EMAIL PROTECTED]
Troubles with the list:
mailto:[EMAIL PROTECTED]
   
  
  
   __
   Do You Yahoo!?
   Yahoo! Tax Center - online filing with TurboTax
   http://taxes.yahoo.com/
  
   --
   To unsubscribe:  
  mailto:[EMAIL PROTECTED]
   For additional commands:
  mailto:[EMAIL PROTECTED]
   Troubles with the list:
  mailto:[EMAIL PROTECTED]
  
  
  
  
  --
  To unsubscribe:  
  mailto:[EMAIL PROTECTED]
  For additional commands:
  mailto:[EMAIL PROTECTED]
  Troubles with the list:
  mailto:[EMAIL PROTECTED]
  
 
 
 __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with TurboTax
 http://taxes.yahoo.com/
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]
 

--
To unsubscribe:   mailto:[EMAIL 

RE: Working Directory

2002-04-03 Thread Robert Priest

I think that you may need a / in front of the properties file name. If you
don't have that.
I think that it expects like a path/package name in front of the package
file (like org_myorg_util_myprops.properties or something like that).

So when you call getResourceAsStream(), you will need something like:

getClass().getResourceAsStream(/myprops.properties)

or

getClass().getResourceAsStream(/+propFile);

-Original Message-
From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 5:28 PM
To: Tomcat Users List
Subject: RE: Working Directory


Carig,
I tried this it does not work. I can't get the stream.
I have a property file in the classes directory- where
I all my classes are. My code is:
MyClass thisInstance  = new MyClass();
InputStream stream =
thisInstance.getClass().getResourceAsStream(propFile);
if ( stream != null) {
  props.load(stream);
  stream.close();
}else System.out.println(The stream null);

Thanks
Sanjay


--- Craig R. McClanahan [EMAIL PROTECTED] wrote:
 
 
 On Wed, 3 Apr 2002, Sanjay Bahal wrote:
 
  Date: Wed, 3 Apr 2002 12:00:17 -0800 (PST)
  From: Sanjay Bahal [EMAIL PROTECTED]
  Reply-To: Tomcat Users List
 [EMAIL PROTECTED]
  To: Tomcat Users List
 [EMAIL PROTECTED]
  Subject: RE: Working Directory
 
  Thanks Mark  Craig.
  My situation is slightly different. I am trying to
  read the property file from a Java class on the
  server(not the servlet). I would think there would
 be
  a way around to do this- else I can work around to
  pass a param to the helper class.
 
 Consider using
 getClass().getResourceAsStream(myprops.properties)
 for
 this kind of purpose.  This looks for
 myprops.properties on your class
 path, and loads it from wherever the classes
 themselves are found (either
 an unpacked directory or a JAR file).
 
  Thanks
  Sanjay
 
 Craig
 
 
  --- Craig R. McClanahan [EMAIL PROTECTED]
 wrote:
  
  
   On Wed, 3 Apr 2002, Wagoner, Mark wrote:
  
Date: Wed, 3 Apr 2002 11:38:31 -0500
From: Wagoner, Mark
 [EMAIL PROTECTED]
Reply-To: Tomcat Users List
   [EMAIL PROTECTED]
To: 'Tomcat Users List'
   [EMAIL PROTECTED]
Subject: RE: Working Directory
   
I place my properties files in the WEB-INF
   directory and do the following to
find them -
   
String webInfFolder =
   getServletContext().getRealPath(/WEB-INF)
   
  
   This only works if the app is run from an
 unpacked
   directory, which is not
   guaranteed to be portable (not every server
 supports
   running this way).
   The best way to read a properties file is to put
 it
   in the WEB-INF
   subdirectory and use something like:
  
 Properties props = new Properties();
 InputStream stream =
  
  
 

getServletContext().getResourceAsStream(/WEB-INF/myprops.properties);
 props.load(stream);
 stream.close();
  
   which is guaranteed to be portable to any
 server.
  
   Craig
  
  
-Original Message-
From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 11:34 AM
To: tomcat
Subject: Working Directory
   
   
I am trying to read a properties file from my
   servlet.
It always comes back saying file not found. I
 have
tried placing the file in
classes/web-inf/context-path. Ideally I would
 like
   to
lace it in my classes directory- How do I
 achieve
   it.
Thanks
Sanjay
   
   
 __
Do You Yahoo!?
Yahoo! Tax Center - online filing with
 TurboTax
http://taxes.yahoo.com/
   
--
To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
For additional commands:
   mailto:[EMAIL PROTECTED]
Troubles with the list:
   mailto:[EMAIL PROTECTED]
   
--
To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
For additional commands:
   mailto:[EMAIL PROTECTED]
Troubles with the list:
   mailto:[EMAIL PROTECTED]
   
   
  
  
   --
   To unsubscribe:
  
 mailto:[EMAIL PROTECTED]
   For additional commands:
   mailto:[EMAIL PROTECTED]
   Troubles with the list:
   mailto:[EMAIL PROTECTED]
  
 
 
  __
  Do You Yahoo!?
  Yahoo! Tax Center - online filing with TurboTax
  http://taxes.yahoo.com/
 
  --
  To unsubscribe:  
 mailto:[EMAIL PROTECTED]
  For additional commands:
 mailto:[EMAIL PROTECTED]
  Troubles with the list:
 mailto:[EMAIL PROTECTED]
 
 
 
 
 --
 To unsubscribe:  
 mailto:[EMAIL PROTECTED]
 For additional commands:
 mailto:[EMAIL PROTECTED]
 Troubles with the list:
 mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread George McKinney


 -Original Message-
 From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 2:28 PM
 To: Tomcat Users List
 Subject: RE: Working Directory


 Carig,
 I tried this it does not work. I can't get the stream.
 I have a property file in the classes directory- where
 I all my classes are. My code is:
 MyClass thisInstance  = new MyClass();
 InputStream stream =
 thisInstance.getClass().getResourceAsStream(propFile);
 if ( stream != null) {
   props.load(stream);
   stream.close();
 }else System.out.println(The stream null);

Note that myProps.properties will look for that file in the same package
(place in the directory tree) as MyClass.class, so if MyClass is in
com.sanjay.stuff, the properties file should be in either
webapps/your web app/WEB-INF/classes/com/sanjay/stuff/myProps.properties

or in a jarfile (located in WEB-INF/lib) as
com/sanjay/stuff/myProps.properties

Similarly, if you prepend the propFile filename with
/com/other/myProperties the code will look for the corresponding package.

 Thanks
 Sanjay


 --- Craig R. McClanahan [EMAIL PROTECTED] wrote:
 
 
  On Wed, 3 Apr 2002, Sanjay Bahal wrote:
 
   Date: Wed, 3 Apr 2002 12:00:17 -0800 (PST)
   From: Sanjay Bahal [EMAIL PROTECTED]
   Reply-To: Tomcat Users List
  [EMAIL PROTECTED]
   To: Tomcat Users List
  [EMAIL PROTECTED]
   Subject: RE: Working Directory
  
   Thanks Mark  Craig.
   My situation is slightly different. I am trying to
   read the property file from a Java class on the
   server(not the servlet). I would think there would
  be
   a way around to do this- else I can work around to
   pass a param to the helper class.
 
  Consider using
  getClass().getResourceAsStream(myprops.properties)
  for
  this kind of purpose.  This looks for
  myprops.properties on your class
  path, and loads it from wherever the classes
  themselves are found (either
  an unpacked directory or a JAR file).
 
   Thanks
   Sanjay
 
  Craig
 
 
   --- Craig R. McClanahan [EMAIL PROTECTED]
  wrote:
   
   
On Wed, 3 Apr 2002, Wagoner, Mark wrote:
   
 Date: Wed, 3 Apr 2002 11:38:31 -0500
 From: Wagoner, Mark
  [EMAIL PROTECTED]
 Reply-To: Tomcat Users List
[EMAIL PROTECTED]
 To: 'Tomcat Users List'
[EMAIL PROTECTED]
 Subject: RE: Working Directory

 I place my properties files in the WEB-INF
directory and do the following to
 find them -

 String webInfFolder =
getServletContext().getRealPath(/WEB-INF)

   
This only works if the app is run from an
  unpacked
directory, which is not
guaranteed to be portable (not every server
  supports
running this way).
The best way to read a properties file is to put
  it
in the WEB-INF
subdirectory and use something like:
   
  Properties props = new Properties();
  InputStream stream =
   
   
  
 
 getServletContext().getResourceAsStream(/WEB-INF/myprops.prop
 erties);
  props.load(stream);
  stream.close();
   
which is guaranteed to be portable to any
  server.
   
Craig
   
   
 -Original Message-
 From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 11:34 AM
 To: tomcat
 Subject: Working Directory


 I am trying to read a properties file from my
servlet.
 It always comes back saying file not found. I
  have
 tried placing the file in
 classes/web-inf/context-path. Ideally I would
  like
to
 lace it in my classes directory- How do I
  achieve
it.
 Thanks
 Sanjay


  __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with
  TurboTax
 http://taxes.yahoo.com/

 --
 To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
 For additional commands:
mailto:[EMAIL PROTECTED]
 Troubles with the list:
mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
 For additional commands:
mailto:[EMAIL PROTECTED]
 Troubles with the list:
mailto:[EMAIL PROTECTED]


   
   
--
To unsubscribe:
   
  mailto:[EMAIL PROTECTED]
For additional commands:
mailto:[EMAIL PROTECTED]
Troubles with the list:
mailto:[EMAIL PROTECTED]
   
  
  
   __
   Do You Yahoo!?
   Yahoo! Tax Center - online filing with TurboTax
   http://taxes.yahoo.com/
  
   --
   To unsubscribe:
  mailto:[EMAIL PROTECTED]
   For additional commands:
  mailto:[EMAIL PROTECTED]
   Troubles with the list:
  mailto:[EMAIL PROTECTED]
  
  
 
 
  --
  To unsubscribe:
  mailto:[EMAIL PROTECTED]
  For additional commands:
  mailto:[EMAIL PROTECTED]
  Troubles with the list:
  mailto:[EMAIL PROTECTED]
 


 __
 Do You Yahoo!?
 Yahoo! Tax Center - online filing with TurboTax
 http://taxes.yahoo.com/

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

single-sign-on and cookies

2002-04-03 Thread Aditya

Is there any reason why the JSESSIONIDSSO cookie, if set via a SSL'd login
form, wouldn't be presented on the same server on a subsequent non-SSL page?

Adi

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




JDBCRealm problem (EMPTY page after login)

2002-04-03 Thread Alvin Wang

Hi! I am using JDBCRealm in Tomcat to setup the user authentication. For
example if the user want to access abc.html, Tomcat will first display the
login.jsp page. However, after the user logs in, it shows an EMPTY page. The
user has to refresh the browser to see the content of abc.html

Can any guru tell me how to fix this? Thanks!

Alvin


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




how to store a document file?

2002-04-03 Thread Nancy Crisostomo Martinez

Hi!
Does any of you know how to store a formatted document (text with bolds,
italics, etc) just like a Word document or html file in an Oracle
database?
Do you know what datatype the record must have?
And how does it is stored in programming (Java Code)? you could give me
a trick (Java code) to do it ...

Thanks in advance!!
Nancy.


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




HTTPS connection switched to HTTP

2002-04-03 Thread John Burnley

Sorry for the bandwidth, I saw postings on this the other day but I cleaned out my 
Email folders yesterday.

We are experimenting with Apache 1.3.22 and Tomcat 4.0.3 using the warp connection.  
When we use an SSL connection, it looks like it gets switched back to a non-SSL 
connection by Tomcat.

I thought someone on the list posted that it was indeed a Tomcat bug and it was being 
investigated/addressed.  Could someone please verify that for me?

Thanks much in advance.

Regards, 

John


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Question about container-managed security

2002-04-03 Thread Wellie W. Chao

The other weird thing is that request parameters don't propagate either
across the protected/unprotected boundary. If the user is viewing a form on
a protected page and submits with an action that subsequently does a forward
(via a forward mapping in a Struts action) to an unprotected page, the
parameters don't show up in the request object.

I'm thinking this could be a bug in the JBoss security implementation, a bug
in Struts, or maybe a bug in Tomcat. Either that, or it might be a design
decision -- I remember reading a few days ago that session data does not
remain valid when switching between HTTP and HTTPS. Is this the case with
protected/unprotected pages as well for both user credentials and
parameters?

-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, April 02, 2002 6:02 PM
To: Tomcat Users List
Subject: Re: Question about container-managed security


On Tue, 2 Apr 2002, Wellie W. Chao wrote:

 Date: Tue, 2 Apr 2002 16:59:38 -0500
 From: Wellie W. Chao [EMAIL PROTECTED]
 Reply-To: Tomcat Users List [EMAIL PROTECTED]
 To: Tomcat Users List [EMAIL PROTECTED]
 Subject: Question about container-managed security

 I'm using Tomcat 4.0.2 and noticed that the security attributes returned
by
 request.getRemoteUser(), request.isUserInRole(x), and
 request.getUserPrincipal() seem to only be present when the user is in a
 protected directory, even if he has already logged in. That is to say, the
 user can log in and go to a protected URL, and request.getRemoteUser()
works
 fine. If he then goes to a common area that is not protected by a
 security-constraint block in web.xml, request.getRemoteUser() returns
null.
 If he then goes back to a different protected page,
request.getRemoteUser()
 returns the username again, so clearly Tomcat is storing the information.

 Does anyone know how to get access to the authentication information on a
 non-protected page after the user has logged in? I could set a session
 attribute right after login, but I figured that Tomcat already has the
 information, so it would be nice to not have to resort to a hack.


As long as your common area is within the same web application, you
should continue to see the security attributes, even when accessing an
unprotected resource.  However, if your common area is in some other
webapp, then the attributes won't be set, because they are specific to a
particular webapp only.

Craig


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: TOMCAT STOPS!

2002-04-03 Thread Ricky Leung

which jdk are you using and how was the memory during that time?  It might
be a memory issue and the system is heavily swapping, causing the server to
almost halt?

Just throwing random ideas out.

-Original Message-
From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 5:12 PM
To: Tomcat Users List
Subject: Re: TOMCAT STOPS!


Hi, Eric -

That is what I thought, too (I was not the one to see lynx working, but I'll
try it myself the next time).  Unfortunately, I don't know whether it was to
localHost or www.emergentmusic.com (that's the URL we're having trouble
with).  I'll asked the engineer who did that testing, but he's out for a
while.

tracert showed a complete trace.

Did not try telnet.

What is interesting is that we have another server running another copy of
Tomcat for development.  The firewall is set up to forward port 8080 to that
server and port 80 to the main server (the one that failed).  Accessing the
other server works fine, so DNS does not seem to be the issue and the
firewall seems to be up.

Thanks for your help!
- Bob

- Original Message -
From: Dahnke, Eric [EMAIL PROTECTED]
To: 'Tomcat Users List' [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 4:53 PM
Subject: RE: TOMCAT STOPS!



 If this is true:

 If we use lynx on the server running Tomcat, we CAN access the
 pages.

 then Tomcat is not your problem, and it is more likely a networking /
 firewall issue. When it goes down what does telnetting to port 80 show
you?
 How about traceroute?

 could also be a hostname dns thing. when you run lynx do you use
localhost?
 What is the  exact URL you use in lynx?



 -Original Message-
 From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 4:58 PM
 To: Tomcat Users List
 Cc: [EMAIL PROTECTED]
 Subject: Re: TOMCAT STOPS!


 One more detail, which may be important:
 If we use lynx on the server running Tomcat, we CAN access the pages.  I
 can't figure that out at all.

 Please help if you can.

 - Original Message -
 From: Bob Swerdlow [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 4:51 PM
 Subject: TOMCAT STOPS!


  We're in trouble.
 
  We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it just
  stops servicing requests.
 
  We know it is Tomcat because we can still get to the machine on other
 ports.
  We can SSH to it and everything seems fine.
 
  We know it is not just one project since we cannot get to any projects
 that
  Tomcat should be running.  Not even /manager/list.
 
  If we are patient enough, it sometimes comes back after 4 or 5 minutes.
  Then everything seems normal again.  Usually we don't wait because our
 site
  is down, so we just stop and restart it.  However, it often takes
several
  restarts to get it going again.
 
  I'm not even sure where to start looking!  Any help would be greatly
  appreciated!
 
  Bob Swerdlow
  Chief Operating Officer
  Transpose, LLC
  [EMAIL PROTECTED]
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: Working Directory

2002-04-03 Thread Jacob Kjome

That might work in most cases, but it won't find the file in a container 
that doesn't expand the .war archive.  The following will read it whether 
in a directory structure or in a .war archive:

InputStream is = 
getServletContext().getResourceAsStream(/WEB-INF/myApp.properties);


If the file exists in the same package as the class, you can load it like this:

InputStream is = this.getClass().getResourceAsStream(myApp.properties);

I would think you could also do this to find it in the classes directory:

InputStream is = 
this.getClass().getClassLoader().getResourceAsStream(myApp.properties);


All those methods are independent of the filesystem.

Jake

At 11:38 AM 4/3/2002 -0500, you wrote:
I place my properties files in the WEB-INF directory and do the following to
find them -

String webInfFolder = getServletContext().getRealPath(/WEB-INF)

-Original Message-
From: Sanjay Bahal [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 11:34 AM
To: tomcat
Subject: Working Directory


I am trying to read a properties file from my servlet.
It always comes back saying file not found. I have
tried placing the file in
classes/web-inf/context-path. Ideally I would like to
lace it in my classes directory- How do I achieve it.
Thanks
Sanjay

__
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]



Debugging the servlet

2002-04-03 Thread Juliet


Hello everyone,

I'm new to developing a servlet and I wanted to debug it.

Is anyone has an idea on how to do it?

Thanks,
Juliet

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: TOMCAT STOPS!

2002-04-03 Thread Bob Swerdlow

Thanks, Ricky - We're throwing around some pretty crazy idea here, so thanks
for chiming in.

Memory (and disk space) seem fine during these episodes.  For the record we
have set
   export CATALINA_OPTS='-Xmx256m -Xms128m'

The JDK is 1.3.1

- Original Message -
From: Ricky Leung [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, April 03, 2002 6:17 PM
Subject: RE: TOMCAT STOPS!


 which jdk are you using and how was the memory during that time?  It might
 be a memory issue and the system is heavily swapping, causing the server
to
 almost halt?

 Just throwing random ideas out.

 -Original Message-
 From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 03, 2002 5:12 PM
 To: Tomcat Users List
 Subject: Re: TOMCAT STOPS!


 Hi, Eric -

 That is what I thought, too (I was not the one to see lynx working, but
I'll
 try it myself the next time).  Unfortunately, I don't know whether it was
to
 localHost or www.emergentmusic.com (that's the URL we're having trouble
 with).  I'll asked the engineer who did that testing, but he's out for a
 while.

 tracert showed a complete trace.

 Did not try telnet.

 What is interesting is that we have another server running another copy of
 Tomcat for development.  The firewall is set up to forward port 8080 to
that
 server and port 80 to the main server (the one that failed).  Accessing
the
 other server works fine, so DNS does not seem to be the issue and the
 firewall seems to be up.

 Thanks for your help!
 - Bob

 - Original Message -
 From: Dahnke, Eric [EMAIL PROTECTED]
 To: 'Tomcat Users List' [EMAIL PROTECTED]
 Sent: Wednesday, April 03, 2002 4:53 PM
 Subject: RE: TOMCAT STOPS!


 
  If this is true:
 
  If we use lynx on the server running Tomcat, we CAN access the
  pages.
 
  then Tomcat is not your problem, and it is more likely a networking /
  firewall issue. When it goes down what does telnetting to port 80 show
 you?
  How about traceroute?
 
  could also be a hostname dns thing. when you run lynx do you use
 localhost?
  What is the  exact URL you use in lynx?
 
 
 
  -Original Message-
  From: Bob Swerdlow [mailto:[EMAIL PROTECTED]]
  Sent: Wednesday, April 03, 2002 4:58 PM
  To: Tomcat Users List
  Cc: [EMAIL PROTECTED]
  Subject: Re: TOMCAT STOPS!
 
 
  One more detail, which may be important:
  If we use lynx on the server running Tomcat, we CAN access the pages.  I
  can't figure that out at all.
 
  Please help if you can.
 
  - Original Message -
  From: Bob Swerdlow [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Cc: [EMAIL PROTECTED]
  Sent: Wednesday, April 03, 2002 4:51 PM
  Subject: TOMCAT STOPS!
 
 
   We're in trouble.
  
   We're using Tomcat 4.0.2 Stand-alone on Solaris 8.  Periodically it
just
   stops servicing requests.
  
   We know it is Tomcat because we can still get to the machine on other
  ports.
   We can SSH to it and everything seems fine.
  
   We know it is not just one project since we cannot get to any projects
  that
   Tomcat should be running.  Not even /manager/list.
  
   If we are patient enough, it sometimes comes back after 4 or 5
minutes.
   Then everything seems normal again.  Usually we don't wait because our
  site
   is down, so we just stop and restart it.  However, it often takes
 several
   restarts to get it going again.
  
   I'm not even sure where to start looking!  Any help would be greatly
   appreciated!
  
   Bob Swerdlow
   Chief Operating Officer
   Transpose, LLC
   [EMAIL PROTECTED]
  
  
   --
   To unsubscribe:   mailto:[EMAIL PROTECTED]
   For additional commands: mailto:[EMAIL PROTECTED]
   Troubles with the list: mailto:[EMAIL PROTECTED]
  
 
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 
  --
  To unsubscribe:   mailto:[EMAIL PROTECTED]
  For additional commands: mailto:[EMAIL PROTECTED]
  Troubles with the list: mailto:[EMAIL PROTECTED]
 


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




RE: how to store a document file?

2002-04-03 Thread kalbee

I would store it as HTML in a text field -- that works great, and you don't
have to deal with blobs -- I'm not sure what I'd do with rich text format,
but HTML works great.

Kim 




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




status mod_webapp.so?

2002-04-03 Thread Bernd Prager

Hi everybody,
I just installed Tomcat 4.0.3 and everything seems to work fine.

Next step was the Apache HTTP server integration.
First I had a hard time to find the mod_webapp.so module,
before I realised it exists only in /release/v4.0.3/bin/linux/
on the build site. I can't find any sources.
When I configure and restart the Apache httpd it complains
[warn] Loaded DSO libexec/mod_webapp.so uses plain Apache 1.3 API, this
module might crash under EAPI! (please recompile it with -DEAPI)

The server works for a moment and eventually stops working.
The restart fails with:
(98)Address already in use: make_sock: could not bind to port 80
First question: Where do I find the sources in order to recompile them?
Second question (probably a stupid one): How do I free port 80?
Third question: Is the way I'm doing this the recommended way to
integrate Tomcat with the Apache web server?

Thanks for any help?
-- Bernd


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Debugging the servlet

2002-04-03 Thread Valera Molyakov

Hi!

You can use IDE that allow local and remote debug( for example Intel JIDEA
or JBuilder).

- Original Message -
From: Juliet [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Thursday, April 04, 2002 3:39 AM
Subject: Debugging the servlet



 Hello everyone,

 I'm new to developing a servlet and I wanted to debug it.

 Is anyone has an idea on how to do it?

 Thanks,
 Juliet

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]