Hi,
I use Tomcat 5.0.19 under Windows 2000 and have different applications
running on one tomcat instance.
When I set a session variable in one application it does not appear in the
other applications.
Is there an easy way to achive that?
Thanks
Bernhard Slominski
Technical Project Manager
Hi,
I had a simalar problem when not closing database related stuff
(connections, resultsets, statemnts).
Does that apply to your application maybe?
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Chanan Braunstein [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 15. April 2004 16:27
An:
Hi,
I posted the same question, and didn't get an answer, so I just did some
research on my own:
First of all the session is ALWAYS on application scope, this is not an
Tomcat specific behaviour but a requirement of the Specification:
SRV.7.3 Session Scope
HttpSession objects must be scoped at
Maybe your query just returns too much results, because sometimes copies a
part of the data locally to your client and does the query processing there,
so for a serious Web Apllication Access is definitly the wrong choice,
consider using either SQL Server or maybe MySql.
Cheers
Bernhard
Hi,
Is it possible, to extract the value that is is the web.xml file for session
timeout into my JSP page
session-config
session-timeout
5
/session-timeout
/session-config
I want to get the 5 minutes into the JSP page so I can use it for some
information.
Thanks for your help!
Bernhard
!
session.getMaxInactiveInterval() is I believe the right thing to call...
look at the docs to be sure which method you should be calling.
Bernhard Slominski wrote:
Hi,
Is it possible, to extract the value that is is the web.xml file for
session
timeout into my JSP page
session-config
session-timeout
5
Hi,
you can use something like HTTPUnit which just calls the web page with your
servlet.
Can can easiliy schedule the HTTPUnit Job, so it runs every 30mins.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Shilpa Nalgonda [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 21. Dezember 2004
Hi Greg,
we had simalar problems and couldn't find out the exact reason.
We solved it by just making an automated nightly restart of Tomcat.
It's maybe just running out of memory after some time.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Greg Lappen [mailto:[EMAIL PROTECTED]
Hi,
I'm using the following conmfiguration:
- tomcat 5.0.28
- Windows 2000
- Oracle 9i database on Sun Solaris
I'm using the Tomcat connection pooling dbcp and have the following problem.
When reloading the applcation, the open connections are not released and
just stay open on the database
Hi Huu,
First of all the session is ALWAYS on application scope, this is not an
Tomcat specific behaviour but a requirement of the Specification:
SRV.7.3 Session Scope
HttpSession objects must be scoped at the application (or servlet context)
level.
The underlying mechanism, such as the cookie
a ServletContextLlistener and in its contextDestroyed() method
use the shutdown() method of the DBCP pool to close connections.
rgds
Antony Paul
On Thu, 13 Jan 2005 11:37:22 +0100, Bernhard Slominski
[EMAIL PROTECTED] wrote:
Hi,
I'm using the following conmfiguration:
- tomcat 5.0.28
Hi Andrzej,
one possible workaround is compress the output, so the response is
compressed with zip compresseion and your response gets shorter.
You need a response filter for that, if this is an option an you need more
details let me know.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von:
Hi,
for an automated build process I want to reload an application via command
line, is this possible?
The possibilties I found out so far were:
- ant script
- using the tomcat manager
Thanks
Bernhard Slominski
These autoreply is really annoying, but it can easily happen if you forget
to unsubscribe, before leaving on holiday
That's why I vote for a forum instead of a mailist!
Does anyone agree?
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
If you use it together with Apache it may be an Apache configuration problem
-Ursprüngliche Nachricht-
Von: Vivek Behal [mailto:[EMAIL PROTECTED]
Gesendet: Mittwoch, 29. September 2004 11:41
An: Tomcat Users List
Betreff: RE: Not able to run .html and servlet in Tomcat 5
yes. it is
Hi Eric,
did you check the generated code?
Maybe from the code you see what might be the problem.
Another possible solution is wrting your own EL function which replaces the
nested calls.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Eric Blenkush [mailto:[EMAIL PROTECTED]
Gesendet:
Hi,
I think the easiest way is to add a security contsraint in you web.xml of
you web application:
web app...
security-contraint
web-resources-collection
web-resource-nameTest/web-resource-name
url-pattern/myjsps/*/url-pattern
/web-resources-collection
Hi,
in Tomcat Version 5.5.4 there is a bug in the JSP Compiler Jasper, it
sometiems looses the classpath (Bug:
http://issues.apache.org/bugzilla/show_bug.cgi?id=32330)
This is fixed in 5.5.7.
So there are two ways to fix it:
1. Restart Tomcat
2. Upgrade to 5.5.7
Cheers
Bernhard
Hi,
HttpSession.getAttributeNames()
should do what you want!
From the javadoc:
getAttributeNames
public java.util.Enumeration getAttributeNames()
Returns an Enumeration of String objects containing the names of all the
objects bound to this session.
Cheers
Bernhard
-Ursprüngliche
Matt
-Original Message-
From: Bernhard Slominski [mailto:[EMAIL PROTECTED]
Sent: 23 February 2005 09:17
To: 'Tomcat Users List'
Subject: AW: Getting other Sessions
Hi,
HttpSession.getAttributeNames()
should do what you want!
From the javadoc:
getAttributeNames
public
Hi,
we use this instructions to log to a file. Sounds a bit complicated, but
should work:
Follow the following steps to setup a file named tomcat.log that has
internal Tomcat logging output to it:
1. Create a file called log4j.properties with the following content and
save it into
Hi,
I try to get the precompilation working with tomcat 5.5.7 under Windows NT.
I use the following target:
target name=jspc
taskdef classname=org.apache.jasper.JspC name=jasper2
classpath id=jspc.classpath
pathelement
Hi Scott,
it's quite easy: you just have to copy the war-file across in your webapps
root.
Tomcat picks up the war file automatically and redeploys your application.
You don't have to mess around with the manager app. It normally only takes a
few seonds.
Depending on your configuration after some
Hi,
after getting the jsp precompilation finally working, I want also want to do
the precompliation for tag files.
I'm using tomcat 5.5.7 on both Windows 2000 and Sun Solaris.
So something like this:
%@ taglib prefix=mytag tagdir=/WEB-INF/tags %
mytag:header/
The precompilation task generates
Hi Charles,
what you can do is to use an ant task for do the precompilation.
This is a bit smarter than via the command line I guess.
The docu is under
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/jasper-howto.html#Web%20Appl
ication%20Compilation
It's not very well documented, it took me a
I agree with Steve, but there is a much simpler possibility that the JS
validation does not work:
The user can just switch it off in the browser.
This might not be just to bypass validation, but maybe just for security
reasons, so for a business critical apllications I'd discourage anyone from
Hi,
I would suggest that you do a precompilation of your jsps on a deployment
machine which is separate from the live machine.
So your compilation is not done on the live server, which might be on heavy
load.
Also you don't have the problem that the first visitor has to wait an awful
long time
production servers.
Btw. I'm using tomcat 5.0.28.
Thx,
Vesa
- Original Message -
From: Bernhard Slominski [EMAIL PROTECTED]
To: 'Tomcat Users List' tomcat-user@jakarta.apache.org
Sent: Friday, May 27, 2005 3:25 PM
Subject: AW: jspServlet runs out of memory while
Hi,
the thread death is caused by log4j.
You have to shutdown log4j when the context is destroyed:
see http://issues.apache.org/bugzilla/show_bug.cgi?id=26372 for more
details.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Ari Suutari [mailto:[EMAIL PROTECTED]
Gesendet: Freitag,
fork=true
Hmh.. how does you deployment script work? Do you compile jsp
pages in some
other server than the live server?
Well, I didn't write those pages :), I just have to live with
legacy code :D
Vesa
- Original Message -
From: Bernhard Slominski [EMAIL PROTECTED
Hi Cristi,
they are in the Apache Logfile anyway, why do you want to log them again?
Bernhard
-Ursprüngliche Nachricht-
Von: cristi [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 2. Juni 2005 10:04
An: Tomcat Users List
Betreff: Logging the HTTP headers
Hello all
Is there
Hi,
I have a very strange phenomenon:
When I do a hot deployment of my application via war file, my application
disappears sometimes!
I'm using Tomcat 5.5.7 on Sun Solaris 7.
I post you my ant script, which I'm using.
As you can image, this is not very nice in a production environment. I try
to
Hi all,
I'm working on a backoffice admin application on Tomcat (5.5.7, Sun Solaris
9).
I try to do hot deployment via a war file, but it doesn't work at all for
me.
What I do is just to copy the war file across.
The problems I got (happens randomly):
- application including war file disappears
An: Tomcat Users List
Betreff: Re: Hot deployment - Your experience
Hi,
--- Ursprüngliche Nachricht ---
Von: Bernhard Slominski [EMAIL PROTECTED]
An: 'Tomcat Users List' tomcat-user@jakarta.apache.org
Betreff: Hot deployment - Your experience
Datum: Mon, 13 Jun 2005 14:27:45 +0200
Hi Mino,
just one thing to add to the very good answer from Charl:
I post you my ant sccript, which does all together precompiling and
automatic generation of the web.xml file.
You might take it as a basis for your stuff.
Cheers
Bernhard
!-- do the precompilation --
target
Well there is one big advantage when using precompiled JSPs:
You're sure that all JSPs are compilable, so you don't get any compile
errors on your live site.
That gives your application more stability.
Bernhard
-Ursprngliche Nachricht-
Von: Charl Gerber [mailto:[EMAIL PROTECTED]
It's not that it's not tested.
It can happen very easiliy, when you just forgot to check something in the
version control:
You added a method to a bean, change the JSP, it's working fine in you test
environment, you check in the JSP, but forget the bean, do the release and
you get the compile
it doesn't matter ?
Maybe someone have an idea on what I miss...
--
Nicolas
-Original Message-
From: Bernhard Slominski [mailto:[EMAIL PROTECTED]
Sent: jeudi 16 juin 2005 11:44
To: 'Tomcat Users List'
Subject: AW: Use JSPC
Hi Mino,
just one thing to add to the very good
: Bernhard Slominski [mailto:[EMAIL PROTECTED]
Sent: jeudi 16 juin 2005 11:44
To: 'Tomcat Users List'
Subject: AW: Use JSPC
Hi Mino,
just one thing to add to the very good answer from Charl:
I post you my ant sccript, which does all together precompiling and
automatic generation
Hi Tim,
what you also can do is just checking if the directory of the webapp exists.
So this would be a check on the filesystem and not in Tomcat, but should
work as well.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Tim Diggins [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 23.
Hi Darren,
what I do is to deploy the war file as zip file, then extract it and reload
the applicataion.
It's not very nice, but it's working automatically in an ant script, I did
it because the war file deployment was to unstable.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von:
I don't want to precompile in my build script,
With the precompilation you can do the stuff you need, it automatically
creates the servlet mapping in the web.xml.
The only thing you have to add is the load-on-startup1/load-on-startup
part, but I think you can automate this as well.
So why
We have a custom (non-generated) web.xml, with some taglibs
and servlets defined in there.
Precompilation is tomcat dependend I suppose?
You're right precompliation is tomcat dependent, but it works like this that
the ant task takes your (non-tomcat dependent) web.xml and just adds the
We have a custom (non-generated) web.xml, with some taglibs
and servlets defined in there.
Precompilation is tomcat dependend I suppose?
You're right precompliation is tomcat dependent, but it works
like this that
the ant task takes your (non-tomcat dependent) web.xml and
just
It's even better than that: the webapp itself is portable, without the
Tomcat libraries. The precompilation process just churns
your JSPs into
servlets at build time instead of runtime.
Let me add somthing here, it's right that the servlets are build at compile
time, but they still use
Hi Nils,
two things:
1. I would use an absolute path instead of the realitive one ./hummingbird
I guess jasper just can't pick up your jsps!
2. outputDir: You set it to WEB-INF/classes but what you create are
actually java source files, so this is not right, even tohough it doesn't
explain the
Hi Tim,
Iam sure that Iam using the right tools.jar, and it is containing the
class com.sun.tools.javah.Main
I also think so, because that's what the errormessage says, it cannot find
the requested constructor.
I check my tools.jar (JDK 1.5.0_01) and I found this method signature, which
Hi Kristoffer,
the java files are under ${TOMCAT_HOME}\work\catalina\localhost ...
But you cannot get these files via URI, because that would mean that
everyone can see the sourcecode of your jsp.
It's not quite clear to me how you retrive the sutdent name from the
generated java file.
A better
: URI of *_jsp.java
On Monday 11 July 2005 14:01, Bernhard Slominski wrote:
Hi Kristoffer,
the java files are under ${TOMCAT_HOME}\work\catalina\localhost ...
But you cannot get these files via URI, because that would mean that
everyone can see the sourcecode of your jsp.
It's
How about integrating it in your ant build script?
This changes your preprocessing from runtime to compile time.
Bernhard
-Ursprüngliche Nachricht-
Von: Edward Hibbert [mailto:[EMAIL PROTECTED]
Gesendet: Montag, 18. Juli 2005 11:32
An: tomcat-user@jakarta.apache.org
Betreff:
Hi Joaquim,
I think you always should do a COMPLETE release of the war file.
So you always have an atomic, conistent relase.
When it comes to rollback, versioning etc. you're much better off in having
a complete release as war file.
You can use hot deployment, so when you copy the new war file
Hi,
this is simply not supported in EL!
I submitted this already as an enhancement
https://jsp-spec-public.dev.java.net/issues/show_bug.cgi?id=134
But it won't be in the next release in JSP 2.1, that's for sure.
So you need to do a workaround:
- Use a bean to retrive the constant
- write an EL
Some small addition:
URL Rewriting is only used when cookies are switched off.
From the Servlet Spec:
SRV.7.1.3 URL Rewriting
URL rewriting is the lowest common denominator of session tracking. When a
client will not accept a cookie, URL rewriting may be used by the server as
the basis
for
-Ursprüngliche Nachricht-
Von: Charles P. Killmer [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 2. August 2005 19:08
An: Tomcat Users List
Betreff: RE: Session ID's
Thanks. I will take a look through this.
Charles
-Original Message-
From: Bernhard Slominski [mailto
Hi Richard,
the problem is that your classpath for the jasper path is not correct.
So this Null Pointer exception actually means that some class was not found.
Note that you need all the tomcat libraries in your jaser classpath, as well
as your libs as well.
I post you my script, which is working
Maybe there are a few classfiles missing, which are only used with these two
jsps.
Bernhard
-Ursprüngliche Nachricht-
Von: Ramnish Kalsi [mailto:[EMAIL PROTECTED]
Gesendet: Mittwoch, 17. August 2005 20:52
An: 'Tomcat Users List'
Betreff: JSP Precompilation
I am trying to use
You're both right.
But when you run your Webapplication under non-tomcat container you need the
tomcat libraries.
Also when going to dfferent versions of tomcat, so e.g. from 4 to 5.5 you
might get compatibility issues.
Bernhard
-Ursprüngliche Nachricht-
Von: Allistair Crossley
Hi Alain,
First of all the session is ALWAYS on application scope, this is not an
Tomcat specific behaviour but a requirement of the Specification:
SRV.7.3 Session Scope
HttpSession objects must be scoped at the application (or servlet context)
level.
The underlying mechanism, such as the cookie
Hi Ron,
I don't know about the JSP 2.1 Support in Tomcat, but if you want to try it
out just use Glassfish: https://glassfish.dev.java.net/
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Ron Kiat [mailto:[EMAIL PROTECTED]
Gesendet: Sonntag, 18. September 2005 18:16
An: Tomcat
The session ids in the URL (URL Rewriting) are only used when cookies are
switched off as a fallback, so when cookies are switched on on your machine
you shouldn't see the session Id in the URL.
When you don't need a seesion on your page you can use this page directive
to switch off the session,
on the search
engine listing. Any way to remove that?
Assaf
--- Bernhard Slominski
[EMAIL PROTECTED] wrote:
The session ids in the URL (URL Rewriting) are only
used when cookies are
switched off as a fallback, so when cookies are
switched on on your machine
you shouldn't see the session Id
From the Tomcat docs:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/jasper-howto.html
-Ursprüngliche Nachricht-
Von: Murali [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 29. September 2005 16:54
An: tomcat-user@jakarta.apache.org
Betreff: How to PreCompile JSPs
Hi ,
Can
Hi Michael,
this comes up every so often, so here is just the answer, which I posted
some time ago:
First of all the session is ALWAYS on application scope, this is not an
Tomcat specific behaviour but a requirement of the Specification:
SRV.7.3 Session Scope
HttpSession objects must be scoped
Hi,
you can write a class which handles the loading of the resoucres, so you can
control the behaviour.
We have the resource bundles in the DB, so we can administer it via the DB
without restarting the application
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Roland Carlsson
64 matches
Mail list logo