Re: About mod_jk's retry setting

2010-12-10 Thread Rainer Jung

On 10.12.2010 04:43, Yu Kikuchi wrote:

Hello All.

My Environment:
  RHEL 5.3
  Apache 2.2.11
  mod_jk 1.2.30
  JBoss 5.0.0 GA

I have used mod_proxy_ajp to connect Apache and Tomcat(in JBoss).
But I decided to use not mod_proxy_ajp but mod_jk 1.2.30.

In the default setting of mod_proxy_xxx, it would be set retry=60 option.
How do I set workers.properties if want to make it the same setting?

It's my guess that follow setting makes it possible...
---
worker.node1.retries=2
worker.node1.retry_interval=6
---


First: there are lots of interesting options to change. The retry 
attributes are normally not of the kind that should be adjusted.


If you take a fresh download of the 1.2.31 sources, you can find a well 
commented example configuration in the tarball, including all the 
important timeouts etc. Setting those right is much more important!


Finally: the attribute you are looking for is recover_time. Have a look at

http://tomcat.apache.org/connectors-doc/reference/workers.html

Note that the attribute belongs to the load balancer, not to the 
individual nodes. The attribute retry_interval is for something very 
different and there should be no need to adjust.


Regards,

Rainer

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



minSpareThreads maxSpareThreads property

2010-12-10 Thread Christoph Kukulies
I installed the APR tomcat native library today.  It is giving the 
WARNINGs below.

Can anyone comment?
catalina.out:
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: Loaded APR based Apache Tomcat Native library 1.1.20.
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters 
[false], random [true].

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'minSpareThreads' to '25' did not find a matching property.

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'maxSpareThreads' to '75' did not find a matching property.

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'minSpareThreads' to '25' did not find a matching property.

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'maxSpareThreads' to '75' did not find a matching property.

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'minSpareThreads' to '25' did not find a matching property.

10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting 
property 'maxSpareThreads' to '75' did not find a matching property.

10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
INFO: Initializing Coyote HTTP/1.1 on http-8081
10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
INFO: Initializing Coyote HTTP/1.1 on http-8082
10.12.2010 11:08:54 org.apache.coyote.ajp.AjpAprProtocol init
INFO: Initializing Coyote AJP/1.3 on ajp-8009
10.12.2010 11:08:54 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1048 ms
10.12.2010 11:08:54 org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
10.12.2010 11:08:54 org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.28
10.12.2010 11:08:54 org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor manager.xml
10.12.2010 11:08:55 org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor host-manager.xml

--
Christoph P.U. Kukulies


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: minSpareThreads maxSpareThreads property

2010-12-10 Thread Mark Thomas
On 10/12/2010 10:38, Christoph Kukulies wrote:
 I installed the APR tomcat native library today.  It is giving the
 WARNINGs below.
 Can anyone comment?

Which part isn't clear?

Mark

 catalina.out:
 10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
 INFO: Loaded APR based Apache Tomcat Native library 1.1.20.
 10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
 INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters
 [false], random [true].
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'minSpareThreads' to '25' did not find a matching property.
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'maxSpareThreads' to '75' did not find a matching property.
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'minSpareThreads' to '25' did not find a matching property.
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'maxSpareThreads' to '75' did not find a matching property.
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'minSpareThreads' to '25' did not find a matching property.
 10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
 WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
 property 'maxSpareThreads' to '75' did not find a matching property.
 10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
 INFO: Initializing Coyote HTTP/1.1 on http-8080
 10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
 INFO: Initializing Coyote HTTP/1.1 on http-8081
 10.12.2010 11:08:54 org.apache.coyote.http11.Http11AprProtocol init
 INFO: Initializing Coyote HTTP/1.1 on http-8082
 10.12.2010 11:08:54 org.apache.coyote.ajp.AjpAprProtocol init
 INFO: Initializing Coyote AJP/1.3 on ajp-8009
 10.12.2010 11:08:54 org.apache.catalina.startup.Catalina load
 INFO: Initialization processed in 1048 ms
 10.12.2010 11:08:54 org.apache.catalina.core.StandardService start
 INFO: Starting service Catalina
 10.12.2010 11:08:54 org.apache.catalina.core.StandardEngine start
 INFO: Starting Servlet Engine: Apache Tomcat/6.0.28
 10.12.2010 11:08:54 org.apache.catalina.startup.HostConfig deployDescriptor
 INFO: Deploying configuration descriptor manager.xml
 10.12.2010 11:08:55 org.apache.catalina.startup.HostConfig deployDescriptor
 INFO: Deploying configuration descriptor host-manager.xml
 


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



URIEncoding problem ver 6.0.29 64 bit on windows

2010-12-10 Thread imrezol
Hi!

I set URIEncoding=UTF-8 at http connector  in server.xml:

Connector port=8080 protocol=HTTP/1.1
   connectionTimeout=2
   redirectPort=8443 URIEncoding=UTF-8/

restart tomcat service and after that type an url with special charaters
like this:

http://localhost:8080/mywebapp/docs/Felhasználói_kézikönyv.pdfhttp://localhost:8080/mywebapp/docs/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf

and I get a 404 error message:

*description* *The requested resource
(/*mywebapp*/*docs*/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf)
is not available.*

If I do the same settings with 6.0.29 32 bit verison, it's work fine.

Thank:

Zoltan Imre*
*

*
*


Re: minSpareThreads maxSpareThreads property

2010-12-10 Thread André Warnier

Mark Thomas wrote:

On 10/12/2010 10:38, Christoph Kukulies wrote:

I installed the APR tomcat native library today.  It is giving the
WARNINGs below.
Can anyone comment?


Which part isn't clear?

;-)

Christoph,

compare this page :
http://tomcat.apache.org/tomcat-6.0-doc/config/http.html#Standard_Implementation

to this page :
http://tomcat.apache.org/tomcat-5.5-doc/config/http.html

In other words, there is a strong suspicion that when you installed 6.0, you just copied a 
previous server.xml from a previous Tomcat version.
You should not do that.  You should start from the 6.0 server.xml, and make the 
modifications in it that are necessary for your applications, if any.


You scored an own-goal, and you are lucky that the result is only a warning.





Mark


catalina.out:
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: Loaded APR based Apache Tomcat Native library 1.1.20.
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters
[false], random [true].
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
property 'minSpareThreads' to '25' did not find a matching property.
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin
WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
property 'maxSpareThreads' to '75' did not find a matching property.
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule begin

...

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Brett Delle Grazie
Hi,

We're using:
RHEL5 (fully up to date)
Tomcat 6.0.29 (from apache.org)
JVM 1.6.0_22

We use HAproxy (1.4.8) as a front end to Tomcat, HAproxy uses the 'option
forwardfor' which adds an additional X-Forwarded-For header
to the request.

Everything works fine except if the client has an X-Forwarded-For header
_already_ in the request (perhaps due to Squid in forward proxy on client
side).

Thus offending request looks like:

Headers (fake IP addresses used):
X-Forwarded-For: 192.168.0.4  (client side added)
... (some other headers) ...
X-Forwarded-For: 224.212.128.2 (added by HAproxy - this is the actual IP of
the client's squid proxy).
... (some other headers) ...

Now Tomcat's RemoteIP valve doesn't appear to handle this situation
correctly - it returns 192.168.0.4 instead of the expected 224.212.128.2

Should HAproxy be extending the existing header to:
e.g. X-Forwarded-For: 192.168.0.4, 224.212.128.2

Or should Tomcat's RemoteIP valve handle this situation?

I'm also not sure which situation is 'correct' according to standards
anyway...

Any ideas?

Thanks,

-- 
Best Regards,

Brett Delle Grazie


Re: URIEncoding problem ver 6.0.29 64 bit on windows

2010-12-10 Thread imrezol
Sorry, it was my mistake.
On 64 bit version webapp name was MyWebApp
On 32 bit version webapp name was mywebapp

On Fri, Dec 10, 2010 at 13:54, imrezol imre...@gmail.com wrote:

 Hi!

 I set URIEncoding=UTF-8 at http connector  in server.xml:

 Connector port=8080 protocol=HTTP/1.1
connectionTimeout=2
redirectPort=8443 URIEncoding=UTF-8/

 restart tomcat service and after that type an url with special charaters
 like this:

 http://localhost:8080/mywebapp/docs/Felhasználói_kézikönyv.pdfhttp://localhost:8080/mywebapp/docs/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf

 and I get a 404 error message:

 *description* *The requested resource 
 (/*mywebapp*/*docs*/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf)
 is not available.*

 If I do the same settings with 6.0.29 32 bit verison, it's work fine.

 Thank:

 Zoltan Imre*
 *

 *
 *





Re: URIEncoding problem ver 6.0.29 64 bit on windows

2010-12-10 Thread André Warnier

imrezol wrote:

Hi!

I set URIEncoding=UTF-8 at http connector  in server.xml:

Connector port=8080 protocol=HTTP/1.1
   connectionTimeout=2
   redirectPort=8443 URIEncoding=UTF-8/

restart tomcat service and after that type an url with special charaters
like this:

http://localhost:8080/mywebapp/docs/Felhasználói_kézikönyv.pdfhttp://localhost:8080/mywebapp/docs/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf

and I get a 404 error message:

*description* *The requested resource
(/*mywebapp*/*docs*/Felhaszn%C3%A1l%C3%B3i_k%C3%A9zik%C3%B6nyv.pdf)
is not available.*

If I do the same settings with 6.0.29 32 bit verison, it's work fine.


Hi.

That's an interesting question.
Before we tackle this, can you answer this question, precisely :
When you mention trying this with a 32-bit and a 64-bit version of Tomcat, do you mean 
that you tried this on the exact same machine, with the same version of Tomcat, and with 
the exact same .pdf file under /mywebapp ?


(I am quoting of Tomcat above, because Tomcat itself would be the same, being Java code. 
 It is the JVM which is different)(which may already give a hint).


I consider the question interesting, because personally, I have always found this 
URIEncoding attribute rather questionable, in the HTTP and URI RFC sense.


As I understand the specs, this attribute should not exist.  A HTTP server should take the 
URI as it comes, decode it as per the uri-encoding/decoding scheme, and then just use the 
*byte* result 'as is' to locate the resource on disk.  It should not second-guess the 
client's intent.






-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Mark Thomas
On 10/12/2010 13:03, Brett Delle Grazie wrote:
 Hi,
 
 We're using:
 RHEL5 (fully up to date)
 Tomcat 6.0.29 (from apache.org)
 JVM 1.6.0_22
 
 We use HAproxy (1.4.8) as a front end to Tomcat, HAproxy uses the 'option
 forwardfor' which adds an additional X-Forwarded-For header
 to the request.
 
 Everything works fine except if the client has an X-Forwarded-For header
 _already_ in the request (perhaps due to Squid in forward proxy on client
 side).
 
 Thus offending request looks like:
 
 Headers (fake IP addresses used):
 X-Forwarded-For: 192.168.0.4  (client side added)
 ... (some other headers) ...
 X-Forwarded-For: 224.212.128.2 (added by HAproxy - this is the actual IP of
 the client's squid proxy).
 ... (some other headers) ...
 
 Now Tomcat's RemoteIP valve doesn't appear to handle this situation
 correctly - it returns 192.168.0.4 instead of the expected 224.212.128.2
 
 Should HAproxy be extending the existing header to:
 e.g. X-Forwarded-For: 192.168.0.4, 224.212.128.2
 
 Or should Tomcat's RemoteIP valve handle this situation?

It isn't absolutely clear since I can't find a precise enough definition
of the X-Forwarded-For header but the implication is that Tomcat should
handle this. Currently it doesn't.

 I'm also not sure which situation is 'correct' according to standards
 anyway...

The problem is Tomcat is only looking at the first X-Forwarded-For
header when it should probably be looking at both. Please create a
bugzilla entry for this and someone will hopefully take a look.

Mark

 
 Any ideas?
 
 Thanks,
 


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Konstantin Kolinko
2010/12/10 Brett Delle Grazie brett.dellegra...@gmail.com:
(...)

 Everything works fine except if the client has an X-Forwarded-For header
 _already_ in the request (perhaps due to Squid in forward proxy on client
 side).

 Thus offending request looks like:

 Headers (fake IP addresses used):
 X-Forwarded-For: 192.168.0.4  (client side added)
 ... (some other headers) ...
 X-Forwarded-For: 224.212.128.2 (added by HAproxy - this is the actual IP of
 the client's squid proxy).
 ... (some other headers) ...

 Now Tomcat's RemoteIP valve doesn't appear to handle this situation
 correctly - it returns 192.168.0.4 instead of the expected 224.212.128.2


Looks like a bug,

Please add it to bugzilla, as Mark suggested.

BTW, I think that the following change can fix it:
(for current tc6.0.x, not tested!)

Index: java/org/apache/catalina/valves/RemoteIpValve.java
===
--- java/org/apache/catalina/valves/RemoteIpValve.java  (revision 1044342)
+++ java/org/apache/catalina/valves/RemoteIpValve.java  (working copy)
@@ -564,12 +564,12 @@
 // loop on remoteIpHeaderValue to find the first trusted
remote ip and to build the proxies chain
 for (idx = remoteIpHeaderValue.length - 1; idx = 0; idx--) {
 String currentRemoteIp = remoteIpHeaderValue[idx];
-remoteIp = currentRemoteIp;
 if (matchesOne(currentRemoteIp, internalProxies)) {
 // do nothing, internalProxies IPs are not appended to the
 } else if (matchesOne(currentRemoteIp, trustedProxies)) {
 proxiesHeaderValue.addFirst(currentRemoteIp);
 } else {
+remoteIp = currentRemoteIp;
 idx--; // decrement idx because break statement
doesn't do it
 break;
 }

Best regards,
Konstantin Kolinko

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Mark Thomas
On 10/12/2010 13:54, Konstantin Kolinko wrote:
 2010/12/10 Brett Delle Grazie brett.dellegra...@gmail.com:
 (...)

 Everything works fine except if the client has an X-Forwarded-For header
 _already_ in the request (perhaps due to Squid in forward proxy on client
 side).

 Thus offending request looks like:

 Headers (fake IP addresses used):
 X-Forwarded-For: 192.168.0.4  (client side added)
 ... (some other headers) ...
 X-Forwarded-For: 224.212.128.2 (added by HAproxy - this is the actual IP of
 the client's squid proxy).
 ... (some other headers) ...

 Now Tomcat's RemoteIP valve doesn't appear to handle this situation
 correctly - it returns 192.168.0.4 instead of the expected 224.212.128.2

 
 Looks like a bug,
 
 Please add it to bugzilla, as Mark suggested.
 
 BTW, I think that the following change can fix it:
 (for current tc6.0.x, not tested!)

I don't think so. I think the problem is further up on line 558:
String[] remoteIpHeaderValue =
commaDelimitedListToStringArray(request.getHeader(remoteIpHeader));

I'm pretty sure that needs to be using request.getHeaders() but I
haven't tested it either ;)

Fortunately, the contribution of this valve and the matching filter came
with an extensive set of unit tests. It should be easy to extend the
tests to cover multiple headers.

Mark

 
 Index: java/org/apache/catalina/valves/RemoteIpValve.java
 ===
 --- java/org/apache/catalina/valves/RemoteIpValve.java(revision 
 1044342)
 +++ java/org/apache/catalina/valves/RemoteIpValve.java(working copy)
 @@ -564,12 +564,12 @@
  // loop on remoteIpHeaderValue to find the first trusted
 remote ip and to build the proxies chain
  for (idx = remoteIpHeaderValue.length - 1; idx = 0; idx--) {
  String currentRemoteIp = remoteIpHeaderValue[idx];
 -remoteIp = currentRemoteIp;
  if (matchesOne(currentRemoteIp, internalProxies)) {
  // do nothing, internalProxies IPs are not appended to 
 the
  } else if (matchesOne(currentRemoteIp, trustedProxies)) {
  proxiesHeaderValue.addFirst(currentRemoteIp);
  } else {
 +remoteIp = currentRemoteIp;
  idx--; // decrement idx because break statement
 doesn't do it
  break;
  }
 
 Best regards,
 Konstantin Kolinko
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



SocketTimeoutException with tomcat 5.5.25 while handling POST/PUT requests uploading content 2gb

2010-12-10 Thread Moiz Dohadwala

Hello,

Our application is currently using Tomcat 5.5.25 with jdk 1.5.0_13 (32-bit) and 
tcnative 1.1.20 (32-bit) on windows. While handling POSTS/PUT requests for 
large files (  2gb ), it frequently experiences timeouts. This happens on 
different windows platforms ( windows 7, windows 2003/2008 both 32 and 64 bit). 
So, it doesn't seem specific to any windows version.

Below is the complete stack trace:

2010-12-09 22:40:33,758 [http-0.0.0.0-9090-2] ERROR 
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/backup].[fileService]
 - Servlet.service() for servlet fileService threw exception
java.net.SocketTimeoutException: Exception filling buffer with data from 
underlying input stream: not an EAGAIN status, so perhaps disconnected client?
at 
org.apache.coyote.http11.InternalAprInputBuffer.fill(InternalAprInputBuffer.java:827)
at 
org.apache.coyote.http11.InternalAprInputBuffer$SocketInputBuffer.doRead(InternalAprInputBuffer.java:858)
at 
org.apache.coyote.http11.filters.IdentityInputFilter.doRead(IdentityInputFilter.java:116)
at 
org.apache.coyote.http11.InternalAprInputBuffer.doRead(InternalAprInputBuffer.java:773)
at org.apache.coyote.Request.doRead(Request.java:419)
at 
org.apache.catalina.connector.InputBuffer.realReadBytes(InputBuffer.java:265)
at org.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java:403)
at org.apache.catalina.connector.InputBuffer.read(InputBuffer.java:280)
at 
org.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:193)
at 
java.nio.channels.Channels$ReadableByteChannelImpl.read(Channels.java:196)
at com.corp.vdas.util.nio.NIOUtils.channelCopy(NIOUtils.java:33)
at 
com.corp.vdas.rcos.handler.impl.PutPathHandler.handleRequest(PutPathHandler.java:90)
at com.corp.vdas.rcos.handler.PathHandler.handlePath(PathHandler.java:116)
at 
com.corp.vdas.service.impl.ObjectStoreService.doExecute(ObjectStoreService.java:112)
at com.corp.vdas.service.impl.BaseService.execute(BaseService.java:44)
at com.corp.vdas.servlet.BeanServlet.service(BurritoServlet.java:71)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at 
org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378)
at 
com.corp.vdas.security.filters.RCOSAuthenticationFilter.doFilterHttp(RCOSAuthenticationFilter.java:58)
at 
org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
at 
org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)
at 
org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175)
at 
org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236)
at 
org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at 
org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:834)
at 
org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
at java.lang.Thread.run(Thread.java:595)

Any help would be appreciated.

Thanks,

Moiz
  

Re: deploy log4j

2010-12-10 Thread Pid
On 12/10/10 2:43 AM, cpanon wrote:
 Hello
 I agree it should be simple and in the IDE it works fine.  In simple 
 production 
 environment on Windows Servers it fails.  In simple production environment on 
 a 
 WinXPP it works.  It cant get any more discipline testing than that.  Nothing 
 changes other than the deployment OS.  
 
 
 I am loading an applet and I can synthesize my location as 
 codebase+WEB-INF/classes/log4j.properties but even the working IDE 
 environment 
 fails.  I am doing a 
 prop.load(getClass().getResourceAsStream(codebase+WEB-INF/classes/log4j.properties)).
  
  Now neither environment works.  Ideas?

Is the log4j property file loading code inside an applet or inside a web
application?


p


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



0x62590808.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature


Re: RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Brett Delle Grazie
On 10 December 2010 13:59, Mark Thomas ma...@apache.org wrote:

 On 10/12/2010 13:54, Konstantin Kolinko wrote:
  2010/12/10 Brett Delle Grazie brett.dellegra...@gmail.com:
  (...)
 
  Everything works fine except if the client has an X-Forwarded-For header
  _already_ in the request (perhaps due to Squid in forward proxy on
 client
  side).
 
  Thus offending request looks like:
 
  Headers (fake IP addresses used):
  X-Forwarded-For: 192.168.0.4  (client side added)
  ... (some other headers) ...
  X-Forwarded-For: 224.212.128.2 (added by HAproxy - this is the actual IP
 of
  the client's squid proxy).
  ... (some other headers) ...
 
  Now Tomcat's RemoteIP valve doesn't appear to handle this situation
  correctly - it returns 192.168.0.4 instead of the expected 224.212.128.2
 
 
  Looks like a bug,
 
  Please add it to bugzilla, as Mark suggested.


Done:
https://issues.apache.org/bugzilla/show_bug.cgi?id=50453


 
  BTW, I think that the following change can fix it:
  (for current tc6.0.x, not tested!)

 I don't think so. I think the problem is further up on line 558:
 String[] remoteIpHeaderValue =
 commaDelimitedListToStringArray(request.getHeader(remoteIpHeader));

 I'm pretty sure that needs to be using request.getHeaders() but I
 haven't tested it either ;)

 Fortunately, the contribution of this valve and the matching filter came
 with an extensive set of unit tests. It should be easy to extend the
 tests to cover multiple headers.

 Mark

 
  Index: java/org/apache/catalina/valves/RemoteIpValve.java
  ===
  --- java/org/apache/catalina/valves/RemoteIpValve.java(revision
 1044342)
  +++ java/org/apache/catalina/valves/RemoteIpValve.java(working
 copy)
  @@ -564,12 +564,12 @@
   // loop on remoteIpHeaderValue to find the first trusted
  remote ip and to build the proxies chain
   for (idx = remoteIpHeaderValue.length - 1; idx = 0; idx--)
 {
   String currentRemoteIp = remoteIpHeaderValue[idx];
  -remoteIp = currentRemoteIp;
   if (matchesOne(currentRemoteIp, internalProxies)) {
   // do nothing, internalProxies IPs are not appended
 to the
   } else if (matchesOne(currentRemoteIp, trustedProxies))
 {
   proxiesHeaderValue.addFirst(currentRemoteIp);
   } else {
  +remoteIp = currentRemoteIp;
   idx--; // decrement idx because break statement
  doesn't do it
   break;
   }
 
  Best regards,
  Konstantin Kolinko
 
  -
  To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
  For additional commands, e-mail: users-h...@tomcat.apache.org
 


 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




-- 
Best Regards,

Brett Delle Grazie


Re: RemoteIP valve and multiple X-Forwarded-For headers

2010-12-10 Thread Jim Riggs
On Dec 10, 2010, at 7:59 AM, Mark Thomas wrote:

 Looks like a bug,
 
 Please add it to bugzilla, as Mark suggested.
 
 BTW, I think that the following change can fix it:
 (for current tc6.0.x, not tested!)
 
 I don't think so. I think the problem is further up on line 558:
 String[] remoteIpHeaderValue =
 commaDelimitedListToStringArray(request.getHeader(remoteIpHeader));
 
 I'm pretty sure that needs to be using request.getHeaders() but I
 haven't tested it either ;)

It does indeed need to be using the Enumeration from request.getHeaders() 
instead of the single value from getHeader().  I have started work on a patch, 
unless someone beats me to it...


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Not supported by Basic Datasource

2010-12-10 Thread SOPANMISHRA

1.By normal jdbc process means without implementing any datasource concept in
tomcat  for my project evrything is working fine.It is just when i do
datasource config I'm facing not supported by basic data source against a
method that uses a stringbuilder to form a query by retrieving values from a
jsp page dynamically

if (Validation.validate(defRetrivalFields)) {
defRetrivalFieldsArr = 
defRetrivalFields.split(,);
int defRetrivalFieldsArrLen = 
defRetrivalFieldsArr.length;

for (int i = 0; i  defRetrivalFieldsArrLen; 
i++) {

tempRepresentData = representorMap

.get(defRetrivalFieldsArr[i]);
if 
(gaGrpCd.equalsIgnoreCase(tempRepresentData)
|| 
taCd.equalsIgnoreCase(tempRepresentData)) {

formedReqField.append(coalesce(M. + tempRepresentData
+ ,'-1') AS  
+ tempRepresentData);
} else if ((pccDteCreate

.equalsIgnoreCase(tempRepresentData)
|| pccDteUpdated

.equalsIgnoreCase(tempRepresentData) || (lastUpdate

.equalsIgnoreCase(tempRepresentData {
formedReqField.append(M. + 
tempRepresentData +  AS 
+ 
tempRepresentData);
} else {

formedReqField.append(coalesce(M. + tempRepresentData
+ ,' ') AS  + 
tempRepresentData);
}
orderByField.append(M. + 
tempRepresentData);

if (i != (defRetrivalFieldsArrLen - 1)) 
{
formedReqField.append(,);
orderByField.append(,);
}
tempRepresentData = null;
}
}
retStr[0] = formedReqField.toString();
retStr[1] = orderByField.toString();
}
return retStr;

2.I tried various  data source possible - resource
type=javax.sql.DataSource/javax.sql.ConnectionPoolDataSource but to no avail

3.driverClassName=oracle.jdbc.driver.OracleDriver/oracle.jdbc.OracleDriver  

4.The complete java stack trace is while processing the soap message
request:-

Dec 10, 2010 8:13:46 PM com..care.agentevaluation.db.dao.
getAgentDetails
INFO: Query:SELECT coalesce(M.iataNo,' ') AS iataNo,coalesce(M.pcc,' ') AS
pcc FROM  AS M WHERE M.pcc IN (:lst) ORDER BY M.iataNo,M.pcc
java.lang.UnsupportedOperationException: Not supported by BasicDataSource
at
org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:899)
at
org.hibernate.connection.DatasourceConnectionProvider.getConnection(DatasourceConnectionProvider.java:89)
at
org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)
at
org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)
at
org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:161)
at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1573)
at org.hibernate.loader.Loader.doQuery(Loader.java:696)
at
org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:259)
at org.hibernate.loader.Loader.doList(Loader.java:2228)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2125)
at org.hibernate.loader.Loader.list(Loader.java:2120)
at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1722)
at
org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:165)
at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:175)
at
com..care.agentevaluation.db.dao..getAgentDetails(.java:131)
at
com..care.agentevaluation.business.manager.Manager.searchAgent(Manager.java:64)
at
com..care.agentevaluation.services.service.ServiceMaster.searchAgent(ServiceMaster.java:79)
at 

Re: minSpareThreads maxSpareThreads property

2010-12-10 Thread Christoph Kukulies

Am 10.12.2010 14:02, schrieb André Warnier:

Christoph,

compare this page :
http://tomcat.apache.org/tomcat-6.0-doc/config/http.html#Standard_Implementation 



to this page :
http://tomcat.apache.org/tomcat-5.5-doc/config/http.html

In other words, there is a strong suspicion that when you installed 
6.0, you just copied a previous server.xml from a previous Tomcat 
version.


I just copied in my three http-proxies, indeed. But the native library 
was the first one that notified me of

the configuration error.



You should not do that.  You should start from the 6.0 server.xml, and 
make the modifications in it that are necessary for your applications, 
if any.


You scored an own-goal, and you are lucky that the result is only a 
warning.






Mark


catalina.out:
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: Loaded APR based Apache Tomcat Native library 1.1.20.
10.12.2010 11:08:54 org.apache.catalina.core.AprLifecycleListener init
INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters
[false], random [true].
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule 
begin

WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
property 'minSpareThreads' to '25' did not find a matching property.
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule 
begin

WARNUNG: [SetAllPropertiesRule]{Server/Service/Connector} Setting
property 'maxSpareThreads' to '75' did not find a matching property.
10.12.2010 11:08:54 org.apache.catalina.startup.SetAllPropertiesRule 
begin




--
Christoph P.U. Kukulies


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: minSpareThreads maxSpareThreads property

2010-12-10 Thread Rainer Jung

On 10.12.2010 16:06, Christoph Kukulies wrote:

Am 10.12.2010 14:02, schrieb André Warnier:

Christoph,

compare this page :
http://tomcat.apache.org/tomcat-6.0-doc/config/http.html#Standard_Implementation


to this page :
http://tomcat.apache.org/tomcat-5.5-doc/config/http.html

In other words, there is a strong suspicion that when you installed
6.0, you just copied a previous server.xml from a previous Tomcat
version.


I just copied in my three http-proxies, indeed. But the native library
was the first one that notified me of
the configuration error.


See also:

http://marc.info/?t=12898530712r=1w=2

and

https://issues.apache.org/bugzilla/show_bug.cgi?id=50285

Regards,

Rainer

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: deploy log4j

2010-12-10 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Pid,

On 12/10/2010 9:27 AM, Pid wrote:
 On 12/10/10 2:43 AM, cpanon wrote:
 Hello
 I agree it should be simple and in the IDE it works fine.  In simple 
 production 
 environment on Windows Servers it fails.  In simple production environment 
 on a 
 WinXPP it works.  It cant get any more discipline testing than that.  
 Nothing 
 changes other than the deployment OS.  


 I am loading an applet and I can synthesize my location as 
 codebase+WEB-INF/classes/log4j.properties but even the working IDE 
 environment 
 fails.  I am doing a 
 prop.load(getClass().getResourceAsStream(codebase+WEB-INF/classes/log4j.properties)).
  
  Now neither environment works.  Ideas?
 
 Is the log4j property file loading code inside an applet or inside a web
 application?

Great question: I hadn't considered an applet being part of the
equation, though the use of the word codebase is certainly a tip.

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0CVaMACgkQ9CaO5/Lv0PAeDgCgq0oAQJEwWVRPkuFHEAxP4A2c
9VwAnjxATjWi2q4kF9Ia6upSD/pIHCBD
=GMZT
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Tomcat 6 performance multiple instances

2010-12-10 Thread Pid
On 12/9/10 9:04 PM, John Goodleaf wrote:
 Google is giving me too many different answers!
 
 I need to serve a single webapp to a lot of people with acceptable latency.
 There's no need for multiple contexts or any other funkines. Tomcat 6, JVM
 1.6x. I have a hardware load balancer and two 64-bit machines (Windows 2003
 Server--not my choice, yes I'd have preferred Linux) each with two CPUs and
 8GB RAM.
 
 I also have a consultant who insists we need to set up at least two,
 possibly more, instances of Tomcat on each machine for good performance.

I'm late to this thread, but I'd still be interested to hear the
reasoning behind the above.  There are (largely historical) reasons for
doing this for some setups, but I don't see it as required/standard
practice for high performance sites.

(Maybe we don't know enough about your environment.)


p

 I'm
 more inclined to think that a single instance with tuned Java options will
 provide the same performance, but be easier to set up and maintain. If I
 needed to serve different webapps or somehow needed to separate things for
 some reason, I could see it, but given just the one app/context. it seems
 like multiple instances really amounts to second-guessing the OS scheduler.
 
 Also notable: the servers are VMs.
 
 Anyway, I'd appreciate advice, and I don't mind being wrong if you need to
 side with the consultant. If it needs to be complicated to go fast, then
 that's what we'll do... Ideally, I'd try both ways and hit it with JMeter,
 but I lack the time and resources (because mgmt spent the money on our
 consultant). So I must beg for answers here...
 
 Thanks in advance.
 J
 



0x62590808.asc
Description: application/pgp-keys


signature.asc
Description: OpenPGP digital signature


Re: Tomcat 6 performance multiple instances

2010-12-10 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Chuck,

On 12/9/2010 11:09 PM, Caldarale, Charles R wrote:
 I'm also very, very interested in the exact cause for the improvement
 observed with multiple JVMs using another servlet container - which
 may have no applicability to Tomcat.

Glad to see someone else is skeptical. I wonder what the environment
was, too: the JRE version is very sensitive: older versions of the
runtime were much slower for even uncontended locks, etc. and of course
GC gets better with every release.

- -chris

 It's worse than that - the compressed OOPs are relative as well, so
 it's an add and a shift.  However, if you keep the heap size down (so
 that direct 32-bit pointers are used), that extra overhead is
 eliminated - but now you're constrained by a small heap.

I hadn't thought of them being relative, but I guess the OS is obviously
doing some virtual memory mapping as well. Heh... running a 32-bit JVM
will certainly speed-up memory access, as long as you're willing to live
inside a 1.6GiB heap :)

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0CcvAACgkQ9CaO5/Lv0PBw7wCggidq59l99UqxGuTRao1rLbtI
tvgAn2QXNYOHwEOo6tjCsEgeUrwTeYwn
=kA2h
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Not supported by Basic Datasource

2010-12-10 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

SOPANMISHRA,

On 12/10/2010 9:51 AM, SOPANMISHRA wrote:
 1.By normal jdbc process means without implementing any datasource concept in
 tomcat  for my project evrything is working fine.

Glad to hear it.

 It is just when i do
 datasource config I'm facing not supported by basic data source against a
 method that uses a stringbuilder to form a query by retrieving values from a
 jsp page dynamically

The source of the query is not relevant: whether you use a StringBuilder
or a plain-old String (which is what you get, anyway), it's just a query
to the JDBC driver.

 if (Validation.validate(defRetrivalFields)) {

 [snip]

   }
   return retStr;

None of that code had anything to do with Hibernate or a DataSource.

 2.I tried various  data source possible - resource
 type=javax.sql.DataSource/javax.sql.ConnectionPoolDataSource but to no avail

Case matters: you need to have Resource in your configuration. You
need to have type=javax.sql.DataSource, otherwise the DataSource won't
be created at all (and you should get an error message in catalina.out).

 3.driverClassName=oracle.jdbc.driver.OracleDriver/oracle.jdbc.OracleDriver
   

You might want to determine which one of these is more appropriate for
you to use and stick with it.

 4.The complete java stack trace is while processing the soap message
 request:-
 
 Dec 10, 2010 8:13:46 PM com..care.agentevaluation.db.dao.
 getAgentDetails
 INFO: Query:SELECT coalesce(M.iataNo,' ') AS iataNo,coalesce(M.pcc,' ') AS
 pcc FROM  AS M WHERE M.pcc IN (:lst) ORDER BY M.iataNo,M.pcc
 java.lang.UnsupportedOperationException: Not supported by BasicDataSource
   at
 org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:899)

A call to getConnection will occur /before/ the query is executed. I
suspect that if you were to issue the query SELECT 1 FROM DUAL you'd
get the same error. I think this has nothing to do with your query at all.

BasicDataSource.getConnection in DBCP-1.2.2 only throws
UnsupportedOperationException when you call getConnection(String
username, String password) on the DataSource. Does your Hibernate
configuration specify a username and password? If so, you should remove
those and allow Hibernate to use the pool without specifying
credentials. I suspect this will clear-up your problem.

 5.I understand that datasource configuration is a separate entity and does
 not depend on the SQL query i have written in my .java file that is fetched
 using hibernate but still I want to enquire whether coalesce that i'm
 using in the dynamic query creation is the culprit because the exception is
 occurring when the method returning this processed query is returned as you
 can see in the scriptlet

No. No part of the query here is a problem.

 6.the reqfieldtype,colHeaderRequired etc and other are values saved into
 session from user input page and then requested wherever required

That doesn't make them trusted.

 7.I understand u are stressing on code optimization as
 (stringbuilder,finally) but my main problem is the functionality that i have
 to meet using data source and only after that I can stress upon code
 enhancement.i have noted and will implement it.The fact is the project is in
 testing environment and i have to implement the datasource and verify again
 including final code optimization without which it cannot be tested and put
 into production. 

Certainly correctness is key, but security is a part of correctness.

Good luck,
- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0CdyUACgkQ9CaO5/Lv0PCWTQCffTCmaueprea8cJbwN8xPz1FB
8b4AoIS93YHsnB9vHZ1hSynNfNVl/h4e
=NE93
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: deploy log4j

2010-12-10 Thread cpanon
Hello
I have some evidence that should get to cause of this and possibly help/edify 
others;hopefully not said selfishly.
The exact same war file works in a bare simple deployment in WinXPP and fails 
in 
Windows Server OSs, Win2KSrv, and Win2003Srv.
I enabled logging and tracing in the plugin and there were distinct differences 
as follows
WinXPP-working
basic: Plugin2ClassLoader.addURL parent called for 
http://localhost:8080/demo/clientSide.jar
security: Blacklist revocation check is enabled
security: Trusted libraries list check is enabled
network: Cache entry found [url: http://localhost:8080/demo/stuff00.jar, 
version: null] prevalidated=false/0
network: Connecting http://localhost:8080/demo/stuff00.jar with proxy=DIRECT
network: Connecting http://localhost:8080/ with proxy=DIRECT
network: Connecting http://localhost:8080/demo/stuff00.jar with cookie 
blackbird={pos:1,size:0,load:false}; 
JSESSIONID=C13AD93C0E79D14009D983749ED69189
network: ResponseCode for http://localhost:8080/demo/stuff00.jar : 304
network: Encoding for http://localhost:8080/demo/stuff00.jar : null
network: Disconnect connection to http://localhost:8080/demo/stuff00.jar
cache: Reading Signers from 2966 http://localhost:8080/demo/stuff00.jar | 
C:\Documents and Settings\Administrator\Application 
Data\Sun\Java\Deployment\cache\6.0\31\3bc270df-3b0abcb9.idx
cache:  Read manifest for http://localhost:8080/demo/stuff00.jar: read=45 
full=16708
basic: Plugin2ClassLoader.isTrustedByPolicy called 
basic: Plugin2ClassLoader.isTrustedByPolicy returns false 
network: Cache entry found [url: http://localhost:8080/demo/stuff01.jar, 
version: null] prevalidated=false/0




WinServer OSs-failing
basic: Plugin2ClassLoader.addURL parent called for 
http://localhost:8080/demo/clientSide.jar
network: Cache entry not found [url: http://localhost:8080/demo/stuff00.jar, 
version: null]
network: Connecting http://localhost:8080/demo/stuff00.jar with proxy=DIRECT
network: Connecting http://localhost:8080/ with proxy=DIRECT
network: Connecting http://localhost:8080/demo/stuff00.jar with cookie 
blackbird={pos:1,size:0,load:null}; 
JSESSIONID=A6229E473C7C7ACE4A6D1B4E0A83E537
network: Downloading resource: http://localhost:8080/demo/stuff00.jar
Content-Length: 797,273
Content-Encoding: null
network: CleanupThread used 91208 us
network: Wrote URL http://localhost:8080/demo/stuff00.jar to File C:\Documents 
and Settings\Administrator\Application 
Data\Sun\Java\Deployment\cache\6.0\31\3bc270df-4b448aa9-temp
security: Blacklist revocation check is enabled
security: Trusted libraries list check is enabled
network: CleanupThread used 3 us
security: Accessing keys and certificate in Mozilla user profile: null
security: Loading Root CA certificates from C:\Program 
Files\Java\jre6\lib\security\cacerts
security: Loaded Root CA certificates from C:\Program 
Files\Java\jre6\lib\security\cacerts
security: Loading Deployment certificates from C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
security: Loaded Deployment certificates from C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
security: Loading certificates from Deployment session certificate store
security: Loaded certificates from Deployment session certificate store
security: Validate the certificate chain using CertPath API
security: Obtain certificate collection in Root CA certificate store
security: Obtain certificate collection in Root CA certificate store
security: Start to check whether root CA is replaced
security: The root CA hasnt been replaced
security: No timestamping info available
security: Found jurisdiction list file
security: No need to checking trusted extension for this certificate
security: The CRL support is disabled
security: The OCSP support is disabled
security: This OCSP End Entity validation is disabled
security: Checking if certificate is in Deployment denied certificate store
security: Checking if certificate is in Deployment permanent certificate store
security: Checking if certificate is in Deployment session certificate store
security: User has granted the priviledges to the code forever
security: Loading Deployment certificates from C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
security: Loaded Deployment certificates from C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
security: Adding certificate in Deployment permanent certificate store
security: Added certificate in Deployment permanent certificate store as alias 
deploymentusercert-4090099776771522002
security: Saving Deployment certificates in C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
security: Saved Deployment certificates in C:\Documents and 
Settings\Administrator\Application 
Data\Sun\Java\Deployment\security\trusted.certs
basic: 

Re: Not supported by Basic Datasource

2010-12-10 Thread Mark Eggers
In your first message, did you post your complete hibernate configuration file?

I'm asking because of two issues.

1. You don't need the following line if you're using Tomcat's database pooling:

property name=connection.pool_size10/property

2. From a quick google search on Tomcat, Hibernate, Oracle, and Not supported 
by BasicDataSource, I find the following:

java.lang.UnsupportedOperationException: Not supported by BasicDataSource at
  
org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:899)


which is caused by trying to use Datasource.getConnection(username,password). 
This is not supported.

The underlying cause for using that method signature is the following two lines 
in a hibernate configuration file (which is why I asked if you posted your 
complete configuration file):

property name=hibernate.connection.username value=/
property name=hibernate.connection.password value=/

Remove the above two lines if they exist in your hibernate configuration file. 
The user name and password exist in the META-INF/context.xml file.

. . . . hope that helps.

/mde/

- Original Message 
From: SOPANMISHRA sopan.mis...@gmail.com
To: users@tomcat.apache.org
Sent: Fri, December 10, 2010 6:51:43 AM
Subject: Re: Not supported by Basic Datasource


1.By normal jdbc process means without implementing any datasource concept in
tomcat  for my project evrything is working fine.It is just when i do
datasource config I'm facing not supported by basic data source against a
method that uses a stringbuilder to form a query by retrieving values from a
jsp page dynamically

if (Validation.validate(defRetrivalFields)) {
defRetrivalFieldsArr = defRetrivalFields.split(,);
int defRetrivalFieldsArrLen = defRetrivalFieldsArr.length;

for (int i = 0; i  defRetrivalFieldsArrLen; i++) {

tempRepresentData = representorMap
.get(defRetrivalFieldsArr[i]);
if (gaGrpCd.equalsIgnoreCase(tempRepresentData)
|| taCd.equalsIgnoreCase(tempRepresentData)) {
formedReqField.append(coalesce(M. + tempRepresentData
+ ,'-1') AS  + tempRepresentData);
} else if ((pccDteCreate
.equalsIgnoreCase(tempRepresentData)
|| pccDteUpdated
.equalsIgnoreCase(tempRepresentData) || 
(lastUpdate
.equalsIgnoreCase(tempRepresentData {
formedReqField.append(M. + tempRepresentData +  AS 
+ tempRepresentData);
} else {
formedReqField.append(coalesce(M. + tempRepresentData
+ ,' ') AS  + tempRepresentData);
}
orderByField.append(M. + tempRepresentData);

if (i != (defRetrivalFieldsArrLen - 1)) {
formedReqField.append(,);
orderByField.append(,);
}
tempRepresentData = null;
}
}
retStr[0] = formedReqField.toString();
retStr[1] = orderByField.toString();
}
return retStr;

2.I tried various  data source possible - resource
type=javax.sql.DataSource/javax.sql.ConnectionPoolDataSource but to no avail

3.driverClassName=oracle.jdbc.driver.OracleDriver/oracle.jdbc.OracleDriver  

4.The complete java stack trace is while processing the soap message
request:-

Dec 10, 2010 8:13:46 PM com..care.agentevaluation.db.dao.
getAgentDetails
INFO: Query:SELECT coalesce(M.iataNo,' ') AS iataNo,coalesce(M.pcc,' ') AS
pcc FROM  AS M WHERE M.pcc IN (:lst) ORDER BY M.iataNo,M.pcc
java.lang.UnsupportedOperationException: Not supported by BasicDataSource
at
org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:899)

at
org.hibernate.connection.DatasourceConnectionProvider.getConnection(DatasourceConnectionProvider.java:89)

at
org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)
at
org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)
at
org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:161)

at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1573)
at org.hibernate.loader.Loader.doQuery(Loader.java:696)
at
org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:259)

at org.hibernate.loader.Loader.doList(Loader.java:2228)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2125)
at org.hibernate.loader.Loader.list(Loader.java:2120)
at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:312)
at 

Re: minSpareThreads maxSpareThreads property

2010-12-10 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Christoph,

On 12/10/2010 5:38 AM, Christoph Kukulies wrote:
 I installed the APR tomcat native library today.  It is giving the
 WARNINGs below.
 Can anyone comment?

I had the same problem when using keepAliveTimeout with TC 6.0.29, which
is definitely a supported setting. I never got an explanation but didn't
follow up on it.

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0CgBoACgkQ9CaO5/Lv0PBmmgCfWb6BLGExmSqrUcrlIaQOzDwC
ckAAn1TEGQ9x9vwAxDn4ZaOGVZLh2Hk0
=PuwF
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Tomcat/IIS Integration

2010-12-10 Thread Miner, James
I have been working on this issue for a few days now. Last week, my client 
needed to refresh their development server and one of the web services 
applications that they were running did not come over in working order. To 
reinstall I needed to remove the Tomcat instance, and any references in the 
registries, uninstall everything and then reinstall.
This has caused a few new problems, mainly that, because the application is 
configured to use IIS as its web server and Tomcat as its Java server, it needs 
a Jakarta instance to facilitate the Java handling back and forth. I've looked 
into this solution and cannot seem to find Jakarta (at least not a current 
version) on the Apache site. I did, however, find that Tomcat Connectors may 
have the functionality that I am looking for but, when I looked at the 
configuration guide included with the binary distribution it seemed to be a 
process more complicated than I, a business process analyst/Remedy developer, 
am comfortable performing on a client's box.
As I said, this is a bit out of my area of expertise and I am looking for 
suggestions of any nature here. If there is a product that I missed, a 
step-by-step guide somewhere out there or anything that you believe would be 
helpful to me at this point, I will be more than happy to hear about it. As it 
is, I am at a stand-still with my actual work until I can get this issue 
resolved, so any help will be greatly appreciated.

Versions:

Windows Server 2003 R2 Enterprise x64 SP2
Tomcat 5.5.9
IIS 6.0
JDK and JRE 1.6.0

Thank you,

James Miner
Consultant/Service Support-Column Technologies
130 William Street, 8th Floor, New York, NY 10038
P: (917) 969-8331
E: jmi...@columnit.com



Re: Tomcat/IIS Integration

2010-12-10 Thread Jordan Michaels

It is daunting at first, for sure. But it's easy once you understand it.

This guide may help:

http://it.megocollector.com/?p=224

-Jordan

On 12/10/2010 11:56 AM, Miner, James wrote:

I have been working on this issue for a few days now. Last week, my client 
needed to refresh their development server and one of the web services 
applications that they were running did not come over in working order. To 
reinstall I needed to remove the Tomcat instance, and any references in the 
registries, uninstall everything and then reinstall.
This has caused a few new problems, mainly that, because the application is 
configured to use IIS as its web server and Tomcat as its Java server, it needs 
a Jakarta instance to facilitate the Java handling back and forth. I've looked 
into this solution and cannot seem to find Jakarta (at least not a current 
version) on the Apache site. I did, however, find that Tomcat Connectors may 
have the functionality that I am looking for but, when I looked at the 
configuration guide included with the binary distribution it seemed to be a 
process more complicated than I, a business process analyst/Remedy developer, 
am comfortable performing on a client's box.
As I said, this is a bit out of my area of expertise and I am looking for 
suggestions of any nature here. If there is a product that I missed, a 
step-by-step guide somewhere out there or anything that you believe would be 
helpful to me at this point, I will be more than happy to hear about it. As it 
is, I am at a stand-still with my actual work until I can get this issue 
resolved, so any help will be greatly appreciated.

Versions:

Windows Server 2003 R2 Enterprise x64 SP2
Tomcat 5.5.9
IIS 6.0
JDK and JRE 1.6.0

Thank you,

James Miner
Consultant/Service Support-Column Technologies
130 William Street, 8th Floor, New York, NY 10038
P: (917) 969-8331
E: jmi...@columnit.com




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Tomcat/IIS Integration

2010-12-10 Thread Miner, James
This is exactly what I've been looking for. Thank you so much.

-Original Message-
From: Jordan Michaels [mailto:jor...@viviotech.net] 
Sent: Friday, December 10, 2010 3:09 PM
To: Tomcat Users List
Subject: Re: Tomcat/IIS Integration

It is daunting at first, for sure. But it's easy once you understand it.

This guide may help:

http://it.megocollector.com/?p=224

-Jordan

On 12/10/2010 11:56 AM, Miner, James wrote:
 I have been working on this issue for a few days now. Last week, my client 
 needed to refresh their development server and one of the web services 
 applications that they were running did not come over in working order. To 
 reinstall I needed to remove the Tomcat instance, and any references in the 
 registries, uninstall everything and then reinstall.
 This has caused a few new problems, mainly that, because the application is 
 configured to use IIS as its web server and Tomcat as its Java server, it 
 needs a Jakarta instance to facilitate the Java handling back and forth. I've 
 looked into this solution and cannot seem to find Jakarta (at least not a 
 current version) on the Apache site. I did, however, find that Tomcat 
 Connectors may have the functionality that I am looking for but, when I 
 looked at the configuration guide included with the binary distribution it 
 seemed to be a process more complicated than I, a business process 
 analyst/Remedy developer, am comfortable performing on a client's box.
 As I said, this is a bit out of my area of expertise and I am looking for 
 suggestions of any nature here. If there is a product that I missed, a 
 step-by-step guide somewhere out there or anything that you believe would be 
 helpful to me at this point, I will be more than happy to hear about it. As 
 it is, I am at a stand-still with my actual work until I can get this issue 
 resolved, so any help will be greatly appreciated.

 Versions:

 Windows Server 2003 R2 Enterprise x64 SP2
 Tomcat 5.5.9
 IIS 6.0
 JDK and JRE 1.6.0

 Thank you,

 James Miner
 Consultant/Service Support-Column Technologies
 130 William Street, 8th Floor, New York, NY 10038
 P: (917) 969-8331
 E: jmi...@columnit.com



-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Srikanth Konjarla
All,

I have a webservice client in the webapp. When the webapp is undeployed
the classloader has not been GC'ed. Upon investigation it is found that
a thread is in WAIT state which has references to the webapp class
loader. I see the following from heap dump.

http-8080-2
  at java.lang.Object.wait(J)V (Native Method)
  at java.lang.Object.wait()V (Object.java:485)
  at
org.apache.tomcat.util.net.JIoEndpoint$Worker.await()Ljava/net/Socket;
(JIoEndpoint.java:458)
  at org.apache.tomcat.util.net.JIoEndpoint$Worker.run()V
(JIoEndpoint.java:484)
  at java.lang.Thread.run()V (Unknown Source)

This is a pure development instance used by only a single user. Hence, I
have configured the Connector with minSpareThreads=2. If the thread is
retained by tomcat to reuse for another request, then wondering why
would it not remove references to other objects. Essentially, the thread
has threadLocals object that has few references.

Version details of tomcat:

Server version: Apache Tomcat/6.0.26
Server built:   March 9 2010 1805
Server number:  6.0.26.0
OS Name:Linux
OS Version: 2.6.18-164.15.1.el5
Architecture:   amd64
JVM Version:1.6.0_18-b07
JVM Vendor: Sun Microsystems Inc.

Thanks

Srikanth

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Can tomcat detect disconnection by client side in Async mode?

2010-12-10 Thread Michael Ludwig
Justin Randall schrieb am 07.12.2010 um 00:16 (+):
 
 Without knowing the application and going on standard sockets,
 I know from experience without using Async mode that Tomcat does
 generate a ClientAbortException when a TCP RST is received from
 a client when Tomcat is writing the HTTP response to the client.

Which seems to mean that it is only upon request completion, or
at any rate after beginning to write the answer, that Tomcat, or
rather, the specific thread attempting to write to the socket,
has a chance of being notified of an aborted client connection.

So, there is no such thing as an active client connection registry
maintained by the server, or possibly some other implementation
property which a thread could check to find out about the state
of the connection, is there?

 The client was a CPE which downloaded firmware/config via HTTP
 and sent a TCP RST after the first chunk of data if the version
 on the server and in the CPE were identical.  Not sure if this
 is relevant and what the behaviour of your client would be for
 disconnecting from the server (assuming it's not a web
 browser).

I'd really like to know the truth about this age-old myth, of
which there's an example in this old message back from 2000:

RE: STOP button of browser causes connection leak..
http://www.mail-archive.com/orion-inter...@orionserver.com/msg06077.html

  One of our engineers said that the web server should pick up on
  the connection being dead (back to the browser) so should abort
  the thread.

Are there any servers at all that proactively notify their
children or threads of aborted connections in order to stop them
from serving them, or at least provide them the opportunity to
cooperatively abort themselves when discovering an aborted
connection - other than by having them attempt to write to the
socket?

Has anyone ever encountered any server at all caring in such a way
about connections? Or is it all just what I labeled it - a myth?

 -Original Message-
 From: Ben xpsl...@gmail.com
 Date: Sun, 5 Dec 2010 14:25:56 

 Any idea about the disconnection handling? Cannot find reference
 for this.
 
 In my application the client may disconnect and send a new
 request with different parameters. On server side I wanna clean
 the AsynContext held by previous request. Right now only timeout
 will do, which is not efficient cos I set the timeout to quite
 high value to avoid frequent disconnect / connect.

-- 
Michael Ludwig

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Can tomcat detect disconnection by client side in Async mode?

2010-12-10 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Michael,

On 12/6/2010 4:11 PM, Michael Ludwig wrote:
 Ben schrieb am 05.12.2010 um 14:25 (+0800):
 and send a new request with different parameters. On server side I
 wanna clean the AsynContext held by previous request.
 
 Will the server even be notified? I still don't know if and how any HTTP
 server will be notified of this infamous user hit the cancel button
 event.

I think if the server tries to flush the response buffer, an exception
will be thrown. That's a pretty hacky way to detect this state, and
isn't really available in an asynchronous context because there's no
event that is in progress during which a flush() could be performed.

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0CnMwACgkQ9CaO5/Lv0PC1cQCfQk8nBN1oix7Il/V+9BLG5DDV
suUAoLbuLuwsPy6W/4jRQKGkml1kXDML
=r1v9
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



WARNING: Failed to register in JMX:

2010-12-10 Thread Linda Golff
I am using Tomcat6.0.26 - packaged with recent upgrade to Fedora 2.6.35.9-64
fc 14 x86-64.

 When I start Tomcat I get this error message:

INFO: Deploying= web application directory X
Dec 10, 2010 4:35:17 PM
org.apache.catalina.core.
NamingContextListener addResource

WARNING: Failed to register in JMX: javax.naming.NamingException: Could not
create resource factory instance [Root exception is
java.lang.ClassNotFoundException:
org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory]

I have Goggled the error (warning) no real help there, I have modified the
context.xml in the conf directory, I have checked .jar files in
$CATALINA_HOME/lib and found commons-dbcp.jar missing so copied it from
/usr/share/java and still i get the warning.  I am able to access static
content, unable to access anything connecting to the database.  I would
appreciate any assistance. I have been trying to resolve this issue for 3
days.


-- 
LG


RE: Can tomcat detect disconnection by client side in Async mode?

2010-12-10 Thread Caldarale, Charles R
 From: Michael Ludwig [mailto:mil...@gmx.de] 
 Subject: Re: Can tomcat detect disconnection by client side in Async mode?

 Are there any servers at all that proactively notify their
 children or threads of aborted connections in order to stop
 them from serving them

None that I'm aware of, since the TCP/IP stack doesn't pass that information 
along unless asked.  Something on the server side of the connection would have 
to access the socket in order to see if the other end is still alive, and the 
request processing thread has control of the socket, so other server code can't 
really presume to use it.

 or at least provide them the opportunity to cooperatively
 abort themselves when discovering an aborted connection -
 other than by having them attempt to write to the socket?

There is a Socket.isOutputShutdown() method that /might/ indicate that the 
client sent an RST, but the exact JRE implementation may well be 
platform-specific.  Failing that, writing to the socket is the only way I know 
of to be sure if the client is still listening (and even that's not a 
guarantee).

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Tomcat/IIS Integration

2010-12-10 Thread Caldarale, Charles R
 From: Miner, James [mailto:jmi...@columnit.com] 
 Subject: Tomcat/IIS Integration

 Versions:
 Tomcat 5.5.9

Please, please, upgrade Tomcat while you're in there.  That version is over 
five years old, and many, many security and bug fixes have gone in since then.

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Caldarale, Charles R
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com] 
 Subject: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

 Essentially, the thread has threadLocals object that has 
 few references.

And who put the ThreadLocal there?  (Hint: it wasn't Tomcat; your webapp - or a 
library it's using - is behaving badly, and not cleaning up after itself.)

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Srikanth Konjarla
Chuck,

You are right. It is apache Axis client that is responsible for
threadLocals in this case. However, as part of the thread local cleanup
process at the time of undeploy, tomcat removes few threadLocals but
misses the threadLocals for the thread in question. I am wondering about
the tomcat thread still being in WAIT mode and been cleaned up.

Srikanth

On 12/10/10 2:36 PM, Caldarale, Charles R wrote:
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com] 
 Subject: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)
 
 Essentially, the thread has threadLocals object that has 
 few references.
 
 And who put the ThreadLocal there?  (Hint: it wasn't Tomcat; your webapp - or 
 a library it's using - is behaving badly, and not cleaning up after itself.)
 
  - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Caldarale, Charles R
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com] 
 Subject: Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

 as part of the thread local cleanup process at the time of undeploy,
 tomcat removes few threadLocals but misses the threadLocals for the
 thread in question. I am wondering about the tomcat thread still being
 in WAIT mode and been cleaned up.

The WAIT mode is normal - the thread is sitting in the pool, waiting for a 
request to show up.  I believe the ThreadLocal objects are discarded by letting 
such infected threads exit and creating new ones.  That's an area still 
undergoing refinement, so you might want to try moving up to 6.0.29 and see if 
it makes any difference.  Or try sending in enough concurrent requests to get 
all the threads busy and see if the references disappear after that.

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: WARNING: Failed to register in JMX:

2010-12-10 Thread Pid *
On 10 Dec 2010, at 22:12, Linda Golff lgo...@gmail.com wrote:

 I am using Tomcat6.0.26 - packaged with recent upgrade to Fedora 2.6.35.9-64
 fc 14 x86-64.

Maybe the package is broken.

What happens if you uninstall it and use a Tomcat downloaded from apache.org?


p


 When I start Tomcat I get this error message:

 INFO: Deploying= web application directory X
 Dec 10, 2010 4:35:17 PM
 org.apache.catalina.core.
 NamingContextListener addResource

 WARNING: Failed to register in JMX: javax.naming.NamingException: Could not
 create resource factory instance [Root exception is
 java.lang.ClassNotFoundException:
 org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory]

 I have Goggled the error (warning) no real help there, I have modified the
 context.xml in the conf directory, I have checked .jar files in
 $CATALINA_HOME/lib and found commons-dbcp.jar missing so copied it from
 /usr/share/java and still i get the warning.  I am able to access static
 content, unable to access anything connecting to the database.  I would
 appreciate any assistance. I have been trying to resolve this issue for 3
 days.


 --
 LG

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Pid *
On 10 Dec 2010, at 22:46, Srikanth Konjarla srikanth.konja...@gmail.com wrote:

 Chuck,

 You are right. It is apache Axis client that is responsible for
 threadLocals in this case. However, as part of the thread local cleanup
 process at the time of undeploy, tomcat removes few threadLocals but
 misses the threadLocals for the thread in question. I am wondering about
 the tomcat thread still being in WAIT mode and been cleaned up.

Please upgrade to the latest 6.0 release. Monitor your catalina logs
on app unload, look for leak warnings.

Please report them and the version of Axis you're using here.


p




 Srikanth

 On 12/10/10 2:36 PM, Caldarale, Charles R wrote:
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com]
 Subject: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

 Essentially, the thread has threadLocals object that has
 few references.

 And who put the ThreadLocal there?  (Hint: it wasn't Tomcat; your webapp - 
 or a library it's using - is behaving badly, and not cleaning up after 
 itself.)

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org


 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Srikanth Konjarla


On 12/10/10 3:41 PM, Caldarale, Charles R wrote:
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com] 
 Subject: Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)
 
 as part of the thread local cleanup process at the time of undeploy,
 tomcat removes few threadLocals but misses the threadLocals for the
 thread in question. I am wondering about the tomcat thread still being
 in WAIT mode and been cleaned up.
 
 The WAIT mode is normal - the thread is sitting in the pool, waiting for a 
 request to show up. 
Does it mean that the thread is actually released to serve next request?
As in thread is recycled for reuse? What happens to data that was
referenced during the previous cycle?

 I believe the ThreadLocal objects are discarded by letting such
infected threads exit and creating new ones.

I was thinking on the same lines. As I have mentioned earlier, I see few
messages in catalina log to the effect that threadLocals are forcibly
removed.

I was initially embarked on finding out Axis related threads that are
leaking by checking threads in destroy method of application but, could
not catch the thread in question.

That's an area still undergoing refinement, so you might want to try
moving up to 6.0.29 and see if it makes any difference.

Ok. Will try that.

Thanks

Srikanth
  Or try sending in enough concurrent requests to get all the threads
busy and see if the references disappear after that.
 
  - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Srikanth Konjarla


On 12/10/10 4:11 PM, Pid * wrote:
 On 10 Dec 2010, at 22:46, Srikanth Konjarla srikanth.konja...@gmail.com 
 wrote:
 
 Chuck,

 You are right. It is apache Axis client that is responsible for
 threadLocals in this case. However, as part of the thread local cleanup
 process at the time of undeploy, tomcat removes few threadLocals but
 misses the threadLocals for the thread in question. I am wondering about
 the tomcat thread still being in WAIT mode and been cleaned up.
 
 Please upgrade to the latest 6.0 release. Monitor your catalina logs
 on app unload, look for leak warnings.
Will try that.

 
 Please report them and the version of Axis you're using here.
Axis version is 1.4. Actually, the threadLocals in question are coming
from Axis' MethodCache.

Srikanth

 
 
 p
 
 
 

 Srikanth

 On 12/10/10 2:36 PM, Caldarale, Charles R wrote:
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com]
 Subject: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

 Essentially, the thread has threadLocals object that has
 few references.

 And who put the ThreadLocal there?  (Hint: it wasn't Tomcat; your webapp - 
 or a library it's using - is behaving badly, and not cleaning up after 
 itself.)

 - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org


 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org

 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)

2010-12-10 Thread Srikanth Konjarla
BTW, I see some similarities with the following.

https://jira.springframework.org/browse/SWS-533

Srikanth

On 12/10/10 3:41 PM, Caldarale, Charles R wrote:
 From: Srikanth Konjarla [mailto:srikanth.konja...@gmail.com] 
 Subject: Re: 6.0.26 java.lang.Thread.State: WAITING (on object monitor)
 
 as part of the thread local cleanup process at the time of undeploy,
 tomcat removes few threadLocals but misses the threadLocals for the
 thread in question. I am wondering about the tomcat thread still being
 in WAIT mode and been cleaned up.
 
 The WAIT mode is normal - the thread is sitting in the pool, waiting for a 
 request to show up.  I believe the ThreadLocal objects are discarded by 
 letting such infected threads exit and creating new ones.  That's an area 
 still undergoing refinement, so you might want to try moving up to 6.0.29 and 
 see if it makes any difference.  Or try sending in enough concurrent requests 
 to get all the threads busy and see if the references disappear after that.
 
  - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Problem Started JBoss service -

2010-12-10 Thread Karthik Nanjangude
Hi

Off the topic this is a JBOSS Problem at start up process
If the Ports defined internal to Tc with in Joss is occupied by some other 
Application

My guess is to use netstat and watch the other Application using this port.



With regards
Karthik

-Original Message-
From: Nick Beare [mailto:nick.be...@causeway.com]
Sent: Thursday, December 09, 2010 11:21 PM
To: Tomcat Users List
Subject: Problem Started JBoss service -

Hi Community

Can anybody shed any light on the error we are experiencing when attempting to 
start the JBoss service?

An extract of the run.log is shown below.

.
.
.
12:17:46,836 INFO  [Http11Protocol] Initializing Coyote HTTP/1.1 on 
http-VMNWT118%2F10.5.23.151-8080
12:17:46,836 INFO  [AjpProtocol] Initializing Coyote AJP/1.3 on 
ajp-VMNWT118%2F10.5.23.151-8009
12:17:47,555 INFO  [Http11Protocol] Initializing Coyote HTTP/1.1 on 
http-VMNWT118%2F10.5.23.151-8443
12:17:47,571 INFO  [StandardService] Starting service jboss.web
12:17:47,571 INFO  [StandardEngine] Starting Servlet Engine: JBoss Web/2.1.3.GA
12:17:47,805 INFO  [Catalina] Server startup in 254 ms
12:17:47,821 INFO  [TomcatDeployment] deploy, ctxPath=/jbossws
12:17:49,289 WARN  [arjLoggerI18N] 
[com.arjuna.ats.arjuna.recovery.ActionStatusService_2] - Other Exception: 
java.lang.NullPointerException
12:17:49,289 ERROR [STDERR] java.lang.NullPointerException
12:17:49,289 ERROR [STDERR] at 
com.arjuna.ats.arjuna.recovery.ActionStatusService.doWork(ActionStatusService.java:123)
12:17:49,289 ERROR [STDERR] at 
com.arjuna.ats.internal.arjuna.recovery.Connection.run(Connection.java:83)
12:17:49,524 INFO  [TomcatDeployment] deploy, ctxPath=/invoker
12:17:49,789 INFO  [TomcatDeployment] deploy, ctxPath=/web-console
.
.
.

Any guidance or suggestions would be very much appreciated.

Regards

Nick Beare
Developer



Causeway is committed towards reducing its carbon footprint. Please consider 
the environment before printing this email.



Disclaimer Notice :-

The message and any attachments contained in this e-mail are intended for the 
named recipient(s) only. It may contain privileged or confidential information 
or information which is exempt from disclosure under the applicable laws. If 
you are not the intended recipient(s), you must not read, print, retain, copy 
distribute, forward or take any or refrain from taking any action in reliance 
on it or any of its attachments. If you have received or have been forwarded 
this e-mail in error, please notify us immediately by return e-mail or 
telephone (+44 (0)1628 552000) and delete this message from the computer or any 
other data-reading device in its entirety.

Please advise us immediately if you do not or your employer does not consent to 
Internet e-mail for messages of this nature.

Internet communications cannot be guaranteed to be secure and error-free as the 
information could be intercepted, corrupted, lost, arrive late or contain 
viruses. The sender and this Company therefore do not and shall not accept any 
liability or responsibility of whatsoever nature in the context of this message 
and its attachment(s) which arises as a result of Internet transmission. 
Opinions, conclusion, representations, views and such other information in this 
message that do not relate to the official business of this Company shall be 
understood as neither given nor endorsed by it.

Registered Office: Comino House, Furlong Road, Bourne End, Buckinghamshire, SL8 
5AQ
Registered in England No: 3921897 www.causeway.com

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org