can't seem to migrate this app over to a new server
We're in the process of extricating ourselves from a host who developed and managed our app through their own hosted server. In attempting to move the app over to a server under our control: Tomcat 5.5.28 w/ admin package java 1.5.0_28 Windows 2003 R2 all they gave me was a zipped up directory under their webapps dir and the JKS file for SSL. Do I need anything other than the JKS file to transfer the SSL cert over to our new tomcat server? Also, in trying to setup the app, I installed tomcat and unzipped it under webapps. and subsequently when i try to connect to the app through localhost/ourapp it gives up an error: Firefox can't establish a connection to the server at localhost:8443 I know very little about tomcat and java, so please at the very least, any answers that can be fully googleable, I would greatly appreciate. Thanks, John
Re: can't seem to migrate this app over to a new server
The SSL configuration for a Tomcat 5.5 server is described at http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html. To quote from the top of that file, this assumes you're not using APR (Apache Portable Runtime). APR is not the default configuration as I recall - if you don't know that you are using APR, you're probably not! I'll leave someone who knows more about the crypto side to answer your question about the JKS file. Can you set this up and test it in two stages? In the first stage, set up Tomcat and the webapp and see whether you can get to the app through normal HTTP. In the second stage, set up SSL. The main thing that might prevent this is if there's a transport guarantee of CONFIDENTIAL in your application's WEB-INF/web.xml file - if there is, you might want to comment that out while testing over HTTP, then put it back after you've got SSL working! A google for something like web-inf web.xml transport-guarantee will give you more details. Good luck with the configuration. - Peter On 24 March 2010 06:22, joon yoo jyoo1...@gmail.com wrote: We're in the process of extricating ourselves from a host who developed and managed our app through their own hosted server. In attempting to move the app over to a server under our control: Tomcat 5.5.28 w/ admin package java 1.5.0_28 Windows 2003 R2 all they gave me was a zipped up directory under their webapps dir and the JKS file for SSL. Do I need anything other than the JKS file to transfer the SSL cert over to our new tomcat server? Also, in trying to setup the app, I installed tomcat and unzipped it under webapps. and subsequently when i try to connect to the app through localhost/ourapp it gives up an error: Firefox can't establish a connection to the server at localhost:8443 I know very little about tomcat and java, so please at the very least, any answers that can be fully googleable, I would greatly appreciate. Thanks, John
Re: can't seem to migrate this app over to a new server
Hi John, You need to enable HTTPS connector, refer to SSL Support section in http://tomcat.apache.org/tomcat-5.5-doc/config/http.html to enable SSL in server.xml. On 24 March 2010 14:22, joon yoo jyoo1...@gmail.com wrote: We're in the process of extricating ourselves from a host who developed and managed our app through their own hosted server. In attempting to move the app over to a server under our control: Tomcat 5.5.28 w/ admin package java 1.5.0_28 Windows 2003 R2 all they gave me was a zipped up directory under their webapps dir and the JKS file for SSL. Do I need anything other than the JKS file to transfer the SSL cert over to our new tomcat server? Also, in trying to setup the app, I installed tomcat and unzipped it under webapps. and subsequently when i try to connect to the app through localhost/ourapp it gives up an error: Firefox can't establish a connection to the server at localhost:8443 I know very little about tomcat and java, so please at the very least, any answers that can be fully googleable, I would greatly appreciate. Thanks, John - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Compiling JSP with SMAP
I'm using apache-tomcat-6.0.20 with JASPER 2 I need to compile a web project (Eclipse WAR application) which is JSP to JAVA source files. I'm successfully generating JAVA files from JSP files (Used JASPER 2), but now i need to get mapping from JSP lines to JAVA lines. I tried using SMAP feature which available in JASPER 2, but i can't configure it correctly. There are two questions i need to ask, 1) Will generating SMAP files will help me to map JSP lines to generated JAVA lines? 2) How to do this? JASPER how to doc says - The servlet which implements Jasper is configured using init parameters in your global $CATALINA_BASE/conf/web.xml. I edited that web.xml with following code - (used dumpSmap suppressSmap) servlet servlet-namejsp/servlet-name servlet-classorg.apache.jasper.servlet.JspServlet/servlet-class init-param param-namesuppressSmap/param-name param-valuefalse/param-value /init-param init-param param-namedumpSmap/param-name param-valuetrue/param-value /init-param /servlet But no luck Any help! -- _A_N_I_M_E_-_O_T_A_K_U_
path in context.xml
I am trying to configure context in a META-INF context.xml which is new to me. I have set my path to myPath and when I am deploying my myWar.war I thought that my app would be called myPath but instead, as usual, it is called myWar. What am I doing wrong??? What is path for??? Soren, DK - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
The requested resource ... is not available
hi i installed apache-tomcat-6.0.20 and set path variable accordingly then i access http://localhost:8080/ and it shows default apache tomcat page. but as if try to access http://localhost:8080/myfile.html then it display error type Status report message /myfile.html description The requested resource (/myfile.html) is not available. Apache Tomcat/6.0.20 can anyone suggest what step should i take to resolve problem thanks Note: this problem occurs from last few days. Before that, i was able to access all files and directory (myapp) properly. -- View this message in context: http://old.nabble.com/The-requested-resource-...-is-not-available-tp28013923p28013923.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: The requested resource ... is not available
You could access http://localhost:8080/myapp/myfile.html, or check the path is right or not in $CATALINA_HOME/conf/context.xml. Mercy mehar300 wrote: hi i installed apache-tomcat-6.0.20 and set path variable accordingly then i access http://localhost:8080/ and it shows default apache tomcat page. but as if try to access http://localhost:8080/myfile.html then it display error type Status report message /myfile.html description The requested resource (/myfile.html) is not available. Apache Tomcat/6.0.20 can anyone suggest what step should i take to resolve problem thanks Note: this problem occurs from last few days. Before that, i was able to access all files and directory (myapp) properly. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Compiling JSP with SMAP
Hi TWönlìnè, Did you a project named Server with a sub folder whose name is like Tomcat v6.0 Server at localhost-config? If you had, please set these values into web.xml in. Kind regards, Mercy TWönlìnè wrote: I'm using apache-tomcat-6.0.20 with JASPER 2 I need to compile a web project (Eclipse WAR application) which is JSP to JAVA source files. I'm successfully generating JAVA files from JSP files (Used JASPER 2), but now i need to get mapping from JSP lines to JAVA lines. I tried using SMAP feature which available in JASPER 2, but i can't configure it correctly. There are two questions i need to ask, 1) Will generating SMAP files will help me to map JSP lines to generated JAVA lines? 2) How to do this? JASPER how to doc says - The servlet which implements Jasper is configured using init parameters in your global $CATALINA_BASE/conf/web.xml. I edited that web.xml with following code - (used dumpSmap suppressSmap) servlet servlet-namejsp/servlet-name servlet-classorg.apache.jasper.servlet.JspServlet/servlet-class init-param param-namesuppressSmap/param-name param-valuefalse/param-value /init-param init-param param-namedumpSmap/param-name param-valuetrue/param-value /init-param /servlet But no luck Any help! - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Compiling JSP with SMAP
@Mercy, Thanks I managed to create SMAP files, using this code in my BUILD.XML - which compiles JSPs taskdef classname=org.apache.jasper.JspC name=jasper2 classpath refid=tomcat.classpath / /taskdef target name=jasper.jspc echo message=Starting JASPER/JSPC compiler... / jasper2 validateXml=false failonerror=false package=${module.name} smapSuppressed=false smapDumped=true compilertargetvm=1.6 compilersourcevm=1.6 classdebuginfo=true listErrors=true verbose=9 uriroot=${web.dir} webXmlFragment=${tool.work.dir}/generated_web.xml outputDir=${tool.web.scr.dir} / /target Now it is creating .SMAP files. Now a new problem arise, How to read a .SMAP file, I know its map from JSP to JAVA but how the numbers are associated, (can someone explain) is there an easier way to do this?
apache-tomcat-6.0.26 (log4j:WARN No appenders)
Hi, I executed a sample on apache-tomcat-6.0.26 as follows : [man...@localhost axis-1_4]$ java -cp $AXISCLASSPATH samples.stock.GetQuote -lhttp://localhost:8080/axis/servlet/AxisServlet -uuser1 -wpass1 XXX log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle). log4j:WARN Please initialize the log4j system properly. XXX: 55.25 I got correct result but how can I solve log4j:WARN ? _ The latest songs, trailers and more http://video.in.msn.com/
RE: path in context.xml
From: Søren Blidorf [mailto:so...@nolas.dk] Subject: path in context.xml I am trying to configure context in a META-INF context.xml which is new to me. I have set my path to myPath The path attribute is illegal when the Context element is in META-INF/context.xml. You must rename your .war file to myPath.war. What am I doing wrong??? What is path for??? The path attribute is viable *only* when the webapp is located outside of any Host appBase directory and the Context element is in server.xml - and placing Context elements in server.xml is not wise. - 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: The requested resource ... is not available
From: Mercy [mailto:techme...@gmail.com] Subject: Re: The requested resource ... is not available or check the path is right or not in $CATALINA_HOME/conf/context.xml. The above file must never, never have a path attribute in it. - 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: The requested resource ... is not available
From: mehar300 [mailto:mehar...@yahoo.com] Subject: The requested resource ... is not available i installed apache-tomcat-6.0.20 and set path variable accordingly What do you mean by path variable? If you're referring to the system PATH environment variable, it need not be set to anything in particular to run Tomcat. If you're referring to the CLASSPATH environment variable, you should never, never be using that, especially for Tomcat. then i access http://localhost:8080/ and it shows default apache tomcat page. A good sign. if try to access http://localhost:8080/myfile.html then it display error Why do you think that should do anything useful? can anyone suggest what step should i take to resolve problem Post some useful information, such as where myfile.html is located, what webapps have you deployed, where are the webapps deployed, and the contents of conf/server.xml (if you have modified it in any way). - 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
OT: Howto exclude files/folders i .war
Can anybody tell me how to exclude files/folders in my .war. I am using Jbuilder 2006. Soren, DK
GC behavior elucidation
Hi all, I've been working on the memory behavior of a small Tomcat 6.0.20/Java 1.6 app running in constrained space (288MB total on a VPS running CentOS 5). Earlier advice from the list enabled me to track down the most glaring culprit memory leaks. The app is currently lightly used, but even under light use earlier, it was growing out of bounds. This message is a question about types of GC behavior. I've been monitoring the app using GC logging and dumping a lot of info to catalina out. I've seen three distinct types of GCs. I understand the Full GC and routine GC, but I'm not sure I understand the third type. My gclog shows routine GCs approx every 3-4 mins that look like this: 2010-03-17T01:28:05.888-0400: 543717.992: [GC 543717.992: [DefNew: 6222K-487K(6528K), 0.0030010 secs] 44060K-38706K(64832K), 0.0030920 secs] [Times: user=0.01 sys=0.00, real=0.01 secs] Since 3/10, I've seen 5 Full GCs 03-11T05:23 03-11T15:00 03-11T19:49 03-12T00:09 03-17T01:07 looking like this last one: 2010-03-17T01:07:34.278-0400: 542486.382: [Full GC 542486.382: [Tenured: 58226K-35935K(58304K), 0.1316550 secs] 64221K- 35935K(64832K), [Perm : 21200K-21200K(21248K)], 0.1317440 secs] [Times: user=0.13 sys=0.00, real=0.13 secs] At the same time, catalina.out shows a lot of entries like this: INFO | jvm 1| 2010/03/17 01:07:34 | [Unloading class sun.reflect.GeneratedMethodAccessor233] I've seen 7 GCs of the third type: 03-11T00:11 03-11T10:12 03-11T15:00 03-12T04:23 03-12T08:33 03-21T03:44 03-23T20:44 looking like this one last night: 2010-03-23T20:44:55.835-0400: 1131527.939: [GC 1131527.939: [DefNew (promotion failed): 6205K-5999K(6528K), 0.0047690 secs]1131527.944: [Tenured: 58304K-36397K(58304K), 0.1396970 secs] 64399K- 36397K(64832K), [Perm : 21631K-21631K(21760K)], 0.1446100 secs] [Times: user=0.14 sys=0.00, real=0.14 secs] Just like the Full GCs, catalina.out shows lots of these entries: INFO | jvm 1| 2010/03/23 20:44:55 | [Unloading class sun.reflect.GeneratedMethodAccessor360] Finally, last night I happened to notice that top was showing tomcat % was 44, while this morning was 43.5, which of course is nice to see :-). I assume that the third type of GC is something intermediate between the routine (every 4 mins) small collection and a Full GC. Can anyone describe it to me or point me to some GC doc describing the details. Many thanks, Ken - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: GC behavior elucidation
From: Ken Bowen [mailto:kbo...@als.com] Subject: GC behavior elucidation My gclog shows routine GCs approx every 3-4 mins that look like this: 2010-03-17T01:28:05.888-0400: 543717.992: [GC 543717.992: [DefNew: 6222K-487K(6528K), 0.0030010 secs] 44060K-38706K(64832K), 0.0030920 secs] [Times: user=0.01 sys=0.00, real=0.01 secs] Looks reasonable. Make sure the contracted number stay about where they are; if they keep increasing, you've still got a leak. Since 3/10, I've seen 5 Full GCs 2010-03-17T01:07:34.278-0400: 542486.382: [Full GC 542486.382: [Tenured: 58226K-35935K(58304K), 0.1316550 secs] 64221K-35935K(64832K), [Perm : 21200K-21200K(21248K)], 0.1317440 secs] [Times: user=0.13 sys=0.00, real=0.13 secs] At the same time, catalina.out shows a lot of entries like this: INFO | jvm 1| 2010/03/17 01:07:34 | [Unloading class sun.reflect.GeneratedMethodAccessor233] Normal for a full GC - unused classes are being discarded. I've seen 7 GCs of the third type: 2010-03-23T20:44:55.835-0400: 1131527.939: [GC 1131527.939: [DefNew (promotion failed): 6205K-5999K(6528K), 0.0047690 secs] 1131527.944: [Tenured: 58304K-36397K(58304K), 0.1396970 secs] 64399K-36397K(64832K), [Perm : 21631K-21631K(21760K)], 0.1446100 secs] [Times: user=0.14 sys=0.00, real=0.14 secs] I assume that the third type of GC is something intermediate between the routine (every 4 mins) small collection and a Full GC. No, it's a minor collection that turned into a major one due to the tenured space being full. If you haven't prevented internal heap component resizing via command-line settings, the JVM will try to adjust the sizes of the spaces to try to avoid reoccurrence. However, your tenured usage seems to be creeping up, so you may well still have a leak. - 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: apache-tomcat-6.0.26 (log4j:WARN No appenders)
On 24/03/2010 12:44, Manoj Kumar wrote: Hi, I executed a sample on apache-tomcat-6.0.26 as follows : [man...@localhost axis-1_4]$ java -cp $AXISCLASSPATH samples.stock.GetQuote -lhttp://localhost:8080/axis/servlet/AxisServlet -uuser1 -wpass1 XXX log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle). log4j:WARN Please initialize the log4j system properly. XXX: 55.25 I got correct result but how can I solve log4j:WARN ? This would be a log4j question. Your application appears to include the jar, but you've not bothered to configure it. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: OT: Howto exclude files/folders i .war
On 24/03/2010 13:08, Søren Blidorf wrote: Can anybody tell me how to exclude files/folders in my .war. I am using Jbuilder 2006. Soren, DK Probably a question for the JBuilder community rather than the Tomcat community, no? p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: GC behavior elucidation
ChuckthanksKen On Mar 24, 2010, at 9:51 AM, Caldarale, Charles R wrote: From: Ken Bowen [mailto:kbo...@als.com] Subject: GC behavior elucidation My gclog shows routine GCs approx every 3-4 mins that look like this: 2010-03-17T01:28:05.888-0400: 543717.992: [GC 543717.992: [DefNew: 6222K-487K(6528K), 0.0030010 secs] 44060K-38706K(64832K), 0.0030920 secs] [Times: user=0.01 sys=0.00, real=0.01 secs] Looks reasonable. Make sure the contracted number stay about where they are; if they keep increasing, you've still got a leak. Since 3/10, I've seen 5 Full GCs 2010-03-17T01:07:34.278-0400: 542486.382: [Full GC 542486.382: [Tenured: 58226K-35935K(58304K), 0.1316550 secs] 64221K-35935K(64832K), [Perm : 21200K-21200K(21248K)], 0.1317440 secs] [Times: user=0.13 sys=0.00, real=0.13 secs] At the same time, catalina.out shows a lot of entries like this: INFO | jvm 1| 2010/03/17 01:07:34 | [Unloading class sun.reflect.GeneratedMethodAccessor233] Normal for a full GC - unused classes are being discarded. I've seen 7 GCs of the third type: 2010-03-23T20:44:55.835-0400: 1131527.939: [GC 1131527.939: [DefNew (promotion failed): 6205K-5999K(6528K), 0.0047690 secs] 1131527.944: [Tenured: 58304K-36397K(58304K), 0.1396970 secs] 64399K-36397K(64832K), [Perm : 21631K-21631K(21760K)], 0.1446100 secs] [Times: user=0.14 sys=0.00, real=0.14 secs] I assume that the third type of GC is something intermediate between the routine (every 4 mins) small collection and a Full GC. No, it's a minor collection that turned into a major one due to the tenured space being full. If you haven't prevented internal heap component resizing via command-line settings, the JVM will try to adjust the sizes of the spaces to try to avoid reoccurrence. However, your tenured usage seems to be creeping up, so you may well still have a leak. - 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
JSP with a form and importing another form
Hi all ! If I post a form in the jsp then it execute the doPost of the right servlet. If the servlet detects an error in the form, I send back to the jsp. All is OK. But... If the jsp has an c:import url=/form2/ ( /form2 is a servlet redirecting to another jsp, and c:import is the 'core' taglib), Tomcat do the import with the POST method request and it's the doPOST method of my form2 servlet who is executed Is it a normal way ? Here's all the code: WEB.XML Code: welcome-file-list welcome-fileform1.jsp/welcome-file /welcome-file-list servlet servlet-nameform1/servlet-name servlet-classorg.Form1/servlet-class /servlet servlet-mapping servlet-nameform1/servlet-name url-pattern/form1/url-pattern /servlet-mapping servlet servlet-nameform2/servlet-name servlet-classorg.Form2/servlet-class /servlet servlet-mapping servlet-nameform2/servlet-name url-pattern/form2/url-pattern /servlet-mapping FORM1.JSP Code: %@ taglib prefix=c uri=http://java.sun.com/jsp/jstl/core% body form action=/form1 method=post input type=text name=mytext/ input type=submit name=mysubmit/ /form c:import url=/form2 / /body FORM2.JSP Code: body form action=/form2 method=post input type=text name=mytext2/ input type=submit name=mysubmit2/ /form /body org.Form1.class Code: public class Form1 extends HttpServlet { @Override protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { System.out.println(DOGET INITIALIZING FORM1); } @Override protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { System.out.println(DOPOST FORM1); // I detect errors in my form: go back req.getRequestDispatcher(/form1.jsp).forward(req, resp); } } org.Form2.class Code: public class Form2 extends HttpServlet { @Override protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { System.out.println(DOGET INITIALIZING FORM2); req.getRequestDispatcher(/form2.jsp).forward(req, resp); } @Override protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { System.out.println(DOPOST FORM2); } } So, when I submit something with the form 1 it shows: DOPOST FORM1 DOPOST FORM2 Thanks _ Hotmail arrive sur votre téléphone ! Compatible Iphone, Windows Phone, Blackberry, … http://www.messengersurvotremobile.com/?d=Hotmail - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: DB connection error -Tomcat 6 config
Thanks, Mark -- I'll shake down that thread here in a bit. -Original Message- From: Mark Thomas [mailto:ma...@apache.org] Sent: Tuesday, March 23, 2010 5:54 PM To: Tomcat Users List Subject: Re: DB connection error -Tomcat 6 config On 23/03/2010 22:39, Propes, Barry L wrote: I got this again today, and it seems to happen when/if I go into the Tomcat Manager app and either Stop and Start or Reload the app. Should that have a significant bearing on something like a DBCP connection so adversely? I was thinking it was tantamount to shutting down the Tomcat console and restarting itthat not the case? No. It just re-loads the app. Sounds like you have hit a bug in commons-pool / Tomcat's memory leak clean-up code. http://wiki.apache.org/tomcat/MemoryLeakProtection search for TimerThread 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: DB connection error -Tomcat 6 config
Admittedly, this is my first dance with the Tomcat manager app, deploying anything. I was, I suppose archaically, arguably, just using the startup and shutdown commands at the cmd prompt level. Although when I ran find memory leaks or whatever that little button reads, it did mention my app had some classes that were still being used, which seemed odd, but I assume accurate. Thanks, pid. -Original Message- From: Pid [mailto:p...@pidster.com] Sent: Tuesday, March 23, 2010 6:16 PM To: Tomcat Users List Subject: Re: DB connection error -Tomcat 6 config On 23/03/2010 22:54, Mark Thomas wrote: On 23/03/2010 22:39, Propes, Barry L wrote: I got this again today, and it seems to happen when/if I go into the Tomcat Manager app and either Stop and Start or Reload the app. Should that have a significant bearing on something like a DBCP connection so adversely? I was thinking it was tantamount to shutting down the Tomcat console and restarting itthat not the case? No. It just re-loads the app. Sounds like you have hit a bug in commons-pool / Tomcat's memory leak clean-up code. http://wiki.apache.org/tomcat/MemoryLeakProtection search for TimerThread Mark I've also seen this intermittently with the latest mysql connector/J (.12) but I'm going to start a new thread for this when I can replicate it, because this thread is too big* and it's a slightly different topic. p * and every time i see a new post in this thread, my stomach sinks. - 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: DB connection error -Tomcat 6 config
From: Propes, Barry L [mailto:barry.l.pro...@citi.com] Subject: RE: DB connection error -Tomcat 6 config Although when I ran find memory leaks or whatever that little button reads, it did mention my app had some classes that were still being used, which seemed odd, but I assume accurate. What was the condition of your webapp at that point? If it had been undeployed, there shouldn't be any traces of it left; if there are, you've got a leak. - 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: DB connection error -Tomcat 6 config
No, I didn't undeploy it at all - I simply stopped, and started it. Then I reloaded it. And/or, if I simply only reloaded it, I got the same error message. I'm not using a MySQL connector at all, as I noticed Pid had mentioned - only Oracle 10g. -Original Message- From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sent: Wednesday, March 24, 2010 9:45 AM To: Tomcat Users List Subject: RE: DB connection error -Tomcat 6 config From: Propes, Barry L [mailto:barry.l.pro...@citi.com] Subject: RE: DB connection error -Tomcat 6 config Although when I ran find memory leaks or whatever that little button reads, it did mention my app had some classes that were still being used, which seemed odd, but I assume accurate. What was the condition of your webapp at that point? If it had been undeployed, there shouldn't be any traces of it left; if there are, you've got a leak. - 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: Connecting to a Database
No, not sure. That is what I was confused about. JDBC Realm, vs JNDI DataSourceRealm, vs JDBC DataSource I think what was throwing me off was seeing examples of the tomcat-users in both the realm-howto and in the jndi-resources-howto I'm attempting container managed security using SQL Server. It looks like I need both a DataSourceRealm and a JDBC DataSource? Assuming I have the correct tables in the database named authstore, does this look right? ** in server.xml ** Realm className=com.microsoft.sqlserver.jdbc.SQLServerDriver dataSourceName=jdbc/authority userTable=users userNameCol=user_name userCredCol=user_pass userRoleTable=user_roles roleNameCol=role_name/ ** in META-INF/context.xml of specific webapp ** resource-ref descriptionDB Connection/description res-ref-namejdbc/authority/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref ** also in META-INF/context.xml file? ** Resource name=jdbc/authority auth=Container type=javax.sql.DataSource username=javauser password=javadude driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://localhost;database=authstore/ -Original Message- From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sent: Tuesday, March 23, 2010 3:22 PM To: Tomcat Users List Subject: RE: Connecting to a Database From: Leo Donahue - PLANDEVX [mailto:leodona...@mail.maricopa.gov] Subject: Connecting to a Database Tomcat 6.0.24 Windows Server 2003 R2 SP2 SQL Server 2005 Express Microsoft SQL Server 2005 JDBC Driver 1.2 - October 2007 I know I need to configure a Realm Are you sure? A Realm is used for authentication only, not for a webapp that accesses a database. Do you perhaps mean Resource? JDBCRealm or JNDI DataSourceRealm? If you are in fact storing credentials in SQL Server, use DataSourceRealm - it's much more robust. - 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
/META-INF/context.xml is being copied to $CATALINA_HOME/conf/my_engine/my_app/ROOT.xml
Dear Tomcat community: Here's my setup: - I am running Apache Tomcat/6.0.24. - I am deploying the my applications 'exploded' -- i.e. NOT as a war file. - each application is defined by a /META-INF/context.xml in the respective appBase directory. - I have several virtual hosts: Service name=my_service Connector protocol=AJP/1.3 port=8009 / Engine name=my_engine defaultHost=proj-2-1 !-- Default host -- Host name=proj-2-1 appBase=/home/webadmin/proj-2-1.djinnsoft.com unpackWARs=false ... /Host !-- UAT site -- Host name='hg.djinnsoft.com' unpackWARs='false' appBase='/home/webadmin/hg.djinnsoft.com/appBase' workDir='/home/webadmin/work/hg.djinnsoft.com' Aliashg.djinnsoft.com/Alias ... /Host !-- QA site -- Host name='test-hg.djinnsoft.com' unpackWARs='false' appBase='/home/webadmin/test-hg.djinnsoft.com/appBase' workDir='/home/webadmin/work/test-hg.djinnsoft.com' Aliastest-hg.djinnsoft.com/Alias ... /Host /Engine /Service Here'smy question/problem: I've noticed that the /META-INF/context.xml files are being copied from the respective appBase directories to $CATALINA_HOME/conf/my_engine directory. For example: # ls /opt/tomcat6/conf/my_engine/hg.djinnsoft.com/ROOT.xml /opt/tomcat6/conf/my_engine/hg.djinnsoft.com/ROOT.xml # ls /opt/tomcat6/conf/my_engine/test-hg.djinnsoft.com/ROOT.xml /opt/tomcat6/conf/my_engine/test-hg.djinnsoft.com/ROOT.xml This behaviour is unexpected for two reasons: - I have another system, which is configured identically (for another client), except that the Tomcat version is 6.0.18. The older Tomcat version is not copying files like this. - I can't find anything in the documentation that talks about copying the context.xml files for Host container (not to be confused with copying context.xml for the Context container, which might happen on occasion). Is this a new bug? Did I do something wrong? Did the Tomcat behaviour change in an undocumented fashion? Thanks, -- Dave Cherkassky VP of Software Development DJiNN Software Inc. 416.504.1354 - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Connecting to a Database
On 24/03/2010 15:43, Leo Donahue - PLANDEVX wrote: No, not sure. That is what I was confused about. JDBC Realm, vs JNDI DataSourceRealm, vs JDBC DataSource I think what was throwing me off was seeing examples of the tomcat-users in both the realm-howto and in the jndi-resources-howto I'm attempting container managed security using SQL Server. It looks like I need both a DataSourceRealm and a JDBC DataSource? Assuming I have the correct tables in the database named authstore, does this look right? Nope. If you define the DataSource in the app's context.xml, you need to define the realm there too, or it won't have access to the datasource. If you define the datasource as a global resource, you can define the Realm in server.xml (before or inside the Host), but then you need a resource link in the context.xml to make the global resource available to the app. ResourceLink global=jdbc/GlobalName name=jdbc/LocalName type=javax.sql.DataSource/ p ** in server.xml ** Realm className=com.microsoft.sqlserver.jdbc.SQLServerDriver dataSourceName=jdbc/authority userTable=users userNameCol=user_name userCredCol=user_pass userRoleTable=user_roles roleNameCol=role_name/ ** in META-INF/context.xml of specific webapp ** resource-ref descriptionDB Connection/description res-ref-namejdbc/authority/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref ** also in META-INF/context.xml file? ** Resource name=jdbc/authority auth=Container type=javax.sql.DataSource username=javauser password=javadude driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://localhost;database=authstore/ -Original Message- From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sent: Tuesday, March 23, 2010 3:22 PM To: Tomcat Users List Subject: RE: Connecting to a Database From: Leo Donahue - PLANDEVX [mailto:leodona...@mail.maricopa.gov] Subject: Connecting to a Database Tomcat 6.0.24 Windows Server 2003 R2 SP2 SQL Server 2005 Express Microsoft SQL Server 2005 JDBC Driver 1.2 - October 2007 I know I need to configure a Realm Are you sure? ARealm is used for authentication only, not for a webapp that accesses a database. Do you perhaps meanResource? JDBCRealm or JNDI DataSourceRealm? If you are in fact storing credentials in SQL Server, use DataSourceRealm - it's much more robust. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: /META-INF/context.xml is being copied to $CATALINA_HOME/conf/my_engine/my_app/ROOT.xml
On 24/03/2010 15:44, Dave Cherkassky wrote: Dear Tomcat community: Here's my setup: - I am running Apache Tomcat/6.0.24. - I am deploying the my applications 'exploded' -- i.e. NOT as a war file. - each application is defined by a /META-INF/context.xml in the respective appBase directory. - I have several virtual hosts: Service name=my_service Connector protocol=AJP/1.3 port=8009 / Engine name=my_engine defaultHost=proj-2-1 !-- Default host -- Host name=proj-2-1 appBase=/home/webadmin/proj-2-1.djinnsoft.com unpackWARs=false ... /Host !-- UAT site -- Host name='hg.djinnsoft.com' unpackWARs='false' appBase='/home/webadmin/hg.djinnsoft.com/appBase' workDir='/home/webadmin/work/hg.djinnsoft.com' Aliashg.djinnsoft.com/Alias ... /Host !-- QA site -- Host name='test-hg.djinnsoft.com' unpackWARs='false' appBase='/home/webadmin/test-hg.djinnsoft.com/appBase' workDir='/home/webadmin/work/test-hg.djinnsoft.com' Aliastest-hg.djinnsoft.com/Alias ... /Host /Engine /Service Here'smy question/problem: I've noticed that the /META-INF/context.xml files are being copied from the respective appBase directories to $CATALINA_HOME/conf/my_engine directory. For example: # ls /opt/tomcat6/conf/my_engine/hg.djinnsoft.com/ROOT.xml /opt/tomcat6/conf/my_engine/hg.djinnsoft.com/ROOT.xml # ls /opt/tomcat6/conf/my_engine/test-hg.djinnsoft.com/ROOT.xml /opt/tomcat6/conf/my_engine/test-hg.djinnsoft.com/ROOT.xml This behaviour is unexpected for two reasons: - I have another system, which is configured identically (for another client), except that the Tomcat version is 6.0.18. The older Tomcat version is not copying files like this. - I can't find anything in the documentation that talks about copying the context.xml files for Host container (not to be confused with copying context.xml for the Context container, which might happen on occasion). Is this a new bug? Why is it a bug? Did I do something wrong? Nope. Did the Tomcat behaviour change in an undocumented fashion? See notes for 6.0.19. http://tomcat.apache.org/tomcat-6.0-doc/changelog.html p Thanks, -- Dave Cherkassky VP of Software Development DJiNN Software Inc. 416.504.1354 - 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: Connecting to a Database
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 11:43 AM, Leo Donahue - PLANDEVX wrote: No, not sure. That is what I was confused about. JDBC Realm, vs JNDI DataSourceRealm, vs JDBC DataSource A Realm is something Tomcat uses for authentication. A DataSource is an object which hands out database connections. The use of JDBC vs. JNDI is really just about how the connections are obtained: JDBCRealm manages its own JDBC connection (and is heavily synchronized, as Mark mentions: don't use it). DataSourceRealm uses a DataSource obtained via JNDI and configured via a Resource element. There is no JDBCDataSource that I know of. Recommended setup (IMHO): configure everything in META-INF/context.xml and use DataSourceRealm. No need to configure anything in server.xml and no need to configure anything at the OS level (as Mark mentioned, that's ODBC). Assuming I have the correct tables in the database named authstore, does this look right? ** in server.xml ** Realm className=com.microsoft.sqlserver.jdbc.SQLServerDriver className should be org.apache.catalina.realm.DataSourceRealm dataSourceName=jdbc/authority userTable=users userNameCol=user_name userCredCol=user_pass userRoleTable=user_roles roleNameCol=role_name/ Ok. ** in META-INF/context.xml of specific webapp ** resource-ref descriptionDB Connection/description res-ref-namejdbc/authority/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref This is actually stuff for web.xml, though it is not required if you have your Resource defined in META-INF/context.xml. ** also in META-INF/context.xml file? ** Resource name=jdbc/authority auth=Container type=javax.sql.DataSource username=javauser password=javadude driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://localhost;database=authstore/ Looks good to me. Make sure your JDBC driver JAR file is in CATALINA_BASE/lib and nowhere else. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqNfkACgkQ9CaO5/Lv0PAgQwCgt7UySAU4hOcZzw4oGFlEqeqM l3EAoJt8ySaQRmKKwVZbS8NytPs8HfqZ =ou3q -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Connecting to a Database
From: Pid [mailto:p...@pidster.com] Subject: Re: Connecting to a Database If you define the datasource as a global resource, you can define the Realm in server.xml (before or inside the Host), but then you need a resource link in the context.xml to make the global resource available to the app. Are you sure about that? The ResourceLink is necessary when the app is accessing the data source, but in this case, it's not the app, it's Tomcat, doing the authentication lookups. I don't think the ResourceLink is necessary, but the rest is definitely needed. - 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: /META-INF/context.xml is being copied to $CATALINA_HOME/conf/my_engine/my_app/ROOT.xml
See below: Is this a new bug? Why is it a bug? Sorry, I was not implying anything :) I was just wondering why the behaviour changed. Did the Tomcat behaviour change in an undocumented fashion? See notes for 6.0.19. http://tomcat.apache.org/tomcat-6.0-doc/changelog.html Ah, this is a side effect of fixing issue https://issues.apache.org/bugzilla/show_bug.cgi?id=42747 right? Subtle! I wish that http://tomcat.apache.org/tomcat-6.0-doc/config/host.html has explained this -- would have saved a lot of time. Anyhoo, it all makes sense now. Thanks for your help. -- Dave Cherkassky VP of Software Development DJiNN Software Inc. 416.504.1354 p Thanks, -- Dave Cherkassky VP of Software Development DJiNN Software Inc. 416.504.1354 - 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: Connecting to a Database
Thanks everyone. I understand this better. I know you can specify digest for a Realm, but I don't see where I can do that for a Resource. Do I need to leave the password of javadude in the Resource in clear text, or can it be a digested version of javadude in clear text in the Resource element? The SQL table of user passwords will be in digest, but I wasn't sure if I could use a digested password as part of the configuration for the account that connects to the authstore database. Leo -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: Wednesday, March 24, 2010 8:56 AM To: Tomcat Users List Subject: Re: Connecting to a Database -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 11:43 AM, Leo Donahue - PLANDEVX wrote: No, not sure. That is what I was confused about. JDBC Realm, vs JNDI DataSourceRealm, vs JDBC DataSource A Realm is something Tomcat uses for authentication. A DataSource is an object which hands out database connections. The use of JDBC vs. JNDI is really just about how the connections are obtained: JDBCRealm manages its own JDBC connection (and is heavily synchronized, as Mark mentions: don't use it). DataSourceRealm uses a DataSource obtained via JNDI and configured via a Resource element. There is no JDBCDataSource that I know of. Recommended setup (IMHO): configure everything in META-INF/context.xml and use DataSourceRealm. No need to configure anything in server.xml and no need to configure anything at the OS level (as Mark mentioned, that's ODBC). Assuming I have the correct tables in the database named authstore, does this look right? ** in server.xml ** Realm className=com.microsoft.sqlserver.jdbc.SQLServerDriver className should be org.apache.catalina.realm.DataSourceRealm dataSourceName=jdbc/authority userTable=users userNameCol=user_name userCredCol=user_pass userRoleTable=user_roles roleNameCol=role_name/ Ok. ** in META-INF/context.xml of specific webapp ** resource-ref descriptionDB Connection/description res-ref-namejdbc/authority/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref This is actually stuff for web.xml, though it is not required if you have your Resource defined in META-INF/context.xml. ** also in META-INF/context.xml file? ** Resource name=jdbc/authority auth=Container type=javax.sql.DataSource username=javauser password=javadude driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://localhost;database=authstore/ Looks good to me. Make sure your JDBC driver JAR file is in CATALINA_BASE/lib and nowhere else. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqNfkACgkQ9CaO5/Lv0PAgQwCgt7UySAU4hOcZzw4oGFlEqeqM l3EAoJt8ySaQRmKKwVZbS8NytPs8HfqZ =ou3q -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
need help
Hi, I have to run tomcat against 500 concurrent users. I am using tomcat6, Java1.6 and tomcat running on windows2003 OS. Do I have to do any additional configuration for this in tomcat or no configuration required? Kindly help me. Do I have to specify any maximum threads allowed or kind of things? Pls help me guys.
import public certificate
I'm getting this error when trying to merge CERT into keystore c:\Program Files\Java\jre6\binkeytool -import -alias tomcat -keystore c:\sbskey tools\keys\sbs.keystore -trustcacerts -file c:\sbskeytools\keys\ebiz-sslcert.ce r keytool error: java.security.cert.CertificateException: sun.security.pkcs.Parsin gException: ObjectIdentifier() -- data isn't an object ID (tag = 48) thanks in advance. Charles G. Toman Database Administrator Stock Building Supply 8020 Arco Corporate Drive Raleigh, NC 27617 T: (919) 431 1792 C: (919) 524 8652 E: chuck.to...@stocksupply.com www.stockbuildingsupply.com Customer Focused, Associate Driven.
Re: Session replication: Channel.SEND_OPTIONS_SECURE
On 03/23/2010 09:46 AM, Tom wrote: On Tue, Mar 23, 2010 at 1:58 PM, Caldarale, Charles R chuck.caldar...@unisys.com wrote: From: Tom [mailto:808...@gmail.com] Subject: Session replication: Channel.SEND_OPTIONS_SECURE There is little documentation about Channel.SEND_OPTIONS_SECURE From a brief glance at the code, SEND_OPTIONS_SECURE appears to be defined, but not yet implemented - which would explain the behavior you observe. Thanks, that is what I feared. I think for our needs a crossover cable or tunnel will be sufficient. I am also interested in SEND_OPTIONS_BYTE_MESSAGE. Can anyone elaborate on the pros/cons other than speed? only pros, since you get to control all the class loading and how it happens. otherwise, you have to build some block on top of the channel that does the class loading for you Regards, Tom - 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
Configuring a database connection pool by source
Hi, I'm working in an application that uses an embedded tomcat and I'd like to add a feature to add a connection pool by source but when I run the server I'm getting this error: javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial I'm using the tomcat jars for the version 6.0.18, and this is how I'm trying to do it: tomcat = new org.apache.catalina.startup.Tomcat() //creates the new server ... // configures the server StandardContext application = tomcat.addWebapp(); //creates the web application ... // configures the web application resource = org.apache.catalina.deploy.ContextResource() // creates the new JNDI resource ... // configures the JNDI resource with the name, type and properties application.getNamingResources().addResource(resource) // adds the resource to the application context tomcat.start() //start tomcat This is more or less the code, seems I'm not configuring anything because without the resource it works fine. Can anyone help me? Thank you
Re: Connecting to a Database
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 1:28 PM, Leo Donahue - PLANDEVX wrote: I know you can specify digest for a Realm, but I don't see where I can do that for a Resource. Note that the digest is for hashing passwords during /user/ authentication, not connecting to the database. Do I need to leave the password of javadude in the Resource in clear text, or can it be a digested version of javadude in clear text in the Resource element? You cannot hash the db password. If you could, how would Tomcat decrypt it to make the connection? The SQL table of user passwords will be in digest, but I wasn't sure if I could use a digested password as part of the configuration for the account that connects to the authstore database. Nope. Search the archives for that question being asked repeatedly, or just think about the implications of hashing a password that you want to use later. Then, think about the implications of /two-way/ encryption for a password and I think you'll see that you're just moving the problem somewhere else. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqbDYACgkQ9CaO5/Lv0PBhHwCgqFQcdHypen2gtOfbtqjhd0IR CNUAoLT3Joi1rTnqvWC0wQ82Hls1zoK9 =uX5k -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: [OT] import public certificate
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Chuck, On 3/24/2010 2:02 PM, Toman, Chuck [Stock] wrote: I'm getting this error when trying to merge CERT into keystore c:\Program Files\Java\jre6\binkeytool -import -alias tomcat -keystore c:\sbskeytools\keys\sbs.keystore -trustcacerts -file c:\sbskeytools\keys\ebiz-sslcert.cer keytool error: java.security.cert.CertificateException: sun.security.pkcs.ParsingException: ObjectIdentifier() -- data isn't an object ID (tag = 48) - From the 'keytool' man page: keytool can import X.509 v1, v2, and v3 certificates, and PKCS#7 formatted certificate chains consisting of certificates of that type. The data to be imported must be provided either in binary encoding format, or in printable encoding format (also known as Base64 encoding) as defined by the Internet RFC 1421 standard. In the latter case, the encoding must be bounded at the beginning by a string that starts with -BEGIN, and bounded at the end by a string that starts with -END. Do you have a certificate file that meets these requirements? You may have to convert using openssl or another tool before using keytool. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqetIACgkQ9CaO5/Lv0PCI9ACgh5kkUQtO33wxVW6oOf8IgCgt enMAn3ju4xUt9BAOfBcDb6v430bvtD7d =Omeh -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Connecting to a Database
Chris, In my realm, you're saying that the digest attribute is how the password is stored in the database? Not how it is entered/translated when the user logs in. I'm using this to generate a MD5 hash of the password = password: java -classpath C:\apache-tomcat-6.0.24\lib\catalina.jar;C:\apache-tomcat-6.0.24\bin\tomcat-juli.jar org.apache.catalina.realm.RealmBase -a md5 password I don't understand why I can't authenticate with what I have. When I login and supply a username and password, I get the 401 error page. This user does have the webservicereader role. And the user's password is the same value in the database as in the dos window when I create a password of password. Page 144 of the servlet 2.5 spec speaks to the login-config Element. It doesn't list the values for realm-name, is DataSourceRealm valid? I've tried using DIGEST instead of BASIC for the auth-method, but that change doesn't make a difference, so I must have something else wrong? The only thing I haven't tried is changing the names of the tables to the names listed in the Tomcat docs. Maybe I can't use different table names for users and roles? I do have SSL enabled and I have another webapp working with Active Directory authentication - BASIC over HTTPS. This experiment is an extension of the SSL question I posted a few weeks ago. That is probably why the web.xml looks very similar. ** META-INF/context.xml: Context antiJARLocking=true path=/sample2 privileged=true !-- This Realm uses a DataSourceRealm -- Realm className=org.apache.catalina.realm.DataSourceRealm dataSourceName=jdbc/SecurityStore userTable=SECURITYSTORE_USERS userNameCol=USERNAME userCredCol=MD5PASSWORD userRoleTable=SECURITYSTORE_ROLES roleNameCol=ROLENAME digest=MD5/ resource-ref descriptionDB Connection/description res-ref-namejdbc/SecurityStore/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref Resource name=jdbc/SecurityStore auth=Container type=javax.sql.DataSource username=username password=password driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://servername;database=databasename/ /Context ** web.xml: !-- SECURITY CONSTRAINT -- security-constraint web-resource-collection web-resource-namesamplewebapp2/web-resource-name url-pattern/*/url-pattern http-methodGET/http-method http-methodPOST/http-method /web-resource-collection auth-constraint role-namewebservicereader/role-name /auth-constraint user-data-constraint transport-guaranteeCONFIDENTIAL/transport-guarantee /user-data-constraint /security-constraint !-- LOGIN CONFIGURATION-- login-config auth-methodBASIC/auth-method realm-nameDataSourceRealm/realm-name /login-config !-- Security roles referenced by this web application -- security-role role-namewebservicereader/role-name /security-role -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: Wednesday, March 24, 2010 12:47 PM To: Tomcat Users List Subject: Re: Connecting to a Database -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 1:28 PM, Leo Donahue - PLANDEVX wrote: I know you can specify digest for a Realm, but I don't see where I can do that for a Resource. Note that the digest is for hashing passwords during /user/ authentication, not connecting to the database. Do I need to leave the password of javadude in the Resource in clear text, or can it be a digested version of javadude in clear text in the Resource element? You cannot hash the db password. If you could, how would Tomcat decrypt it to make the connection? The SQL table of user passwords will be in digest, but I wasn't sure if I could use a digested password as part of the configuration for the account that connects to the authstore database. Nope. Search the archives for that question being asked repeatedly, or just think about the implications of hashing a password that you want to use later. Then, think about the implications of /two-way/ encryption for a password and I think you'll see that you're just moving the problem somewhere else. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqbDYACgkQ9CaO5/Lv0PBhHwCgqFQcdHypen2gtOfbtqjhd0IR CNUAoLT3Joi1rTnqvWC0wQ82Hls1zoK9 =uX5k -END PGP SIGNATURE- - To unsubscribe, e-mail:
Re: need help
It depends entirely on your application. 500 users each asking for one static HTML page every 10 minutes? Sure, no problem. 500 concurrent users requesting 1 page every 10 seconds that takes 8 seconds to generate? Ah, now you're going to have to do some tuning. Have you profiled your application? Do you know what load you expect? - Peter On 24 March 2010 17:38, Muralidhar Yaragalla yaragallamur...@gmail.comwrote: Hi, I have to run tomcat against 500 concurrent users. I am using tomcat6, Java1.6 and tomcat running on windows2003 OS. Do I have to do any additional configuration for this in tomcat or no configuration required? Kindly help me. Do I have to specify any maximum threads allowed or kind of things? Pls help me guys.
RE: Connecting to a Database
Good Evening Leo- i would suggest using the Digest class (over command line calculation of Password) http://tomcat.apache.org/tomcat-6.0-doc/realm-howto.html#Digested%20Passwords HTH Martin Gainty __ Relayers are requested to not disrupt or alter this transmission. From: leodona...@mail.maricopa.gov To: users@tomcat.apache.org Date: Wed, 24 Mar 2010 10:28:52 -0700 Subject: RE: Connecting to a Database Thanks everyone. I understand this better. I know you can specify digest for a Realm, but I don't see where I can do that for a Resource. Do I need to leave the password of javadude in the Resource in clear text, or can it be a digested version of javadude in clear text in the Resource element? The SQL table of user passwords will be in digest, but I wasn't sure if I could use a digested password as part of the configuration for the account that connects to the authstore database. Leo -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: Wednesday, March 24, 2010 8:56 AM To: Tomcat Users List Subject: Re: Connecting to a Database -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 11:43 AM, Leo Donahue - PLANDEVX wrote: No, not sure. That is what I was confused about. JDBC Realm, vs JNDI DataSourceRealm, vs JDBC DataSource A Realm is something Tomcat uses for authentication. A DataSource is an object which hands out database connections. The use of JDBC vs. JNDI is really just about how the connections are obtained: JDBCRealm manages its own JDBC connection (and is heavily synchronized, as Mark mentions: don't use it). DataSourceRealm uses a DataSource obtained via JNDI and configured via a Resource element. There is no JDBCDataSource that I know of. Recommended setup (IMHO): configure everything in META-INF/context.xml and use DataSourceRealm. No need to configure anything in server.xml and no need to configure anything at the OS level (as Mark mentioned, that's ODBC). Assuming I have the correct tables in the database named authstore, does this look right? ** in server.xml ** Realm className=com.microsoft.sqlserver.jdbc.SQLServerDriver className should be org.apache.catalina.realm.DataSourceRealm dataSourceName=jdbc/authority userTable=users userNameCol=user_name userCredCol=user_pass userRoleTable=user_roles roleNameCol=role_name/ Ok. ** in META-INF/context.xml of specific webapp ** resource-ref descriptionDB Connection/description res-ref-namejdbc/authority/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref This is actually stuff for web.xml, though it is not required if you have your Resource defined in META-INF/context.xml. ** also in META-INF/context.xml file? ** Resource name=jdbc/authority auth=Container type=javax.sql.DataSource username=javauser password=javadude driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://localhost;database=authstore/ Looks good to me. Make sure your JDBC driver JAR file is in CATALINA_BASE/lib and nowhere else. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkuqNfkACgkQ9CaO5/Lv0PAgQwCgt7UySAU4hOcZzw4oGFlEqeqM l3EAoJt8ySaQRmKKwVZbS8NytPs8HfqZ =ou3q -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 _ Hotmail has tools for the New Busy. Search, chat and e-mail from your inbox. http://www.windowslive.com/campaign/thenewbusy?ocid=PID27925::T:WLMTAGL:ON:WL:en-US:WM_HMP:032010_1
RE: need help
i would look at tuning permgen (specifically for handling anonymous classes) and perhaps using DBCP for connection pooling..resource handles ARE expensive (and anything else pete suggests) Martin Gainty __ Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité Ez az üzenet bizalmas. Ha nem ön az akinek szánva volt, akkor kérjük, hogy jelentse azt nekünk vissza. Semmiféle továbbítása vagy másolatának készítése nem megengedett. Ez az üzenet csak ismeret cserét szolgál és semmiféle jogi alkalmazhatósága sincs. Mivel az electronikus üzenetek könnyen megváltoztathatóak, ezért minket semmi felelöség nem terhelhet ezen üzenet tartalma miatt. Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen. Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni. Date: Wed, 24 Mar 2010 22:00:59 + Subject: Re: need help From: peter.crowt...@melandra.com To: users@tomcat.apache.org It depends entirely on your application. 500 users each asking for one static HTML page every 10 minutes? Sure, no problem. 500 concurrent users requesting 1 page every 10 seconds that takes 8 seconds to generate? Ah, now you're going to have to do some tuning. Have you profiled your application? Do you know what load you expect? - Peter On 24 March 2010 17:38, Muralidhar Yaragalla yaragallamur...@gmail.comwrote: Hi, I have to run tomcat against 500 concurrent users. I am using tomcat6, Java1.6 and tomcat running on windows2003 OS. Do I have to do any additional configuration for this in tomcat or no configuration required? Kindly help me. Do I have to specify any maximum threads allowed or kind of things? Pls help me guys. _ Hotmail is redefining busy with tools for the New Busy. Get more from your inbox. http://www.windowslive.com/campaign/thenewbusy?ocid=PID27925::T:WLMTAGL:ON:WL:en-US:WM_HMP:032010_2
httpd vs. Tomcat performance
Just to get this into the archives for the next time it comes up http://tomcatexpert.com/blog/2010/03/24/myth-or-truth-one-should-always-use-apache-httpd-front-apache-tomcat-improve-perform because I don't know if the author (a certain mthomas) will mention it here. :-) (via @springsource on Twitter) -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: httpd vs. Tomcat performance
On 25/03/2010 00:26, Hassan Schroeder wrote: Just to get this into the archives for the next time it comes up http://tomcatexpert.com/blog/2010/03/24/myth-or-truth-one-should-always-use-apache-httpd-front-apache-tomcat-improve-perform because I don't know if the author (a certain mthomas) will mention it here. :-) (via @springsource on Twitter) Chris deserves a lot of the credit. Without his figures, it is just opinion. I'll have to see if I can get the graph to display as well. It is nice to have the hard figures but the graph gives you a quicker handle on the data. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: httpd vs. Tomcat performance
On Thu, Mar 25, 2010 at 1:50 AM, Mark Thomas ma...@apache.org wrote: Chris deserves a lot of the credit. Without his figures, it is just opinion. That's the second benchmark that I see today that has odd numbers. Rémy - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: can't seem to migrate this app over to a new server
Peter, Thank you so much for your help, that tip about CONFIDENTIAL was just HUGE in helping me get this working. Also, thanks to Sam for linking to the documentation. All the best, John On Wed, Mar 24, 2010 at 3:24 AM, Peter Crowther peter.crowt...@melandra.com wrote: The SSL configuration for a Tomcat 5.5 server is described at http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html. To quote from the top of that file, this assumes you're not using APR (Apache Portable Runtime). APR is not the default configuration as I recall - if you don't know that you are using APR, you're probably not! I'll leave someone who knows more about the crypto side to answer your question about the JKS file. Can you set this up and test it in two stages? In the first stage, set up Tomcat and the webapp and see whether you can get to the app through normal HTTP. In the second stage, set up SSL. The main thing that might prevent this is if there's a transport guarantee of CONFIDENTIAL in your application's WEB-INF/web.xml file - if there is, you might want to comment that out while testing over HTTP, then put it back after you've got SSL working! A google for something like web-inf web.xml transport-guarantee will give you more details. Good luck with the configuration. - Peter On 24 March 2010 06:22, joon yoo jyoo1...@gmail.com wrote: We're in the process of extricating ourselves from a host who developed and managed our app through their own hosted server. In attempting to move the app over to a server under our control: Tomcat 5.5.28 w/ admin package java 1.5.0_28 Windows 2003 R2 all they gave me was a zipped up directory under their webapps dir and the JKS file for SSL. Do I need anything other than the JKS file to transfer the SSL cert over to our new tomcat server? Also, in trying to setup the app, I installed tomcat and unzipped it under webapps. and subsequently when i try to connect to the app through localhost/ourapp it gives up an error: Firefox can't establish a connection to the server at localhost:8443 I know very little about tomcat and java, so please at the very least, any answers that can be fully googleable, I would greatly appreciate. Thanks, John
Project: Develop a tool that can provision a Tuscany SCA enabled web application based on the extension requirements of the composite (implementation/binding/databinding/policy types) for Google App
i want you to give me more details about this idea bacause i want to do something with Tuscany SCA in Java and i think this an opportunity for me to do it. So i want more details about this idea and i will submit you my project and we will discuss about it before the subcription for the GSoC begin. I thank you very much in advance for the time you will take to read this. I'm waiting for your reply. Thank you very much.
Project : SPDY connector for Tomcat
I would like to work on this project. I propose a JAVA API that we can use to let Tomcat support SPDY. I'm waiting for your critics about this proposal. Thank you very much. Nouhoun
Re: Portable
Hi all, Thanks alot for your contributions. What other file should i reconfigure to permanently connect the tomcat to a particular mysql server? Say, mysql server running on port 3308? And can i make it automatically start the mysql database? Thank you in anticipation for your collaboration. CTO - Thinkwizer Limited, +234 703 5358949 +234 805 7590042 skype: asangansi.ini yahoo: inionfire On Mon, Mar 22, 2010 at 7:03 PM, Dan Armbrust daniel.armbrust.l...@gmail.com wrote: and what specific files do i need to reconfigure withe the new port address say, 8088? conf/server.xml Don't forget to change these other ports (in the same file) as well to something non-default: port=8005 port=8009 port=8443 - 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: Connecting to a Database
** SOLVED ** 1. It would have helped had I added the localDataSource=true to the Realm, since I was using the realm in META-INF/context.xml 2. It would have helped if I had paid attention to the actual table name I was using for the userRoleTable. The table should have been SECURITYSTORE_USERS_ROLES I don't know how many times I looked at that and ignored it. I feel about as stupid as possible. Leo -Original Message- From: Leo Donahue - PLANDEVX [mailto:leodona...@mail.maricopa.gov] Sent: Wednesday, March 24, 2010 2:56 PM To: 'Tomcat Users List' Subject: RE: Connecting to a Database Chris, In my realm, you're saying that the digest attribute is how the password is stored in the database? Not how it is entered/translated when the user logs in. I'm using this to generate a MD5 hash of the password = password: java -classpath C:\apache-tomcat-6.0.24\lib\catalina.jar;C:\apache-tomcat-6.0.24\bin\tomcat-juli.jar org.apache.catalina.realm.RealmBase -a md5 password I don't understand why I can't authenticate with what I have. When I login and supply a username and password, I get the 401 error page. This user does have the webservicereader role. And the user's password is the same value in the database as in the dos window when I create a password of password. Page 144 of the servlet 2.5 spec speaks to the login-config Element. It doesn't list the values for realm-name, is DataSourceRealm valid? I've tried using DIGEST instead of BASIC for the auth-method, but that change doesn't make a difference, so I must have something else wrong? The only thing I haven't tried is changing the names of the tables to the names listed in the Tomcat docs. Maybe I can't use different table names for users and roles? I do have SSL enabled and I have another webapp working with Active Directory authentication - BASIC over HTTPS. This experiment is an extension of the SSL question I posted a few weeks ago. That is probably why the web.xml looks very similar. ** META-INF/context.xml: Context antiJARLocking=true path=/sample2 privileged=true !-- This Realm uses a DataSourceRealm -- Realm className=org.apache.catalina.realm.DataSourceRealm dataSourceName=jdbc/SecurityStore userTable=SECURITYSTORE_USERS userNameCol=USERNAME userCredCol=MD5PASSWORD userRoleTable=SECURITYSTORE_ROLES roleNameCol=ROLENAME digest=MD5/ resource-ref descriptionDB Connection/description res-ref-namejdbc/SecurityStore/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref Resource name=jdbc/SecurityStore auth=Container type=javax.sql.DataSource username=username password=password driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver url=jdbc:sqlserver://servername;database=databasename/ /Context ** web.xml: !-- SECURITY CONSTRAINT -- security-constraint web-resource-collection web-resource-namesamplewebapp2/web-resource-name url-pattern/*/url-pattern http-methodGET/http-method http-methodPOST/http-method /web-resource-collection auth-constraint role-namewebservicereader/role-name /auth-constraint user-data-constraint transport-guaranteeCONFIDENTIAL/transport-guarantee /user-data-constraint /security-constraint !-- LOGIN CONFIGURATION-- login-config auth-methodBASIC/auth-method realm-nameDataSourceRealm/realm-name /login-config !-- Security roles referenced by this web application -- security-role role-namewebservicereader/role-name /security-role -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: Wednesday, March 24, 2010 12:47 PM To: Tomcat Users List Subject: Re: Connecting to a Database -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Leo, On 3/24/2010 1:28 PM, Leo Donahue - PLANDEVX wrote: I know you can specify digest for a Realm, but I don't see where I can do that for a Resource. Note that the digest is for hashing passwords during /user/ authentication, not connecting to the database. Do I need to leave the password of javadude in the Resource in clear text, or can it be a digested version of javadude in clear text in the Resource element? You cannot hash the db password. If you could, how would Tomcat decrypt it to make the connection? The SQL table of user passwords will be in digest, but I wasn't sure if I could use a digested password as part of the configuration for the account that connects to the authstore database. Nope. Search the archives for that question being asked repeatedly, or just think about the
Help required for SMAP....
Can someone help me to understand SMAP feature (how the mapping is indicated in files) in TOMCAT? (a reference link or a book would be great) -- _A_N_I_M_E_-_O_T_A_K_U_
RE: Help required for SMAP....
From: TWönlìnè [mailto:twonlinevi...@gmail.com] Subject: Help required for SMAP Can someone help me to understand SMAP feature (how the mapping is indicated in files) in TOMCAT? Try reading the servlet spec. All of it should be required reading for anyone using servlets or JSPs, but the SRV.11 section is what you need right now. http://jcp.org/aboutJava/communityprocess/mrel/jsr154/index2.html - 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: Help required for SMAP....
Not URL mapping, i need to understand SMAP mapping, here's a SMAP file i created, (when compiling JSP to JAVA sources) SMAP time_jsp.java JSP *S JSP *F + 0 time.jsp mytest/time.jsp *L 3,11:55,0 14,3:57 16,3:60,0 18:61 19,2:62,0 *E this is JSP line to JAVA line mapping ??? but i found that they are indicated incorrectly... like line JSP line 3 to 11 should map to JAVA line 55 but its not indicating this correctly. JAVA line 55 only contains lines from 6 to 12 of original JSP. Is this a bug in TOMCAT or Problem with my compiling. time.jsp %@ page language=java contentType=text/html; charset=ISO-8859-1 pageEncoding=ISO-8859-1 % %@ page import=java.util.* % %@ page import=java.text.* % !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN http://www.w3.org/TR/html4/loose.dtd; html head meta http-equiv=Content-Type content=text/html; charset=ISO-8859-1 titleInsert title here/title /head body % Date day = new Date(); String today = DateFormat.getDateInstance().format(day); % Today is: em%=today %/em /body /html time_jsp.java package sdasdasd_jsp.mytest; import javax.servlet.*; import javax.servlet.http.*; import javax.servlet.jsp.*; import java.util.*; import java.text.*; public final class time_jsp extends org.apache.jasper.runtime.HttpJspBase implements org.apache.jasper.runtime.JspSourceDependent { private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory(); private static java.util.List _jspx_dependants; private javax.el.ExpressionFactory _el_expressionfactory; private org.apache.AnnotationProcessor _jsp_annotationprocessor; public Object getDependants() { return _jspx_dependants; } public void _jspInit() { _el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory(); _jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName()); } public void _jspDestroy() { } public void _jspService(HttpServletRequest request, HttpServletResponse response) throws java.io.IOException, ServletException { PageContext pageContext = null; HttpSession session = null; ServletContext application = null; ServletConfig config = null; JspWriter out = null; Object page = this; JspWriter _jspx_out = null; PageContext _jspx_page_context = null; try { response.setContentType(text/html; charset=ISO-8859-1); pageContext = _jspxFactory.getPageContext(this, request, response, null, true, 8192, true); _jspx_page_context = pageContext; application = pageContext.getServletContext(); config = pageContext.getServletConfig(); session = pageContext.getSession(); out = pageContext.getOut(); _jspx_out = out; out.write(\r\n\r\n\n!DOCTYPE html PUBLIC \-//W3C//DTD HTML 4.01 Transitional//EN\ \http://www.w3.org/TR/html4/loose.dtd\;\nhtml\nhead\nmeta http-equiv=\Content-Type\ content=\text/html; charset=ISO-8859-1\\ntitleInsert title here/title\n/head\nbody\n); Date day = new Date(); String today = DateFormat.getDateInstance().format(day); out.write(\r\nToday is:\r\nem); out.print(today ); out.write(/em\n/body\n/html); } catch (Throwable t) { if (!(t instanceof SkipPageException)){ out = _jspx_out; if (out != null out.getBufferSize() != 0) try { out.clearBuffer(); } catch (java.io.IOException e) {} if (_jspx_page_context != null) _jspx_page_context.handlePageException(t); } } finally { _jspxFactory.releasePageContext(_jspx_page_context); } } } As i know
Re: Project : SPDY connector for Tomcat
Hi Nouhoun, I too was interested in this idea and Jean-Frederic provided a brief explanation and also some useful resources. Perhaps you will also find them useful to get started. I'm including a link [1] to the discussion below. [1] http://marc.info/?l=tomcat-devm=126924586709978w=2 Regards, Rajeev On Thu, Mar 25, 2010 at 8:57 AM, Nouhoun KANE nouhounk...@gmail.com wrote: I would like to work on this project. I propose a JAVA API that we can use to let Tomcat support SPDY. I'm waiting for your critics about this proposal. Thank you very much. Nouhoun
RE: Help required for SMAP....
From: TWönlìnè [mailto:twonlinevi...@gmail.com] Subject: Re: Help required for SMAP Not URL mapping, i need to understand SMAP mapping Sorry, I misunderstood the problem. 3,11:55,0 14,3:57 16,3:60,0 18:61 19,2:62,0 I believe the above notation is starting line followed by the number of lines, not the ending line. So 3,11 means lines 3 through 13; 14,3 is lines 14 through 16; etc. You need to post the files with line numbers, since e-mail clients are going to wrap lines at various and somewhat unpredictable places, making correct interpretation rather tricky. - 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