Re: Error page problem

2004-09-17 Thread Martin Schaefer
> May I ask you - how did you conclude that expection occurs on error page
> itself? I think, exception does not occur on error page.

It said so: Exception Processing ErrorPage[errorCode=500, 
location=/errorpage.jsp]

> But when error page is defined for context, Tomcat tries to send error page
> to client. Tomcat tries to reset the response, but it is not possible
> because Axis library tries to send response too. That is why
> IllegalStateException occurs.

Sounds like a good explanation to me.

> Sending error page (that is intended for ordinary servlets or jsp) does not
> make sense, because clients expect SOAP messages.
> Is it possible to remove certain servlets from error page mechanism? Error
> page does not make sense for web services.

Maybe separate the web services from user interface!? Different WARs...

Regards,
Martin

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



Re: valid XHTML 1.1, Tomcat, text/xml, and @!&* IE

2004-09-17 Thread Mark Eggers
Yes, but the actual XSL is just a copy statement:

http://www.w3.org/1999/XSL/Transform";>





This should mean that no actual transformation gets done.

However, also from the FAQ:

Why is it allowed to send XHTML 1.0 documents as text/html?

XHTML is an XML format; this means that strictly speaking it should be
sent with an XML-related media type (application/xhtml+xml,
application/xml, or text/xml). However XHTML 1.0 was carefully designed
so that with care it would also work on legacy HTML user agents as well.
If you follow some simple guidelines, you can get many XHTML 1.0
documents to work in legacy browsers. However, legacy browsers only
understand the media type text/html, so you have to use that media type
if you send XHTML 1.0 documents to them. But be well aware, sending
XHTML documents to browsers as text/html means that those browsers see
the documents as HTML documents, not XHTML documents.

A third hack might be to use the:

  

hack in your document.  This means that only Internet Exploder will see
what's there.

Sigh - asking Microsoft to play by the rules is just not a possible
thing.

/mde/
just my two cents . . . .


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



jstl:import---static information?

2004-09-17 Thread Garret Wilson
According to the JSF and JSTL documentation (and two JSF books), 
 should dynamically import information. I have:


...



...

However, everything from navigation.jsp is included 
literally---including all JSF tags and everything in the imported JSP. 
This happens both on Tomcat 5.5.2 and 5.0.28, so I must be doing 
something wrong---yet I'm using examples almost verbatim (pun not 
intended) from _Core JavaServer Faces_ and _Mastering JavaServer Faces_.

Shouldn't the imported information be merged into the JSF component 
tree, rather than just spitting out the JSF tags (and all other tags) as 
if they were serialized literally?

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


Re: Error page problem

2004-09-17 Thread Igor
Hello!

> You probably focused on the rest of your application and didn't notice
> that the exception occurs in the error page itself.

Thank you for responses!

May I ask you - how did you conclude that expection occurs on error page
itself? I think, exception does not occur on error page.

I may be wrong, but I think, that the reason is the following:

To notify client of web service, that non standard situation occured, we
throw SOAPFaultException in web service. Axis library takes care of this
exception and client reseives response with 200 code status.

But when error page is defined for context, Tomcat tries to send error page
to client. Tomcat tries to reset the response, but it is not possible
because Axis library tries to send response too. That is why
IllegalStateException occurs.

Sending error page (that is intended for ordinary servlets or jsp) does not
make sense, because clients expect SOAP messages.

Is it possible to remove certain servlets from error page mechanism? Error
page does not make sense for web services.

Thank you,
Igor


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



Re: valid XHTML 1.1, Tomcat, text/xml, and @!&* IE

2004-09-17 Thread Garret Wilson
No, please, tell me it's all a bad dream...
Doesn't that workaround mean that all browsers, even ones that support 
XHTML 1.1 (such as Firefox), will suddenly start applying an XSL 
transformation to the entire web page?

Wouldn't it be a much less nasty hack just to tell Tomcat to serve these 
pages as text/html? How can I do that?

Garret
Mark Eggers wrote:
On Fri, 2004-09-17 at 17:55, Garret Wilson wrote:
With Tomcat 5.5.2, JSF, and JSP, I'm serving up pure, 
standards-compliant XHTML 1.1 that starts out with:


http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd";>
http://www.w3.org/1999/xhtml";>

That works just fine with FireFox, but with IE (the very latest and 
greatest available), I get:

Parameter entity must be defined before it is used. Error processing 
resource 'http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd...

%xhtml-prefw-redecl.mod;
-^

Yep - known bug that IE cannot handle this.  Apparently there is a
work-around detailed at:
http://www.w3.org/MarkUp/2004/xhtml-faq#texthtml
I haven't tried it yet.
/mde/
just my two cents . . . .
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


language

2004-09-17 Thread Eugene
Hi again! Another question. I have a system language Spanish on my
server. How can I setup error pages (404,413 etc) to use English instead of Spanish?

Thank you for any help!


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



Re: valid XHTML 1.1, Tomcat, text/xml, and @!&* IE

2004-09-17 Thread Mark Eggers
On Fri, 2004-09-17 at 17:55, Garret Wilson wrote:
> With Tomcat 5.5.2, JSF, and JSP, I'm serving up pure, 
> standards-compliant XHTML 1.1 that starts out with:
> 
> 
>  "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd";>
> http://www.w3.org/1999/xhtml";>
> 
> That works just fine with FireFox, but with IE (the very latest and 
> greatest available), I get:
> 
> Parameter entity must be defined before it is used. Error processing 
> resource 'http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd...
> 
> %xhtml-prefw-redecl.mod;
> -^

Yep - known bug that IE cannot handle this.  Apparently there is a
work-around detailed at:

http://www.w3.org/MarkUp/2004/xhtml-faq#texthtml

I haven't tried it yet.

/mde/
just my two cents . . . .


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



cannot find server

2004-09-17 Thread Brian Roberts
Hello,
I'm having a problem with tomcat server version 5. When I click on
the welcome button from the start/programs/apache tomcat 5.0 the
browser opens and says 'cannot find server'.
I installed it from the install wizard with a full install. I set the
 environment variable JAVA_HOME to j2re1.4.2_04. On the configure I
tried the start button. I tried with the zone alarm fire wall on and
off but no effect. Do I need to add the jsdk.jar to the classpath
with this version (I haven't done it, I couldn't see any reference to
it with this version).
Your help would be appreciated. Thank you.
Brian Roberts.



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


valid XHTML 1.1, Tomcat, text/xml, and @!&* IE

2004-09-17 Thread Garret Wilson
With Tomcat 5.5.2, JSF, and JSP, I'm serving up pure, 
standards-compliant XHTML 1.1 that starts out with:


http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd";>
http://www.w3.org/1999/xhtml";>

That works just fine with FireFox, but with IE (the very latest and 
greatest available), I get:

Parameter entity must be defined before it is used. Error processing 
resource 'http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd...

%xhtml-prefw-redecl.mod;
-^
Apparently, it's because of an IE bug that chokes if the content is 
served as text/xml. See:

http://lists.w3.org/Archives/Public/www-math/2002Apr/0002.html
http://www.biglist.com/lists/xsl-list/archives/200405/msg00106.html
http://www.intertwingly.net/blog/1626.html
How do I tell Tomcat to serve JavaServer Faces files as text/html (or 
application/html+xml, but maybe that's asking for too much) so that IE 
users can access content that's apparently too standards-compliant for 
their browsers?

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


SSL for multiple domains and one application with Tomcat

2004-09-17 Thread David Bryan

I have an app currently running on stand alone Tomcat(with a Win2K OS).
Different 'user-experiences', (text and graphics) are served
depending on the different URL address which are used to reach the
site. What we want is to have SSL certificates to authenticate for
these different domain names.

What I've read in my research is that it is a limitation of SSL to
have multiple domain names authenticate with the same IP. So if that
is a limitation and we have to get a second IP to connect to the
server, how would we configure Tomcat for that?

Thanks,

Dave B
 

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



Re: 404 etc

2004-09-17 Thread ALWAYSRIA
Unsubscribe me!


Re: 404 etc

2004-09-17 Thread ALWAYSRIA
unsubscribe me!


404 etc

2004-09-17 Thread Eugene
Hello all!
How to disable ServerTokens in Tomcat and how to replace
the error pages on custom static pages?

Thank you for any help!




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



RE: performance problem

2004-09-17 Thread Mike Curwen
Hmm...
http://www.greenfieldresearch.ca/technical/jk2_config.html

Reading that, look for the one line in red font.  Seems there's potential
config problems when apache and tomcat are on separate boxes, as they need
to share a file. You'd think this would prevent operation, rather than
slowing it down , so perhaps it's not related.
 
We use similar architecture, but JK (which doesn't seem to require that
shared file).


> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
> Sent: Friday, September 17, 2004 2:06 PM
> To: [EMAIL PROTECTED]
> Subject: performance problem
> 
> 
> I have an apache/tomcat environment that is experiencing performance 
> problems.
> 
> My production environment has apache on one win2k box, and 
> the two tomcat 
> instances on another win 2k box. 
> 
> When I load test the my application directly against either 
> of the tomcat 
> instances, I get about 150 req/s. When I test with apache in 
> front, I get 
> 10 req/s. This was with apache server temporarily placed on 
> same network 
> segment as tomcat box.
> 
> I recreated the production setup on a couple of developer 
> workstations 
> (slightly slower hardware than the production environment), 
> and got > 70 
> req/s.
> 
> Apache and tomcat conf files are essentially identical in both 
> environments.
> 
> Does anyone have any clues?
> 


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



Re: cluster FarmWarDeployer

2004-09-17 Thread Filip Hanik - Dev
>- should the deploy dir point to the webapp directory?
no it should not, cause you would double deploy your app, and that is why you get an 
error

>but that seemed to only copy the war

no, it deployed it, just didn't expand it, there is no reason to expand it

Filip

- Original Message -
From: "Rob van Oostrum" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 4:14 PM
Subject: RE: cluster FarmWarDeployer


- should the deploy dir point to the webapp directory? I tried using the 
out-of-the-box configuration, but that seemed to only copy
the war and not actually deploy it
- where is the warfile supposed to arrive at each of the other 2 nodes? Is that what 
the deploy dir property is for in the Deployer
element on each of the nodes?

> -Original Message-
> From: Filip Hanik - Dev [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 17, 2004 4:59 PM
> To: Tomcat Users List
> Subject: Re: cluster FarmWarDeployer
>
>
> yes, all servers should have the deployer element.
> the only difference would be "watchEnabled" would only be
> true for the admin server.
>
> also, never seen that error, but I will investigate, feel
> free to open an item in bugzilla
>
> Filip
>
> - Original Message -
> From: "Rob van Oostrum" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, September 17, 2004 3:51 PM
> Subject: cluster FarmWarDeployer
>
>
> I have a Deployer set up like so:
>
>  className="org.apache.catalina.cluster.deploy.FarmWarDeployer"
>   tempDir="/home/apache/temp/"
>
> deployDir="/usr/local/jakarta-tomcat-5.0.27/webapps/"
>   watchDir="/home/apache/watch/"
>   watchEnabled="true" />
>
> There's 2 other nodes in the cluster. The server.xml for
> those 2 doesn't contain this element (should it?).
>
> When I drop a war-file (enroll.war) into the watch directory,
> it gets picked up and deployed to that node, but the following error
> shows up in catalina.out and there's no deployment to the
> other 2 nodes (and nothing in their logs):
>
>
> *** BEGIN
> INFO: Installing web application at context path /enroll from
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll.war
> Sep 17, 2004 2:08:55 PM
> org.apache.catalina.cluster.deploy.FarmWarDeployer fileModified
> SEVERE: Unable to install WAR file
> java.lang.IllegalArgumentException: Context path /enroll must
> match the directory or WAR file name: enroll.war
> at
> org.apache.catalina.core.StandardHostDeployer.install(Standard
> HostDeployer.java:250)
> at
> org.apache.catalina.cluster.deploy.FarmWarDeployer.install(Far
> mWarDeployer.java:196)
> at
> org.apache.catalina.cluster.deploy.FarmWarDeployer.fileModifie
> d(FarmWarDeployer.java:261)
> at
> org.apache.catalina.cluster.deploy.WarWatcher.run(WarWatcher.java:93)
> at java.lang.Thread.run(Thread.java:534)
> Sep 17, 2004 2:08:59 PM
> org.apache.catalina.core.StandardHostDeployer install
> INFO: Installing web application at context path /enroll from
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll
>
>
>
>
> Creating ClusterManager for context /enroll using class
> org.apache.catalina.cluster.session.DeltaManager
> *** END
>
>
> I tried searching the web and the archives for this list but
> no luck finding anything informative. How should this be setup? My 3
> instances run on 3 different machines. The cluster itself
> seems to run fine (I get member added/disappeared log messages and no
> errors).
>
> All this is running on Red Hat Enterprise / JDK 1.4.2_03-b02
> / Tomcat 5.0.27
>
>
> thanks
> Rob
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

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


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



505 Error in Tomcat 5.0

2004-09-17 Thread Michael McGrady
I am using Tomcat 5.0 and Struts 1.1.  I also use a Filter that zips the 
requests and responses.  I am running a chat room on port 80 with a 
frameset html that auto refreshes in one frame and sends in another 
frame.  When a user with IE tries to chat with me from her office, she 
gets 505 messages.  I have recently changed the code on the pages.  I am 
getting requests when she sends one, but they are old requests, with the 
same chat lines she sent before.  Anyone know what is probably going on 
here?  The Filter I use follows:

  public class GZIPFilter implements Filter {
public void doFilter(ServletRequest req, ServletResponse res,
FilterChain chain) throws IOException, ServletException {
  if (req instanceof HttpServletRequest) {
HttpServletRequest request = (HttpServletRequest) req;
HttpServletResponse response = (HttpServletResponse) res;
String ae = request.getHeader("accept-encoding");
if (ae != null && ae.indexOf("gzip") != -1) {
  GZIPResponseWrapper wrappedResponse = new
  GZIPResponseWrapper(response);
  chain.doFilter(req, wrappedResponse);
  wrappedResponse.finishResponse();
  return;
}
chain.doFilter(req, res);
  }
}
public void init(FilterConfig filterConfig) {
  // noop
}
public void destroy() {
  // noop
}
  }
What do you think?
Michael McGrady

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


RE: cluster FarmWarDeployer

2004-09-17 Thread Rob van Oostrum
- should the deploy dir point to the webapp directory? I tried using the 
out-of-the-box configuration, but that seemed to only copy the war and not actually 
deploy it
- where is the warfile supposed to arrive at each of the other 2 nodes? Is that what 
the deploy dir property is for in the Deployer element on each of the nodes?

> -Original Message-
> From: Filip Hanik - Dev [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 17, 2004 4:59 PM
> To: Tomcat Users List
> Subject: Re: cluster FarmWarDeployer
> 
> 
> yes, all servers should have the deployer element.
> the only difference would be "watchEnabled" would only be 
> true for the admin server.
> 
> also, never seen that error, but I will investigate, feel 
> free to open an item in bugzilla
> 
> Filip
> 
> - Original Message -
> From: "Rob van Oostrum" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, September 17, 2004 3:51 PM
> Subject: cluster FarmWarDeployer
> 
> 
> I have a Deployer set up like so:
> 
>  className="org.apache.catalina.cluster.deploy.FarmWarDeployer"
>   tempDir="/home/apache/temp/"
>   
> deployDir="/usr/local/jakarta-tomcat-5.0.27/webapps/"
>   watchDir="/home/apache/watch/"
>   watchEnabled="true" />
> 
> There's 2 other nodes in the cluster. The server.xml for 
> those 2 doesn't contain this element (should it?).
> 
> When I drop a war-file (enroll.war) into the watch directory, 
> it gets picked up and deployed to that node, but the following error
> shows up in catalina.out and there's no deployment to the 
> other 2 nodes (and nothing in their logs):
> 
> 
> *** BEGIN
> INFO: Installing web application at context path /enroll from 
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll.war
> Sep 17, 2004 2:08:55 PM 
> org.apache.catalina.cluster.deploy.FarmWarDeployer fileModified
> SEVERE: Unable to install WAR file
> java.lang.IllegalArgumentException: Context path /enroll must 
> match the directory or WAR file name: enroll.war
> at 
> org.apache.catalina.core.StandardHostDeployer.install(Standard
> HostDeployer.java:250)
> at 
> org.apache.catalina.cluster.deploy.FarmWarDeployer.install(Far
> mWarDeployer.java:196)
> at 
> org.apache.catalina.cluster.deploy.FarmWarDeployer.fileModifie
> d(FarmWarDeployer.java:261)
> at 
> org.apache.catalina.cluster.deploy.WarWatcher.run(WarWatcher.java:93)
> at java.lang.Thread.run(Thread.java:534)
> Sep 17, 2004 2:08:59 PM 
> org.apache.catalina.core.StandardHostDeployer install
> INFO: Installing web application at context path /enroll from 
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll
> 
> 
> 
> 
> Creating ClusterManager for context /enroll using class 
> org.apache.catalina.cluster.session.DeltaManager
> *** END
> 
> 
> I tried searching the web and the archives for this list but 
> no luck finding anything informative. How should this be setup? My 3
> instances run on 3 different machines. The cluster itself 
> seems to run fine (I get member added/disappeared log messages and no
> errors).
> 
> All this is running on Red Hat Enterprise / JDK 1.4.2_03-b02 
> / Tomcat 5.0.27
> 
> 
> thanks
> Rob
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

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



Re: Why tomcat 4 or even 3?

2004-09-17 Thread Norris Shelton
Sometimes "we" developers have no choice on the version that we
run.  "We" were upgraded from 4.1.12 to 4.1.30 last weekend. 
This only happened because IT wanted to upgrade from SLES7 to
SLES8 and 4.1.30 is the version that YAAST had.  If it had been
up to my part of the "We", we would have been on 5.0 a LONG time
ago.

I've only been harping to get a 5.0 development server for a
year and a half.  It looks like I'm still at least 2 months
away.  

Dang nabbit.


--- John Villar <[EMAIL PROTECTED]> wrote:

> A question to everyone out there. why does anyone use
> nowadays 
> Tomcat 4 branch?. isn't tomcat 5 branch more bug free,
> featurefull 
> and backwards compatible?
> 
> that question has haunted me from the beginning of joining
> this list.
> 
> -- 
> John Villar
> Gerente de Proyectos
> Computadores Flor Hard Soft 2058 C.A.
> www.florhard.com
> 
> 
> >
-
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
[EMAIL PROTECTED]


=

Norris Shelton
Software Engineer
Sun Certified Java 1.1 Programmer
Appriss, Inc.
ICQ# 26487421
AIM NorrisEShelton
YIM norrisshelton




___
Do you Yahoo!?
Express yourself with Y! Messenger! Free. Download now. 
http://messenger.yahoo.com

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



Re: cluster FarmWarDeployer

2004-09-17 Thread Filip Hanik - Dev
yes, all servers should have the deployer element.
the only difference would be "watchEnabled" would only be true for the admin server.

also, never seen that error, but I will investigate, feel free to open an item in 
bugzilla

Filip

- Original Message -
From: "Rob van Oostrum" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 3:51 PM
Subject: cluster FarmWarDeployer


I have a Deployer set up like so:



There's 2 other nodes in the cluster. The server.xml for those 2 doesn't contain this 
element (should it?).

When I drop a war-file (enroll.war) into the watch directory, it gets picked up and 
deployed to that node, but the following error
shows up in catalina.out and there's no deployment to the other 2 nodes (and nothing 
in their logs):


*** BEGIN
INFO: Installing web application at context path /enroll from URL 
file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll.war
Sep 17, 2004 2:08:55 PM org.apache.catalina.cluster.deploy.FarmWarDeployer fileModified
SEVERE: Unable to install WAR file
java.lang.IllegalArgumentException: Context path /enroll must match the directory or 
WAR file name: enroll.war
at 
org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:250)
at 
org.apache.catalina.cluster.deploy.FarmWarDeployer.install(FarmWarDeployer.java:196)
at 
org.apache.catalina.cluster.deploy.FarmWarDeployer.fileModified(FarmWarDeployer.java:261)
at org.apache.catalina.cluster.deploy.WarWatcher.run(WarWatcher.java:93)
at java.lang.Thread.run(Thread.java:534)
Sep 17, 2004 2:08:59 PM org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /enroll from URL 
file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll




Creating ClusterManager for context /enroll using class 
org.apache.catalina.cluster.session.DeltaManager
*** END


I tried searching the web and the archives for this list but no luck finding anything 
informative. How should this be setup? My 3
instances run on 3 different machines. The cluster itself seems to run fine (I get 
member added/disappeared log messages and no
errors).

All this is running on Red Hat Enterprise / JDK 1.4.2_03-b02 / Tomcat 5.0.27


thanks
Rob


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



RE: cluster FarmWarDeployer

2004-09-17 Thread Rob van Oostrum
BTW the web.xml for the war does include the  element

> -Original Message-
> From: Rob van Oostrum [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 17, 2004 4:51 PM
> To: [EMAIL PROTECTED]
> Subject: cluster FarmWarDeployer
> 
> 
> I have a Deployer set up like so:
> 
>  className="org.apache.catalina.cluster.deploy.FarmWarDeployer"
>   tempDir="/home/apache/temp/"
>   
> deployDir="/usr/local/jakarta-tomcat-5.0.27/webapps/"
>   watchDir="/home/apache/watch/"
>   watchEnabled="true" />
> 
> There's 2 other nodes in the cluster. The server.xml for 
> those 2 doesn't contain this element (should it?).
> 
> When I drop a war-file (enroll.war) into the watch directory, 
> it gets picked up and deployed to that node, but the 
> following error shows up in catalina.out and there's no 
> deployment to the other 2 nodes (and nothing in their logs):
> 
> 
> *** BEGIN
> INFO: Installing web application at context path /enroll from 
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll.war
> Sep 17, 2004 2:08:55 PM 
> org.apache.catalina.cluster.deploy.FarmWarDeployer fileModified
> SEVERE: Unable to install WAR file
> java.lang.IllegalArgumentException: Context path /enroll must 
> match the directory or WAR file name: enroll.war
> at 
> org.apache.catalina.core.StandardHostDeployer.install(Standard
> HostDeployer.java:250)
> at 
> org.apache.catalina.cluster.deploy.FarmWarDeployer.install(Far
> mWarDeployer.java:196)
> at 
> org.apache.catalina.cluster.deploy.FarmWarDeployer.fileModifie
> d(FarmWarDeployer.java:261)
> at 
> org.apache.catalina.cluster.deploy.WarWatcher.run(WarWatcher.java:93)
> at java.lang.Thread.run(Thread.java:534)
> Sep 17, 2004 2:08:59 PM 
> org.apache.catalina.core.StandardHostDeployer install
> INFO: Installing web application at context path /enroll from 
> URL file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll
> 
> 
> 
> 
> Creating ClusterManager for context /enroll using class 
> org.apache.catalina.cluster.session.DeltaManager
> *** END
> 
> 
> I tried searching the web and the archives for this list but 
> no luck finding anything informative. How should this be 
> setup? My 3 instances run on 3 different machines. The 
> cluster itself seems to run fine (I get member 
> added/disappeared log messages and no errors).
> 
> All this is running on Red Hat Enterprise / JDK 1.4.2_03-b02 
> / Tomcat 5.0.27
> 
> 
> thanks
> Rob
> 

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



cluster FarmWarDeployer

2004-09-17 Thread Rob van Oostrum
I have a Deployer set up like so:



There's 2 other nodes in the cluster. The server.xml for those 2 doesn't contain this 
element (should it?).

When I drop a war-file (enroll.war) into the watch directory, it gets picked up and 
deployed to that node, but the following error shows up in catalina.out and there's no 
deployment to the other 2 nodes (and nothing in their logs):


*** BEGIN
INFO: Installing web application at context path /enroll from URL 
file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll.war
Sep 17, 2004 2:08:55 PM org.apache.catalina.cluster.deploy.FarmWarDeployer fileModified
SEVERE: Unable to install WAR file
java.lang.IllegalArgumentException: Context path /enroll must match the directory or 
WAR file name: enroll.war
at 
org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:250)
at 
org.apache.catalina.cluster.deploy.FarmWarDeployer.install(FarmWarDeployer.java:196)
at 
org.apache.catalina.cluster.deploy.FarmWarDeployer.fileModified(FarmWarDeployer.java:261)
at org.apache.catalina.cluster.deploy.WarWatcher.run(WarWatcher.java:93)
at java.lang.Thread.run(Thread.java:534)
Sep 17, 2004 2:08:59 PM org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /enroll from URL 
file:/usr/local/jakarta-tomcat-5.0.27/webapps/enroll




Creating ClusterManager for context /enroll using class 
org.apache.catalina.cluster.session.DeltaManager
*** END


I tried searching the web and the archives for this list but no luck finding anything 
informative. How should this be setup? My 3 instances run on 3 different machines. The 
cluster itself seems to run fine (I get member added/disappeared log messages and no 
errors).

All this is running on Red Hat Enterprise / JDK 1.4.2_03-b02 / Tomcat 5.0.27


thanks
Rob


RE: Autodeploy problems in 5.0.27

2004-09-17 Thread Kaiser, Paul

> Am I wrong to think this should work? Have I left out a 
> necessary config step?

I forgot to create an empty webapps directory in CATALINA_BASE.



--
Notice:  This e-mail message, together with any attachments, contains information of 
Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or 
its affiliates (which may be known outside the United States as Merck Frosst, Merck 
Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary 
copyrighted and/or legally privileged. It is intended solely for the use of the 
individual or entity named on this message.  If you are not the intended recipient, 
and have received this message in error, please notify us immediately by reply e-mail 
and then delete it from your system.
--

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



performance problem

2004-09-17 Thread JEsterh
I have an apache/tomcat environment that is experiencing performance 
problems.

My production environment has apache on one win2k box, and the two tomcat 
instances on another win 2k box. 

When I load test the my application directly against either of the tomcat 
instances, I get about 150 req/s. When I test with apache in front, I get 
10 req/s. This was with apache server temporarily placed on same network 
segment as tomcat box.

I recreated the production setup on a couple of developer workstations 
(slightly slower hardware than the production environment), and got > 70 
req/s.

Apache and tomcat conf files are essentially identical in both 
environments.

Does anyone have any clues?

Re: Class Loading question

2004-09-17 Thread QM
On Fri, Sep 17, 2004 at 01:49:51PM -0400, Robert Bateman wrote:
: Some where in the code I think I've messed up a call because the code I'm 
: invoking is failing.  The problem is, the message I'm getting isn't telling 
: me what I specified wrong.

Specifically, what is your code, and what message do you get?


: What I'd like to do is have the system tell me 
: what classes as being loaded.  With stand alone Java code, I specify 
: -verbose:class.  Is there an easy way to do this directly in Tomcat?  Or do I 
: use -verbose:class?

Why not try it?

-QM

-- 

software  -- http://www.brandxdev.net
tech news -- http://www.RoarNetworX.com


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



RE: Autodeploy problems in 5.0.27

2004-09-17 Thread Shapira, Yoav

Hi,
As the RUNNING.txt file include with the distribution says, webapps and
several other directories are calculated relative to $CATALINA_BASE, not
$CATALINA_HOME, when the two are different.  So you're sort of doing
this backwards.

Check section 4 of the RUNNING.txt file:
http://cvs.apache.org/viewcvs.cgi/jakarta-tomcat-5/RUNNING.txt?rev=1.6&o
nly_with_tag=TOMCAT_5_0&view=markup.

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: Kaiser, Paul [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 1:59 PM
>To: '[EMAIL PROTECTED]'
>Subject: Autodeploy problems in 5.0.27
>
>I'm running into a problem with the auto-deploy mechanism (maybe the
wrong
>term... the mechanism that deploys contexts based on a external context
>configuration XML file in
$CATALINA_BASE/conf//).
>
>I started with an out-of-the-box install of 5.0.27 on SuSE 8.2.
>
>I set JAVA_HOME, then run startup.sh.
>
>Everything looks okay.
>
>I then create a directory (call it ~/catbase) and
>  - copy $CATALINA_HOME/conf to catbase/conf
>  - create empty directories in catbase (logs, work, temp,
shared/classes,
>shared/lib)
>
>I set CATALINA_BASE=~/catbase and run startup.sh.
>
>I'm expecting the same result as when CATALINA_BASE = CATALINA_HOME.
>
>I discover that none of the contexts in catbase/conf/Catalina/localhost
get
>deployed. There is no indication in the Catalina log file that anything
is
>wrong.
>
>Am I wrong to think this should work? Have I left out a necessary
config
>step?
>
>Thanks in advance.
>
>Paul
>
>
>---

>---
>Notice:  This e-mail message, together with any attachments, contains
>information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station,
New
>Jersey, USA 08889), and/or its affiliates (which may be known outside
the
>United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan,
as
>Banyu) that may be confidential, proprietary copyrighted and/or legally
>privileged. It is intended solely for the use of the individual or
entity
>named on this message.  If you are not the intended recipient, and have
>received this message in error, please notify us immediately by reply
e-
>mail and then delete it from your system.
>---

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




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Autodeploy problems in 5.0.27

2004-09-17 Thread Kaiser, Paul
I'm running into a problem with the auto-deploy mechanism (maybe the wrong
term... the mechanism that deploys contexts based on a external context
configuration XML file in $CATALINA_BASE/conf//).

I started with an out-of-the-box install of 5.0.27 on SuSE 8.2.

I set JAVA_HOME, then run startup.sh.

Everything looks okay.

I then create a directory (call it ~/catbase) and
  - copy $CATALINA_HOME/conf to catbase/conf
  - create empty directories in catbase (logs, work, temp, shared/classes,
shared/lib)

I set CATALINA_BASE=~/catbase and run startup.sh.

I'm expecting the same result as when CATALINA_BASE = CATALINA_HOME.

I discover that none of the contexts in catbase/conf/Catalina/localhost get
deployed. There is no indication in the Catalina log file that anything is
wrong.

Am I wrong to think this should work? Have I left out a necessary config
step?

Thanks in advance.

Paul


--
Notice:  This e-mail message, together with any attachments, contains information of 
Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New Jersey, USA 08889), and/or 
its affiliates (which may be known outside the United States as Merck Frosst, Merck 
Sharp & Dohme or MSD and in Japan, as Banyu) that may be confidential, proprietary 
copyrighted and/or legally privileged. It is intended solely for the use of the 
individual or entity named on this message.  If you are not the intended recipient, 
and have received this message in error, please notify us immediately by reply e-mail 
and then delete it from your system.
--

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



RE: Referencias of utilization of the Tomcat by the world

2004-09-17 Thread Shapira, Yoav

Hi,
We have a very very partial list on the FAQ
(http://jakarta.apache.org/tomcat/faq/misc.html#productionStories).  As
it says, many production users can't divulge that information due to
company policy.

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 1:36 PM
>To: [EMAIL PROTECTED]
>Subject: Referencias of utilization of the Tomcat by the world
>
>It would like know which companies are utilizing the tomcat in
large-scale
>systems.
>
>Filipe Giovany



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Class Loading question

2004-09-17 Thread Robert Bateman
I'm playing with some code that loads classes at run time.

Some where in the code I think I've messed up a call because the code I'm 
invoking is failing.  The problem is, the message I'm getting isn't telling 
me what I specified wrong.  What I'd like to do is have the system tell me 
what classes as being loaded.  With stand alone Java code, I specify 
-verbose:class.  Is there an easy way to do this directly in Tomcat?  Or do I 
use -verbose:class?

Thanks!

Bob


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



Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Xeth Waxman
Worked perfectly - tomcat users get soup :)


On Fri, 17 Sep 2004 11:52:48 -0400, Shapira, Yoav <[EMAIL PROTECTED]> wrote:
> 
> Hi,
> 
> >login.jsp in /webapps/ChargeCard (let's call it
> >).  I have moved my servlets from
> >/webapps/ROOT/WEB-INF/classes to
> >/WEB-INF/classes.  So my question is twofold:
> >
> >1) from my jsp, how do I invoke the servlet in it's new location?
> >Prior I was using:
> > >action="servlet/com.gcc.creditcard/CCLogin"> but that no longer works,
> >and it doesn't work without the servlet prefix either.
> 
> To /WEB-INF/web.xml add
> 
> 
>   CCLoginServlet
>   com.gcc.creditcard.CCLogin
> 
> 
>   CCLoginServlet
>   /CCLogin
> 
> 
> Modify the  tag to
> 
> 
> 
> 
> Yoav
> 
> This e-mail, including any attachments, is a confidential business communication, 
> and may contain information that is confidential, proprietary and/or privileged.  
> This e-mail is intended only for the individual(s) to whom it is addressed, and may 
> not be saved, copied, printed, disclosed or used by anyone else.  If you are not 
> the(an) intended recipient, please immediately delete this e-mail from your computer 
> system and notify the sender.  Thank you.
> 
> 



-- 
Xeth Waxman
[EMAIL PROTECTED]

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



Referencias of utilization of the Tomcat by the world

2004-09-17 Thread filipe
It would like know which companies are utilizing the tomcat in large-scale 
systems. 

Filipe Giovany

Re: Using custom CoyoteResponse(Facade)

2004-09-17 Thread Tim Funk
A Valve is just like a Servlet Filter but tomcat specific. They are run early 
enough in the request lifecycle that you can change different behaviors of 
how things work. But a Valve also has access to tomcat's internals, something 
servlet filters don't have.

http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/valve.html
-Tim
Markus Krogemann wrote:
Thanks Yoav, Martin, Tim
You're right, ServletApi's Filter appears to be a simple solution. I 
somehow didn't expect that I could just do something like:

response = new ResponseWrapper(response)
in the doFilter method, but of course it works, because the wrapper is 
just passed on to the next elements in the chain, I guess.

Our design is not that nice, I know. I would much prefer to use only one 
tomcat but that is unfortunately not an option right now and sessions 
will have to be maintained independently on both servers.

Tim: What are these valves you mentioned?
 
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Shapira, Yoav

Hi,

>login.jsp in /webapps/ChargeCard (let's call it
>).  I have moved my servlets from
>/webapps/ROOT/WEB-INF/classes to
>/WEB-INF/classes.  So my question is twofold:
>
>1) from my jsp, how do I invoke the servlet in it's new location?
>Prior I was using:
>action="servlet/com.gcc.creditcard/CCLogin"> but that no longer works,
>and it doesn't work without the servlet prefix either.

To /WEB-INF/web.xml add


  CCLoginServlet
  com.gcc.creditcard.CCLogin


  CCLoginServlet
  /CCLogin


Modify the  tag to


Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Xeth Waxman
I am sorry, I don't think I am explaining well.  My english
comprehension is still new, so I am doing a poor job.  I have jsp page
login.jsp in /webapps/ChargeCard (let's call it
).  I have moved my servlets from
/webapps/ROOT/WEB-INF/classes to
/WEB-INF/classes.  So my question is twofold:

1) from my jsp, how do I invoke the servlet in it's new location? 
Prior I was using:
 but that no longer works,
and it doesn't work without the servlet prefix either.

2) Once I am sucessfully able to invoke CCLogin, how do I dispatch to
my second jsp (keeping my session variables)?  I think Yoav answered
this for me though - now that the servlets are in same context, I
should be able to use
RequestDispatcher rd = 
getServletContext().getRequestDispatcher("/CCEntry.jsp");

But I can't test this theory until first issue is resolved.  I thank
everyone (especially Yoav, who is my new java superhero) for your
patience with me!  Tomcat user list is the best!

--Xeth


On Fri, 17 Sep 2004 11:26:50 -0400, Shapira, Yoav <[EMAIL PROTECTED]> wrote:
> 
> Hi,
> Declare a  and  element for every one of your
> servlets in web.xml.  Use the url-pattern from the servlet-mapping as
> the argument for getRequestDispatcher().
> 
> Yoav Shapira
> Millennium Research Informatics
> 
> 
> 
> 
> >-Original Message-
> >From: Xeth Waxman [mailto:[EMAIL PROTECTED]
> >Sent: Friday, September 17, 2004 11:25 AM
> >To: Shapira, Yoav
> >Cc: Tomcat Users List
> >Subject: Re: Traversing up a directory using RequestDispatcher
> >
> >OK, so apparently I am doing a cross context request dispatcher call,
> >which is bad.  So I shouldn't do that.  Assuming my app is under
> >c:\jakarta\webapps\ChargeCard (context is /ChargeCard), that means my
> >servlets should be under
> >c:\jakarta\webapps\ChargeCard\WEB-INF\classes, correct?  If that is
> >the case, how do I get my pages to invoke my servlets?  To date I have
> >been putting my servlets in c:\jakarta\webapps\ROOT\WEB-INF\classes,
> >and invoking them with /servlet/com.gcc.creditcard.DoLogin.  Now that
> >my classes are under /ChargeCard, invoking them with
> >/servlet/com.gcc.creditcard.DoLogin says that they're not found, and
> >likewise with just com.gcc.creditcard/DoLogin.  I'm sure their's a
> >very simple answer found somewhere I just don't know where to look, so
> >if you feel like making me work to get the answer feel free to just
> >point out the resource I should be viewing (I can't find anything in
> >the tomcat docs).
> >
> >Thanks!
> >
> >--Xeth
> >
> >
> >On Fri, 17 Sep 2004 08:17:07 -0400, Shapira, Yoav
> <[EMAIL PROTECTED]>
> >wrote:
> >>
> >> Hi,
> >> First of all, Xeth is the best name I've seen in a long time -- cool!
> >>
> >>
> >>
> >> >I have a bizarre issue.  Using Tomcat 5.0.12, I have an application
> in
> >> >the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
> >> >After loggin in, I am trying to forward a request to jsp page in
> that
> >> >directory.  However, RequestDispatcher apparently uses the directory
> >> >C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I
> need
> >> >to go up a directory in my forward request (something like url =
> >> >"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
> >> >to start off the url, so I can't use the ../ start to go up a
> >> >directory.  Does anyone have an idea how I would do this?  I tried
> url
> >> >= "/../ChargeCard/index.jsp";, but that results in a
> >> >NullPointerException being thrown.  All help is appreciated!
> >>
> >> The RequestDispatcher's behavior is constrained by the Servlet
> >> Specification.  Its JavaDoc has an explanation on how it resolves
> >> relative links: the leading slash for the getRequestDispatcher call
> is
> >> not really absolute, it's relative to the webapp's docBase.
> >>
> >> There's no reason Tomcat would use ROOT as the docBase, unless you're
> >> actually in the root webapp.  What is the docBase for your webapp?
> >> (Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
> >> under it, unless you've explicitly defined a Context with the webapp
> >> docBase) (in which case, if you kept the default Host appBase, you
> have
> >> a bad configuration).
> >>
> >> Yoav
> >>
> >> This e-mail, including any attachments, is a confidential business
> >communication, and may contain information that is confidential,
> >proprietary and/or privileged.  This e-mail is intended only for the
> >individual(s) to whom it is addressed, and may not be saved, copied,
> >printed, disclosed or used by anyone else.  If you are not the(an)
> intended
> >recipient, please immediately delete this e-mail from your computer
> system
> >and notify the sender.  Thank you.
> >>
> >>
> >
> >
> >
> >--
> >Xeth Waxman
> >[EMAIL PROTECTED]
> 
> 
> 
> 
> This e-mail, including any attachments, is a confidential business communication, 
> and may contain information that is confidential, proprietary and/or privileged.  
> This e-mail is int

Monitoring different Contexts with JMX MBean

2004-09-17 Thread Stefan Fleiter
Hi,
I try to do my first steps with the java server platform and have chosen 
Tomcat for this.

I wrote a class which is able to Monitor the database pools of a Context
when beeing called out of it.
I only had to use JNDI to iterate over "comp/env/jdbc" and cast the 
DataSource instances to a BasicDataSource.

Now I want to implement an MBean which is able to monitor the pools of 
all Contexts of Tomcat.

I even don't know whether this is possible, but hope to get some help.
Now my concrete questions:
 - Can I somehow change the Context my code is executed in?
 - If not: How do I get instances of all JNDI DataSource for all
   Contexts ?
 - Where do I have to put my MBean .class-files?
   In the webapps dir or somewhere else?
 - How can I make Tomcat register my MBeans at startup?
Thanks a lot in advance,
Stefan
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread John Villar
You have to enable the invoker servlet, this question comes up *A LOT* 
in this mailing list xeth try the better, cleaner, securer way 
do a servlet mapping in your web.xml file

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Xeth Waxman escribió:
OK, so apparently I am doing a cross context request dispatcher call,
which is bad.  So I shouldn't do that.  Assuming my app is under
c:\jakarta\webapps\ChargeCard (context is /ChargeCard), that means my
servlets should be under
c:\jakarta\webapps\ChargeCard\WEB-INF\classes, correct?  If that is
the case, how do I get my pages to invoke my servlets?  To date I have
been putting my servlets in c:\jakarta\webapps\ROOT\WEB-INF\classes,
and invoking them with /servlet/com.gcc.creditcard.DoLogin.  Now that
my classes are under /ChargeCard, invoking them with
/servlet/com.gcc.creditcard.DoLogin says that they're not found, and
likewise with just com.gcc.creditcard/DoLogin.  I'm sure their's a
very simple answer found somewhere I just don't know where to look, so
if you feel like making me work to get the answer feel free to just
point out the resource I should be viewing (I can't find anything in
the tomcat docs).
Thanks!
--Xeth
On Fri, 17 Sep 2004 08:17:07 -0400, Shapira, Yoav <[EMAIL PROTECTED]> wrote:
 

Hi,
First of all, Xeth is the best name I've seen in a long time -- cool!

   

I have a bizarre issue.  Using Tomcat 5.0.12, I have an application in
the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
After loggin in, I am trying to forward a request to jsp page in that
directory.  However, RequestDispatcher apparently uses the directory
C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
to go up a directory in my forward request (something like url =
"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
to start off the url, so I can't use the ../ start to go up a
directory.  Does anyone have an idea how I would do this?  I tried url
= "/../ChargeCard/index.jsp";, but that results in a
NullPointerException being thrown.  All help is appreciated!
 

The RequestDispatcher's behavior is constrained by the Servlet
Specification.  Its JavaDoc has an explanation on how it resolves
relative links: the leading slash for the getRequestDispatcher call is
not really absolute, it's relative to the webapp's docBase.
There's no reason Tomcat would use ROOT as the docBase, unless you're
actually in the root webapp.  What is the docBase for your webapp?
(Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
under it, unless you've explicitly defined a Context with the webapp
docBase) (in which case, if you kept the default Host appBase, you have
a bad configuration).
Yoav
This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.
   


 


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

Re: [ot] something similar to phps ?

2004-09-17 Thread John Villar
It isn't a bad idea at all you could use one of those in-browser 
editors to aid in the editing, and the preview would be in another 
frame. dumping  dreamweaver never sounded so good... LOL...

now, speaking seriously, that could be a good alternative to 
"noteppading", "viing" or "emacsing" and then going to the browser 
window... why leave the window if you can edit it right there. :D my 
marketing skills kicks a** LOL

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Mike Curwen escribió:
Ok, I'll bite.
Isn't this what IDE's are for? Browser as IDE? no thanks.  ;)
 

-Original Message-
From: John Villar [mailto:[EMAIL PROTECTED] 
Sent: Friday, September 17, 2004 9:39 AM
To: Tomcat Users List
Subject: Re: [ot] something similar to phps ?

Expanding a little more the idea, you could enabled the 
servlet output 
to receive modifications to the jsp page and ave it ot the 
corresponding 
jsp *grin* and that way you integrate nice output with editing 
capabilities

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

John Villar escribió:
   

Also, you could do a Servlet that serves all the .jsps 
 

files that take
   

the corresponding jsp file and outputs it on html format, coloured 
with graphics, etc

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Shapira, Yoav escribió:
 

Hi,

   

would it be of any use to anyone for the development of something
 
 

similar
   

to phps in php?  where you can rename a file to .jsps for 
 

instance 
   

and
 
 

it
   

would show you the code line for line and have pretty colours...
 
 

Something like that is trivial to do already -- just serve the JSP 
with content-type text/plain from a streaming servlet like 
   

Tomcat's 
   

DefaultServlet.  That's not to say something like this 
   

isn't useful: 
   

it's a nice thing to have (although it would have to be 
   

turned off on 
   

production systems, because it's a security risk).
Yoav

This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential, 
proprietary and/or privileged.  This e-mail is intended 
   

only for the 
   

individual(s) to whom it is addressed, and may not be 
   

saved, copied, 
   

printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail 
   

from your 
   

computer system and notify the sender.  Thank you.

   

-
   

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

[EMAIL PROTECTED]
   


   

-
 

--
   

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

   


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

 


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

DIGEST Authentication question

2004-09-17 Thread Alexander Fishchuk
Hi guys.
I'm having trouble setting up DIGEST authentication for single webapp in 
Tomcat 5.0.27.

does anyone have done it successfully
I'd appreciate some guidance in this area

Alex

Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Xeth Waxman
OK, so apparently I am doing a cross context request dispatcher call,
which is bad.  So I shouldn't do that.  Assuming my app is under
c:\jakarta\webapps\ChargeCard (context is /ChargeCard), that means my
servlets should be under
c:\jakarta\webapps\ChargeCard\WEB-INF\classes, correct?  If that is
the case, how do I get my pages to invoke my servlets?  To date I have
been putting my servlets in c:\jakarta\webapps\ROOT\WEB-INF\classes,
and invoking them with /servlet/com.gcc.creditcard.DoLogin.  Now that
my classes are under /ChargeCard, invoking them with
/servlet/com.gcc.creditcard.DoLogin says that they're not found, and
likewise with just com.gcc.creditcard/DoLogin.  I'm sure their's a
very simple answer found somewhere I just don't know where to look, so
if you feel like making me work to get the answer feel free to just
point out the resource I should be viewing (I can't find anything in
the tomcat docs).

Thanks!

--Xeth


On Fri, 17 Sep 2004 08:17:07 -0400, Shapira, Yoav <[EMAIL PROTECTED]> wrote:
> 
> Hi,
> First of all, Xeth is the best name I've seen in a long time -- cool!
> 
> 
> 
> >I have a bizarre issue.  Using Tomcat 5.0.12, I have an application in
> >the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
> >After loggin in, I am trying to forward a request to jsp page in that
> >directory.  However, RequestDispatcher apparently uses the directory
> >C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
> >to go up a directory in my forward request (something like url =
> >"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
> >to start off the url, so I can't use the ../ start to go up a
> >directory.  Does anyone have an idea how I would do this?  I tried url
> >= "/../ChargeCard/index.jsp";, but that results in a
> >NullPointerException being thrown.  All help is appreciated!
> 
> The RequestDispatcher's behavior is constrained by the Servlet
> Specification.  Its JavaDoc has an explanation on how it resolves
> relative links: the leading slash for the getRequestDispatcher call is
> not really absolute, it's relative to the webapp's docBase.
> 
> There's no reason Tomcat would use ROOT as the docBase, unless you're
> actually in the root webapp.  What is the docBase for your webapp?
> (Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
> under it, unless you've explicitly defined a Context with the webapp
> docBase) (in which case, if you kept the default Host appBase, you have
> a bad configuration).
> 
> Yoav
> 
> This e-mail, including any attachments, is a confidential business communication, 
> and may contain information that is confidential, proprietary and/or privileged.  
> This e-mail is intended only for the individual(s) to whom it is addressed, and may 
> not be saved, copied, printed, disclosed or used by anyone else.  If you are not 
> the(an) intended recipient, please immediately delete this e-mail from your computer 
> system and notify the sender.  Thank you.
> 
> 



-- 
Xeth Waxman
[EMAIL PROTECTED]

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



RE: [ot] something similar to phps ?

2004-09-17 Thread Mike Curwen
Ok, I'll bite.

Isn't this what IDE's are for? Browser as IDE? no thanks.  ;)


> -Original Message-
> From: John Villar [mailto:[EMAIL PROTECTED] 
> Sent: Friday, September 17, 2004 9:39 AM
> To: Tomcat Users List
> Subject: Re: [ot] something similar to phps ?
> 
> 
> Expanding a little more the idea, you could enabled the 
> servlet output 
> to receive modifications to the jsp page and ave it ot the 
> corresponding 
> jsp *grin* and that way you integrate nice output with editing 
> capabilities
> 
> John Villar
> Gerente de Proyectos
> Computadores Flor Hard Soft 2058 C.A.
> www.florhard.com
> 
> 
> 
> John Villar escribió:
> 
> > Also, you could do a Servlet that serves all the .jsps 
> files that take
> > the corresponding jsp file and outputs it on html format, coloured 
> > with graphics, etc
> >
> > John Villar
> > Gerente de Proyectos
> > Computadores Flor Hard Soft 2058 C.A.
> > www.florhard.com
> >
> >
> >
> > Shapira, Yoav escribió:
> >
> >> Hi,
> >>
> >>  
> >>
> >>> would it be of any use to anyone for the development of something
> >>>   
> >>
> >> similar
> >>  
> >>
> >>> to phps in php?  where you can rename a file to .jsps for 
> instance 
> >>> and
> >>>   
> >>
> >> it
> >>  
> >>
> >>> would show you the code line for line and have pretty colours...
> >>>   
> >>
> >>
> >> Something like that is trivial to do already -- just serve the JSP 
> >> with content-type text/plain from a streaming servlet like 
> Tomcat's 
> >> DefaultServlet.  That's not to say something like this 
> isn't useful: 
> >> it's a nice thing to have (although it would have to be 
> turned off on 
> >> production systems, because it's a security risk).
> >>
> >> Yoav
> >>
> >>
> >>
> >> This e-mail, including any attachments, is a confidential business
> >> communication, and may contain information that is confidential, 
> >> proprietary and/or privileged.  This e-mail is intended 
> only for the 
> >> individual(s) to whom it is addressed, and may not be 
> saved, copied, 
> >> printed, disclosed or used by anyone else.  If you are not the(an) 
> >> intended recipient, please immediately delete this e-mail 
> from your 
> >> computer system and notify the sender.  Thank you.
> >>
> >>
> >> 
> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: 
> [EMAIL PROTECTED]
> >>
> >>
> >>
> >>  
> >>
> >
> >-
> --
> >-
> >
> >-
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> 
> 


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



Re: Problem configuring a global resource to be linked from Context elements ....

2004-09-17 Thread Jonathan Rengifo
Thanks to all.

The resource link problem has been solve with this recommendations you
gave me, at the end I copied my database .jar to common/lib so all web
application and the server can see it, what seems strange to me is
that it used to work on Tomcat 4 without any copy task, but the
solution you gave me goes according to the ClassLoader documentation
so you were just rigth..

Thanks to all of you...

Regards

Jonathan M. Rengifo



On Fri, 17 Sep 2004 08:10:13 -0400, Shapira, Yoav <[EMAIL PROTECTED]> wrote:
> 
> Hi,
> 
> >I think it is because of the way Tomcat classloaders work. Classes in
> >common\lib or common\classes cannot see classes in WEB-INF\lib. DBCP
> looks
> >for the JDBC Driver class and it cannot read it from WEB-INF\lib. This
> is
> >the answer I got when I had similar problem. For further info on this
> you
> >need help from experts in this list. If the problem is not solved
> please
> >reply.
> 
> Your thought is right -- the above is a good description.  The
> ClassLoader hierarchy is just that, a hierarchy, meaning different
> visibility for different classloaders.  It's described in detail the
> ClassLoader how-to, which I might rank at the #1 document all developers
> using Tomcat should read and understand.
> 
> Yoav
> 
> 
> 
> 
> This e-mail, including any attachments, is a confidential business communication, 
> and may contain information that is confidential, proprietary and/or privileged.  
> This e-mail is intended only for the individual(s) to whom it is addressed, and may 
> not be saved, copied, printed, disclosed or used by anyone else.  If you are not 
> the(an) intended recipient, please immediately delete this e-mail from your computer 
> system and notify the sender.  Thank you.
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

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



Re: Tomcat 5.0.28 form post encoding problem

2004-09-17 Thread Martin Schaefer

Again (there was a similar problem today), it might help to run tomcat
with -Dfile.encoding=ISO-8859-2
Or better use UTF-8 if applicable...


Krzysztof Cieniuch <[EMAIL PROTECTED]> schrieb am 17.09.2004, 16:42:36:
> Hi I've got problem (again)  with encoding.
> Yes I've read all bugs  23929 25360 etc.
> No I didn't read www.anassina.com/struts/i18n/i18n.html because I can't
> reach that site don't know why server down or my connection broken???
> 
> I've got two jsp pages index.jsp and out.jsp
> On index.jsp I have simple form with one text input field (the name of this
> text field is "user")
> on out.jsp  page  I read that input with line like this
> request.getParameter("user")
> and of course when I use some national characters i.e not iso-8859-1 then I
> get ??? on the out.jsp page
> when i use
> new
> String(request.getParameter("user").getBytes("ISO-8859-1"),"ISO-8859-2");
> everything is ok
> I've tried everything :
> -setting encoding
>-- in html meta tag
>-- in jsp page tag
>-- i use method Post in that  form
> 
> nothing works the browser allways sends data encoded in ISO-8859-1
> so using through all my pages syntax like this
> new
> String(request.getParameter("user").getBytes("ISO-8859-1"),"ISO-8859-2");
> is the only solution ??
> I would like to use jsp and struts tags and then this is not an option
> bean:write tag also gives ??? on national characters
> I've changed server.xml connector  part and added URIencoding="ISO-8859-2"
> and useBodyEncodingForURI=true this either doesn't help
> and since I'm sending form data in body part of the request how should this
> help anyhow
> 
> HELP the lost newbi :-)))
> 
> KC
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
Martin Schaefer
NAXOS Software Solutions GmbH i.G.
Herrenstr. 1
69502 Hemsbach
Germany
 
Phone:+49 (0) 6201 49298-2
Mobile: +49 (0) 172 6269246
Fax: +49 (0) 6201 49298-1
Mail: [EMAIL PROTECTED]

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



Re: Tomcat fine within the LAN, but invisible from without

2004-09-17 Thread Hassan Schroeder
Lee Hoffner wrote:
1) does host/dig/nslookup resolve 'www.mydomain.com' to your address?

I don't have a DNS server here, just a /etc/hosts file. www.mydomain.com is 
listed in the hosts file at 192.168.1.5
nslookup finds www.mydomain.com at the public IP provided by my ISP.
So this is broken; what OS are you running? First you need to have
nslookup return your local address; do you have an /etc/nsswitch.conf
file or equivalent? Configure your system to look at /etc/hosts for
name resolution, and then try doing a simple `ping\telnet\ssh` to
my.domain.com. Until you can do that, don't even worry about Tomcat. :-)
Shorewall
No idea what that is. Is it running on the server with Tomcat? Or
on a router/gateway machine? Or???
But you need to fix your "inside" access first...
HTH,
--
Hassan Schroeder - [EMAIL PROTECTED]
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com
  dream.  code.

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


Re: Error page problem

2004-09-17 Thread Martin_Schaefer

You probably focused on the rest of your application and didn't notice
that the exception occurs in the error page itself.

"ukr.net" <[EMAIL PROTECTED]> schrieb am 17.09.2004, 16:30:25:
> Hello!
> 
> Tomcat 5.0.24 is used. Context contains ordinary jsp and Axis library.
> 
> There is error page, defined in web.xml:
> 
> 
> 500
> /errorpage.jsp
> 
> 
> Everething works fine, but when exception occurs in web services, the following 
> records are writen to localhost_log:
> 
> 2004-09-17 17:05:04 [EMAIL PROTECTED]: Exception Processing ErrorPage[errorCode=500, 
> location=/errorpage.jsp]
> java.lang.IllegalStateException
>  at org.apache.coyote.Response.reset(Response.java:296)
>  at org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:631)
>  at org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:887)
>  at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:389)
>  at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:301)
>  at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:147)
>  at 
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>  at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
>  at 
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
>  at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:535)
>  at 
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
>  at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>  at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>  at 
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>  at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>  at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>  at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:793)
>  at 
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:702)
>  at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:571)
>  at 
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:644)
>  at java.lang.Thread.run(Thread.java:534)
> 
> I do not want to see such records in log file. Is it possible to configure tomcat 
> somehow in order to remove this logging?
> 
> Any help would be appreciated.
> 
> Thank you,
> Igor
-- 
Martin Schaefer
NAXOS Software Solutions GmbH i.G.
Herrenstr. 1
69502 Hemsbach
Germany
 
Phone:+49 (0) 6201 49298-2
Mobile: +49 (0) 172 6269246
Fax: +49 (0) 6201 49298-1
Mail: [EMAIL PROTECTED]

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



Tomcat 5.0.28 form post encoding problem

2004-09-17 Thread Krzysztof Cieniuch
Hi I've got problem (again)  with encoding.
Yes I've read all bugs  23929 25360 etc.
No I didn't read www.anassina.com/struts/i18n/i18n.html because I can't
reach that site don't know why server down or my connection broken???

I've got two jsp pages index.jsp and out.jsp
On index.jsp I have simple form with one text input field (the name of this
text field is "user")
on out.jsp  page  I read that input with line like this
request.getParameter("user")
and of course when I use some national characters i.e not iso-8859-1 then I
get ??? on the out.jsp page
when i use
new
String(request.getParameter("user").getBytes("ISO-8859-1"),"ISO-8859-2");
everything is ok
I've tried everything :
-setting encoding
   -- in html meta tag
   -- in jsp page tag
   -- i use method Post in that  form

nothing works the browser allways sends data encoded in ISO-8859-1
so using through all my pages syntax like this
new
String(request.getParameter("user").getBytes("ISO-8859-1"),"ISO-8859-2");
is the only solution ??
I would like to use jsp and struts tags and then this is not an option
bean:write tag also gives ??? on national characters
I've changed server.xml connector  part and added URIencoding="ISO-8859-2"
and useBodyEncodingForURI=true this either doesn't help
and since I'm sending form data in body part of the request how should this
help anyhow

HELP the lost newbi :-)))

KC


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



Re: [ot] something similar to phps ?

2004-09-17 Thread John Villar
Expanding a little more the idea, you could enabled the servlet output 
to receive modifications to the jsp page and ave it ot the corresponding 
jsp *grin* and that way you integrate nice output with editing 
capabilities

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

John Villar escribió:
Also, you could do a Servlet that serves all the .jsps files that take 
the corresponding jsp file and outputs it on html format, coloured 
with graphics, etc

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Shapira, Yoav escribió:
Hi,
 

would it be of any use to anyone for the development of something
  
similar
 

to phps in php?  where you can rename a file to .jsps for instance and
  
it
 

would show you the code line for line and have pretty colours...
  

Something like that is trivial to do already -- just serve the JSP with
content-type text/plain from a streaming servlet like Tomcat's
DefaultServlet.  That's not to say something like this isn't useful:
it's a nice thing to have (although it would have to be turned off on
production systems, because it's a security risk).
Yoav

This e-mail, including any attachments, is a confidential business 
communication, and may contain information that is confidential, 
proprietary and/or privileged.  This e-mail is intended only for the 
individual(s) to whom it is addressed, and may not be saved, copied, 
printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your 
computer system and notify the sender.  Thank you.

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

 


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

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

RE: Error page problem

2004-09-17 Thread Shapira, Yoav

Hi,
IllegalStateExceptions are serious enough that they shouldn't be ignored
by removing them from the logs.  You CAN configure tomcat's logging to
not log these, the directions are in the FAQ's section on logging, but
that's a terrible idea.  As is the general idea of removing exceptions
from your logs.

Instead, focus on finding the root cause for the exception and fixing
it.

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: ukr.net [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 10:30 AM
>To: [EMAIL PROTECTED]
>Subject: Error page problem
>
>Hello!
>
>Tomcat 5.0.24 is used. Context contains ordinary jsp and Axis library.
>
>There is error page, defined in web.xml:
>
>
>500
>/errorpage.jsp
>
>
>Everething works fine, but when exception occurs in web services, the
>following records are writen to localhost_log:
>
>2004-09-17 17:05:04 [EMAIL PROTECTED]:
>Exception Processing ErrorPage[errorCode=500, location=/errorpage.jsp]
>java.lang.IllegalStateException
> at org.apache.coyote.Response.reset(Response.java:296)
> at
org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:631)
> at
org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:887)
> at
>org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.jav
a:38
>9)
> at
>org.apache.catalina.core.StandardHostValve.status(StandardHostValve.jav
a:30
>1)
> at
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.jav
a:14
>7)
> at
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveC
onte
>xt.java:104)
> at
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.jav
a:11
>7)
> at
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveC
onte
>xt.java:102)
> at
>org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:53
5)
> at
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveC
onte
>xt.java:102)
> at
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:
520)
> at
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve
.jav
>a:109)
> at
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveC
onte
>xt.java:104)
> at
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:
520)
> at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
> at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
> at
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:7
93)
> at
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process
Conn
>ection(Http11Protocol.java:702)
> at
>org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:5
71)
> at
>org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPoo
l.ja
>va:644)
> at java.lang.Thread.run(Thread.java:534)
>
>I do not want to see such records in log file. Is it possible to
configure
>tomcat somehow in order to remove this logging?
>
>Any help would be appreciated.
>
>Thank you,
>Igor



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Re: [ot] something similar to phps ?

2004-09-17 Thread John Villar
Also, you could do a Servlet that serves all the .jsps files that take 
the corresponding jsp file and outputs it on html format, coloured with 
graphics, etc

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Shapira, Yoav escribió:
Hi,
 

would it be of any use to anyone for the development of something
   

similar
 

to phps in php?  where you can rename a file to .jsps for instance and
   

it
 

would show you the code line for line and have pretty colours...
   

Something like that is trivial to do already -- just serve the JSP with
content-type text/plain from a streaming servlet like Tomcat's
DefaultServlet.  That's not to say something like this isn't useful:
it's a nice thing to have (although it would have to be turned off on
production systems, because it's a security risk).
Yoav

This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

 


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

Error page problem

2004-09-17 Thread ukr.net
Hello!

Tomcat 5.0.24 is used. Context contains ordinary jsp and Axis library.

There is error page, defined in web.xml:


500
/errorpage.jsp


Everething works fine, but when exception occurs in web services, the following 
records are writen to localhost_log:

2004-09-17 17:05:04 [EMAIL PROTECTED]: Exception Processing ErrorPage[errorCode=500, 
location=/errorpage.jsp]
java.lang.IllegalStateException
 at org.apache.coyote.Response.reset(Response.java:296)
 at org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:631)
 at org.apache.coyote.tomcat5.CoyoteResponse.reset(CoyoteResponse.java:887)
 at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:389)
 at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:301)
 at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:147)
 at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
 at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
 at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
 at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:535)
 at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
 at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
 at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
 at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
 at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
 at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
 at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:793)
 at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:702)
 at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:571)
 at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:644)
 at java.lang.Thread.run(Thread.java:534)

I do not want to see such records in log file. Is it possible to configure tomcat 
somehow in order to remove this logging?

Any help would be appreciated.

Thank you,
Igor

RE: [ot] something similar to phps ?

2004-09-17 Thread Shapira, Yoav

Hi,

>would it be of any use to anyone for the development of something
similar
>to phps in php?  where you can rename a file to .jsps for instance and
it
>would show you the code line for line and have pretty colours...

Something like that is trivial to do already -- just serve the JSP with
content-type text/plain from a streaming servlet like Tomcat's
DefaultServlet.  That's not to say something like this isn't useful:
it's a nice thing to have (although it would have to be turned off on
production systems, because it's a security risk).

Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



[ot] something similar to phps ?

2004-09-17 Thread Alex

would it be of any use to anyone for the development of something similar
to phps in php?  where you can rename a file to .jsps for instance and it
would show you the code line for line and have pretty colours...




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



Re: Using custom CoyoteResponse(Facade)

2004-09-17 Thread Markus Krogemann
Thanks Yoav, Martin, Tim
You're right, ServletApi's Filter appears to be a simple solution. I 
somehow didn't expect that I could just do something like:

response = new ResponseWrapper(response)
in the doFilter method, but of course it works, because the wrapper is 
just passed on to the next elements in the chain, I guess.

Our design is not that nice, I know. I would much prefer to use only one 
tomcat but that is unfortunately not an option right now and sessions 
will have to be maintained independently on both servers.

Tim: What are these valves you mentioned?
Thanks again,
Markus
Shapira, Yoav wrote:
Hi,
Why not use an HttpServletResponseWrapper?  You can easily wrap whatever
responses you want with a Filter, and then implement the encodeURL
method however you want.
I think the design itself is cruising for a bruising, as is the case any
time you deviate from Servlet Spec mandates on session tracking, but I
imagine you already know that and have no choice.
Yoav Shapira
Millennium Research Informatics

-Original Message-
From: Markus Krogemann [mailto:[EMAIL PROTECTED]
Sent: Friday, September 17, 2004 8:32 AM
To: Tomcat Users List
Subject: Using custom CoyoteResponse(Facade)
Dear List,
I am having a hard time to figure out how I could fulfill a special
requirement in a current project.
I could use either tomcat 4.1.x or tomcat 5.0.x for this project, I
presume it doesn't make much difference in terms of possible solutions.
The project also uses struts (1.2.2) and here is the special
requirement: Instead of encoding URLs with "our" tomcat's session Id I
have to use the session Id from another server to encode the URL, since
all URLs first call that other server which then includes stuff from
"our" tomcat. Hope that description was clear ...
Anyway, what I would like to do is somehow "smuggle" a response object
into a request/response pair that could then have it's own encodeURL
implementation. I don't really want to patch tomcat if possible and I
also don't want to extend many struts classes which would be another
solution. Anyone got an idea?
I have tried to use dynamic proxies (creating proxies for
CoyoteResponseFacade objects) but that didn't appear to work (invoke
would not get called on the proxies).
I also had a look at the option to wrap my own implementation of
HttpServletResponse around the CoyoteResponseFacade, but that also
didn't get me very far. I was hoping that the .setResponse method of
CoyoteRequest could help, but I cannot get to a CoyoteRequest object,
only to a CoyoteRequestFacade object. Hm ...
If all else fails, I guess I will have to patch tomcat.

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


Re: Tomcat development rate.

2004-09-17 Thread John Villar
Well my friend, that's the open source way to software, remember 
"release early, release often" is the motto. If you problem is the 
mainteinance costs, stick to some stable release.

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

[EMAIL PROTECTED] escribió:

   -Original Message-
   From: John Villar
   
   Yep there are lots :-D David, as long as you adhere 
   to the servlet specification, there won't be any problems 
   at all (off course, there's always a glitch here and 
   there).

The service provided to customers is both the TC configuration
as well as the servlets, jsp pages etc. So I would be loathe to
separate the two with respect to a web service?
 I initially tried tc 4, blinked twice and had to do lots
of work to get the same app running on tc 5, mainly due
to configuration differences. 
 Its that that makes me a little concerned.
And now 5.5x is nearing stable, what other changes?
 Just that from my perspective the change rate seems
to be getting expensive from maint costs?

It may decrease as my tc experience increases, but thats
the view I take today.
regards DaveP
 


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

RE: Serializable Logging implementation

2004-09-17 Thread Shapira, Yoav

Hi,
OP = Original Poster, the person who started this thread.

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: Antony Paul [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 9:31 AM
>To: Tomcat Users List
>Subject: Re: Serializable Logging implementation
>
>What is OP ? Can you please expand it ?
>
>rgds
>Antony Paul
>
>- Original Message -
>From: "Shapira, Yoav" <[EMAIL PROTECTED]>
>To: "Tomcat Users List" <[EMAIL PROTECTED]>
>Sent: Friday, September 17, 2004 5:41 PM
>Subject: RE: Serializable Logging implementation
>
>
>
>Hi,
>
>>Ditch the super class philosphy. And copy the following 3 lines of
>code:
>>import ... LogFactory;
>>import ... Log;
>>private static log = LogFactory.get...(My.class);
>
>Yup, exactly.  Tim's message is right on, and if you look at the start
>of this thread you see we only started suggesting the alternative
>approaches (transient, activation listener) when the OP wanted to stick
>to his bad design pattern.
>
>Yoav
>
>
>
>This e-mail, including any attachments, is a confidential business
>communication, and may contain information that is confidential,
>proprietary
>and/or privileged.  This e-mail is intended only for the individual(s)
to
>whom it is addressed, and may not be saved, copied, printed, disclosed
or
>used by anyone else.  If you are not the(an) intended recipient, please
>immediately delete this e-mail from your computer system and notify the
>sender.  Thank you.
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Re: Serializable Logging implementation

2004-09-17 Thread Antony Paul
What is OP ? Can you please expand it ?

rgds
Antony Paul

- Original Message -
From: "Shapira, Yoav" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 5:41 PM
Subject: RE: Serializable Logging implementation



Hi,

>Ditch the super class philosphy. And copy the following 3 lines of
code:
>import ... LogFactory;
>import ... Log;
>private static log = LogFactory.get...(My.class);

Yup, exactly.  Tim's message is right on, and if you look at the start
of this thread you see we only started suggesting the alternative
approaches (transient, activation listener) when the OP wanted to stick
to his bad design pattern.

Yoav



This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential, proprietary
and/or privileged.  This e-mail is intended only for the individual(s) to
whom it is addressed, and may not be saved, copied, printed, disclosed or
used by anyone else.  If you are not the(an) intended recipient, please
immediately delete this e-mail from your computer system and notify the
sender.  Thank you.


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


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



RE: Tomcat development rate.

2004-09-17 Thread David . Pawson
 

-Original Message-
From: John Villar

Yep there are lots :-D David, as long as you adhere 
to the servlet specification, there won't be any problems 
at all (off course, there's always a glitch here and 
there).

The service provided to customers is both the TC configuration
as well as the servlets, jsp pages etc. So I would be loathe to
separate the two with respect to a web service?
  I initially tried tc 4, blinked twice and had to do lots
of work to get the same app running on tc 5, mainly due
to configuration differences. 
  Its that that makes me a little concerned.
And now 5.5x is nearing stable, what other changes?
  Just that from my perspective the change rate seems
to be getting expensive from maint costs?

It may decrease as my tc experience increases, but thats
the view I take today.

regards DaveP

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

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



automated (un)deployment

2004-09-17 Thread Quinten Verheyen
Hi, in tomcat 4.1.29, what is the best approach to replace a deployed war (wich is 
expanded) via the manager webapp ?

Also, what's the best choice between 1) automated deployment settings via the  
element e.g. 'liveDeploy' or 2) the manager webapp deploy/install functions ?

Kind regards,
Quinten

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



RE: Invalid restrictions on cookie name in javax.servlet.http.Cookie

2004-09-17 Thread Shapira, Yoav

Hi,
Contact the expert group for JSR154:
http://www.jcp.org/en/jsr/detail?id=154.  They control the code for the
Servlet API.  If they agree with you, they will open an enhancement
issue right away for this item, you don't need to worry about that part
;)

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: Arto Huusko [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 8:51 AM
>To: [EMAIL PROTECTED]
>Subject: Invalid restrictions on cookie name in
javax.servlet.http.Cookie
>
>Hi,
>
>I believe javax.servlet.http.Cookie (as seen in Tomcat 5.0.28 sources,
>at
jakarta-servletapi-5/jsr154/src/share/javax/servlet/http/Cookie.java)
>is invalidly enforcing restrictions on the cookie name.
>
>The constructor does not accept, for example, "Domain" as a cookie
name.
>The same goes for other "special" names that are used when transmitting
>
>However, as far as I can see, neither RFC 2109 or RFC 2965 imposes
>such restrictions on the cookie name. The only restriction is that
>the name is a "token" and that it does not start with $. Sun's
>javax.servlet.http.Cookie javadoc agrees.
>
>Am I mistaken, and if not what should I do? File a bug report?
>
>--
>Arto Huusko
>WM-data Novo
>Ruukinkatu 2-4, 20540 Turku, FINLAND
>http://www.wmdata.fi/
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Nullpointer exception using ssl in tomcat 5.0

2004-09-17 Thread Michael Cornell
Hi folks,

I am getting a Null Pointer exception that I am finding hard to pinpoint,
and wonder whether you may have some insight into the matter.  Note that the
exception is being handled, but as I am using Eclipse, the nullpointer is
being displayed.

Below is my server.xml, a snippet of debug statement and two consecutive NP
exceptions that are thrown.  I am using tomcat 5.0.

A possible source of this problem could be my .keystore having only having
carried out the first part of generating a keystore on
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/ssl-howto.html and not
"Installing a Certificate from a Certificate Authority"

Server.xml:














  

  



Debug trace:

INFO  13:27:43,578 [182 ] org.apache.coyote.http11.Http11Protocol  -
Starting Coyote HTTP/1.1 on http-80
INFO  13:27:44,109 [182 ] org.apache.coyote.http11.Http11Protocol  -
Starting Coyote HTTP/1.1 on http-443


Caught nullpointer:
System Thread [Finalizer] (Suspended (exception NullPointerException))
SSLSocketImpl.a(OutputRecord) line: not available [local variables
unavailable]
SSLSocketImpl.a(byte, byte) line: not available
SSLSocketImpl.a(byte) line: not available
SSLSocketImpl.b(boolean) line: not available
SSLSocketImpl.close() line: not available
SSLSocketImpl(BaseSSLSocketImpl).finalize() line: not available
Finalizer.invokeFinalizeMethod(Object) line: not available [native method]
Finalizer.runFinalizer() line: not available
Finalizer.access$100(Finalizer) line: not available
Finalizer$FinalizerThread.run() line: not available

(next one)
System Thread [Finalizer] (Suspended (exception NullPointerException))
SSLSocketImpl.b(boolean) line: not available [local variables unavailable]
SSLSocketImpl.close() line: not available
SSLSocketImpl(BaseSSLSocketImpl).finalize() line: not available
Finalizer.invokeFinalizeMethod(Object) line: not available [native method]
Finalizer.runFinalizer() line: not available
Finalizer.access$100(Finalizer) line: not available
Finalizer$FinalizerThread.run() line: not available


Thanks

/Michael Cornell

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.754 / Virus Database: 504 - Release Date: 06/09/2004



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



Invalid restrictions on cookie name in javax.servlet.http.Cookie

2004-09-17 Thread Arto Huusko
Hi,
I believe javax.servlet.http.Cookie (as seen in Tomcat 5.0.28 sources,
at jakarta-servletapi-5/jsr154/src/share/javax/servlet/http/Cookie.java)
is invalidly enforcing restrictions on the cookie name.
The constructor does not accept, for example, "Domain" as a cookie name.
The same goes for other "special" names that are used when transmitting
However, as far as I can see, neither RFC 2109 or RFC 2965 imposes
such restrictions on the cookie name. The only restriction is that
the name is a "token" and that it does not start with $. Sun's
javax.servlet.http.Cookie javadoc agrees.
Am I mistaken, and if not what should I do? File a bug report?
--
Arto Huusko
WM-data Novo
Ruukinkatu 2-4, 20540 Turku, FINLAND
http://www.wmdata.fi/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Using custom CoyoteResponse(Facade)

2004-09-17 Thread Martin_Schaefer

More a question than an answer: Could a servlet filter do the job?

Markus Krogemann <[EMAIL PROTECTED]> schrieb am
17.09.2004, 14:31:51:
> Dear List,
> 
> I am having a hard time to figure out how I could fulfill a special 
> requirement in a current project.
> 
> I could use either tomcat 4.1.x or tomcat 5.0.x for this project, I 
> presume it doesn't make much difference in terms of possible solutions.
> The project also uses struts (1.2.2) and here is the special 
> requirement: Instead of encoding URLs with "our" tomcat's session Id I 
> have to use the session Id from another server to encode the URL, since 
> all URLs first call that other server which then includes stuff from 
> "our" tomcat. Hope that description was clear ...
> 
> Anyway, what I would like to do is somehow "smuggle" a response object 
> into a request/response pair that could then have it's own encodeURL 
> implementation. I don't really want to patch tomcat if possible and I 
> also don't want to extend many struts classes which would be another 
> solution. Anyone got an idea?
> 
> I have tried to use dynamic proxies (creating proxies for 
> CoyoteResponseFacade objects) but that didn't appear to work (invoke 
> would not get called on the proxies).
> 
> I also had a look at the option to wrap my own implementation of 
> HttpServletResponse around the CoyoteResponseFacade, but that also 
> didn't get me very far. I was hoping that the .setResponse method of 
> CoyoteRequest could help, but I cannot get to a CoyoteRequest object, 
> only to a CoyoteRequestFacade object. Hm ...
> 
> If all else fails, I guess I will have to patch tomcat.
> 
> Thanks,
> Markus
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
-- 
Martin Schaefer
NAXOS Software Solutions GmbH i.G.
Herrenstr. 1
69502 Hemsbach
Germany
 
Phone:+49 (0) 6201 49298-2
Mobile: +49 (0) 172 6269246
Fax: +49 (0) 6201 49298-1
Mail: [EMAIL PROTECTED]

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



Re: Using custom CoyoteResponse(Facade)

2004-09-17 Thread Tim Funk
I think you might need to use a Valve instead of Http...Wrapper. The 
Http...Wrappers can't dig enough into the correct internals to do your 
session management. But the Valves (probably) can. (Without me thinking about 
the details)

With a valve you should be able to wrap or change the internal tomcat 
implementations. And probably do it in such a way that your webapp might not 
need changed so if this requirement goes away - there is nothing to change in 
your app.

-Tim
Markus Krogemann wrote:
Dear List,
I am having a hard time to figure out how I could fulfill a special 
requirement in a current project.

I could use either tomcat 4.1.x or tomcat 5.0.x for this project, I 
presume it doesn't make much difference in terms of possible solutions.
The project also uses struts (1.2.2) and here is the special 
requirement: Instead of encoding URLs with "our" tomcat's session Id I 
have to use the session Id from another server to encode the URL, since 
all URLs first call that other server which then includes stuff from 
"our" tomcat. Hope that description was clear ...

Anyway, what I would like to do is somehow "smuggle" a response object 
into a request/response pair that could then have it's own encodeURL 
implementation. I don't really want to patch tomcat if possible and I 
also don't want to extend many struts classes which would be another 
solution. Anyone got an idea?

I have tried to use dynamic proxies (creating proxies for 
CoyoteResponseFacade objects) but that didn't appear to work (invoke 
would not get called on the proxies).

I also had a look at the option to wrap my own implementation of 
HttpServletResponse around the CoyoteResponseFacade, but that also 
didn't get me very far. I was hoping that the .setResponse method of 
CoyoteRequest could help, but I cannot get to a CoyoteRequest object, 
only to a CoyoteRequestFacade object. Hm ...

If all else fails, I guess I will have to patch tomcat.
Thanks,
Markus
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

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


RE: Using custom CoyoteResponse(Facade)

2004-09-17 Thread Shapira, Yoav

Hi,
Why not use an HttpServletResponseWrapper?  You can easily wrap whatever
responses you want with a Filter, and then implement the encodeURL
method however you want.

I think the design itself is cruising for a bruising, as is the case any
time you deviate from Servlet Spec mandates on session tracking, but I
imagine you already know that and have no choice.

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: Markus Krogemann [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 8:32 AM
>To: Tomcat Users List
>Subject: Using custom CoyoteResponse(Facade)
>
>Dear List,
>
>I am having a hard time to figure out how I could fulfill a special
>requirement in a current project.
>
>I could use either tomcat 4.1.x or tomcat 5.0.x for this project, I
>presume it doesn't make much difference in terms of possible solutions.
>The project also uses struts (1.2.2) and here is the special
>requirement: Instead of encoding URLs with "our" tomcat's session Id I
>have to use the session Id from another server to encode the URL, since
>all URLs first call that other server which then includes stuff from
>"our" tomcat. Hope that description was clear ...
>
>Anyway, what I would like to do is somehow "smuggle" a response object
>into a request/response pair that could then have it's own encodeURL
>implementation. I don't really want to patch tomcat if possible and I
>also don't want to extend many struts classes which would be another
>solution. Anyone got an idea?
>
>I have tried to use dynamic proxies (creating proxies for
>CoyoteResponseFacade objects) but that didn't appear to work (invoke
>would not get called on the proxies).
>
>I also had a look at the option to wrap my own implementation of
>HttpServletResponse around the CoyoteResponseFacade, but that also
>didn't get me very far. I was hoping that the .setResponse method of
>CoyoteRequest could help, but I cannot get to a CoyoteRequest object,
>only to a CoyoteRequestFacade object. Hm ...
>
>If all else fails, I guess I will have to patch tomcat.
>
>Thanks,
>Markus
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Using custom CoyoteResponse(Facade)

2004-09-17 Thread Markus Krogemann
Dear List,
I am having a hard time to figure out how I could fulfill a special 
requirement in a current project.

I could use either tomcat 4.1.x or tomcat 5.0.x for this project, I 
presume it doesn't make much difference in terms of possible solutions.
The project also uses struts (1.2.2) and here is the special 
requirement: Instead of encoding URLs with "our" tomcat's session Id I 
have to use the session Id from another server to encode the URL, since 
all URLs first call that other server which then includes stuff from 
"our" tomcat. Hope that description was clear ...

Anyway, what I would like to do is somehow "smuggle" a response object 
into a request/response pair that could then have it's own encodeURL 
implementation. I don't really want to patch tomcat if possible and I 
also don't want to extend many struts classes which would be another 
solution. Anyone got an idea?

I have tried to use dynamic proxies (creating proxies for 
CoyoteResponseFacade objects) but that didn't appear to work (invoke 
would not get called on the proxies).

I also had a look at the option to wrap my own implementation of 
HttpServletResponse around the CoyoteResponseFacade, but that also 
didn't get me very far. I was hoping that the .setResponse method of 
CoyoteRequest could help, but I cannot get to a CoyoteRequest object, 
only to a CoyoteRequestFacade object. Hm ...

If all else fails, I guess I will have to patch tomcat.
Thanks,
Markus
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Serializable Logging implementation

2004-09-17 Thread Tim Funk
static variables are not serialized because they are not "part of the object 
instance being serialized". (Can thing of a better phrasing)

-Tim
Spiegs wrote:
Ok, in a nutshell - using a private static logger in each model object 
will not be serialized across the cluster. Use the following 3 lines of 
code you provided and I won't have any problems with the log4j log 
instance not being serializable, because it never will be. Right? (I'm 
not familiar with how the Classloader handles static variables in a 
clustered environment)

Thanks,
Eric
 Original Message --
Ditch the super class philosphy. And copy the following 3 lines of code:
import ... LogFactory;
import ... Log;
private static log = LogFactory.get...(My.class);
You don't want to use the super class philophy because debugging the 
inheritance chain becomes impossible. For example:
SuperClass
SubClass
   SubSubClass
  SubSubSubClass

With a log variable at the Super class level inherited by the sub 
classes, it is IMPOSSIBLE to debug SubClass or SubSubClass. (As well as 
SuperClass) For example - I might want trace turned on for the super 
class and warn on for the rest of the classes in the hierarchy. 
Inheritance kills any chance of fine grained control of log output.

If it's static - it can't be transient. And all the instances share all 
the same log instance at the Classloader level so it is never serialized.

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


Re: Tomcat development rate.

2004-09-17 Thread John Villar
Yep there are lots :-D David, as long as you adhere to the 
servlet specification, there won't be any problems at all (off course, 
there's always a glitch here and there). I think servlets have been 
sufficiently backwards compatible until now, however, that's my opinion 
(i started using the tomcat 3 branch a long time ago and all the 
knowledge i acquired since then has been of use to me on the 5 branch).

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Shapira, Yoav escribió:
Hi,
 

Is there any particular incompatibility that concerns you? I have been
using the same apps basically from an early version of 4 with no
   

changes
 

required to upgrade other than small changes to web.xml etc to fall in
   

line
 

with the newer servlet specs which tomcat has to follow and is not in
   

the
 

Tomcat developers control.
   

I've been the same way, as a tomcat user.  The key is in designing and
implementing your app to the Servlet Specification, minimizing
dependence on container-specific behavior.
 

If you are concerned then you don't need to upgrade, there are many
   

people
 

on this list still running versions 3 or 4 of tomcat. In fact, unless
   

you
 

are affected by bugs that are subsequently fixed or require the new
features or more performance there isnt really a good arguement to
   

upgrade.
Well, I'd argue there are many good reasons to keep upgrading, but there
are already enough other threads on the mailing list with that argument
;)
Yoav

This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

 


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

[OFF-TOPIC] Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread John Villar
isn't Xeth a biblic name? i have a friend that is called Seth, he told 
me its roots are from the (cristian) bible.

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Allistair Crossley escribió:
shame about the surname lol (sorry xeth just kidding)
ADC
 

-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
Sent: 17 September 2004 13:17
To: Tomcat Users List; Xeth Waxman
Subject: RE: Traversing up a directory using RequestDispatcher

Hi,
First of all, Xeth is the best name I've seen in a long time -- cool!
   

I have a bizarre issue.  Using Tomcat 5.0.12, I have an 
 

application in
   

the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
After loggin in, I am trying to forward a request to jsp page in that
directory.  However, RequestDispatcher apparently uses the directory
C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
to go up a directory in my forward request (something like url =
"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
to start off the url, so I can't use the ../ start to go up a
directory.  Does anyone have an idea how I would do this?  I 
 

tried url
   

= "/../ChargeCard/index.jsp";, but that results in a
NullPointerException being thrown.  All help is appreciated!
 

The RequestDispatcher's behavior is constrained by the Servlet
Specification.  Its JavaDoc has an explanation on how it resolves
relative links: the leading slash for the getRequestDispatcher call is
not really absolute, it's relative to the webapp's docBase.
There's no reason Tomcat would use ROOT as the docBase, unless you're
actually in the root webapp.  What is the docBase for your webapp?
(Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
under it, unless you've explicitly defined a Context with the webapp
docBase) (in which case, if you kept the default Host 
appBase, you have
a bad configuration).

Yoav

This e-mail, including any attachments, is a confidential 
business communication, and may contain information that is 
confidential, proprietary and/or privileged.  This e-mail is 
intended only for the individual(s) to whom it is addressed, 
and may not be saved, copied, printed, disclosed or used by 
anyone else.  If you are not the(an) intended recipient, 
please immediately delete this e-mail from your computer 
system and notify the sender.  Thank you.

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


 
---
QAS Ltd.
Developers of QuickAddress Software
http://www.qas.com";>www.qas.com
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---


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

 


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

RE: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Allistair Crossley
shame about the surname lol (sorry xeth just kidding)
ADC

> -Original Message-
> From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
> Sent: 17 September 2004 13:17
> To: Tomcat Users List; Xeth Waxman
> Subject: RE: Traversing up a directory using RequestDispatcher
> 
> 
> 
> Hi,
> First of all, Xeth is the best name I've seen in a long time -- cool!
> 
> >I have a bizarre issue.  Using Tomcat 5.0.12, I have an 
> application in
> >the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
> >After loggin in, I am trying to forward a request to jsp page in that
> >directory.  However, RequestDispatcher apparently uses the directory
> >C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
> >to go up a directory in my forward request (something like url =
> >"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
> >to start off the url, so I can't use the ../ start to go up a
> >directory.  Does anyone have an idea how I would do this?  I 
> tried url
> >= "/../ChargeCard/index.jsp";, but that results in a
> >NullPointerException being thrown.  All help is appreciated!
> 
> The RequestDispatcher's behavior is constrained by the Servlet
> Specification.  Its JavaDoc has an explanation on how it resolves
> relative links: the leading slash for the getRequestDispatcher call is
> not really absolute, it's relative to the webapp's docBase.
> 
> There's no reason Tomcat would use ROOT as the docBase, unless you're
> actually in the root webapp.  What is the docBase for your webapp?
> (Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
> under it, unless you've explicitly defined a Context with the webapp
> docBase) (in which case, if you kept the default Host 
> appBase, you have
> a bad configuration).
> 
> Yoav
> 
> 
> 
> This e-mail, including any attachments, is a confidential 
> business communication, and may contain information that is 
> confidential, proprietary and/or privileged.  This e-mail is 
> intended only for the individual(s) to whom it is addressed, 
> and may not be saved, copied, printed, disclosed or used by 
> anyone else.  If you are not the(an) intended recipient, 
> please immediately delete this e-mail from your computer 
> system and notify the sender.  Thank you.
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


 
---
QAS Ltd.
Developers of QuickAddress Software
http://www.qas.com";>www.qas.com
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---



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



Re: Tomcat fine within the LAN, but invisible from without

2004-09-17 Thread John Villar
LOL it seems shorewall is getting very popular however, the 
x.x.x.your_public_ip part is unnecesary, the "net" part at the beginning 
of the rule tells shorewall to use the public ip of the firewall for the 
DNAT procedure

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Big Chiz escribió:
it can be alot of factors. if its a  fw problem, e.g if you only have
one public ip forwading it to your local host then you should have
something like this in your shorewall/rules
DNAT  net  loc:192.168.1.5 tcp 8080 - x.x.x.your_public_ip

On Fri, 17 Sep 2004 00:29:55 -0500, Lee Hoffner
<[EMAIL PROTECTED]> wrote:
 

For some reason, I'm not getting replies to my posts, although I see them at
http://www.mail-archive.com/tomcat-user%40jakarta.apache.org/
Weird!
Anyway, in regard to those replies:
   

you can also add www.mydomain.com to your hosts file to test accessing
the web server within your lan, if that failed check your dns or if it
resolves to a public ip then check your fw
On Thu, 16 Sep 2004 13:03:14 -0700, Hassan Schroeder
<[EMAIL PROTECTED]> wrote:
 

Lee Hoffner wrote:
   

I've untarred and setup Tomcat 4.1.30 on my server and can get to
 

index.jsp
   

just fine on my web server's 192.168.x.x:8080 address, but I get a
 

timeout
   

error if I try to browse to www.mydomain.com:8080.
 

Sounds like a basic networking problem --
1) does host/dig/nslookup resolve 'www.mydomain.com' to your address?
2) if you're really trying this from "outside" your LAN, what's the
  firewall/routing setup? (hint: try it from "inside" first!)
HTH,
--
Hassan Schroeder - [EMAIL PROTECTED]
   

I don't have a DNS server here, just a /etc/hosts file. www.mydomain.com is
listed in the hosts file at 192.168.1.5
nslookup finds www.mydomain.com at the public IP provided by my ISP.
Shorewall has the rule:
Action  ACCEPT
Source Zone Net
Destination Zone
ProtocolTCP
Source PortsAny
Destination Ports   8080
DNAT or REDIRECTNone
Trying to access the domain:8080 from within this LAN results in a timeout.
Trying to access the domain:8080 from an office elsewhere results in an alert
that the connection was refused.
I'm mystified. I'd be grateful for any help. Thank you!

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

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


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

RE: Traversing up a directory using RequestDispatcher

2004-09-17 Thread Shapira, Yoav

Hi,
First of all, Xeth is the best name I've seen in a long time -- cool!

>I have a bizarre issue.  Using Tomcat 5.0.12, I have an application in
>the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard.
>After loggin in, I am trying to forward a request to jsp page in that
>directory.  However, RequestDispatcher apparently uses the directory
>C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
>to go up a directory in my forward request (something like url =
>"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
>to start off the url, so I can't use the ../ start to go up a
>directory.  Does anyone have an idea how I would do this?  I tried url
>= "/../ChargeCard/index.jsp";, but that results in a
>NullPointerException being thrown.  All help is appreciated!

The RequestDispatcher's behavior is constrained by the Servlet
Specification.  Its JavaDoc has an explanation on how it resolves
relative links: the leading slash for the getRequestDispatcher call is
not really absolute, it's relative to the webapp's docBase.

There's no reason Tomcat would use ROOT as the docBase, unless you're
actually in the root webapp.  What is the docBase for your webapp?
(Hint: it's not c:\jakarta-tomcat-5.0.12\webapps, it's a subdirectory
under it, unless you've explicitly defined a Context with the webapp
docBase) (in which case, if you kept the default Host appBase, you have
a bad configuration).

Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Re: Traversing up a directory using RequestDispatcher

2004-09-17 Thread John Villar
if you're forwarding from the "ChargeCard" directory, you just have to 
include only the name of the page in the forward directive (e.g. 
"something.jsp" or "./something.jsp") the trailing backslash is 
directly referring the root context of "this" host

John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

Xeth Waxman escribió:
I have a bizarre issue.  Using Tomcat 5.0.12, I have an application in
the directory C:\jakarta-tomcat-5.0.12\webapps called ChargeCard. 
After loggin in, I am trying to forward a request to jsp page in that
directory.  However, RequestDispatcher apparently uses the directory
C:\jakarta-tomcat-5.0.12\webapps\ROOT as the Document root, so I need
to go up a directory in my forward request (something like url =
"../ChargeCard/index.jsp";)  However, RequestDispatcher requires a /
to start off the url, so I can't use the ../ start to go up a
directory.  Does anyone have an idea how I would do this?  I tried url
= "/../ChargeCard/index.jsp";, but that results in a
NullPointerException being thrown.  All help is appreciated!
 


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

RE: Tomcat development rate.

2004-09-17 Thread Shapira, Yoav

Hi,

>Is there any particular incompatibility that concerns you? I have been
>using the same apps basically from an early version of 4 with no
changes
>required to upgrade other than small changes to web.xml etc to fall in
line
>with the newer servlet specs which tomcat has to follow and is not in
the
>Tomcat developers control.

I've been the same way, as a tomcat user.  The key is in designing and
implementing your app to the Servlet Specification, minimizing
dependence on container-specific behavior.

>If you are concerned then you don't need to upgrade, there are many
people
>on this list still running versions 3 or 4 of tomcat. In fact, unless
you
>are affected by bugs that are subsequently fixed or require the new
>features or more performance there isnt really a good arguement to
upgrade.

Well, I'd argue there are many good reasons to keep upgrading, but there
are already enough other threads on the mailing list with that argument
;)

Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



RE: Serializable Logging implementation

2004-09-17 Thread Shapira, Yoav

Hi,

>Ditch the super class philosphy. And copy the following 3 lines of
code:
>import ... LogFactory;
>import ... Log;
>private static log = LogFactory.get...(My.class);

Yup, exactly.  Tim's message is right on, and if you look at the start
of this thread you see we only started suggesting the alternative
approaches (transient, activation listener) when the OP wanted to stick
to his bad design pattern.

Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



RE: Problem configuring a global resource to be linked from Context elements ....

2004-09-17 Thread Shapira, Yoav

Hi,

>I think it is because of the way Tomcat classloaders work. Classes in
>common\lib or common\classes cannot see classes in WEB-INF\lib. DBCP
looks
>for the JDBC Driver class and it cannot read it from WEB-INF\lib. This
is
>the answer I got when I had similar problem. For further info on this
you
>need help from experts in this list. If the problem is not solved
please
>reply.

Your thought is right -- the above is a good description.  The
ClassLoader hierarchy is just that, a hierarchy, meaning different
visibility for different classloaders.  It's described in detail the
ClassLoader how-to, which I might rank at the #1 document all developers
using Tomcat should read and understand.

Yoav



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



RE: A little offbeat question

2004-09-17 Thread Shapira, Yoav

Hi,
You know, I haven't run a command-line javac in a couple of years, I
think.  Ant is such a wonderful tool ;)

Yoav Shapira
Millennium Research Informatics


>-Original Message-
>From: Frank Zammetti [mailto:[EMAIL PROTECTED]
>Sent: Friday, September 17, 2004 12:24 AM
>To: [EMAIL PROTECTED]
>Subject: Re: A little offbeat question
>
>
>>I wish they would clarify that, to, "Don't set CLASSPATH yourself. Let
>>the applications or frameworks do that." I think that would be less
>>confusing.
>
>As I understand it, this simply means that if you are going to execute
a
>Java app, you should set the classpath right before executing the app
(on
>the command line really).  Likewise, when you compile, construct the
>classpath on the command line of javac.  Or, when running Tomcat or
>something like that, let it's startup scripts create the classpath.
>
>At least in Windows, all those situations would result in a "local"
>classpath, i.e., if you have three command prompt windows open, one to
do
>compiles, one to execute apps directly and one to run Tomcat in, all
three
>can basically set up their own classpath, completely independent of one
>another.  I think this is what that statement is talking about.
>
>Frank
>
>_
>Express yourself instantly with MSN Messenger! Download today - it's
FREE!
>http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



Re: Windows 2003 Java VM memory leak due to C# garbage collection algorithm

2004-09-17 Thread Sjoerd van Leent
I'd use Windows 2003 (or .NET Server if you like) and there is no 
Garbage Collection to the application. About internal kernel management 
I don't know, but applications can't use it. Applications have to use 
there own algorithms. It would simply be impossible to redesign this for 
the Windows environment, because it will render thousands of 
applications completely useless.

I think you are mistakenly replacing *.NET Server* with *.NET*, which is 
a Virtual Machine, just as the JVM is. Since *.NET* is delivered 
together with *.NET Server*, there is a Garbage Collector within the 
.NET environment, which is used by languages such as C#, VB.NET and 
Managed C++.

Regards,
Sjoerd
Travis De Silva wrote:
Hi Steffen,
Thanks for your reply. What you say confirms my understanding of how the JVM
works.
We start Tomcat from the command prompt as an application.
We have been using various settings for the OPTS. Currently its set as:
set
AVA_OPTS= -server -Xmx512M -XX:MaxNewSize=256M -Xminf.5 -Xmaxf.8  -XX:NewSiz
e=2m -XX:NewRatio=3 -Xcompactgc -XX:+UseParallelGC -XX:+UseAdaptiveSizePolic
y -XX:ParallelGCThreads=4 -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=256m
 -Xloggc:%M_JVM_LOG_FILE%  -XX:+PrintTLE
Previously we have set the following as well (and a lot of others as well
such as changing the GC algorithm etc)
#set JAVA_OPTS= -Xms256m -Xmx256m -Xgc:parallel -Xcleartype:gc  (the min and
max heap was set to the same as we have memory on our server (4GB) and
wanted to avoid the overhead associated with growing the JVM that require
multiple system calls resulting in segmented system memory.)
I was thinking its a windows 2003 garbage collection issue as they seem to
have changed their memory handing concept and now use the garbage collection
concept. In windows 2000, it was different. And when we were running our
webapps on windows 2000, it was fine. Unfortunately we recently moved our
webapps to a new dedicated server with a new hosting company and it came
with windows 2003.
Thanks for any assistance.
Travis

- Original Message - 
From: "SH Solutions" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>; "'Travis De
Silva'" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 6:26 PM
Subject: AW: Windows 2003 Java VM memory leak due to C# garbage collection
algorithm

 

Hi
   

What I want to know is even if our program has a memory leak, it should
 

crash the JVM right?
No, your program (better your webapp) should get OutOfMemoryExceptions and
should continue running. Mostly, it will not do sensful things any more,
   

but
 

it should NEVER crash the JVM.
   

It should not keep increasing the memory allocated from the Windows
 

Server
 

2003 O/S.
Right. It should go about 64 MB over your max heap setting (which is
   

approx.
 

the jvm overhead), but not 1 GB above. There is something wrong. Are you
sure you specified both MIN AND MAX heap values? Can you show your OPTS?
   

How
 

are you starting tomcat - as service or as application?
   

Could this be a issue with the Windows server 2003 garbage collection as
 

I
 

read it is written using C#? anyone has any idea if this is the problem?
No.
Windows 2003 server has nothing to do with applications garbage
   

collection.
 

Java JVM have their own garbage collector, you can even choose one from
command line - what you could try.
Windows 2003 itself has no garbage collection at all. Windows 2003
   

provides
 

.net by default, which itself works semtantically like a VM and which
   

itself
 

DOES HAVE a garbage collector. That one IS used for C#, but I doubt it is
written in C#.
And even if it would be written in C#, that should not be the problem,
   

since
 

it is used in really huge applications and has not shown to be a big
   

source
 

of leaks so far.
Regards,
 Steffen
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   


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


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


RE: What is the difference in classloading between tomcat 4.1.x and 5.0.x

2004-09-17 Thread tomcat-user

Hello 

Sorry to drag this issue on but, I still don't get Tomcat 5 to recognize classes in 
jar files located in $CATALINA_HOME/shared/lib

I tried my orginal application (which was running fine under Tomcat 4.1.x, both on 
Windows and Linux)
with Tomcat 5.0.28 and then with 5.0.16, both under Windows and Linux, but the problem 
with the ClassNotFoundEception still occurred.

Then I decided to reduce as many potential problem areas as possible, by writing a new 
very simple application consisting of only one html page and one servlet, and only one 
external jar-file. (My original application was quite large with many jar dependencies)

So I started up my IDE, created the new application, created the servlet, deployed in 
tomcat 4.1.x and, placed the jar-file in /shared/lib and of course it works.
Then I deployed under Tomcat 5.0.28, but no, it does not work. After moving the 
jarfile to /common/lib it works though.

This really puzzels me.

What can I do to get to the bottom with this ?
Is there any specific configuration that I could have missed ?
Any other test cases I should perform ?
Should I send my code to someone for inspection ?


Any help is appreciated


On 2004-09-01 Shapira Yoav  wrote:


>Hi,
>Oh yeah, that reminds me, we might have a bug still present with
>classloading from shared/lib in 5.0.x.  Try a much earlier version, e.g.
>5.0.16, and let us know if that works.
>
>Yoav Shapira
>Millennium Research Informatics
>
>
>>-Original Message-
>>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
>>Sent: Wednesday, September 01, 2004 3:58 PM
>>To: [EMAIL PROTECTED]
>>Subject: What is the difference in classloading between tomcat 4.1.x
>and
>>5.0.x
>>
>>
>>In a web application running under Tomcat, I have defined a filter in
>the
>>web.xml file. The filter is pointing to a class that is packed in a
>jar-
>>file, and the jar-file is kept in the $CATALINA_HOME/shared/lib
>directory.
>>
>>In Tomcat 4.1.x the application is working without any problems. When
>>trying to run the same application under Tomcat 5.0.28 a
>>java.lang.ClassNotFoundException is thrown.
>>
>>If the jar-file is placed in $CATALINA_HOME/common/lib, then the class
>is
>>found  and the application runs without problem.
>>
>>The same issue appears when using Listeners in the web.xml file.
>>
>>I have also tried the same setup with 5.0.27 which leads to the same
>>result.
>>
>>What is it that has changed between 4.1x and 5.0.x, in regards to
>>classloading, in order to cause this problem ?
>>
>>Any help in understanding this problem is appreciated.
>>Regards
>>Erik
>>
>>
>> **  stacktrace
>>**
>>2004-09-01 17:35:07
>>NamingContextListener[/Catalina/localhost/webdialInstance]:   Resource
>>parameters for UserTransaction = null
>>2004-09-01 17:35:07 StandardContext[/webdialInstance]Exception starting
>>filter Compress
>>java.lang.ClassNotFoundException:
>>se.erit.web.servlet.filters.gzip.GZIPFilter
>>  at
>>org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoade
>r.ja
>>va:1340)
>>  at
>>org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoade
>r.ja
>>va:1189)
>>  at
>>org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationF
>ilte
>>rConfig.java:211)
>>  at
>>org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(Applicati
>onFi
>>lterConfig.java:308)
>>  at
>>org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilt
>erCo
>>nfig.java:79)
>>  at
>>org.apache.catalina.core.StandardContext.filterStart(StandardContext.ja
>va:3
>>698)
>>  at
>>org.apache.catalina.core.StandardContext.start(StandardContext.java:434
>9)
>>  at
>>org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.j
>ava:
>>823)
>>  at
>>org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:12
>1)
>>  at
>>org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(Container
>Base
>>.java:143)
>>  at java.security.AccessController.doPrivileged(Native Method)
>>  at
>>org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:805)
>>  at
>>org.apache.catalina.core.StandardHost.addChild(StandardHost.java:595)
>>  at
>>org.apache.catalina.core.StandardHostDeployer.addChild(StandardHostDepl
>oyer
>>.java:903)
>>  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>  at
>>sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.ja
>va:3
>>9)
>>  at
>>sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccesso
>rImp
>>l.java:25)
>>  at java.lang.reflect.Method.invoke(Method.java:324)
>>  at
>>org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:
>216)
>>  at
>org.apache.commons.digester.SetNextRule.end(SetNextRule.java:256)
>>  at org.apache.commons.digester.Rule.end(Rule.java:276)
>>  at
>>org.apache.commons.digester.Digester.endElement(Digester.java:1058)
>>  at
>>

Re: Windows 2003 Java VM memory leak due to C# garbage collection algorithm

2004-09-17 Thread Travis De Silva
Hi Steffen,

Thanks for your reply. What you say confirms my understanding of how the JVM
works.

We start Tomcat from the command prompt as an application.

We have been using various settings for the OPTS. Currently its set as:

set
AVA_OPTS= -server -Xmx512M -XX:MaxNewSize=256M -Xminf.5 -Xmaxf.8  -XX:NewSiz
e=2m -XX:NewRatio=3 -Xcompactgc -XX:+UseParallelGC -XX:+UseAdaptiveSizePolic
y -XX:ParallelGCThreads=4 -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=256m
  -Xloggc:%M_JVM_LOG_FILE%  -XX:+PrintTLE

Previously we have set the following as well (and a lot of others as well
such as changing the GC algorithm etc)

#set JAVA_OPTS= -Xms256m -Xmx256m -Xgc:parallel -Xcleartype:gc  (the min and
max heap was set to the same as we have memory on our server (4GB) and
wanted to avoid the overhead associated with growing the JVM that require
multiple system calls resulting in segmented system memory.)

I was thinking its a windows 2003 garbage collection issue as they seem to
have changed their memory handing concept and now use the garbage collection
concept. In windows 2000, it was different. And when we were running our
webapps on windows 2000, it was fine. Unfortunately we recently moved our
webapps to a new dedicated server with a new hosting company and it came
with windows 2003.

Thanks for any assistance.

Travis




- Original Message - 
From: "SH Solutions" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>; "'Travis De
Silva'" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 6:26 PM
Subject: AW: Windows 2003 Java VM memory leak due to C# garbage collection
algorithm


> Hi
>
> > What I want to know is even if our program has a memory leak, it should
> crash the JVM right?
>
> No, your program (better your webapp) should get OutOfMemoryExceptions and
> should continue running. Mostly, it will not do sensful things any more,
but
> it should NEVER crash the JVM.
>
> > It should not keep increasing the memory allocated from the Windows
Server
> 2003 O/S.
>
> Right. It should go about 64 MB over your max heap setting (which is
approx.
> the jvm overhead), but not 1 GB above. There is something wrong. Are you
> sure you specified both MIN AND MAX heap values? Can you show your OPTS?
How
> are you starting tomcat - as service or as application?
>
> > Could this be a issue with the Windows server 2003 garbage collection as
I
> read it is written using C#? anyone has any idea if this is the problem?
>
> No.
> Windows 2003 server has nothing to do with applications garbage
collection.
> Java JVM have their own garbage collector, you can even choose one from
> command line - what you could try.
> Windows 2003 itself has no garbage collection at all. Windows 2003
provides
> .net by default, which itself works semtantically like a VM and which
itself
> DOES HAVE a garbage collector. That one IS used for C#, but I doubt it is
> written in C#.
> And even if it would be written in C#, that should not be the problem,
since
> it is used in really huge applications and has not shown to be a big
source
> of leaks so far.
>
> Regards,
>   Steffen
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



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



RE: Tomcat development rate.

2004-09-17 Thread Dale, Matt
Hi,

Is there any particular incompatibility that concerns you? I have been using the same 
apps basically from an early version of 4 with no changes required to upgrade other 
than small changes to web.xml etc to fall in line with the newer servlet specs which 
tomcat has to follow and is not in the Tomcat developers control.

If you are concerned then you don't need to upgrade, there are many people on this 
list still running versions 3 or 4 of tomcat. In fact, unless you  are affected by 
bugs that are subsequently fixed or require the new features or more performance there 
isnt really a good arguement to upgrade.

Ta
Matt

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 17 September 2004 08:30
To: [EMAIL PROTECTED]
Subject: Tomcat development rate.


Since I've been watching Tomcat, it has been rapidly changing
version, with some incompatibility.

Are there any plans to stabilise and perhaps even
consider backwards compatibility?

Am I the only one looking at deployment concerns 
over a fast moving target?


Regards DaveP.

 snip here *

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

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

Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not the 
intended recipient or the person responsible for delivering to the intended recipient, 
be advised that you have received this E-mail in error and that any use or copying is 
strictly prohibited. If you have received this E-mail in error please notify the 
beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual sender and 
not beCogent Ltd. You must take full responsibility for virus checking this email and 
any attachments.
Please note that the content of this email or any of its attachments may contain data 
that falls within the scope of the Data Protection Acts and that you must ensure that 
any handling or processing of such data by you is fully compliant with the terms and 
provisions of the Data Protection Act 1984 and 1998.


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

Re: Question on use of Java style comments in JSP

2004-09-17 Thread Jarl Skogsholm
I tried it again using a 5+ version, it works correctly.  Is this a bug 
version 4?  Anyone else care to comment?

  out.write("
\r\n");
//a
  out.write("Comment:\r\n");

On Fri, 17 Sep 2004 09:15:03 +0530, Antony Paul <[EMAIL PROTECTED]> 
wrote:

t.jsp
<%//a%>
aaa
t_jsp.java
//a  out.write("\naaa\n");
The out.write() needs to be on second line.
rgds
Antony Paul
- Original Message -
From: "Jarl Skogsholm" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Thursday, September 16, 2004 8:14 PM
Subject: Re: Question on use of Java style comments in JSP

Go look in the work directory and find the corresponding java file to 
this
jsp.

On Thu, 16 Sep 2004 19:22:50 +0530, Antony Paul 
<[EMAIL PROTECTED]>
wrote:

> It is not producing error messages on stdout/stderr or to screen 
instead
> it
> gives this output
>
> 
> 
> 
> 
>
> rgds
> Anotny Paul.
>

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

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

--
They that can give up essential liberty to obtain a little temporary 
safety deserve neither liberty nor safety.
-- Benjamin Franklin (1755)

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


RE: jk2 and file upload

2004-09-17 Thread Allistair Crossley
yes we are successfully for the most part also but every now and again jk2 causes a 
stream terminated unexpectedly error.

we use Commons FileUpload too but that is not the problem, it' JK2 and this is 
mentioned is fixed in CVS HEAD (again, because it was "fixed" before but people 
continued to have issues).

ADC

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: 17 September 2004 08:26
> To: [EMAIL PROTECTED]
> Subject: RE: jk2 and file upload
> 
> 
>  
> 
> -Original Message-
> From: juhani
> 
> Hi! As curren jk2 has problem with file upload i am asking 
> does anybody know when next version will be available or is 
> there any workaround?
> 
> Software used: 
>  Windows server 2003
>  IIS 6
>  Tomcat 5.0.28
>  jk2.0.4-win32-IIS
> 
> I'm successfully uploading n files, mix of javascript 
> and servlet, using
> http://jakarta.apache.org/commons/fileupload/
> 
> I'm currently using win2k, tc 5.0.27
> but will move over to rhel.
> HTH DaveP
> 
> -- 
> DISCLAIMER: 
> 
> NOTICE: The information contained in this email and any 
> attachments is 
> confidential and may be privileged. If you are not the intended 
> recipient you should not use, disclose, distribute or copy any of the 
> content of it or of any attachment; you are requested to notify the 
> sender immediately of your receipt of the email and then to delete it 
> and any attachments from your system. 
> 
> RNIB endeavours to ensure that emails and any attachments 
> generated by 
> its staff are free from viruses or other contaminants. However, it 
> cannot accept any responsibility for any  such which are transmitted.
> We therefore recommend you scan all attachments. 
> 
> Please note that the statements and views expressed in this email and 
> any attachments are those of the author and do not 
> necessarily represent 
> those of RNIB. 
> 
> RNIB Registered Charity Number: 226227 
> 
> Website: http://www.rnib.org.uk 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


 
---
QAS Ltd.
Developers of QuickAddress Software
http://www.qas.com";>www.qas.com
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---



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



AW: Windows 2003 Java VM memory leak due to C# garbage collection algorithm

2004-09-17 Thread SH Solutions
Hi

> What I want to know is even if our program has a memory leak, it should
crash the JVM right?

No, your program (better your webapp) should get OutOfMemoryExceptions and
should continue running. Mostly, it will not do sensful things any more, but
it should NEVER crash the JVM.

> It should not keep increasing the memory allocated from the Windows Server
2003 O/S.

Right. It should go about 64 MB over your max heap setting (which is approx.
the jvm overhead), but not 1 GB above. There is something wrong. Are you
sure you specified both MIN AND MAX heap values? Can you show your OPTS? How
are you starting tomcat - as service or as application?

> Could this be a issue with the Windows server 2003 garbage collection as I
read it is written using C#? anyone has any idea if this is the problem? 

No.
Windows 2003 server has nothing to do with applications garbage collection.
Java JVM have their own garbage collector, you can even choose one from
command line - what you could try.
Windows 2003 itself has no garbage collection at all. Windows 2003 provides
.net by default, which itself works semtantically like a VM and which itself
DOES HAVE a garbage collector. That one IS used for C#, but I doubt it is
written in C#.
And even if it would be written in C#, that should not be the problem, since
it is used in really huge applications and has not shown to be a big source
of leaks so far.

Regards,
  Steffen


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



virtual hosts howto! (jk2/apache2.0.50||iis5.0/tomcat5.0.25)

2004-09-17 Thread Alex

For a while now, i've been making posts, which for the most part have gone
unanswered.  Mostly I believe it's because people that do know the answer
aren't on the list...Anyways, I threw together a few docs about how i
managed to finally get everythign working fine with the above apps.

A lot of this was taken from documentation i've found scattered around the
internet and stuffed into README's...

1.  With apache: (assumes you have apache working)

Obtain the Tomcat JK2 connectors source code.  http://jakarta.apache.org/
jakarta-tomcat-connectors-jk2-2.0.4-src was used in this instance.
Unpack the distribution and enter the directory.

cd jk/native2

Compile the JK2 adapter:
- the options used:
#! /bin/sh
#
# Created by configure
"./configure " \
"--with-jni " \
"--with-apxs2=/opt/apache-2.0.50/bin/apxs " \
"--with-apache2=/usr/local/src/httpd-2.0.50 " \
"--with-java-home=/usr/local/jdk " \
"$@"

- make.  once it's finished compiling go find the module: cd 
../build/jk2/apache2

Now, we want to take the module we've compiled against the apache2 apxs
and do something with it.

- /opt/apache-2.0.50/bin/apxs -n jk2 -i mod_jk2.so

Add the following to the apache httpd.conf:

LoadModule jk2_module modules/mod_jk2.so

Create a workers2.properties in conf (where httpd.conf is localised).
The one located below was developed and is used to support clustered
tomcat application servers.

[shm]
file=/tmp/shm.file
size=1048576

[lb:lb]
info=Tomcat load balance

[channel.socket:server1]
port=8009
host=10.1.1.1
type=ajp13
group=lb

[channel.socket:server2]
port=8009
host=10.1.1.2
type=ajp13
group=lb

[uri:www.virtualhost1.com/*.jsp]
worker=lb:lb

[uri:www.virtualhost1.com/*.do]
worker=lb:lb

[uri:www.virtualhost2.com/*.jsp]
worker=lb:lb

[uri:www.virtualhost2.com/*.do]
worker=lb:lb

2.  With IIS5.0

Obtain the binary release for the JK2 isapi dll from http://jakarta.apache.org/

Create a registry file and insert the following information into it:

REGEDIT4

[HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\2.0]
"workersFile"="C:\\Apache\\Tomcat5\\conf\\workers2.properties"
"extensionUri"="/jakarta/isapi_redirector2.dll"
"logLevel"="debug"
"serverRoot"="C:\\Apache\\Tomcat5\\"

Create the folders which have been defined above in the registry file.

Double click the registry file to import it into the registry.

Create the virtual hosts in iis5.0 according to the iis documentation.
Register a new isapi dll with the virtual host and ensure that a virtual
directory within the virtual host exists called: jakarta which points at
the directory where the isapi_dll is stored.  Restart IIS and you should
see in the properties, under isapi, the dll is now green.

Create a workers2.properties in conf in the directory that workersFile is
defined in the registry file.  The one located below was developed and is
used to support clustered tomcat application servers.

(Use the one in the apache example.  The only difference is that the
shm.file will move to somewhere other then /tmp)

3.  Setting up tomcat

By default, in server.xml for tomcat, you'll have the following host set up:


  
  


To get virtual hosts working so that the jk2 adapters work, create
another. (I created a new dir $CATALINA_HOME$/virtual-hosts)


  
  



  
  


Now all of it should work.  Apps deployed to virtualhost1 will not be seen
by virtualhost2

Hope this helps a few people save a few hours of searching and mucking
about...




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



RE: jk2 and file upload

2004-09-17 Thread Allistair Crossley
apparently in the bugzilla report this has been fixed in the connectors CVS HEAD

ADC

> -Original Message-
> From: juhani [mailto:[EMAIL PROTECTED]
> Sent: 17 September 2004 05:28
> To: [EMAIL PROTECTED]
> Subject: jk2 and file upload
> 
> 
> Hi! As curren jk2 has problem with file upload i am asking does
> anybody know when next version will be available or is there any
> workaround?
> 
> Software used: 
>  Windows server 2003
>  IIS 6
>  Tomcat 5.0.28
>  jk2.0.4-win32-IIS
> 
> 
>   
> __
> Do you Yahoo!?
> Take Yahoo! Mail with you! Get it on your mobile phone.
> http://mobile.yahoo.com/maildemo 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


 
---
QAS Ltd.
Developers of QuickAddress Software
http://www.qas.com";>www.qas.com
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---



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



Tomcat development rate.

2004-09-17 Thread David . Pawson
Since I've been watching Tomcat, it has been rapidly changing
version, with some incompatibility.

Are there any plans to stabilise and perhaps even
consider backwards compatibility?

Am I the only one looking at deployment concerns 
over a fast moving target?


Regards DaveP.

 snip here *

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

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



RE: jk2 and file upload

2004-09-17 Thread David . Pawson
 

-Original Message-
From: juhani

Hi! As curren jk2 has problem with file upload i am asking 
does anybody know when next version will be available or is 
there any workaround?

Software used: 
 Windows server 2003
 IIS 6
 Tomcat 5.0.28
 jk2.0.4-win32-IIS

I'm successfully uploading n files, mix of javascript 
and servlet, using
http://jakarta.apache.org/commons/fileupload/

I'm currently using win2k, tc 5.0.27
but will move over to rhel.
HTH DaveP

-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

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



RE: Tomcat Problems - Any help is appreciated

2004-09-17 Thread David . Pawson
 

-Original Message-
From: Jon Wingfield

The error message tends to imply there is no DOCTYPE (at 
all) in one of your web.xml files. The parser fails when 
validating the doc with this rather strange error message.

Is a normal XML validation process used? I.e. DTD must be accessible,
and is used, or *must* the value  be
"http://java.sun.com/dtd/web-app_2_3.dtd";>

I had to validate locally due to errors, and I've left the local
(on machine) DTD in place, which seems to work.

btw, so long as the document has the correct root element,
and is well formed, tomcat seems quite happy to run, and seems
not to report errors. 

Is validation against the dtd actually done?


regards DaveP

** snip here **




-- 
DISCLAIMER: 

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged. If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system. 

RNIB endeavours to ensure that emails and any attachments generated by 
its staff are free from viruses or other contaminants. However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments. 

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent 
those of RNIB. 

RNIB Registered Charity Number: 226227 

Website: http://www.rnib.org.uk 

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