RE: just one edit.
Are you talking about persistent data? I.e. Are you talking about database concurrency? -Original Message- From: Emilio Miranda [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 21 May 2002 5:39 AM To: Tomcat Users List Subject: RE: just one edit. Hi, really apreciate your help. but What I mean is a case in web. It is: administrator A login to a site and modify data of some user at the same time administrator B are modifying the data of the same user. I would like some message for administrator A, something like a sorry you cant change these data right now . So I want to know if Tomcat could help me in some way Thanks a lot! -Mensaje original- De: Mike Jackson [mailto:[EMAIL PROTECTED]] Enviado el: lunes, 20 de mayo de 2002 13:32 Para: Tomcat Users List Asunto: RE: just one edit. You'll probably want to synchronize on a static object I think. Something like this: public class WhatEver { protected static Object lock = new Object(); public void doStuff() { sychronized( lock ) { // do protected stuff here } } } --mikej -=- mike jackson [EMAIL PROTECTED] -Original Message- From: Emilio Miranda [mailto:[EMAIL PROTECTED]] Sent: Monday, May 20, 2002 11:15 AM To: Tomcat Users List Subject: just one edit. Hello, I am sorry if that is an offtopic. How can I be sure that only one user is changing some data at the time? could Tomcat help me on that? I mean , supouse that one user change a name an another try to change at the same time. Thanks a lot! -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Squeezing performance out of Tomcat
One thing that is totally off left field, but may help... We had a similar lag problem, - on one of our clients 100mb network with a HP switch, we were getting lags on images etc. The problem was that it would go to the central server to resolve all IP's and especially domain names. Thus we simply excluded (specifically - do not bypass all local addresses) all the relevant addresses. In internet explorer - connection| Lan Settings | Advanced As I said... after investigating for hours, if not days for trying to get tomcat performance ... this is what I came down to. -Original Message- From: Pascal Forget [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 6 February 2002 2:24 PM To: [EMAIL PROTECTED] Subject: Squeezing performance out of Tomcat Hi, I am getting long response times from a JSP served by Apache1.3.23 - mod_jk - Tomcat 4.02 B2. The page always takes less than 100 ms to generate, but still it takes more than 3 seconds for a browser (running on the local 10MBit network) to get the result. The html page that is generated is less than 1kb. Can someone offer tips on how we can squeeze more speed out of Apache-Tomcat? The problem is not due to excessive logging, as the various logs are minuscule and don't grow much in size with each new request. Any help or suggestions would be greatly appreciated. Thanks, Pascal Forget -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Need to refresh .jsp page around five times before it worksproperly
We are using tomcat 4 and we get a blank page if any attribute coming into the page is null... We are using tomcat standalone... I have no idea how to fix it... but I was about to post a question... Any body know why?? -Original Message- From: David Morsberger [mailto:[EMAIL PROTECTED]] Sent: Monday, 24 December 2001 9:36 AM To: Tomcat Users List Subject: Re: Need to refresh .jsp page around five times before it worksproperly We have a similar problem with Tomcat 3.2 and 3.3. The web page is sometimes blank (no error) after the JSP is compiled. If the page is refreshed / reloaded then the page is properly displayed. From: Brandon Cruz [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] Date: Sun, 23 Dec 2001 14:03:21 -0600 To: Tomcat Users List [EMAIL PROTECTED] Subject: Need to refresh .jsp page around five times before it works properly I am using tomcat 3.2.4, Ajp13, and apache 1.3. Every so often, when I go to one of the .jsp pages on my site, I get a 500, internal server error. There is no info posted to any log, and I need to hit refresh on the browser window a bunch of times before it finally comes up correctly. Does anyone know what causes this condition? I was using tomcat 3.2.1 with Ajp12 before, and never had this problem. Is it Ajp13 that causes this? Thanks in advance for any help! Brandon -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Micael mac Grene: DataSource and Pooled Connection
I am not 100% sure, but I am pretty sure that the PostgreSQL (7.1.2) JDBC driver does not yet support Pooled DataSource connections. That is what they have said on the PgSql JDBC list, but please correct me if I am wrong as we would love to use pooled datasource connections.. I believe Postgres 7.2 ( JDBC driver) might support it... Amit -Original Message- From: Micael Padraig Og mac Grene [mailto:[EMAIL PROTECTED]] Sent: Friday, 14 December 2001 9:41 AM To: Tomcat Users List Subject: Micael mac Grene: DataSource and Pooled Connection At 02:13 PM 12/13/01 -0800, you wrote: On Thu, 13 Dec 2001, christophe marcourt wrote: Date: Thu, 13 Dec 2001 21:07:47 +0100 From: christophe marcourt [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: DataSource and Pooled Connection I have a stupid question ? in the JNDI tomcat how to, it says : The J2EE Platform Specification requires J2EE Application Servers to make available a DataSource implementation (that is, a connection pool for JDBC connections) for this purpose. Tomcat 4 offers exactly the same support Do I understand right ? A DataSource retrieve by JNDI in tomcat 4.0.1 is a Pooled Connection ? It's actually a javax.sql.DataSource implementation. Christophe Craig First, I think I speak for thousands in thanking you for your contributions. Despite the flame wars, I hope you guys and gals know how much we appreciate your efforts. Second, could you expand on what Tomcat puts into a pooled connection for javax.sql.DataSource? I have been using Postgresql and getting a pooled connection with JBoss and Tomcat and really do not understand what the hay is going on. Is that from JBoss? I am not getting a pooled connection from Postgresql, even though I though I was. I so far have just been using Tomcat 3.2.3, I think it is, and JBoss and am using a standalone application thus far with Tomcat. But, I definely am getting a pooled connection according to ps aux on my box. I am getting an initial pool of five conncetions, I think. Maybe six. Thanx, -- micael -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: SERVLET CACHING PROBLEM IN TOMCAT- SNODX
That does not necessarily solve the problem. We were running Tomcat 3.1/3.2 for close to 12 months with reloadable=true set, and yet tomcat would not reload class files without restarting... My recommendation would be to upgrade to tomcat4, will solve all your problems... the upgrade is not hard. Amit Kelkar -Original Message- From: Volker Leidl [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 12 December 2001 9:46 PM To: Tomcat Users List Subject: RE: SERVLET CACHING PROBLEM IN TOMCAT- SNODX Add reloadable=true to your webb apps context tag in server.xml. Volker. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, December 12, 2001 9:01 AM To: [EMAIL PROTECTED] Subject: SERVLET CACHING PROBLEM IN TOMCAT- SNODX Greetings, I am facing a servlet caching problem in Tomcat. I create a servlet .java file compile it and put it in the webapps folder of the TOMCAT_HOME folder. I start the Tomcat server and invoke the servlet via http://localhost:TomCat port no/servlet/Servlet name in Netscpe. It gets invoked. All is well uptil now. Problem comes when I make changes in the .java file, recompile it, place it in the same TOMCAT_HOME/webapps folder, and again invoke it in Netscape via http://localhost:Tomcat Port No/servlet/Servlet name. The ALTERED sevlet does NOT get invoked, the old servlet is getting invoked. This must mean Tomcat is caching its sevlets somewhere, and it is picking up the servlets from that cache, ignoring the actual .class servlet file in the webapps folder. Maybe the cache gets cleared everytime Tomcat restarts, but I find it inconvenient to frequently restart Tomcat. So what is the one time solution to this servlet caching problem, WITHOUT HAVING TO REGULARLY RESTART TOMCAT? Will a startup servlet running continuosly alongwith Tomcat, performing the servlet cache cleaning operation- regularly say every 10 seconds- solve the problem? If so then what should be the coding of the servlet? Should I use classes of the java.lang.ref package- PhantomReference e.t.c- ( http://java.sun.com/products/jdk/1.2/docs/api/java/lang/ref/packag e-summary.html )? Or can some changes in server.xml do the trick? I have Apache 1.3.19, Tomcat 3.23 installed, configured and running on RedHat Linux 6.2 platform. Waiting for an early response. Thanks in advance. SNODX -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Web Apps
If you just type http://hostname:port (e.g. http://localhost:8080) it will bring up the default tomcat screen... In Tomcat documentation there is a number of tutes for application developers Amit -Original Message- From: Duncan Smith [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 12 December 2001 8:37 PM To: [EMAIL PROTECTED] Subject: Web Apps Can anybody please point me in the direction for a good help/tutorial file for editing and adding Web Apps in Tomcat 4? Cheers Duncan -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Why do i have to keep on restarting Tomcat?
Not every database API supports connection pooling... Take Postgres for example... The JDBC driver for 7.1.2/7.2 does not support connection pooling... -Original Message- From: Micael Padraig Og mac Grene [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 12 December 2001 1:33 AM To: Tomcat Users List Subject: RE: Why do i have to keep on restarting Tomcat? At 01:00 PM 12/11/01 +, you wrote: Does anybody know where i can get a connection pool called DbBroker from www.javaexchange.com, as it appears as though javaexchange no longer exists Just wondering if you know that you get a pool automatically when you go to javax.sql.*. -micael -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Tomcat shutdown error
Try using ./startup.sh.. You may have a environment variables problem -Original Message- From: Matt Sales [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 21 November 2001 9:15 AM To: Tomcat Users List Subject: Tomcat shutdown error Hello, I've recently installed Tomcat-4.0.1 and am running it on RH 7.2 with apache 1.3.22. Occasionally, when I shut down tomcat using bin/catalina.sh stop, I get the following exception and stack trace dump: Catalina.stop: java.net.ConnectException: Connection refused java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:320) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:133) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:120) at java.net.Socket.init(Socket.java:273) at java.net.Socket.init(Socket.java:100) at org.apache.catalina.startup.Catalina.stop(Catalina.java:826) at org.apache.catalina.startup.Catalina.execute(Catalina.java:683) at org.apache.catalina.startup.Catalina.process(Catalina.java:179) at java.lang.reflect.Method.invoke(Native Method) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243) I don't know if I've got it configured incorrectly or what, but does anyone know what might be causing this? It's like it's not even running, even though it's in the process list via ps -A. -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window
Hi Geoff, Thanks for all the reponses... Here is the latest I have on the issue: * There seems to be a issue with IE 6, with can be fixed up with some options * The session seems to keep alive if we use our full domain name (postmodern.com.au), but not with a local address such as 192.168.x.x But seems to be causing some error once in a while (tests still in progress) * IE 5 has no problems with local address or full name * Your session example worked with local address with session surviving. I have no idea why it would resolve with the full domain and not the local address... but either way seems very very weird. Do you have any theories on why a session might nullify in such a way?? Thanks, Amit -Original Message- From: Geoff Howard [mailto:[EMAIL PROTECTED]] Sent: Thursday, 15 November 2001 2:21 AM To: 'Amit Kelkar'; '[EMAIL PROTECTED]' Subject: RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window I only meant to ask if you were using the default Tomcat sessions, or perhaps some customized implementation via an app server, etc. I'm not entirely clear from your description exactly what is going on, but if you have the examples context installed somewhere, try this: - Go to /examples/servlet/SessionExample - note the session id you've been assigned. - In the IE browser address line type in javascript:void(window.open('/examples/servlet/SessionExample')); - In the new window that opens, note that the session id is identical - Close the new window. - Refresh the original page. - Note the session id remains active. I'm a little suspicious that opening a window like this is not entirely the same as placing the window.open directly into the page -- you may want to try modifying the default SessionExample.java to include a window.open for testing. Does this represent a simplified version of the situation you have, but with opposite behavior? If so, then I'd be suspicious that something else in your code is really the culprit. If not, can you modify the above example to clarify what is going on in the background. Geoff -Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 8:38 PM To: Geoff Howard Subject: RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window I'm not quite sure I understand what you mean. I am using the default tomcat4 settings, so I am using cookies I guess... Amit -Original Message- From: Geoff Howard [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 14 November 2001 4:24 AM To: 'Amit Kelkar' Subject: RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window How are you implementing your sessions? Geoff -Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 10:01 AM To: Tomcat Users List Subject: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window -Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 13 November 2001 6:41 PM To: Tomcat Users List Subject: internet explorer nullifies session on open new window The application we are coding requires a new window to be opened. This new window may just contain a JavaScript calendar or a JSP page (dispatched by a servlet). We have been using Internet Explorer 5 till recently to run the application and this has been fine. But we recently upgraded to I.E. 5.5 and 6.0. In both of the new versions, when a new window is opened and then closed, the session in the original window gets nullified. For example, there are places where I need to see a calendar, so I open this calendar in a new window, I use the calendar, then I close the calendar window. I then press a button (in the main window) to go to another page in my application, where all the session values are now displayed as null. Subsequent system error statements show that the session is indeed null. I am not sure this is a tomcat problem or a IE problem (probably a IE problem), but was wondering if anybody has experienced anything similar and if they have solved the problem... Note: I am using tomcat 4.01 Thanks much in advance, Amit Kelkar -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window
-Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 13 November 2001 6:41 PM To: Tomcat Users List Subject: internet explorer nullifies session on open new window The application we are coding requires a new window to be opened. This new window may just contain a JavaScript calendar or a JSP page (dispatched by a servlet). We have been using Internet Explorer 5 till recently to run the application and this has been fine. But we recently upgraded to I.E. 5.5 and 6.0. In both of the new versions, when a new window is opened and then closed, the session in the original window gets nullified. For example, there are places where I need to see a calendar, so I open this calendar in a new window, I use the calendar, then I close the calendar window. I then press a button (in the main window) to go to another page in my application, where all the session values are now displayed as null. Subsequent system error statements show that the session is indeed null. I am not sure this is a tomcat problem or a IE problem (probably a IE problem), but was wondering if anybody has experienced anything similar and if they have solved the problem... Note: I am using tomcat 4.01 Thanks much in advance, Amit Kelkar -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window
Thanks Jim for your reply... It does not happen when the application is accessed for the first time ever by IE, but every time after that. If I try to repair the installation, it again works for the first time but never again. I have not idea why it is happening. Is there any possibility it could the application or tomcat?? This is very bad, as it was not happening before and we are in final testing, hoping to deploy soon!!! Amit -Original Message- From: Jim Urban [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 14 November 2001 2:21 AM To: Tomcat Users List Subject: RE: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window Our application does the same thing (openning child browser windows and closing them) and we have no problems with IE 5.5. We have not tried I.E. 6.0 yet, so I can't comment on that. We are running Tomcat 4.0 on Win NT and 2K. Jim -Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 9:01 AM To: Tomcat Users List Subject: REPOST: NEED HELP URGENT:: internet explorer nullifies session on open new window -Original Message- From: Amit Kelkar [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 13 November 2001 6:41 PM To: Tomcat Users List Subject: internet explorer nullifies session on open new window The application we are coding requires a new window to be opened. This new window may just contain a JavaScript calendar or a JSP page (dispatched by a servlet). We have been using Internet Explorer 5 till recently to run the application and this has been fine. But we recently upgraded to I.E. 5.5 and 6.0. In both of the new versions, when a new window is opened and then closed, the session in the original window gets nullified. For example, there are places where I need to see a calendar, so I open this calendar in a new window, I use the calendar, then I close the calendar window. I then press a button (in the main window) to go to another page in my application, where all the session values are now displayed as null. Subsequent system error statements show that the session is indeed null. I am not sure this is a tomcat problem or a IE problem (probably a IE problem), but was wondering if anybody has experienced anything similar and if they have solved the problem... Note: I am using tomcat 4.01 Thanks much in advance, Amit Kelkar -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
internet explorer nullifies session on open new window
The application we are coding requires a new window to be opened. This new window may just contain a JavaScript calendar or a JSP page (dispatched by a servlet). We have been using Internet Explorer 5 till recently to run the application and this has been fine. But we recently upgraded to I.E. 5.5 and 6.0. In both of the new versions, when a new window is opened and then closed, the session in the original window gets nullified. For example, there are places where I need to see a calendar, so I open this calendar in a new window, I use the calendar, then I close the calendar window. I then press a button (in the main window) to go to another page in my application, where all the session values are now displayed as null. Subsequent system error statements show that the session is indeed null. I am not sure this is a tomcat problem or a IE problem (probably a IE problem), but was wondering if anybody has experienced anything similar and if they have solved the problem... Note: I am using tomcat 4.01 Thanks much in advance, Amit Kelkar -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]