RE: Tomcat LoadBalancing
Hello, My organisatin is also planning to use NginX web server by replacing apache2 web server in this configuration as a front end Load balancer and then provide load to tomcat. will it work or we should go with apache. Deepak - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
lock session in distributed environment
Hi All! I have an app which rely on session locking and its key point here. Everything work on single tomcat instance, but its completly broken in distributed env. So i want to know is there any way to get my app working without complete redesing? I need lock all incoming requests untill business logic will be done, this lock must be available on all nodes in cluster. any advise? Thanks -- If you think of MS-DOS as mono, and Windows as stereo, then Linux is Dolby Digital and all the music is free... pgpgF2XgLtY1O.pgp Description: PGP signature
Re: lock session in distributed environment
Roman Makurin wrote: Hi All! I have an app which rely on session locking and its key point here. Everything work on single tomcat instance, but its completly broken in distributed env. So i want to know is there any way to get my app working without complete redesing? I need lock all incoming requests untill business logic will be done, this lock must be available on all nodes in cluster. any advise? Yes. Since about 100 years, it is know that the speed of light is the absolute speed limit in the Universe, and that consequently the concept of simultaneity is a fallacy. Thus if your application is such that it would rely on something being simultaneously available on different servers to stop something from happening, then your application is badly designed, and no external mechanism is going to be able to fix that. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: lock session in distributed environment
Op vrijdag, 15 oktober 2010 10:02 schreef Roman Makurin dro...@gmail.com: Hi All! I have an app which rely on session locking and its key point here. Everything work on single tomcat instance, but its completly broken in distributed env. So i want to know is there any way to get my app working without complete redesing? I need lock all incoming requests untill business logic will be done, this lock must be available on all nodes in cluster. any advise? Thanks -- If you think of MS-DOS as mono, and Windows as stereo, then Linux is Dolby Digital and all the music is free... This is something a database can do very well. There are also things like a distributed HashMap which you might use to do locking in your setup. But that probably is what you see as complete redesign (and it is :-) ). Ronald.
Re: lock session in distributed environment
On Fri, Oct 15, 2010 at 12:34:10PM +0200, Ronald Klop wrote: Op vrijdag, 15 oktober 2010 10:02 schreef Roman Makurin dro...@gmail.com: Hi All! I have an app which rely on session locking and its key point here. Everything work on single tomcat instance, but its completly broken in distributed env. So i want to know is there any way to get my app working without complete redesing? I need lock all incoming requests untill business logic will be done, this lock must be available on all nodes in cluster. any advise? Thanks -- If you think of MS-DOS as mono, and Windows as stereo, then Linux is Dolby Digital and all the music is free... This is something a database can do very well. There are also things like a distributed HashMap which you might use to do locking in your setup. But that probably is what you see as complete redesign (and it is :-) ). Ronald. Looks like HashMap is like distributed HttpSession object, but does it support locking? Eg. I lock session at first node and all other nodes r aware of this lock. -- If you think of MS-DOS as mono, and Windows as stereo, then Linux is Dolby Digital and all the music is free... pgphAzsQHAife.pgp Description: PGP signature
Re: lock session in distributed environment
Op vrijdag, 15 oktober 2010 13:00 schreef Roman Makurin dro...@gmail.com: On Fri, Oct 15, 2010 at 12:34:10PM +0200, Ronald Klop wrote: Op vrijdag, 15 oktober 2010 10:02 schreef Roman Makurin dro...@gmail.com: Hi All! I have an app which rely on session locking and its key point here. Everything work on single tomcat instance, but its completly broken in distributed env. So i want to know is there any way to get my app working without complete redesing? I need lock all incoming requests untill business logic will be done, this lock must be available on all nodes in cluster. any advise? Thanks -- If you think of MS-DOS as mono, and Windows as stereo, then Linux is Dolby Digital and all the music is free... This is something a database can do very well. There are also things like a distributed HashMap which you might use to do locking in your setup. But that probably is what you see as complete redesign (and it is :-) ). Ronald. Looks like HashMap is like distributed HttpSession object, but does it support locking? Eg. I lock session at first node and all other nodes r aware of this lock. If you are locking with synchronized or something like that than it doesn't work between different JVM's. Ronald.
RE: Starting/Stopping Tomcat from Java program
Since the question is how to do this from Java, don't go shelling out net start/stop on Windows :) Use JNA (http://jna.dev.java.net) , someone just recently committed complete support for Windows services. Stopping a service looks like this: W32ServiceManager serviceManager = new W32ServiceManager(); W32Service service = serviceManager.openService(tomcat, Winsvc.SERVICE_ALL_ACCESS); service.stopService(); service.close(); -dB. dB. @ dblock.org Moscow|Geneva|Seattle|New York -Original Message- From: André Warnier [mailto:a...@ice-sa.com] Sent: Monday, October 11, 2010 9:34 AM To: Tomcat Users List Subject: Re: Starting/Stopping Tomcat from Java program Hi. I do not really understand the issue here. If you are under Windows, with Tomcat running as a Service, then you can just run the commands net start tomcat6 / net stop tomcat6 to start/stop tomcat. If you are under Linux, then you can just issue the command /etc/init.d/tomcat6 (start|stop). Under most Unixes, the procedure is similar. So where is the problem ? Rob Gregory wrote: I call the scripts via code to both stop and start Tomcat. There is a problem with even calling these scripts via Unix unless you change (cd) into the bin directory before running startup.sh as the log paths are generated relative to the startup.sh location. String strCatalinaBin = System.getenv(CATALINA_HOME) + \\bin\\; File objDir = new File(strCatalinaBin); r = Runtime.getRuntime(); p = r.exec(new String[] { cmd.exe, /C, start, strCatalinaBin + catalina.bat, start }, null, objDir); p.waitFor(); p.destroy(); Hope this helps. Rob -Original Message- From: Karthik Nanjangude [mailto:karthik.nanjang...@xius-bcgi.com] Sent: 11 October 2010 13:26 To: Tomcat Users List Subject: RE: Starting/Stopping Tomcat from Java program Hi Probably u may need to use Embedded version of TOMCAT to do this activity... With regards karthik -Original Message- From: kshitij chandrasen [mailto:kshtjchnd...@gmail.com] Sent: Monday, October 11, 2010 2:49 PM To: users@tomcat.apache.org Subject: Starting/Stopping Tomcat from Java program Hi, I've to write methods on calling which i'd be able to start and stop the tomcat app server. I tried this - I'm using Tomcat 6.0.26. String[] command = new String[4]; command[0] = cmd; command[1] = /C; command[2] = startup.bat; command[3] = C:\\; String x[] = {PATH=C:\\Program Files\\Apache Software Foundation\\Apache Tomcat 6.0.26\\bin,CATALINA_HOME=C:\\Program Files\\Apache Software Foundation\\Apache Tomcat 6.0.26,JAVA_HOME=C:\\Program Files\\Java\\jdk1.6.0_21,JRE_HOME=C:\\Program Files\\Java\\jre6}; Process p = Runtime.getRuntime().exec(command,x); This gives me a strange windows error saying - The system cannot find the file -Djava.util.logging.config.file=C:\Program Files\Apache Software Foundation\Apache Tomcat 6.0.26\conf\logging.properties, while it actually exists. If instead of setting the path, I give the absolute path of startup.bat in command[3], it works fine - Process p = Runtime.getRuntime().exec(cmd /C start C:\\broadway\\bat\\startup.bat); //I copied the startup.bat to a folder and ran it from there, it worked fine. Please give me pointers to the right direction! -- Kshitij Chandrasen Engineer, Software Engineering, Cisco Systems, CBSBU Engineering. -- Kshitij Chandrasen Engineer, Software Engineering, Cisco Systems, CBSBU Engineering. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Kerberos authentication
Jump :) Waffle is windows-only and it seems like this is a Solaris implementation. I have some good news though. Someone just uploaded a big patch for a windows authentication provider that uses JCIFs (which does Kerberos and more), which works on top of Samba on *nix. dB. @ dblock.org Moscow|Geneva|Seattle|New York -Original Message- From: Pid [mailto:p...@pidster.com] Sent: Monday, October 11, 2010 3:27 AM To: Tomcat Users List Subject: Re: Kerberos authentication On 11/10/2010 07:45, Igor Galić wrote: Hello Happy people, I'm cross-posting this to tomcat and archiva. In our company we have a well established Active Directory infrastructure, I'm running an Apache Archiva 1.3.1 installation in Tomcat 6, on Solaris 10. The OS has been Kerberos enabled and I would very much like to make use of this for Tomcat/Archiva in order to provide secure authenticated access to it. We need to provide secure and scalable authentication. Thus, everything else has been ruled out: * No authentication -- not good, because we need some form of auditing on who uploaded/deployed what (i.e.: who broke it) * SSH/SCP doesn't scale from an administration point of view (i.e.: we'd have to do something. That could be done wrong, forgotten about or any number of things when people have to do mundane tasks) * Basic authentication -- not so good from an admin's point of view, because clear-text passwords are stored in a Developer's settings.xml. Not so good from a developer's point of view, because s/he has to change their password in settings.xml every month or so. (sic) Given the lack of (official) documentation: http://www.google.com/search?hl=ensitesearch=tomcat.apache.orgq=kerb eros+OR+krbaq=faqi=aql=oq=gs_rfai= http://wiki.apache.org/tomcat/FrontPage?action=fullsearchcontext=180; value=kerberos+krbfullsearch=Text http://www.google.at/search?client=operarls=enq=site:archiva.apache. org+kerberos+OR+krbsourceid=operaie=utf-8oe=utf-8 http://www.google.com/search?hl=endomains=cwiki.apache.org%2FARCHIVA; sitesearch=cwiki.apache.org%2FARCHIVAq=kerberos+OR+krbsitesearch=cwi ki.apache.org%2FARCHIVAaq=faqi=aql=oq=gs_rfai= I was wondering if that's even in remotely in scope of either Project. It seems fairly simple to integrate Tomcat into a Kerberos Infrastructure (although I haven't had the time to do this so far), the question that remains unanswered to me is how to make Archiva profit from such integration. I appreciate any kind of feedback from people who similarily are stuck between a rock and a hard place, and even more so from those who have a sensible solution :) So long, i Try http://waffle.codeplex.com/. The author lurks hereabouts will jump in shortly, no doubt. p
Re: Inconsistent output of Java 5 enums
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Oliver, On 10/15/2010 1:40 AM, Oliver Siegmar wrote: Am Thursday 14 October 2010 schrieb Christopher Schultz: So I'm surprised that Oliver is getting that weird output. I wrote in my initial mail to this list I have an enum that has an overridden toString() method. I thought it was clear what that means, obviously it was not. Sorry for the confusion. So this is a simplified example for my enum: You're right: that was stupid of me. I had forgotten your toString method. Uh... why override the toString method like that? The thing is, that EL is using the name() method to print the enum and JSTL is using toString(). I did not expect a different enum treatment here. If you need it to emit the same thing, doing: c:out value=${myEnumValue.name}/ ...will certainly work across these versions. One possible explaination is that Pid is right when he says The related sources jar was built in 2006, and the pom for that indicates that it's dependent on JSP 2.0, rather than 2.1. Does anyone know if a true JSTL 1.2 using JSP 2.1 is available in the maven repository? Anyway I will try a manually downloaded version tonight. Try getting it from the canonical https://jstl.dev.java.net/, and ask them about their Maven repo submission. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4YREACgkQ9CaO5/Lv0PDH8wCglvc2kcXjbc1ktxQdvOW5UOxl OTkAoLzly4kRGfrWiPTvLvLHV7hEuH3+ =ClL+ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
JSESSIONID Cookie handle customizing
Hi Folks! I want to put some information on the JSESSIONID that tomcat generates. I'm using aspect programming so I don´t need to change the tomcat code itself. The thing is that I found many points where tomcat handle this information, I checked and notice that the head parser is made on the method parseSessionId and parseSessionCookiesId in the class org.apache.catalina.connector.CoyoteAdapter. I'm not convinced that there is the perfect point to make my code injection. I need to find out the exactly point that this information (Cookie JSESSIONID=22) is received by Tomcat and where tomcat sends this information to the browser, in other words, the first contact with this information when browser sends and the last contact before sending to browser. Thanks. Juliano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat LoadBalancing
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Deepak, On 10/15/2010 2:36 AM, Deepak Pal wrote: My organization is also planning to use NginX web server by replacing apache2 web server I'm always nervous about running pre-1.0 things in production. Exception maybe OpenSSL :) in this configuration as a front end Load balancer and then provide load to tomcat. Using what kind of connections? will it work or we should go with apache. GIYF: http://stackoverflow.com/questions/1746815/configure-nginx-for-jboss-tomcat http://www.ruby-forum.com/topic/194600 I'm sure there are other relevant sites. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4YocACgkQ9CaO5/Lv0PC0wwCfRUxmIkLbqP20qMJsQSzgVqjM CWgAn2j0BKhrYHLUtVajqThdgzx5cvCk =8fgk -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Chris, On Friday 15 October 2010 16:11:29 Christopher Schultz wrote: not. Sorry for the confusion. So this is a simplified example for my enum: You're right: that was stupid of me. I had forgotten your toString method. Uh... why override the toString method like that? Well, as written in java.lang.Enum: An enum type should override this method when a more programmer-friendly string form exists. The thing is, that EL is using the name() method to print the enum and JSTL is using toString(). I did not expect a different enum treatment here. If you need it to emit the same thing, doing: c:out value=${myEnumValue.name}/ No, because that would call a method getName() which doesn't exist - the method is named name(). Bye Oliver - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat LoadBalancing
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Chuck, On 10/15/2010 12:10 AM, Caldarale, Charles R wrote: From: Deepak Pal [mailto:deepak@orkash.com] Subject: Re: Tomcat LoadBalancing Should I continue with this configuration or make some changes to it. Since you're already front-ending Tomcat with httpd, you should use httpd as the load balancer. That's a proven and widely used technique. +1 Deepak's archetecture document shows /way/ more hardware and sofwtare than is necessary. Since there's already a single point of failure (the topmost Apache httpd instance), you may as well use that to directly load-balance the bottom-most Tomcat instances. That eliminates 6 of the 10 logical servers in your diagram without, IMO, any loss of capability. It will certainly improve performance, too, without all that needless re-proxying. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4Y08ACgkQ9CaO5/Lv0PCCwQCgkNaT4r9ON5nGayDu7KzBD2IV KKUAoJt9h8WB1PDmhlRRbvvK6luGNnQB =khy+ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Oliver, On 10/15/2010 10:19 AM, Oliver Siegmar wrote: Chris, On Friday 15 October 2010 16:11:29 Christopher Schultz wrote: not. Sorry for the confusion. So this is a simplified example for my enum: You're right: that was stupid of me. I had forgotten your toString method. Uh... why override the toString method like that? Well, as written in java.lang.Enum: An enum type should override this method when a more programmer-friendly string form exists. Fair enough. I feel like VALID versus INVALID (which could be confusing in this case) would be plenty programmer-friendly. The thing is, that EL is using the name() method to print the enum and JSTL is using toString(). I did not expect a different enum treatment here. If you need it to emit the same thing, doing: c:out value=${myEnumValue.name}/ No, because that would call a method getName() which doesn't exist - the method is named name(). c:out value=${myEnumValue.getName()}/ ? Or, just consistently use EL, since that actually works as you expect. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4Y7MACgkQ9CaO5/Lv0PAeewCdGjswzmpXGShPgpLnYtt74CDv Y04AoJkjy6pgZyXQuvMsA5SFv9HpAQaH =pZSv -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
On 15/10/2010 15:22, Christopher Schultz wrote: Oliver, On 10/15/2010 10:19 AM, Oliver Siegmar wrote: Chris, On Friday 15 October 2010 16:11:29 Christopher Schultz wrote: not. Sorry for the confusion. So this is a simplified example for my enum: You're right: that was stupid of me. I had forgotten your toString method. Uh... why override the toString method like that? Well, as written in java.lang.Enum: An enum type should override this method when a more programmer-friendly string form exists. Fair enough. I feel like VALID versus INVALID (which could be confusing in this case) would be plenty programmer-friendly. The thing is, that EL is using the name() method to print the enum and JSTL is using toString(). I did not expect a different enum treatment here. If you need it to emit the same thing, doing: c:out value=${myEnumValue.name}/ No, because that would call a method getName() which doesn't exist - the method is named name(). c:out value=${myEnumValue.getName()}/ I don't think that'll work in 6.0. Or, just consistently use EL, since that actually works as you expect. +1 'c:out' seems surplus. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
Re: JSESSIONID Cookie handle customizing
On 15/10/2010 15:15, Juliano Daloia de Carvalho wrote: Hi Folks! I want to put some information on the JSESSIONID that tomcat generates. I'm using aspect programming so I don´t need to change the tomcat code itself. What information? The thing is that I found many points where tomcat handle this information, I checked and notice that the head parser is made on the method parseSessionId and parseSessionCookiesId in the class org.apache.catalina.connector.CoyoteAdapter. I'm not convinced that there is the perfect point to make my code injection. You are planning to inject code into the container, from a web application? p I need to find out the exactly point that this information (Cookie JSESSIONID=22) is received by Tomcat and where tomcat sends this information to the browser, in other words, the first contact with this information when browser sends and the last contact before sending to browser. Thanks. Juliano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
What is the lifecycle of the apache tribes channel?
Hi, I'm using apache tribes for messaging between nodes within a cluster. My implementation bases on the quickstart example that is part of the related documentation. At the moment there is Context Listener that starts the communication like this: myChannel = new GroupChannel(); this.msgListener = msgListener; this.mbrListener = mbrListener; //attach the listeners to the channel myChannel.addMembershipListener(mbrListener); myChannel.addChannelListener(msgListener); //start the channel myChannel.start(Channel.DEFAULT); This is a singleton instance and is used for sending messages the whole lifecycle of my webapplication. I don't like this singleton and I'm wondering if it is possible to start the channel everytime I need to send a message? with kind regards Michael - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Res: JSESSIONID Cookie handle customizing
I'll inject code using an agent. The thing is that I need to know for sure the message entering point on Tomcat, and the leaving point also, so I can be able to sniff if the clients message has the Cookie info with JSESSIONID= or not. and before sending to check if tomcat sent set-cookie on header so I can make the change needed. - Mensagem original De: Pid p...@pidster.com Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 12:20:37 Assunto: Re: JSESSIONID Cookie handle customizing On 15/10/2010 15:15, Juliano Daloia de Carvalho wrote: Hi Folks! I want to put some information on the JSESSIONID that tomcat generates. I'm using aspect programming so I don´t need to change the tomcat code itself. What information? The thing is that I found many points where tomcat handle this information, I checked and notice that the head parser is made on the method parseSessionId and parseSessionCookiesId in the class org.apache.catalina.connector.CoyoteAdapter. I'm not convinced that there is the perfect point to make my code injection. You are planning to inject code into the container, from a web application? p I need to find out the exactly point that this information (Cookie JSESSIONID=22) is received by Tomcat and where tomcat sends this information to the browser, in other words, the first contact with this information when browser sends and the last contact before sending to browser. Thanks. Juliano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: What is the lifecycle of the apache tribes channel?
On 15/10/2010 16:45, Michael Knümann wrote: Hi, I'm using apache tribes for messaging between nodes within a cluster. My implementation bases on the quickstart example that is part of the related documentation. At the moment there is Context Listener that starts the communication like this: Please start an entirely new message, rather than editing a reply to an existing email - which leaves the thread mail headers intact is referred to as 'thread hijacking'. p 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
Re: Res: JSESSIONID Cookie handle customizing
On 15/10/2010 17:02, Juliano Daloia de Carvalho wrote: I'll inject code using an agent. The thing is that I need to know for sure the message entering point on Tomcat, and the leaving point also, so I can be able to sniff if the clients message has the Cookie info with JSESSIONID= or not. and before sending to check if tomcat sent set-cookie on header so I can make the change needed. Why? What does the code do that can't be done via a Servlet Filter? p - Mensagem original De: Pid p...@pidster.com Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 12:20:37 Assunto: Re: JSESSIONID Cookie handle customizing On 15/10/2010 15:15, Juliano Daloia de Carvalho wrote: Hi Folks! I want to put some information on the JSESSIONID that tomcat generates. I'm using aspect programming so I don´t need to change the tomcat code itself. What information? The thing is that I found many points where tomcat handle this information, I checked and notice that the head parser is made on the method parseSessionId and parseSessionCookiesId in the class org.apache.catalina.connector.CoyoteAdapter. I'm not convinced that there is the perfect point to make my code injection. You are planning to inject code into the container, from a web application? p I need to find out the exactly point that this information (Cookie JSESSIONID=22) is received by Tomcat and where tomcat sends this information to the browser, in other words, the first contact with this information when browser sends and the last contact before sending to browser. Thanks. Juliano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
Res: Res: JSESSIONID Cookie handle customizing
I need to change the value of the sessionID. If I let this to be done on the servlet, tomcat won't be able to identify the real session, and will send a redirect to login page. - Mensagem original De: Pid p...@pidster.com Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 13:19:54 Assunto: Re: Res: JSESSIONID Cookie handle customizing On 15/10/2010 17:02, Juliano Daloia de Carvalho wrote: I'll inject code using an agent. The thing is that I need to know for sure the message entering point on Tomcat, and the leaving point also, so I can be able to sniff if the clients message has the Cookie info with JSESSIONID= or not. and before sending to check if tomcat sent set-cookie on header so I can make the change needed. Why? What does the code do that can't be done via a Servlet Filter? p - Mensagem original De: Pid p...@pidster.com Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 12:20:37 Assunto: Re: JSESSIONID Cookie handle customizing On 15/10/2010 15:15, Juliano Daloia de Carvalho wrote: Hi Folks! I want to put some information on the JSESSIONID that tomcat generates. I'm using aspect programming so I don´t need to change the tomcat code itself. What information? The thing is that I found many points where tomcat handle this information, I checked and notice that the head parser is made on the method parseSessionId and parseSessionCookiesId in the class org.apache.catalina.connector.CoyoteAdapter. I'm not convinced that there is the perfect point to make my code injection. You are planning to inject code into the container, from a web application? p I need to find out the exactly point that this information (Cookie JSESSIONID=22) is received by Tomcat and where tomcat sends this information to the browser, in other words, the first contact with this information when browser sends and the last contact before sending to browser. Thanks. Juliano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Res: JSESSIONID Cookie handle customizing
From: Juliano Daloia de Carvalho [mailto:judac2...@yahoo.com.br] Subject: Res: Res: JSESSIONID Cookie handle customizing I need to change the value of the sessionID. Why? Using a separate parameter or cookie to hold your specific additional information would seem to be a much more workable solution - assuming you even need to do that. You could just store the additional information in the session object, and not bother with sending it over the wire. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Hello, now I tried with jstl-api-1.2.jar and jstl-impl-1.2.jar downloaded from https://jstl.dev.java.net/download.html - same result. Am Friday 15 October 2010 schrieb Christopher Schultz: Uh... why override the toString method like that? Well, as written in java.lang.Enum: An enum type should override this method when a more programmer-friendly string form exists. Fair enough. I feel like VALID versus INVALID (which could be confusing in this case) would be plenty programmer-friendly. Taht was just a simplified class for demonstration purposes. The thing is, that EL is using the name() method to print the enum and JSTL is using toString(). I did not expect a different enum treatment here. If you need it to emit the same thing, doing: c:out value=${myEnumValue.name}/ No, because that would call a method getName() which doesn't exist - the method is named name(). c:out value=${myEnumValue.getName()}/ You can't do that (at least not with Tomcat 6.0.29). Or, just consistently use EL, since that actually works as you expect. Well...it is again just a simplified example. Bye Oliver - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Pid, Am Friday 15 October 2010 schrieb Pid: No, because that would call a method getName() which doesn't exist - the method is named name(). c:out value=${myEnumValue.getName()}/ I don't think that'll work in 6.0. That's right. Or, just consistently use EL, since that actually works as you expect. +1 'c:out' seems surplus. And how do you escape XML characters to entity codes using pure EL? Bye Oliver - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ApacheCon2010NA Meetup / Connector Performance
+1 I'd also like to see the results. It may be what I need to persuade my bosses about something. On Thu, Oct 14, 2010 at 11:03 PM, Pid p...@pidster.com wrote: On 14/10/2010 21:39, János Löbb wrote: On Oct 14, 2010, at 3:00 PM, Christopher Schultz wrote: All, Is there any interest in my (finally) presenting my performance data for Tomcat connectors versus Apache httpd at the conference meetup? I'd have to repeat my tests (my data is for 6.0.20 and we're on 6.0.29, now) plus add some stuff like static data via mod_jk just for a point of comparison to see what kind of overhead mod_jk adds to the mix. That kind means a pain in my arse with about 15 days to get it done. But, if there's interest, I'll get off my butt and show some purty pitchers at the meetup. -chris - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org Chris, Can You post that also here on this list ? Wiki, then that link to list, is probably better - if at all possible. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Res: Res: JSESSIONID Cookie handle customizing
Chuck, I can't say explicit why I need to use this info on the session. but is related with security issues. and you are right, is much more plausible to make this as you said, but I can't afford to do that. Tks -- Universidade Federal de Uberlândia - UFU Faculdade de Computação - FACOM Mestrado em Ciência da Computação Juliano Daloia de Carvalho Rua: Nordau Gonçalves de Melo, 1069 Uberlândia/MG CEP:38408-218 Lab: (34) 3239-4144 Ramal 44 Tel: (34) 3219-9216 Cel:nbsp;(34) 9146-4645 -- - Mensagem original De: Caldarale, Charles R chuck.caldar...@unisys.com Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 13:37:12 Assunto: RE: Res: JSESSIONID Cookie handle customizing From: Juliano Daloia de Carvalho [mailto:judac2...@yahoo.com.br] Subject: Res: Res: JSESSIONID Cookie handle customizing I need to change the value of the sessionID. Why? Using a separate parameter or cookie to hold your specific additional information would seem to be a much more workable solution - assuming you even need to do that. You could just store the additional information in the session object, and not bother with sending it over the wire. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Inconsistent output of Java 5 enums
Or, just consistently use EL, since that actually works as you expect. +1 'c:out' seems surplus. And how do you escape XML characters to entity codes using pure EL? This seems a valid reason except that is this a problem for your enum? If it really is a problem then did you try and create a new getter method that returns your to string content in the enum? And then call that with c:out. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Res: Res: JSESSIONID Cookie handle customizing
On 15/10/2010 17:47, Juliano Daloia de Carvalho wrote: Chuck, I can't say explicit why I need to use this info on the session. but is related with security issues. and you are right, is much more plausible to make this as you said, but I can't afford to do that. If you need to control the session ID then the right way to do this is to extend the Manager and override generateSessionId(). Anything else is going to be fragile, particularly when you factor in that Tomcat will change the session ID on authentication to prevent session fixation. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
When users connect to our Tomcat 6.0.29 using Google Chrome, they get this warning when they click the security icon: The connection had to be retried using SSL 3.0. This typically means that the server is using very old software and may have other security issues. Tomcat is configured using this: Connector port=xxx address= protocol=HTTP/1.1 SSLEnabled=true maxThreads=100 scheme=https secure=true enableLooks=false compression=on keystoreFile=/certificate.keystore keystorePass= clientAuth=false sslProtocol=TLS / I believe we are using OpenSSL 0.9.8f on Solaris 10. Not sure how to tell which SSL library tomcat is using. How do I fix this? We have to support multiple browser/versions: IE6, IE7, IE8, FF, Chrome... so whatever solution should allow for this. -- - -- Robert La Ferla VP Engineering OMS SafeHarbor This message (and any attachments) contains confidential information and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, distribution, or the taking of any action based on this message, is strictly prohibited. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
There are some issues with Chrome regarding SSL, essentially Chrome is more restrictive than other browsers and will get upset with proxied connections etc. For example http://www.google.com/support/forum/p/Chrome/thread?tid=6cbb881fc85406f4hl=en Especially see reply #2 there. Are you sure that your problem isn't related to that? -Original Message- From: Robert La Ferla [mailto:robert.lafe...@o-ms.com] Sent: Friday, October 15, 2010 12:59 PM To: Tomcat Users List Subject: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0. When users connect to our Tomcat 6.0.29 using Google Chrome, they get this warning when they click the security icon: The connection had to be retried using SSL 3.0. This typically means that the server is using very old software and may have other security issues. Tomcat is configured using this: Connector port=xxx address= protocol=HTTP/1.1 SSLEnabled=true maxThreads=100 scheme=https secure=true enableLooks=false compression=on keystoreFile=/certificate.keystore keystorePass= clientAuth=false sslProtocol=TLS / I believe we are using OpenSSL 0.9.8f on Solaris 10. Not sure how to tell which SSL library tomcat is using. How do I fix this? We have to support multiple browser/versions: IE6, IE7, IE8, FF, Chrome... so whatever solution should allow for this. -- - -- Robert La Ferla VP Engineering OMS SafeHarbor This message (and any attachments) contains confidential information and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, distribution, or the taking of any action based on this message, is strictly prohibited. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
On 15/10/2010 17:58, Robert La Ferla wrote: When users connect to our Tomcat 6.0.29 using Google Chrome, they get this warning when they click the security icon: The connection had to be retried using SSL 3.0. This typically means that the server is using very old software and may have other security issues. Tomcat is configured using this: Connector port=xxx address= protocol=HTTP/1.1 SSLEnabled=true maxThreads=100 scheme=https secure=true enableLooks=false compression=on keystoreFile=/certificate.keystore keystorePass= clientAuth=false sslProtocol=TLS / I believe we are using OpenSSL 0.9.8f on Solaris 10. Not sure how to tell which SSL library tomcat is using. Those two statements are not consistent. Your connector config is for JSSE, not OpenSSL. Tomcat uses TLS by default[1]. See [2] for other options for sslProtocol Mark [1] http://tomcat.apache.org/tomcat-6.0-doc/config/http.html#SSL_Support [2] http://download.oracle.com/javase/6/docs/api/index.html - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
On 10/15/2010 1:12 PM, Maximilian Stocker wrote: There are some issues with Chrome regarding SSL, essentially Chrome is more restrictive than other browsers and will get upset with proxied connections etc. For example http://www.google.com/support/forum/p/Chrome/thread?tid=6cbb881fc85406f4hl=en Especially see reply #2 there. Are you sure that your problem isn't related to that? I did clear all my Chrome settings and restarted Chrome. I am using Chrome 6.0.472.63 on Windows XP. Unless I'm looking at the wrong reply? -- - -- Robert La Ferla VP Engineering OMS SafeHarbor This message (and any attachments) contains confidential information and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, distribution, or the taking of any action based on this message, is strictly prohibited. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
On 10/15/2010 1:14 PM, Mark Thomas wrote: Those two statements are not consistent. Your connector config is for JSSE, not OpenSSL. Tomcat uses TLS by default[1]. See [2] for other options for sslProtocol We are indeed using JSSE. The link for #2 just pointed at the general Java docs. What specific class did you intend to post a link to? -- - -- Robert La Ferla VP Engineering OMS SafeHarbor This message (and any attachments) contains confidential information and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, distribution, or the taking of any action based on this message, is strictly prohibited. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Hello, Am Friday 15 October 2010 schrieb Maximilian Stocker: Or, just consistently use EL, since that actually works as you expect. +1 'c:out' seems surplus. And how do you escape XML characters to entity codes using pure EL? This seems a valid reason except that is this a problem for your enum? As stated before, it was just a simplified example. If it really is a problem then did you try and create a new getter method that returns your to string content in the enum? And then call that with c:out. The enum is part of a 3rd party lib. And of course, there are several workarounds available, but I want to understand what is happening here and clearify if it's a bug. And it's not just the c:out tag - it also happens with other Tags. For demonstration I've created a custom Tag: public class MyCustomTag implements Tag { public void setValue(String value) { System.out.println(value); } @Override public void setPageContext(PageContext pc) { } @Override public void setParent(Tag t) { } @Override public Tag getParent() { return null; } @Override public int doStartTag() throws JspException { return SKIP_BODY; } @Override public int doEndTag() throws JspException { return EVAL_PAGE; } @Override public void release() { } } My TLD: ?xml version=1.0 encoding=UTF-8 ? taglib xsi:schemaLocation=http://java.sun.com/xml/ns/javaee web- jsptaglibrary_2_1.xsd xmlns=http://java.sun.com/xml/ns/javaee; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; version=2.1 tlibversion1.0/tlibversion urihttp://my-domain.org/customLib/uri tag namecustomTag/name tagclassmypackage.MyCustomTag/tagclass bodycontentempty/bodycontent attribute namevalue/name requiredtrue/required rtexprvaluetrue/rtexprvalue /attribute /tag /taglib And in my JSP file is use it: %...@taglib prefix=myLib uri=http://my-domain.org/customLib% myLib:customTag value=${myEnum}/ myLib:customTag value=foo.${myEnum}.bar/ I would expect, that this outputs: VALID foo.VALID.bar The output in catalina.out is very interesting: VALID foo.VALID result, code 0.bar Remember, VALID is the enum name() and VALID result, code 0 is the enum toString(). I think that is REALLY weird... Bye Oliver - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
Wrong reply. The second reply is from a Google employee and there links there to another thread on the subject. If you are only having this problem with chrome then it may well be related to this. Clearing the cache etc won't help if the clients connections are being proxied, maybe. If you are having problems with other browsers then just ignore this. -Original Message- From: Robert La Ferla [mailto:robert.lafe...@o-ms.com] Sent: Friday, October 15, 2010 1:25 PM To: users@tomcat.apache.org Subject: Re: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0. On 10/15/2010 1:12 PM, Maximilian Stocker wrote: There are some issues with Chrome regarding SSL, essentially Chrome is more restrictive than other browsers and will get upset with proxied connections etc. For example http://www.google.com/support/forum/p/Chrome/thread?tid=6cbb881fc85406f4hl=en Especially see reply #2 there. Are you sure that your problem isn't related to that? I did clear all my Chrome settings and restarted Chrome. I am using Chrome 6.0.472.63 on Windows XP. Unless I'm looking at the wrong reply? -- - -- Robert La Ferla VP Engineering OMS SafeHarbor This message (and any attachments) contains confidential information and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, distribution, or the taking of any action based on this message, is strictly prohibited. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: SSL/TLS, Tomcat 6.0.29 and Chrome: The connection had to be retried using SSL 3.0.
On 15/10/2010 18:26, Robert La Ferla wrote: On 10/15/2010 1:14 PM, Mark Thomas wrote: Those two statements are not consistent. Your connector config is for JSSE, not OpenSSL. Tomcat uses TLS by default[1]. See [2] for other options for sslProtocol We are indeed using JSSE. The link for #2 just pointed at the general Java docs. What specific class did you intend to post a link to? Grr. Frames. Grr. http://download.oracle.com/javase/6/docs/technotes/guides//security/StandardNames.html Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Res: Res: Res: JSESSIONID Cookie handle customizing
Mark, I do not want to change how tomcat handle the sessionId. I want to create one little class that handle on the server side the cookie information that can come on the header, make a preprocessing which will create one another information that I want to put on the attributes of the request. I do not want to change nothing on how tomcat handle session id. I just need to process the request header before tomcat use it, so I can make the operation and create a new attribute and put the session id that tomcat knows. I just need to know the first class on tomcat that receives the message from the client and the last one before send it to the client. Tks Juliano - Mensagem original De: Mark Thomas ma...@apache.org Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 13:56:07 Assunto: Re: Res: Res: JSESSIONID Cookie handle customizing On 15/10/2010 17:47, Juliano Daloia de Carvalho wrote: Chuck, I can't say explicit why I need to use this info on the session. but is related with security issues. and you are right, is much more plausible to make this as you said, but I can't afford to do that. If you need to control the session ID then the right way to do this is to extend the Manager and override generateSessionId(). Anything else is going to be fragile, particularly when you factor in that Tomcat will change the session ID on authentication to prevent session fixation. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Inconsistent output of Java 5 enums
I did some testing myself just now with a simple enum and I think this is a Tomcat bug somewhere. Whether the old behaviour was right or wrong vs the new I don't know. I also think that your enum is screwy or doing something different then you think. At any rate I created a simple enum public enum Fruit{APPLE,ORANGE,BANANA; public String toString(){ switch(this){ case APPLE: return A is for Apple; case ORANGE: return O is for Orange; default: return B is for Banana; } } } I then used the following in a JSP (enumtest is a simple model object with a Fruit property set to Fruit.APPLE) #1 = ${enumtest.fruit} br #2 = c:out value=${enumtest.fruit}/ On tomcat 5.5. I get #1 = A is for Apple #2 = A is for Apple On tomcat 6 I get #1 = APPLE #2 = A is for Apple Which is obviously not the same, and surprised me, but it seems if I understand this thread that it is the opposite of what you are seeing and that I really don't understand. -Original Message- From: Oliver Siegmar [mailto:oli...@siegmar.org] Sent: Friday, October 15, 2010 1:29 PM To: Tomcat Users List Subject: Re: Inconsistent output of Java 5 enums Hello, Am Friday 15 October 2010 schrieb Maximilian Stocker: Or, just consistently use EL, since that actually works as you expect. +1 'c:out' seems surplus. And how do you escape XML characters to entity codes using pure EL? This seems a valid reason except that is this a problem for your enum? As stated before, it was just a simplified example. If it really is a problem then did you try and create a new getter method that returns your to string content in the enum? And then call that with c:out. The enum is part of a 3rd party lib. And of course, there are several workarounds available, but I want to understand what is happening here and clearify if it's a bug. And it's not just the c:out tag - it also happens with other Tags. For demonstration I've created a custom Tag: public class MyCustomTag implements Tag { public void setValue(String value) { System.out.println(value); } @Override public void setPageContext(PageContext pc) { } @Override public void setParent(Tag t) { } @Override public Tag getParent() { return null; } @Override public int doStartTag() throws JspException { return SKIP_BODY; } @Override public int doEndTag() throws JspException { return EVAL_PAGE; } @Override public void release() { } } My TLD: ?xml version=1.0 encoding=UTF-8 ? taglib xsi:schemaLocation=http://java.sun.com/xml/ns/javaee web- jsptaglibrary_2_1.xsd xmlns=http://java.sun.com/xml/ns/javaee; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; version=2.1 tlibversion1.0/tlibversion urihttp://my-domain.org/customLib/uri tag namecustomTag/name tagclassmypackage.MyCustomTag/tagclass bodycontentempty/bodycontent attribute namevalue/name requiredtrue/required rtexprvaluetrue/rtexprvalue /attribute /tag /taglib And in my JSP file is use it: %...@taglib prefix=myLib uri=http://my-domain.org/customLib% myLib:customTag value=${myEnum}/ myLib:customTag value=foo.${myEnum}.bar/ I would expect, that this outputs: VALID foo.VALID.bar The output in catalina.out is very interesting: VALID foo.VALID result, code 0.bar Remember, VALID is the enum name() and VALID result, code 0 is the enum toString(). I think that is REALLY weird... Bye Oliver - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Res: Res: JSESSIONID Cookie handle customizing
From: Juliano Daloia de Carvalho [mailto:judac2...@yahoo.com.br] Subject: Res: Res: Res: JSESSIONID Cookie handle customizing I want to create one little class that handle on the server side the cookie information that can come on the header, make a preprocessing which will create one another information that I want to put on the attributes of the request. Sounds like the perfect task for a ... filter. Unless you're willing to provide more details about why you think a filter is inappropriate, I think everyone is going to believe you're making this much, much harder than it needs to be. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.
Re: Inconsistent output of Java 5 enums
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Oliver, On 10/15/2010 1:28 PM, Oliver Siegmar wrote: The enum is part of a 3rd party lib. And of course, there are several workarounds available, but I want to understand what is happening here and clarify if it's a bug. Just for the record, this has nothing to do with Tomcat: the bug would be in the JSTL implementation, which you got from a 3rd-party. And it's not just the c:out tag - it also happens with other Tags. For demonstration I've created a custom Tag: [snip] attribute namevalue/name requiredtrue/required rtexprvaluetrue/rtexprvalue /attribute [snip] %...@taglib prefix=myLib uri=http://my-domain.org/customLib% myLib:customTag value=${myEnum}/ myLib:customTag value=foo.${myEnum}.bar/ I would expect, that this outputs: VALID foo.VALID.bar The output in catalina.out is very interesting: VALID foo.VALID result, code 0.bar Okay, that might be a bug in Tomcat. Weird: I would expect that the JSTL relies on the platform's EL implementation to work. So, I don't understand why this works for a bare EL expression like ${enum} and not foo value=${enum} / - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4oAAACgkQ9CaO5/Lv0PBD/ACfS+pevIoCaFI/tkIcc+eCcuNJ 1LUAn3sMZEKtX+uvW8161muWPlLmuUR+ =ug3y -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Res: JSESSIONID Cookie handle customizing
On 15/10/2010 19:44, Christopher Schultz wrote: This can be done with a Valve, but I'm not exactly sure how to insert a Valve before the authentication valve, which is (I think) what you'd have to do. Option 1. Auth Valves are on the Context so define Your valve on the Host or Engine. Option 2. Explicitly define the auth Valve for the Context after your own Valve. (Valves get processed in definition order.) Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Res: JSESSIONID Cookie handle customizing
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mark, On 10/15/2010 2:50 PM, Mark Thomas wrote: On 15/10/2010 19:44, Christopher Schultz wrote: This can be done with a Valve, but I'm not exactly sure how to insert a Valve before the authentication valve, which is (I think) what you'd have to do. Option 1. Auth Valves are on the Context so define Your valve on the Host or Engine. Good to know. Option 2. Explicitly define the auth Valve for the Context after your own Valve. (Valves get processed in definition order.) That's what I figured, but I've never done it so I didn't want to simply guess. Thanks, - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4o58ACgkQ9CaO5/Lv0PAsGQCfT9aXmqYD5YTevpLbE5nFN0EV AfwAnj2FzB82dqcE6d5yO4Tmori4rJyc =Iy6r -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ApacheCon2010NA Meetup / Connector Performance
+1 On Oct 15, 2010 9:46 AM, Wesley Acheson wesley.ache...@gmail.com wrote: +1 I'd also like to see the results. It may be what I need to persuade my bosses about something. On Thu, Oct 14, 2010 at 11:03 PM, Pid p...@pidster.com wrote: On 14/10/2010 21:39, János Löbb wrote: On Oct 14, 2010, at 3:00 PM, Christopher Schultz wrote: All, Is there any interest in my (finally) presenting my performance data for Tomcat connectors versus Apache httpd at the conference meetup? I'd have to repeat my tests (my data is for 6.0.20 and we're on 6.0.29, now) plus add some stuff like static data via mod_jk just for a point of comparison to see what kind of overhead mod_jk adds to the mix. That kind means a pain in my arse with about 15 days to get it done. But, if there's interest, I'll get off my butt and show some purty pitchers at the meetup. -chris - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org Chris, Can You post that also here on this list ? Wiki, then that link to list, is probably better - if at all possible. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Am Friday 15 October 2010 schrieb Maximilian Stocker: On tomcat 5.5. I get #1 = A is for Apple #2 = A is for Apple On tomcat 6 I get #1 = APPLE #2 = A is for Apple Which is obviously not the same, and surprised me, but it seems if I understand this thread that it is the opposite of what you are seeing and that I really don't understand. No, that's exactly the same here. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Inconsistent output of Java 5 enums
Okay. Then while I think it is a bug in tomcat (but it might be tomcat 5 that has the bug because I still don't 100% understand what it *should* do) I am not sure what the problem is. Do you want the toString value or the name() value? If it's the name value then there is no danger in using it outside of c:out anyway because I am pretty sure you can't use characters that would need to be escaped as enum labels to begin with. And if it's the toString then c:out is using it... -Original Message- From: Oliver Siegmar [mailto:oli...@siegmar.org] Sent: Friday, October 15, 2010 5:42 PM To: Tomcat Users List Subject: Re: Inconsistent output of Java 5 enums Am Friday 15 October 2010 schrieb Maximilian Stocker: On tomcat 5.5. I get #1 = A is for Apple #2 = A is for Apple On tomcat 6 I get #1 = APPLE #2 = A is for Apple Which is obviously not the same, and surprised me, but it seems if I understand this thread that it is the opposite of what you are seeing and that I really don't understand. No, that's exactly the same here. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ApacheCon2010NA Meetup / Connector Performance
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 All, Sounds like it's a date. I'll bring some hard-copy materials for circulation. I'll also post everything online and post a link to the list. I'm not planning any formal presentation or anything, but I'll obviously be happy to answer any questions anyone has. See you all there. - -chris On 10/14/2010 3:00 PM, Christopher Schultz wrote: All, Is there any interest in my (finally) presenting my performance data for Tomcat connectors versus Apache httpd at the conference meetup? I'd have to repeat my tests (my data is for 6.0.20 and we're on 6.0.29, now) plus add some stuff like static data via mod_jk just for a point of comparison to see what kind of overhead mod_jk adds to the mix. That kind means a pain in my arse with about 15 days to get it done. But, if there's interest, I'll get off my butt and show some purty pitchers at the meetup. -chris - - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky403sACgkQ9CaO5/Lv0PCjYACdGiVwFcM1AuzWiSmc7NQMsaYx HasAnjVzK2XE2efg+ofg+pI0qrWoBLhO =OS/F -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Res: Res: JSESSIONID Cookie handle customizing
Mark thank you! do you know which is the first tomcat class that receives the client request? do you know which is the last tomcat class that is used before send the response to the client? tks. Juliano - Mensagem original De: Christopher Schultz ch...@christopherschultz.net Para: Tomcat Users List users@tomcat.apache.org Enviadas: Sexta-feira, 15 de Outubro de 2010 15:55:27 Assunto: Re: Res: JSESSIONID Cookie handle customizing -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mark, On 10/15/2010 2:50 PM, Mark Thomas wrote: On 15/10/2010 19:44, Christopher Schultz wrote: This can be done with a Valve, but I'm not exactly sure how to insert a Valve before the authentication valve, which is (I think) what you'd have to do. Option 1. Auth Valves are on the Context so define Your valve on the Host or Engine. Good to know. Option 2. Explicitly define the auth Valve for the Context after your own Valve. (Valves get processed in definition order.) That's what I figured, but I've never done it so I didn't want to simply guess. Thanks, - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAky4o58ACgkQ9CaO5/Lv0PAsGQCfT9aXmqYD5YTevpLbE5nFN0EV AfwAnj2FzB82dqcE6d5yO4Tmori4rJyc =Iy6r -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Inconsistent output of Java 5 enums
Am Saturday 16 October 2010 schrieb Maximilian Stocker: Okay. Then while I think it is a bug in tomcat (but it might be tomcat 5 that has the bug because I still don't 100% understand what it *should* do) I am not sure what the problem is. Do you want the toString value or the name() value? If it's the name value then there is no danger in using it outside of c:out anyway because I am pretty sure you can't use characters that would need to be escaped as enum labels to begin with. And if it's the toString then c:out is using it... I think, that name() should be used all the time, because of section 1.18.2 of the 2.1 JSP-EL spec. My real usage scenario is, that I'm using Spring's message tag to output a message from a ResourceBundle. spring:message code=enums.${myEnumValue}/ But Tomcat calls the setCode() method with enums.myEnumToStringRepresentation instead of enums.myEnumNameRepresentation. Because the toString() representation includes whitespaces and other special characters that doesn't work well. Of course I can find workarounds, but I wanted to discuss if this is a bug or not. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org