Detecting terminal HTTP chunk

2007-03-04 Thread Peter Kennard


Hmm - when reading HTTP1.1 chunked data, is there a way of detecting 
reciept of the terminal 0 chunk in a servlet ?


Googling about, Apparently this does not report an EOD exception 
(as I would expect) because some people have been using post last 
chunk data for server internal out-of band information. (?)


Questions:

1 - Is there a way I can detect receipt of the terminal HTTP chunk before
the final read() which would hang and timeout otherwise (Yes I 
could detect an end tag or whatever and push the problem upstairs, 
but that's not the point).


2 - Is there a way (short of writing a protocol handler) to disable
chunk parsing in the ServletInputStream and be responsible for 
my own chunk parsing ? (Ideally for me, I could access an almost raw 
socket read, but, I think access to that has been abstracted away)


Thanks!
PK



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat 6 - includes broken

2007-03-04 Thread Patrick Lee

Hi,

I'm trying to upgrade from Tomcat 5.5.15 to 6.0.10. Everything seems
to have gone fine except that most of my includes are broken.

I can do this:

[EMAIL PROTECTED] file = something.jsp %

But I can't do this:

[EMAIL PROTECTED] file = /path/to/something.jsp %

The latter gives me a status 500 and File not found on the include.

This is independent of the content of the file I'm trying to include.

Does anyone know what might have changed from 5.5.15 to 6.0.10 for
htins to happen? Do I need to change some configurations?

Thanks

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 - includes broken

2007-03-04 Thread Rémy Maucherat

On 3/4/07, Patrick Lee [EMAIL PROTECTED] wrote:

But I can't do this:
[EMAIL PROTECTED] file = /path/to/something.jsp %


It works for me (this will be tested in the TCK, so there can't be any
regressions on this sort of feature). The path is still relative to
the webapp root, of course.

Rémy

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Migration from 5.5.20 to 6.0.10: parser issue on application deployment

2007-03-04 Thread Rémy Maucherat

On 3/3/07, Etienne Giraudy [EMAIL PROTECTED] wrote:

Shall this be considered as a regression as in that case tomcat
configuration is somehow altered by a web app?
(in that case I'll fill a bug in bugzilla))


I don't think there can be a change of behavior in this sort of thing
between TC 5.5 and 6.0.

Rémy

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 - includes broken

2007-03-04 Thread Patrick Lee

I would assume it works in general and is specific to my instance here.

Note that

[EMAIL PROTECTED] file = /path/to/something.jsp %

works fine if I am inside the root directory of the webapp, If however
I have that include inside /somewhere/file.jsp then it always gives me
a File not found.

If I put /path/to/something.jsp inside the directory /somewhere/ it is
then able to find the include - which looks to me like the leading
slash in the include is having no effect and the path is relative to
the current path and not the webapp root?

On 3/4/07, Rémy Maucherat [EMAIL PROTECTED] wrote:

On 3/4/07, Patrick Lee [EMAIL PROTECTED] wrote:
 But I can't do this:
 [EMAIL PROTECTED] file = /path/to/something.jsp %

It works for me (this will be tested in the TCK, so there can't be any
regressions on this sort of feature). The path is still relative to
the webapp root, of course.

Rémy

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat 6 - includes broken

2007-03-04 Thread Rémy Maucherat

On 3/4/07, Patrick Lee [EMAIL PROTECTED] wrote:

I would assume it works in general and is specific to my instance here.

Note that

[EMAIL PROTECTED] file = /path/to/something.jsp %

works fine if I am inside the root directory of the webapp, If however
I have that include inside /somewhere/file.jsp then it always gives me
a File not found.


No, that works fine (I did spend the time to test it, and as I said,
the test suite will test this feature). This is the same mechnism for
request dispatching, so I assume we would know it if it was not
working.


If I put /path/to/something.jsp inside the directory /somewhere/ it is
then able to find the include - which looks to me like the leading
slash in the include is having no effect and the path is relative to
the current path and not the webapp root?


No.

Rémy

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Marking servlet ... as unavailable

2007-03-04 Thread Joe Siebenmann

Hi All,

I've hit this problem and my development has come to a
screeching halt. :-\

I'm using Tomcat 5.5.17 with a JDK/JRE of 1.5.0_11
on a Windows XP Pro SP2 system.

In my Servlets I use:

RequestDispatcher dispatcher =
getServletContext().getRequestDispatcher(/servlet/BlahServlet);
if ( dispatcher != null )
dispatcher.forward(req, res);

to transfer control from one Servlet to the next, and after
several of these it finally gets this Exception when it gets
to the doGet() of the next Servlet:


Mar 4, 2007 9:19:04 AM org.apache.catalina.core.ApplicationContext log
INFO: Marking servlet ClientWMIClassesServlet as unavailable
Mar 4, 2007 9:19:04 AM org.apache.catalina.core.ApplicationDispatcher invoke
SEVERE: Allocate exception for servlet ClientWMIClassesServlet
java.lang.VerifyError: (class: com/jps/NetMgt/ClientWMIClassesServlet, method: 
doGet signature: 
(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V)
 Incompatible argument to function
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2357)
at java.lang.Class.getConstructor0(Class.java:2671)
at java.lang.Class.newInstance0(Class.java:321)
at java.lang.Class.newInstance(Class.java:303)
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1055)
at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:757)
at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:641)
at 
org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
at 
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
at 
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
at com.jps.NetMgt.ClientWMIServlet.doGet(Unknown Source)
at com.jps.NetMgt.ClientWMIServlet.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)


There aren't any typos, and I've already deleted every JDK and JRE
on my system and only reinstalled JDK 1.5.0_11, so that there
would be no possible problems of the compile JVM being different
than the JVM Tomcat was running, or any CLASSPATH issues, but
I keep getting the Exception.  I've also carefully gone over
setclasspath.bat, catalina.bat and service.bat files making sure
the paths to Java and JRE, and the CLASSPATHs are correct.

I also made sure that the final RequestDispatcher dispatcher
Object, was valid before I did the forward(). 

Why is the Servlet being Marked as unavailable???

If anyone has ideas on what I can try to fix this
I'd really appreciate hearing it.


Thanks,

Joe Siebenmann
  




___
Join Excite! - http://www.excite.com
The most personalized portal on the Web!



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Migration from 5.5.20 to 6.0.10: parser issue on application deployment

2007-03-04 Thread Rémy Maucherat

On 3/4/07, Etienne Giraudy [EMAIL PROTECTED] wrote:

I guess that the point that is questionnable here is the way the API
is designed: modifying the system property 'legal' and, AFAIK, it is
the only way to choose the parser implementation we want to use
(http://java.sun.com/j2se/1.5.0/docs/api/javax/xml/parsers/SAXParser.html).

From that point of view, shouldn't Tomcat protect itself against
bad-designed standard APIs usage?


To see how standard and legal this usage is, you can try enabling
the security manager (the only way to control writing to system
properties - which are always JVM wide, so since Tomcat uses JAXP,
Tomcat cannot avoid being affected to some extent when a webapp
changes the parser factory - is to use the security manager) :) The
other problem is that this by defeinition won't behave the same in
different VMs (1.4, and same if you have a 5.0 VM with the
compatibility pack for TC 5.5).

You can send me a WAR to test however, I would be interested to look
at this alleged difference in behavior.

Rémy

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Migration from 5.5.20 to 6.0.10: parser issue on application deployment

2007-03-04 Thread Etienne Giraudy

To see how standard and legal this usage is, you can try enabling
the security manager (the only way to control writing to system
properties - which are always JVM wide, so since Tomcat uses JAXP,
Tomcat cannot avoid being affected to some extent when a webapp
changes the parser factory - is to use the security manager) :) The
other problem is that this by defeinition won't behave the same in
different VMs (1.4, and same if you have a 5.0 VM with the
compatibility pack for TC 5.5).


Not allowing the application to modify this system property is not an
option for me.



You can send me a WAR to test however, I would be interested to look
at this alleged difference in behavior.



I've filled a bug report to which I attached a simple web app for
reproducing the issue:
http://issues.apache.org/bugzilla/show_bug.cgi?id=41759


Etienne

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Detecting terminal HTTP chunk

2007-03-04 Thread Peter Kennard


I guess the general form of this question is, with HTTP1.1 chunked 
input, how do I read a chunk at a time, which requires I know the 
length of the chunk before calling read()  so if I attempt to read 
more than the length of the chunk so I can process it immediately 
instead of waiting for subsequent input ???  (in the final chunk case 
there is no subsequent input.)


That is without having to put in a second form of chunking inside the 
HTTP chunking ??


PK



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Detecting terminal HTTP chunk

2007-03-04 Thread Tim Funk
The servlet API does not expose these details. At best you have the 
InputStream to read from. (And use available() if you want to try to 
read without blocking (but due to buffering probably won't work anyways))


But since you can't send the response without finishing the reading of 
the input stream - the entire question doesn't seem to make sense.


-Tim

Peter Kennard wrote:


I guess the general form of this question is, with HTTP1.1 chunked 
input, how do I read a chunk at a time, which requires I know the 
length of the chunk before calling read()  so if I attempt to read 
more than the length of the chunk so I can process it immediately 
instead of waiting for subsequent input ???  (in the final chunk case 
there is no subsequent input.)


That is without having to put in a second form of chunking inside the 
HTTP chunking ??


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Marking servlet ... as unavailable

2007-03-04 Thread Joe Siebenmann

Hi All,

I was at least able to get the Servlet that was unavailable
to finally show up.  This has been one of the most frustrating
things I've come across.. :-\

I figured that something was happening in the Servlet before
the Servlet that was being flagged as unavailable, so I
commented out most of the code in that Servlet, and stripped
it down to a bare minimum.  The Servlet that was formally
unavailable finally showed up. :-)

So at least I can keep on developing, and later I'll
have to go back and slowly add back piece by piece until it
hits whatever it didn't like to flag it as unavailable.

It would be nice if there was some better information available
as to what it didn't like for it to flag it as unavailable.
Nothing of any value was in any of the log files.


Thanks,

Joe Siebenmann




 --- On Sun 03/04, Joe Siebenmann  [EMAIL PROTECTED]  wrote:
From: Joe Siebenmann [mailto: [EMAIL PROTECTED]
To: users@tomcat.apache.org
Date: Sun,  4 Mar 2007 09:58:49 -0500 (EST)
Subject: Marking servlet ... as unavailable

Hi All,I've hit this problem and my development has come to ascreeching halt. 
:-\I'm using Tomcat 5.5.17 with a JDK/JRE of 1.5.0_11on a Windows XP Pro SP2 
system.In my Servlets I use:RequestDispatcher dispatcher =
getServletContext().getRequestDispatcher(/servlet/BlahServlet);if ( 
dispatcher != null )dispatcher.forward(req, res);to transfer control from 
one Servlet to the next, and afterseveral of these it finally gets this 
Exception when it getsto the doGet() of the next Servlet:Mar 4, 2007 9:19:04 AM 
org.apache.catalina.core.ApplicationContext logINFO: Marking servlet 
ClientWMIClassesServlet as unavailableMar 4, 2007 9:19:04 AM 
org.apache.catalina.core.ApplicationDispatcher invokeSEVERE: Allocate exception 
for servlet ClientWMIClassesServletjava.lang.VerifyError: (class: 
com/jps/NetMgt/ClientWMIClassesServlet, method: doGet signature: 
(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;)V)
 Incompatible argument to function   at 
java.lang.Class.getDeclaredConstructors0(Native Method) at 
java.lang.Class.privateGetDeclaredConstructors(Class.java:2357)  at 
java.lang.Class.getConstructor0(Class.java:2671) at 
java.lang.Class.newInstance0(Class.java:321) at 
java.lang.Class.newInstance(Class.java:303)  at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1055) 
 at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:757)  at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:641)
at 
org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
at 
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
 at 
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
   at com.jps.NetMgt.ClientWMIServlet.doGet(Unknown Source)at 
com.jps.NetMgt.ClientWMIServlet.doPost(Unknown Source)   at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:709) at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
  at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
  at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)   
 at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)   
 at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)  at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)   at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
   at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
  at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
  at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
   at java.lang.Thread.run(Thread.java:595)There aren't any typos, and I've 
already deleted every JDK and JREon my system and only reinstalled JDK 
1.5.0_11, so that therewould be no possible problems of the compile JVM being 
differentthan the JVM Tomcat was running, or any CLASSPATH issues, butI keep 
getting the Exception.  I've also carefully gone oversetclasspath.bat, 
catalina.bat and service.bat files making surethe paths to Java and JRE, and 
the CLASSPATHs are correct.I also made sure that the final RequestDispatcher 
dispatcherObject, was valid before I did the forward(). Why is the Servlet 
being 

valid keystore formats?

2007-03-04 Thread Martin Gainty
Hello All-

Attempting to get a self-signed certificate CACERT operational and cannot 
determine which valid storetype format using the keytool command
I have tried storetype=JCEKS but this always displays 
invalid keysotre format

Thanks!
Martin--
--- 
This e-mail message (including attachments, if any) is intended for the use of 
the individual or entity to which it is addressed and may contain information 
that is privileged, proprietary , confidential and exempt from disclosure. If 
you are not the intended recipient, you are notified that any dissemination, 
distribution or copying of this communication is strictly prohibited.
--- 
Le présent message électronique (y compris les pièces qui y sont annexées, le 
cas échéant) s'adresse au destinataire indiqué et peut contenir des 
renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le 
destinataire de ce document, nous vous signalons qu'il est strictement interdit 
de le diffuser, de le distribuer ou de le reproduire.

WEB-INF/lib ignored in Tomcat 6

2007-03-04 Thread Ron Wheeler
It seems that Tomcat 6 is not finding the jars in the application 
library WEB-INF/lib.


If I put the spring.jar in the tomcat lib directory it is found.
If I put it in the application lib directory it is not found.

If I fix the spring.jar issue, I just get an Class not found error on 
the next library.


Mar 4, 2007 4:35:13 PM org.apache.catalina.loader.WebappLoader start
SEVERE: LifecycleException
java.lang.ClassNotFoundException: 
org.springframework.instrument.classloading.tomcat.TomcatInstrumentableClassLoader

   at java.net.URLClassLoader$1.run(Unknown Source)
   at java.security.AccessController.doPrivileged(Native Method)
   at java.net.URLClassLoader.findClass(Unknown Source)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   at java.lang.ClassLoader.loadClassInternal(Unknown Source)
   at java.lang.Class.forName0(Native Method)
   at java.lang.Class.forName(Unknown Source)
   at 
org.apache.catalina.loader.WebappLoader.createClassLoader(WebappLoader.java:770)



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: WEB-INF/lib ignored in Tomcat 6

2007-03-04 Thread Rashmi Rubdi
Did you set the environment variables correctly?

CATALINA_HOME , should point to the root folder of Tomcat's installation, and 
JAVA_HOME to JDK's root folder. 

Also specify the directory of your project in the docBase attribute of Context 
definition.

Tomcat auto detects the libs under WEB-INF/lib of a project.

Also check if your environment variables are still pointing to the old version?

-Rashmi

- Original Message 
From: Ron Wheeler [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Sunday, March 4, 2007 4:54:30 PM
Subject: WEB-INF/lib ignored in Tomcat 6


It seems that Tomcat 6 is not finding the jars in the application 
library WEB-INF/lib.

If I put the spring.jar in the tomcat lib directory it is found.
If I put it in the application lib directory it is not found.

If I fix the spring.jar issue, I just get an Class not found error on 
the next library.

Mar 4, 2007 4:35:13 PM org.apache.catalina.loader.WebappLoader start
SEVERE: LifecycleException
java.lang.ClassNotFoundException: 
org.springframework.instrument.classloading.tomcat.TomcatInstrumentableClassLoader
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at 
org.apache.catalina.loader.WebappLoader.createClassLoader(WebappLoader.java:770)


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


 

We won't tell. Get more on shows you hate to love 
(and love to hate): Yahoo! TV's Guilty Pleasures list.
http://tv.yahoo.com/collections/265

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: valid keystore formats?

2007-03-04 Thread Caldarale, Charles R
 From: Martin Gainty [mailto:[EMAIL PROTECTED] 
 Subject: valid keystore formats?
 
 I have tried storetype=JCEKS but this always displays 
 invalid keysotre format

The default keystore format is jks (not case sensitive); support for
other formats is provided by additional JCE providers that could be
installed (but I don't know of any free ones).

From the keytool doc:
http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/keytool.html

'There is a built-in default implementation, provided by Sun
Microsystems. It implements the keystore as a file, utilizing a
proprietary keystore type (format) named JKS. It protects each private
key with its individual password, and also protects the integrity of the
entire keystore with a (possibly different) password.

'Keystore implementations are provider-based. More specifically, the
application interfaces supplied by KeyStore are implemented in terms of
a Service Provider Interface (SPI). That is, there is a corresponding
abstract KeystoreSpi class, also in the java.security package, which
defines the Service Provider Interface methods that providers must
implement. (The term provider refers to a package or a set of packages
that supply a concrete implementation of a subset of services that can
be accessed by the Java Security API.) Thus, to provide a keystore
implementation, clients must implement a provider and supply a
KeystoreSpi subclass implementation, as described in How to Implement a
Provider for the Java Cryptography Architecture.'

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



SQLNestedException

2007-03-04 Thread Wojtek Kusch

Hi!
I have a JSP-App and need a database connection (to the MS Access 
database unleashed).

But, I get following exception:

org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC 
driver of class '' for connect URL 'null'



This is the context in conf\Catalina\localhost
---
Context debug=1 reloadable=true

 Logger className=org.apache.catalina.logger.FileLogger
  prefix=localhost_unleashed_ suffix=.log
  timestamp=false/

 Resource name=jdbc/unleashed auth=Container 
type=javax.sql.DataSource/

 ResourceParams name=jdbc/unleashed
   parameter
   namedriverClassName/name
valuesun.jdbc.odbc.JdbcOdbcDriver/value
   /parameter
   parameter
   nameurl/name
valuejdbc:odbc:unleashed/value
   /parameter
 /ResourceParams

/Context
---

What's wrong? Thanks for help!
Wojtek Kusch

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: DWR using WAN vs LAN

2007-03-04 Thread Wayne Bragg

FYI problem solved,

In case some other newbie has the same problem, I've decided to add this 
message to the list.
I solved my problem of not being able to access the tomcat server functions 
through anything other than localhost:8080.
The problem was a misunderstanding of how the httpd server and tomcat, both 
native server and jk connector, were configured and accessed.
In the default setup of devside.net Web[Developer] Server Suite 1.94, it 
install tomcat native server and  a jk connector through httpd (commonly 
referred to as Apache Server). To connect to tomcat native server you use 
localhost:8080. It appears nothing else will connect to the native server 
the way it is configured. If you want to connect to tomcat from outside 
localhost, even with computer-name you have to go through the jk connector. 
Which means using ip-or-computer-name:80.
The confusion came when doing this gave me a $variable not defined error 
upon the served starting. This was caused by the served and 
served-mapping being in the wrong file or not there at all. I don't know 
where it was I just know when I discoverd it and put it in /conf/web.xml or 
/app-program/WEB-INF/web.xml it all came together. Thanks for all the help 
and suggestions. It contributed to me being able to figure this problem out.


This left me with a question -

Is there any reason other than convenience and amount of apps using it that 
you would want to put a related  jar,  servlet and servlet mapping in 
the local  application  folders over the higher level config and common 
folders?


As far as the

- Original Message - 
From: Wayne Bragg [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Saturday, March 03, 2007 10:00 PM
Subject: Re: DWR using WAN vs LAN


After all this, and with a new understanding of how httpd and tomcat work 
together, I was reading the documentation I have on my installation of 
Tomcat, again. It is setup so the native server is on port 8080 and the 
jk connector is through httpd 80 or however you'd say that. All the 
example apps that came with the Tomcat installation work through both the 
native server (8080) and the jk connector (80).


So I installed DWR, using it's defaults, to be able to use the AJAX calls. 
All of DWR's examples only work through the native server 
localhost:8080/dwr/.  If I try to run them using the tk connector 
localhost:80/dwr/ anytime they need to call the supporting jar and class 
files they get the [$variable] is not defined error. Any idea what is 
causing this? Is it something to do with the paths to these supporting 
files?


Also I still can't connect, at all, to the native server through anything 
other than localhost:8080. It's not a network or router issue, they are 
configured correctly. Even my-computer-name:8080 won't connect to the 
native server. Any ideas what's up with that?


I apologize for not asking these questions this way from the start.


- Original Message - 
From: Wayne Bragg [EMAIL PROTECTED]

To: Tomcat Users List users@tomcat.apache.org
Sent: Saturday, March 03, 2007 6:13 PM
Subject: Re: DWR using WAN vs LAN



You may want to limit your question to one topic at a time.


Sorry for any confusion.


Tomcat/Apache/PHP can all work together depending on how
you send up your application. Apache's mod_jk is how you make Apache and
tomcat work together.


 Tomcat is configured to run on 8080 by default
you can change that to 80 by editing the server.xml file. All http 
traffic
that doesn't specify a port automatically go to 80. To access your 
computer

from the Internet you'll need to first open the port on your router or
remove the computer you want to access from the router's DMZ (not
recommended). Make sure you use your actual IP which you can determine 
by

typing what's my IP   on google and following the first link.


I am aware of all this! Thanks for the reply.

All the explanation I have given was to help avoid these unnecessary 
emails, but I guess that didn't work.


I have two topics and I need answers to both. I thought they were related 
but I can now see they are independent from one another. One topic led me 
to the second one or vice versa.


Topic or question 1 -

This is not a router or network question. I know how to configure the 
router and network.
My Tomcat server doesn't recognize any requests that are not coming 
specifically from localhost:8080. Not even from my-computer-name:8080 
which I thought was the same thing.  Is it suppose to do that? If not 
does anyone have a clue as to why it isn't or how to fix it?
If this is not an appropriate question for this list then I guess I need 
the admin to let me know that. I don't see how it's not. But apologies if 
it is.


Topic or question 2 -

Starting with the Devside.net Web[Developer] Server Suite 1.94
standard default installation, does anyone know the steps needed to 
configure HTTPD to handle the PHP and TOMCAT to handle the Java all 
at the same time, from 

Re: Tomcat 6 - includes broken

2007-03-04 Thread Patrick Lee

Do you have your host appBase set to be the same as your webapp
docBase?


Yes, the context docBase is set at .

Easy enough for me to change that and I'm guessing there are good
reasons not to have a setup like that.

Thanks.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: valid keystore formats?

2007-03-04 Thread John McPeek

Hi Martin,
Isn't it supposed to be JKS.
John


Hello All-

Attempting to get a self-signed certificate CACERT operational and cannot 
determine which valid storetype format using the keytool command
I have tried storetype=JCEKS but this always displays 
invalid keysotre format


Thanks!
Martin--
--- 
This e-mail message (including attachments, if any) is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, proprietary , confidential and exempt from disclosure. If you are not the intended recipient, you are notified that any dissemination, distribution or copying of this communication is strictly prohibited.
--- 
Le présent message électronique (y compris les pièces qui y sont annexées, le cas échéant) s'adresse au destinataire indiqué et peut contenir des renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le destinataire de ce document, nous vous signalons qu'il est strictement interdit de le diffuser, de le distribuer ou de le reproduire.
 





Re: WEB-INF/lib ignored in Tomcat 6

2007-03-04 Thread Ron Wheeler



Rashmi Rubdi wrote:

Did you set the environment variables correctly?

CATALINA_HOME , should point to the root folder of Tomcat's installation, and 
JAVA_HOME to JDK's root folder. 

  
I screwed up CATALINA_HOME but after correcting it and rebooting the 
problem remains.

Also specify the directory of your project in the docBase attribute of Context 
definition.

  
The server.xml that ships with tomcat 6 does not have a docBase 
specified. I am using the standard directory structure.
Should I add a doc base to the application context? I would assume that 
Tomcat would default to


CATALINA_HOME/webapps/petclinic/WEB-INF/lib to find the petclinic libraries.



Tomcat auto detects the libs under WEB-INF/lib of a project.

  
That is what the docs say but it is not able to find spring.jar unless I 
put it in the main tomcat lib directory.

Also check if your environment variables are still pointing to the old version?

  

No such luck.
Still have the same problem.
I moved the spring.jar to the tomcat/lib  and now the problem is on the 
hibernate3.jar



-Rashmi

- Original Message 
From: Ron Wheeler [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Sunday, March 4, 2007 4:54:30 PM
Subject: WEB-INF/lib ignored in Tomcat 6


It seems that Tomcat 6 is not finding the jars in the application 
library WEB-INF/lib.


If I put the spring.jar in the tomcat lib directory it is found.
If I put it in the application lib directory it is not found.

If I fix the spring.jar issue, I just get an Class not found error on 
the next library.


Mar 4, 2007 4:35:13 PM org.apache.catalina.loader.WebappLoader start
SEVERE: LifecycleException
java.lang.ClassNotFoundException: 
org.springframework.instrument.classloading.tomcat.TomcatInstrumentableClassLoader

at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at 
org.apache.catalina.loader.WebappLoader.createClassLoader(WebappLoader.java:770)



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


 

We won't tell. Get more on shows you hate to love 
(and love to hate): Yahoo! TV's Guilty Pleasures list.
http://tv.yahoo.com/collections/265 


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




  


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: WEB-INF/lib ignored in Tomcat 6

2007-03-04 Thread Caldarale, Charles R
 From: Ron Wheeler [mailto:[EMAIL PROTECTED] 
 Subject: Re: WEB-INF/lib ignored in Tomcat 6
 
 Should I add a doc base to the application context?

No; docBase should only be used when the app is stored outside of the
Host appBase directory.

  Tomcat auto detects the libs under WEB-INF/lib of a project.

 That is what the docs say but it is not able to find 
 spring.jar unless I put it in the main tomcat lib 
 directory.

Do you have a permissions problem on the subdirectories of the app, such
that Tomcat can't access the jars?

Tomcat certainly can find jars under WEB-INF/lib, otherwise none of the
apps included in the Tomcat download would work.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: WEB-INF/lib ignored in Tomcat 6

2007-03-04 Thread Martin Gainty
Hi Ron--

.\META-INF\context.xml has a reloadable attribute which must be set to true to 
tell tomcat to monitor jars in .\WEB-INF\lib
http://tomcat.apache.org/tomcat-5.5-doc/config/loader.html

also take a look at the delegate attribute to specifically load classes via 
parent class loader before looking in WEB-INF

HTH,
M--
--- 
This e-mail message (including attachments, if any) is intended for the use of 
the individual or entity to which it is addressed and may contain information 
that is privileged, proprietary , confidential and exempt from disclosure. If 
you are not the intended recipient, you are notified that any dissemination, 
distribution or copying of this communication is strictly prohibited.
--- 
Le présent message électronique (y compris les pièces qui y sont annexées, le 
cas échéant) s'adresse au destinataire indiqué et peut contenir des 
renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le 
destinataire de ce document, nous vous signalons qu'il est strictement interdit 
de le diffuser, de le distribuer ou de le reproduire.
- Original Message - 
From: Ron Wheeler [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Sunday, March 04, 2007 4:54 PM
Subject: WEB-INF/lib ignored in Tomcat 6


 It seems that Tomcat 6 is not finding the jars in the application 
 library WEB-INF/lib.
 
 If I put the spring.jar in the tomcat lib directory it is found.
 If I put it in the application lib directory it is not found.
 
 If I fix the spring.jar issue, I just get an Class not found error on 
 the next library.
 
 Mar 4, 2007 4:35:13 PM org.apache.catalina.loader.WebappLoader start
 SEVERE: LifecycleException
 java.lang.ClassNotFoundException: 
 org.springframework.instrument.classloading.tomcat.TomcatInstrumentableClassLoader
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at 
 org.apache.catalina.loader.WebappLoader.createClassLoader(WebappLoader.java:770)
 
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


Re: Using getImplementationVersion() to read MANIFEST.MF

2007-03-04 Thread Paul A . Hoadley

On 03/03/2007, at 5:42 PM, Paul A. Hoadley wrote:

Ultimately what I want to do is quite simple: display a build  
number in the footer of some JSP pages.  I'm using Ant's  
'buildnumber' task to increment the build number at each compile,  
and I am adding a global 'Implementation-Version' property to the  
manifest file when constructing the WAR.  The web application then  
uses getImplementationVersion() on some member package in an  
attempt to retrieve the build number---it shouldn't even matter  
which package, since the property in the manifest file is not in  
any named section, and thus constitutes the default.   
getImplementationVersion() consistently returns null, however---I  
assume it just can't seem to find the manifest file within the WAR  
structure.


Let me ask the question differently.  I use Ant to create /META-INF/ 
MANIFEST.MF as described above (using a 'manifest' element as a child  
of the 'war' element).  It contains the property Implementation- 
Version.


1.  How can I read the value of the property from some arbitrary  
class, say /WEB-INF/classes/some/package/Version.class?


2.  Is there a more appropriate place to store application-wide  
properties like this, and if so, where is it?



--
Paul.

w  http://logicsquad.net/
h  http://paul.hoadley.name/



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: AJP flush packets (tomcat 6.0.10 and mod_jk 1.2.21)

2007-03-04 Thread Sven Köhler
 Any ideas?

Any ideas why tomcat 6.0.10 doesn't send flush packets? I should see
them in mod_jk's log, right? (JkLogLevel is debug)



signature.asc
Description: OpenPGP digital signature


Re: valid keystore formats?

2007-03-04 Thread Martin Gainty
yes I surmised there was a dependency on the provider (in my case I was using 
BC as some of my Axis Projects were using BC)
In the case of the default Sun provider I'll use the default keystore of JKS

Thanks Chuck,
Martin--
--- 
This e-mail message (including attachments, if any) is intended for the use of 
the individual or entity to which it is addressed and may contain information 
that is privileged, proprietary , confidential and exempt from disclosure. If 
you are not the intended recipient, you are notified that any dissemination, 
distribution or copying of this communication is strictly prohibited.
--- 
Le présent message électronique (y compris les pièces qui y sont annexées, le 
cas échéant) s'adresse au destinataire indiqué et peut contenir des 
renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le 
destinataire de ce document, nous vous signalons qu'il est strictement interdit 
de le diffuser, de le distribuer ou de le reproduire.
- Original Message - 
From: Caldarale, Charles R [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Sunday, March 04, 2007 5:13 PM
Subject: RE: valid keystore formats?


 From: Martin Gainty [mailto:[EMAIL PROTECTED] 
 Subject: valid keystore formats?
 
 I have tried storetype=JCEKS but this always displays 
 invalid keysotre format

The default keystore format is jks (not case sensitive); support for
other formats is provided by additional JCE providers that could be
installed (but I don't know of any free ones).

From the keytool doc:
http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/keytool.html

'There is a built-in default implementation, provided by Sun
Microsystems. It implements the keystore as a file, utilizing a
proprietary keystore type (format) named JKS. It protects each private
key with its individual password, and also protects the integrity of the
entire keystore with a (possibly different) password.

'Keystore implementations are provider-based. More specifically, the
application interfaces supplied by KeyStore are implemented in terms of
a Service Provider Interface (SPI). That is, there is a corresponding
abstract KeystoreSpi class, also in the java.security package, which
defines the Service Provider Interface methods that providers must
implement. (The term provider refers to a package or a set of packages
that supply a concrete implementation of a subset of services that can
be accessed by the Java Security API.) Thus, to provide a keystore
implementation, clients must implement a provider and supply a
KeystoreSpi subclass implementation, as described in How to Implement a
Provider for the Java Cryptography Architecture.'

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Detecting terminal HTTP chunk

2007-03-04 Thread Peter Kennard
if available() is accurately suported I guess that does part of the 
job, but it still doesn't let you know the last chunk you read was 
the last one.  It is wholly dependent on the higher levels reading an 
end tag, which seems like a design mistake instead of getting and 
end of file or end of data exception.


At 14:21 3/4/2007, you wrote:
The servlet API does not expose these details. At best you have the 
InputStream to read from. (And use available() if you want to try to 
read without blocking (but due to buffering probably won't work anyways))


But since you can't send the response without finishing the reading 
of the input stream - the entire question doesn't seem to make sense.


-Tim

Peter Kennard wrote:
I guess the general form of this question is, with HTTP1.1 chunked 
input, how do I read a chunk at a time, which requires I know the 
length of the chunk before calling read()  so if I attempt to 
read more than the length of the chunk so I can process it 
immediately instead of waiting for subsequent input ???  (in the 
final chunk case there is no subsequent input.)
That is without having to put in a second form of chunking inside 
the HTTP chunking ??


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Detecting terminal HTTP chunk

2007-03-04 Thread Peter Kennard

At 23:07 3/4/2007, you wrote:
But since you can't send the response without finishing the reading 
of the input stream - the entire question doesn't seem to make sense.


If the input pipe is slow (ie: cellphone with slow pipe) and you are 
sending a transaction where the first part of it initiates a big 
operation (like a database lookup) the lookup can be happening while 
the rest of the data is still being read in.  ie: it is useful to be 
able to read input in small chunks as it comes in. And the client can 
be tuned to chunk appropriately for the transaction(s).


available() may work for this depending on buffering scheme of 
tomcat's protocol handler.


On writing the reply if you call flushBuffer() it will dispatch 
whatever is in the buffer (HTTP chunks as ip packets) to the client 
even if input reading is incomplete.  Doing so if you can, will 
reduce round trip latency and the time your socket is consumed.  A 
gross example would be a transaction to process a large file and 
return it to the client.  If the processing was serial then the 
client could be receiving the return file even before it had finished 
sending the source file.


It seems the servelet API was not upgraded to handle incremental 
chunks in a flexible general manner when it was added in 
HTTP1.1.  This is irrespective of how chunks may be juggled by any 
proxy or other front end. I am simply dealing with how you *can* 
handle them on the receiving end.


PK




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Newbie help...Mac OS/X+Tomcat+Apache

2007-03-04 Thread Jeff Weinberger

Hi:

I am hoping someone can help me identify what I'm sure is a very  
simple oversight on my part...but I cannot get Apache+Tomcat working...


Configuration: Mac OS/X 10.4.8 (PPC client), Apache 1.3.33, mod_jk  
1.2.21, Tomcat 6.0.10


I can run Tomcat standalone, (i.e. start and browse to localhost:8080  
with no modifications...), but when I try to access via a browser  
through apache it fails (503 -service unavailable).


I see lots of these in my jk logs:


[Sun Mar 04 20:42:58 2007] [5950:] [debug]  
jk_open_socket::jk_connect.c (433): trying to connect socket 10 to  
10.0.1.202:8009
[Sun Mar 04 20:42:58 2007] [5950:] [info]   
jk_open_socket::jk_connect.c (451): connect to 10.0.1.202:8009 failed  
(errno=61)
[Sun Mar 04 20:42:58 2007] [5950:] [info]   
ajp_connect_to_endpoint::jk_ajp_common.c (876): Failed opening socket  
to (10.0.1.202:8009) (errno=61)


and when I try to connect via apache I see lots of these:


[Sun Mar 04 20:17:19 2007] [5494:] [info]   
ajp_send_request::jk_ajp_common.c (1273): (worker1) error connecting  
to the backend server (errno=61)
[Sun Mar 04 20:17:19 2007] [5494:] [info]   
ajp_service::jk_ajp_common.c (1930): (worker1) sending request to  
tomcat failed,  recoverable operation attempt=2
[Sun Mar 04 20:17:19 2007] [5494:] [error]  
ajp_service::jk_ajp_common.c (1942): (worker1) Connecting to tomcat  
failed. Tomcat is probably not started or is listening on the wrong port


I am certain that the port is open, and as far as I can tell, Tomcat  
is listening.


Configuration files and sections are below.

I don't know where to look next...or what to look for...and any help  
or advice or direction is very much appreciated!!!


Thanks!!

here's a snippet of my httpd.conf:

LoadModule jk_module  libexec/httpd/mod_jk.so
AddModule mod_jk.c
JkWorkersFile /etc/httpd/workers.properties
JkShmFile /var/log/httpd/mod_jk.shm
JkLogFile /var/log/httpd/mod_jk.log
JkLogLevel debug
JkMount /examples/* worker1

Here's my workers.properties:

workers.tomcat_home=/path/to/tomcat
worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009


And here's my server.xml:


Server port=8005 shutdown=SHUTDOWN
  Listener  
className=org.apache.catalina.core.AprLifecycleListener  
SSLEngine=on /

  Listener className=org.apache.catalina.core.JasperListener /
  Listener  
className=org.apache.catalina.mbeans.ServerLifecycleListener /
  Listener  
className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener  
/
 Listener className=org.apache.jk.config.ApacheConfig modJk=/usr/ 
libexec/httpd/mod_jk.so workersConfig=/etc/httpd/ 
workers.properties jkLog=/var/log/httpd/mod_jk.log jkDebug=debug /

  GlobalNamingResources
Resource name=UserDatabase auth=Container
  type=org.apache.catalina.UserDatabase
  description=User database that can be updated and saved
   
factory=org.apache.catalina.users.MemoryUserDatabaseFactory

  pathname=path/to/tomcat-users.xml /
  /GlobalNamingResources
Service name=Catalina
 Connector port=8080 protocol=HTTP/1.1
   maxThreads=150 connectionTimeout=2
   redirectPort=8443 /
Connector port=8443 protocol=HTTP/1.1 SSLEnabled=true
   maxThreads=150 scheme=https secure=true
   clientAuth=false sslProtocol=TLS /
Connector port=8009 protocol=AJP/1.3 redirectPort=8443 /
Engine name=Catalina defaultHost=localhost
  Realm className=org.apache.catalina.realm.UserDatabaseRealm
 resourceName=UserDatabase/
  Host name=localhost  appBase=webapps
unpackWARs=true autoDeploy=true
xmlValidation=false xmlNamespaceAware=false
Listener className=org.apache.jk.config.ApacheConfig append=true  
jkWorker=worker1 /

 /Host
/Engine
  /Service
/Server







-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



MyApp servlet not deploying

2007-03-04 Thread Prateek Asthana

Hi,
I was trying to run the myapp servlet example. The examples provided
in the webapps directory seem to run fine but when i try the myapp
example by deploying. compiling and so on as illustrated, I run into
the following error:

type Status report
message /myapp/
description The requested resource (/myapp/) is not available.

I checked up the logs and have no trace of any error. The web.xml is as follows:

   display-nameHello, World Application/display-name
   description
This is a simple web application with a source code organization
based on the recommendations of the Application Developer's Guide.
   /description

   servlet
   servlet-nameHelloServlet/servlet-name
   servlet-classmypackage.Hello/servlet-class
   /servlet

   servlet-mapping
   servlet-nameHelloServlet/servlet-name
   url-pattern/myapp/url-pattern
   /servlet-mapping


I tried deploying using the front end and also by copying into
$CATALINA_HOME/webapps but to no avail. When I log into the manager
module, I lists this servlet but when i try viewing it as
http://localhost:8080/myapp/   it gives me the above error.  Please
help me get my first servlet started with tomcat. By the way I am
using Windows 2000.

Thanks,
Prateek

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



install DBCP and mm.mysql 2.0.14 (JDBC Driver) and a test app, getting class compile error

2007-03-04 Thread Wayne Bragg
I am trying to install DBCP and mm.mysql 2.0.14 (JDBC Driver) and a test app to 
see if it works.
I'm not sure I have all the correct steps and configuration, in other words I 
don't know what I am doing.. Here is what I know and my setup for this test 
example that I keep getting a class compile error on.

This is the error reported by browser -

type Exception report
message 
 description The server encountered an internal error () that prevented it from 
fulfilling this request.
exception 
 org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:512)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:377)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause 
 org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
 org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
 org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:414)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
 org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

This is the Tomcat log -

Mar 5, 2007 12:13:30 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 at 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
 at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
 at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:414)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
 at 
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
 at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
 at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
 at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
 at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
 at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
 at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
 at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
 at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
 at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
 at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
 at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
 at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
 at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
 at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
 at java.lang.Thread.run(Unknown Source)

This is how I setup and config for the DBCP and mm.mysql 2.0.14 (JDBC Driver)

Added to \www\tomcat5\common\lib
commons-pool-1.3.jar

RE: Using getImplementationVersion() to read MANIFEST.MF

2007-03-04 Thread Caldarale, Charles R
 From: Paul A. Hoadley [mailto:[EMAIL PROTECTED] 
 Subject: Re: Using getImplementationVersion() to read MANIFEST.MF
 
 1.  How can I read the value of the property from some arbitrary  
 class, say /WEB-INF/classes/some/package/Version.class?

You can use the following construct to create an InputStream pointing to
the manifest file and then pass that to a Properties.load() to retrieve
all the keys and values:

Properties prop = new Properties();
 
prop.load(getServletContext().getResourceAsStream(/META-INF/MANIFEST.MF
));

Use appropriate methods of java.util.Properties to examine the key/value
pair(s) you're interested in.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



install DBCP and mm.mysql 2.0.14 (JDBC Driver) and test app, get class compile error.

2007-03-04 Thread Wayne Bragg
Sorry about the previous premature post.
This is the full question/problem

I am trying to install DBCP and mm.mysql 2.0.14 (JDBC Driver) and a test app to 
see if it works.
I'm not sure I have all the correct steps and configuration, in other words I 
don't know what I am doing.. Here is what I know and my setup for this test 
example that I keep getting a class compile error on.

You can probably tell I only have HALF a clue at best? Any ideas what's wrong?

This is the error reported by browser -

type Exception report
message 
 description The server encountered an internal error () that prevented it from 
fulfilling this request.
exception 
 org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:512)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:377)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause 
 org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
 org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
 org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:414)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
 org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

This is the Tomcat log -

Mar 5, 2007 12:13:30 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
An error occurred at line: 7 in the jsp file: /test.jsp
Generated servlet error:
foo.DBTest cannot be resolved to a type
 at 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
 at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
 at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:414)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
 at 
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
 at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
 at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
 at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
 at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
 at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
 at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
 at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
 at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
 at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
 at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
 at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
 at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
 at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
 at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
 at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
 at 

Re: Using getImplementationVersion() to read MANIFEST.MF

2007-03-04 Thread Paul A. Hoadley

On 05/03/2007, at 5:39 PM, Caldarale, Charles R wrote:


From: Paul A. Hoadley [mailto:[EMAIL PROTECTED]
Subject: Re: Using getImplementationVersion() to read MANIFEST.MF

1.  How can I read the value of the property from some arbitrary
class, say /WEB-INF/classes/some/package/Version.class?


You can use the following construct to create an InputStream  
pointing to
the manifest file and then pass that to a Properties.load() to  
retrieve

all the keys and values:

Properties prop = new Properties();

prop.load(getServletContext().getResourceAsStream(/META-INF/ 
MANIFEST.MF

));


I ended up doing something quite like this (though using  
java.util.jar.Manifest), but I was initially stuck at this point.   
What I may not have made sufficiently clear in my original post is  
that the class I'm using isn't a servlet itself: it's a JavaBean that  
I'm instantiating from a JSP page (actually, from a custom tag  
written as a JSPX fragment).  Consequently, it couldn't call  
getServletContext().  It took me a while, but I finally thought of a  
solution---pass the ServletContext to the bean from the JSP via a  
property of the bean:


jsp:setProperty name=version property=servletContext value=$ 
{pageContext.servletContext}/


Is this the idiomatic way for a non-servlet object to obtain a  
ServletContext, or am I overlooking something easier or more  
appropriate?



--
Paul.

w  http://logicsquad.net/
h  http://paul.hoadley.name/



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Using getImplementationVersion() to read MANIFEST.MF

2007-03-04 Thread Caldarale, Charles R
 From: Paul A. Hoadley [mailto:[EMAIL PROTECTED] 
 Subject: Re: Using getImplementationVersion() to read MANIFEST.MF
 
 I ended up doing something quite like this (though using  
 java.util.jar.Manifest)

Watch out for that - it won't work unless the app is deployed as a .war
on a device with a real file system.  The getResourceAsStream()
mechanism should work in all environments.

 jsp:setProperty name=version property=servletContext value=$ 
 {pageContext.servletContext}/
 
 Is this the idiomatic way for a non-servlet object to obtain a  
 ServletContext, or am I overlooking something easier or more  
 appropriate?

Sounds o.k. to me, but others with more bean experience may have
alternatives.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]