Rejected Message
The attached mail message has been rejected for the following reason: Message contains attachments: spicedham.jpg Additional Information: Please correct the problem before re-sending the mail. Such mails are blocked here: spicedham.jpg
how to upload JSP based website uing Tomcat
Hi all please guide me how can i upload my website on net which is based on JSP using tomcat with windows 2000. thanks Amit
how to check if user is authenticated
I am doing form based login using JDBCRealm and for logging out I call request.getSession().invalidate(). The problem is that after invalidation (duering the very same request) I can still use request.getRemoteUser() and it returns user name just like before calling session.invalidate(). What would be the proper way of asking if the user is logged in or not? I cannot set any session attributes duering login process since I am using tomcat's built in JDBCRealm authentication. Oh and I am using latest nightly build of Tomcat 4.0. Thank you so much for your time with best wishes, Taavi
Help with Tomcat4
Hi, I'm using experimenting with Tomcat4 and I did the following:- I wrote a servlet that implements the ContainerServlet[Obviosuly in the org.apache.catalina.servlets package] . Now I have a set of JSPs which in turn use a set of Java beans whcih in turn use this Servlet for getting hol of information on Context etc. However I am facing the follwing problem:- In my Java bean if I import org.apache.catalina.Deployer it's not able to find the class in my classpath and throws a ClassNotFoundException. I found this problem very weird as these are the classes in the standard JAR that comes with Tomcat 4. Could someone please explain this to me? Anand Associate,RD, Digital Think
Problem with jakarta.apache.org on Aug 26 morning
or do I have a problem from my location?? the time is 10:09 Aug 26 __ Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with Shop@Netscape! http://shopnow.netscape.com/ Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/
rollback problems in session facade
Hello, I am using a SessionBean as a Facade to my EntiyBeans! Well, in one of my SessionBeans I have implemented a method which creates some EntityBeans. Thats all ok, however after that creation I also call some additional set-methods on these creates EntityBeans. If one of these method calls fails an exception is thrown and the transaction is rollbacked. Howerever, the created EntityBeans in that transaction context are still available that means the corresponding entries in my database are still there and were not rollbacked. Is that behavior correct or do I do anything wrong, so that I have to remove all created EntityBeans on myself in the catch-clause of my try-catch block?? Thank you Daniel Schaller
RE: RequestDispatcher.forward()?
Or, more specifically: http://java.sun.com/j2ee/tutorial/api/index.html You'll find RequestDispatcher in the All Classes frame. -Original Message- From: Rob S. [mailto:[EMAIL PROTECTED]] Sent: Friday, August 24, 2001 7:55 AM To: [EMAIL PROTECTED] Subject: Re: RequestDispatcher.forward()? Can you please explain to me how to use RequestDispatcher.forward()? Yikes... you're better off searching Google or picking up a book on servlets. Or heck, you could read the servlet api javadoc comments =) - r
Installation of tomcat package on a debian woody system
I'am trying to get tomcat to work on a Debian woody system, but the only success I have is a plain/text file from local- host. First of all I compiled the sources from jakarta.apache.org, but it stucks due to a segmentation fault. Anyway. Then I tried to install all required packages and changed the init scripts so they can find $DAMON and $CONFIG files: ( the values were set to my self compiled system ) Tomcat 3.2.2-1 apache 1.3.19-1 jdk1.1 1.1.8v1-3 libapache-mod-jk 3.2.2-1 I started apache with /etc/init.d/apache start. Now I'am trying to get access to localhost in order to execute my Hello.java script located under: /usr/share/java/webapps/ The content of this script is available in my browser in plain/ ascii, so I expect the Mime-Types aren't recognized from tomcat ? Before that I've changed server.xml so tomcat can reference the document and proofed that the following lines are included in the httpd.conf: IfModule mod_jk.c The following line is for apacheconfig - DO NOT REMOVE! JkWorkersFile /etc/apache/mod_jk/workers.properties Include /etc/apache/mod_jk/tomcat-auto /IfModule So the module seems to be loaded as without the IfModule directive no error message appears. The bugzilla at debian.org has no entries included refering to tomcat and I wrote a mail to debian-user without any answer to my question. Has someone possibly the a/m packages installed and was able to get them to work properly ? -- Best Regards, Mark
web.XML - JSP mapping ?
Hi, Also a bit off subject, but I need some mapping for JSP pages. I get the thing working for servlets fine, using servlet servlet-mapping. I dont seems to get it working for a JSP page. Could someone be so kind to define the web.xml stuff for following small setup : jsp page to be mapped : /subdir/jsppage.jsp logical name for page : do-jsppage My code should do something like : dorRedirect(do-jsppage) ; Thanx, Fred
Re: Memory used by java process
As long as the growing process stops at some point it's fine. Java is dynamic by nature, meaning the classes are loaded on demand, not proactively. Jsp pages are compiled into servlets and get loaded only as needed, that's why process size is growing with time. Try -verbose options to see how many classes get loaded per request. You're also generating objects yourself in servlets/Jsp's. Some of them are long lived, which contributes to growing heap/process size. Another thing is that VM doesn't give all memory back even after it's reclaimed by GC. If it keeps growing without bounds most likely you have a memory leak somewhere, meaning some objects cannot be reclaimed by GC because they are strongly reachable. Also, the -Xincgc option you use enables train or incremental garbage collection, which from my experience makes GC less aggressive in general (this is what it's meant for anyway), which translates into larger Java process/heap size but less noticeable GC pauses. Hope this helps, --V. - Original Message - From: Roy K. Mayr R. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, August 25, 2001 6:25 PM Subject: Memory used by java process Hi, I'm working with Solaris 8, Tomcat 3.3b, jdk 1.3.1, and Apache... When I start tomcat, java process use 16M and when I run JSP pages this process grow more, more, more I start java with options: export TOMCAT_OPTS= -server -verbosegc -Xincgc -Xmx150m What is wrong?? Output of verbosegc is: [GC 2048K-315K(2368K), 0.0462030 secs] [GC 2363K-700K(2816K), 0.0608491 secs] [GC 2748K-892K(3072K), 0.0341915 secs] [Full GC 2532K-1166K(2944K), 0.1949014 secs] [Full GC 1182K-1166K(2944K), 0.1618361 secs] [Full GC 1182K-1166K(2944K), 0.1584852 secs] [Full GC 1182K-1165K(2944K), 0.1936703 secs] [Full GC 1181K-1165K(2944K), 0.1533219 secs] [Full GC 1181K-1165K(2944K), 0.1563846 secs] [Full GC 1181K-1166K(2944K), 0.1545294 secs] [Full GC 1182K-1165K(2944K), 0.1559197 secs] [Full GC 1181K-1165K(2944K), 0.1528804 secs] [Full GC 1181K-1166K(2944K), 0.1569995 secs] [Full GC 1182K-1165K(2944K), 0.1563494 secs] [Full GC 1181K-1165K(2944K), 0.1603762 secs] [Full GC 1181K-1165K(2944K), 0.1538769 secs] [Full GC 1181K-1165K(2944K), 0.1532354 secs] [Full GC 1181K-1165K(2944K), 0.1560933 secs] [Full GC 1181K-1165K(2944K), 0.1897674 secs] [Full GC 1181K-1165K(2944K), 0.1539893 secs] [Full GC 1181K-1165K(2944K), 0.1579279 secs] [Full GC 1181K-1165K(2944K), 0.1608534 secs] [Full GC 1181K-1165K(2944K), 0.1537858 secs] [Full GC 1181K-1165K(2944K), 0.1563487 secs] [Full GC 1181K-1165K(2944K), 0.1607285 secs] [Full GC 1181K-1165K(2944K), 0.1566505 secs] [Full GC 1181K-1165K(2944K), 0.1559282 secs] [Full GC 1181K-1165K(2944K), 0.1530489 secs] [Full GC 1181K-1165K(2944K), 0.1607813 secs] [Full GC 1181K-1165K(2944K), 0.1538563 secs] ... And finaly, every page that I see, output: [GC 6976K-6516K(7232K), 0.0142359 secs] [GC 7021K-6564K(7232K), 0.0164692 secs] [GC 7076K-6643K(7360K), 0.0208976 secs] What it means ?? Roy
Bug? : Cannot get 403 error-page to work
I'm trying to get tomcat to use my 403 forbidden error page. I've had no luck with it so far. My 404 page works fine. I have this problem even if I turn off IE friendly error messages. Using tomcat 4.0b7, JDBCRealm (against mySQL), running on Linux. from web-xml : error-page error-code404/error-code location/security/status/notfound.jsp/location /error-page error-page error-code403/error-code location/security/status/forbidden.jsp/location /error-page from localhost_access_log : (Here's where I hit a forbidden page)... 192.168.1.100 - - [26/Aug/2001:13:14:13 -0600] POST /security/j_security_check HTTP/1.1 302 - 192.168.1.100 - guest [26/Aug/2001:13:14:13 -0600] GET /secured/index.jsp HTTP/ 1.1 403 - (Here's where I hit a page that doesn't exist)... 192.168.1.100 - guest [26/Aug/2001:13:14:30 -0600] GET /asdasdas HTTP/1.1 200 1561 from catalina.out XmlMapper: new null org.apache.catalina.deploy.ErrorPage error-page ErrorPage[er rorCode=0, location=null] XmlMapper: org.apache.catalina.deploy.ErrorPage.setErrorCode( 403) XmlMapper: org.apache.catalina.deploy.ErrorPage.setLocation( /security/status/fo rbidden.jsp) XmlMapper: Calling org.apache.catalina.core.StandardContext.addErrorPage ErrorPa ge[errorCode=403, location=/security/status/forbidden.jsp] XmlMapper: pop error-page org.apache.catalina.deploy.ErrorPage: ErrorPage[errorC ode=403, location=/security/status/forbidden.jsp]
Virtual Hosting
Does anyone know where I can get instructions on virtual hosting with IIS and Tomcat? Thanks. -Arafat _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com
Re: how to check if user is authenticated
On Sun, 26 Aug 2001, Taavi Tiirik wrote: Date: Sun, 26 Aug 2001 15:49:19 +0200 From: Taavi Tiirik [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: how to check if user is authenticated I am doing form based login using JDBCRealm and for logging out I call request.getSession().invalidate(). By the way, this works only if you are using form-based login -- for BASIC login you have to ask your user to log out. The problem is that after invalidation (duering the very same request) I can still use request.getRemoteUser() and it returns user name just like before calling session.invalidate(). That is because the authentication decision for *this* request was made at the beginning of the request, and lasts for the entire length of that request -- no matter what else happens. What would be the proper way of asking if the user is logged in or not? I cannot set any session attributes duering login process since I am using tomcat's built in JDBCRealm authentication. The simplest thing would be to use an HttpSessionListener (a new listener API added in servlet 2.3). Such listeners are notified when a new session is created (even if it's done by Tomcat) and destroyed. Oh and I am using latest nightly build of Tomcat 4.0. Thank you so much for your time with best wishes, Taavi Craig McClanahan
Re: Help with Tomcat4
On Sun, 26 Aug 2001, Anand B N wrote: Date: Sun, 26 Aug 2001 21:28:51 +0530 From: Anand B N [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Help with Tomcat4 Hi, I'm using experimenting with Tomcat4 and I did the following:- I wrote a servlet that implements the ContainerServlet[Obviosuly in the org.apache.catalina.servlets package] . Now I have a set of JSPs which in turn use a set of Java beans whcih in turn use this Servlet for getting hol of information on Context etc. However I am facing the follwing problem:- In my Java bean if I import org.apache.catalina.Deployer it's not able to find the class in my classpath and throws a ClassNotFoundException. I found this problem very weird as these are the classes in the standard JAR that comes with Tomcat 4. Could someone please explain this to me? Container servlets are loaded from the Catalina internal class loader, so the servlet class itself (and any beans it references) has to be loaded from a $CATALINA_HOME/server/classes, or a JAR file in $CATALINA_HOME/server/lib. If the bean classes must also be referenced from within your webapp, you can put them unde $CATALINA_HOME/common/classes or $CATALINA_HOME/common/lib to make them available both internally and externally. It goes without saying that using this facility is very much specific to Tomcat 4, and you should be very security conscious in your programming -- since the Container servlet has complete access to Catalina internals. But the technique is definitely useful for building Tomcat 4 administrative tools as web applications. Anand Associate,RD, Digital Think Craig McClanahan
Re: web.XML - JSP mapping ?
On Sun, 26 Aug 2001, Frot wrote: Date: Sun, 26 Aug 2001 15:21:38 +0200 From: Frot [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED], [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: web.XML - JSP mapping ? Hi, Also a bit off subject, but I need some mapping for JSP pages. I get the thing working for servlets fine, using servlet servlet-mapping. I dont seems to get it working for a JSP page. Could someone be so kind to define the web.xml stuff for following small setup : jsp page to be mapped : /subdir/jsppage.jsp logical name for page : do-jsppage My code should do something like : dorRedirect(do-jsppage) ; Thanx, Fred Every JSP page has an *implicit* mapping that matches it's name (/subdir/jsppage.jsp in the case above). If you want to give this page a different mapping, you can do so like this: servlet servlet-nameRemapped JSP Page/servlet-name jsp-file/subdir/jsppage.jsp/jsp-file /servlet ... servlet-mapping servlet-nameRemapped JSP Page/servlet-name url-pattern/do-jsppage/url-pattern /servlet-mapping and now a URL like this: http://www.mycompany.com/myapp/do-jsppage will execute the requested page. Craig
Re: Problem with jakarta.apache.org on Aug 26 morning
On Sun, 26 Aug 2001, Peter Shankey wrote: Date: Sun, 26 Aug 2001 10:08:34 -0400 From: Peter Shankey [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: Problem with jakarta.apache.org on Aug 26 morning or do I have a problem from my location?? the time is 10:09 Aug 26 The Apache server that runs this web site was moved last night, and now has a new IP address -- it's possible that your DNS server has not yet recognized the change. Craig
Re: Start up Sax exception init param
Thanks for answering But, do you mean the error is from the cocoon web.xml file or the tomcat one? As I have only changed the cocoon jar, i guess it's from the cocoon one. Here is line 181 !-- This parameter allows you to startup Cocoon2 immediately after startup of your servlet engine. -- load-on-startup1/load-on-startup /servlet Nobody answered my question on the cocoon user mailing list, maybe it was badly fomulated. - Original Message - From: Craig R. McClanahan [EMAIL PROTECTED] To: Tomcat User Mail List [EMAIL PROTECTED]; cib [EMAIL PROTECTED] Sent: Thursday, August 23, 2001 5:48 PM Subject: Re: Start up Sax exception init param On Thu, 23 Aug 2001, cib wrote: Date: Thu, 23 Aug 2001 08:54:24 +0200 From: cib [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED], cib [EMAIL PROTECTED] To: Tomcat User Mail List [EMAIL PROTECTED] Subject: Start up Sax exception init param Hi, I've upgraded to Cocoon2.0b1 from beta1. But since I changed the war old war file to the new one ( I've erased the work directory before, idem for the log files), I get an exception at Tomcat's start. No one answered my question on cocoon mailing list, so I try it here. The exception is: PARSE error at line 181 column -1 org.xml.sax.SAXParseException: org.apache.crimson.parser/V-036 web-app init-param This sounds like there might be a problem with your web.xml file at line 181. In particular, if you have the elements in an order different than what the DTD requires, you will *always* get XML validation errors. Craig McClanahan
Re: Error 500 with java.lang.NoSuchMethodError
Sorry, but I didn't resolve my problems... I'm using tomcat 3.2.3 with servlet.jar (2.2b specification) and jsp.jar (1.2 specification) Maybe I need jsp.jar (1.1 specification) instead of 1.2, but I don't know where I can download it!!! Could you help me, please? Thank you very much!!! Stefano. - Original Message - From: Craig R. McClanahan [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, August 24, 2001 11:43 PM Subject: Re: Error 500 with java.jang.NoSuchMethodError Look for an old or incorrect version of servlet.jar (or possibly j2ee.jar) in your CLASSPATH, or in your $JAVA_HOME/jre/lib/ext directory and remove it. Craig On Fri, 24 Aug 2001, Stefano Monni wrote: Date: Fri, 24 Aug 2001 23:10:28 +0200 From: Stefano Monni [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Error 500 with java.jang.NoSuchMethodError Hello, I have a problem...(I'm new to Tomcat...) I've set TOMCAT_HOME, JAVA_HOME variables... But when I try to run any simple example (e.g date.jsp) I get an ERROR 500 (Internal Servlet Error) with a java.lang.NoSuchMethodError For example: /examples/jsp/dates/date.jsp Internal Servlet Error: java.lang.NoSuchMethodError at org.apache.tomcat.context.ExceptionHandler.doService(DefaultCMSetter.java:28 9) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:1183) at org.apache.tomcat.core.Handler.service(Handler.java:312) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) What does it mean? How could I solve this problem?! Thank you for your help!!! What does it mean? How can I resolve this problem? Thank you for your help!!!
Re: Using Normal Html in methods, or class structures in JSP
Your example below creates a syntactically invalid page -- if you use the %! ... % construct to declare a method, the *entire* method declaration needs to be inside the same construct. You should really really really be using servlets for stuff like this -- trying to mix code and HTML output on the same JSP page is just going to get you into trouble. Craig McClanahan On Sun, 26 Aug 2001 [EMAIL PROTECTED] wrote: Date: Sun, 26 Aug 2001 20:56:13 GMT From: [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Using Normal Html in methods, or class structures in JSP I'm declaring a class inside my jsp %! public class foo{ public void mymethod{ //Java code % Html %! }//mymethod }//foo % The problem is that, the Html is put inside the jsp_service method in the generated servlet code and not inside the class structure, which otherwise works perfectly fine. What I tried to do is pass a JspWriter object into my class via constructor, but that doesn't help. I need the html to appear within the class and not the jsp_service, does anyone have any idea how to fix this? - This message was sent using Endymion MailMan. http://www.endymion.com/products/mailman/
Re: Start up Sax exception init param
On Sun, 26 Aug 2001, cib wrote: Date: Sun, 26 Aug 2001 23:17:29 +0200 From: cib [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED], cib [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: Start up Sax exception init param Thanks for answering But, do you mean the error is from the cocoon web.xml file or the tomcat one? Since you didn't give us the entire error traceback, it's impossible to tell -- but if it were the Tomcat one, it would cause problems for *all* web apps, not just this one. As I have only changed the cocoon jar, i guess it's from the cocoon one. Here is line 181 !-- This parameter allows you to startup Cocoon2 immediately after startup of your servlet engine. -- load-on-startup1/load-on-startup /servlet Please cut-and-paste the *entire* servlet element -- if things are out of order, we can't tell from just this. Craig Nobody answered my question on the cocoon user mailing list, maybe it was badly fomulated. - Original Message - From: Craig R. McClanahan [EMAIL PROTECTED] To: Tomcat User Mail List [EMAIL PROTECTED]; cib [EMAIL PROTECTED] Sent: Thursday, August 23, 2001 5:48 PM Subject: Re: Start up Sax exception init param On Thu, 23 Aug 2001, cib wrote: Date: Thu, 23 Aug 2001 08:54:24 +0200 From: cib [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED], cib [EMAIL PROTECTED] To: Tomcat User Mail List [EMAIL PROTECTED] Subject: Start up Sax exception init param Hi, I've upgraded to Cocoon2.0b1 from beta1. But since I changed the war old war file to the new one ( I've erased the work directory before, idem for the log files), I get an exception at Tomcat's start. No one answered my question on cocoon mailing list, so I try it here. The exception is: PARSE error at line 181 column -1 org.xml.sax.SAXParseException: org.apache.crimson.parser/V-036 web-app init-param This sounds like there might be a problem with your web.xml file at line 181. In particular, if you have the elements in an order different than what the DTD requires, you will *always* get XML validation errors. Craig McClanahan
how to configure tomcat to run with IIS in Win 2000
Hi, I need some help in configuring tomcat with IIS on Win2000. I am running tomcat with WinNT (used the tomcat-IIS how to). Is the procedure for configuring with Win2000 also the same. Pls let me know, Regards, Anand.
Re: how to make a servlet as the home page
one way is to use the index.html and create a frame where you specify src = path to your servlet saadat. - Original Message - From: naveen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, August 26, 2001 9:29 PM Subject: how to make a servlet as the home page hi , I am using tomcat and apache, I want to make a servlet as the home page of my web site, when i access http://www.mysite.com/, a servlet needs to be called and the most important thing in this is I need to access HTTP variables like Remote Host, etc. thanks in advance
Re: how to make a servlet as the home page
one way is to use the index.html and create a frame where you specify src = path to your servlet saadat. - Original Message - From: naveen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, August 26, 2001 9:29 PM Subject: how to make a servlet as the home page hi , I am using tomcat and apache, I want to make a servlet as the home page of my web site, when i access http://www.mysite.com/, a servlet needs to be called and the most important thing in this is I need to access HTTP variables like Remote Host, etc. thanks in advance
RE: how to make a servlet as the home page
Create an index.html with the following text HTML HEAD meta http-equiv=REFRESH CONTENT=0; URL=/servlet/com.acme.XYZServlet /HEAD /HTML Ensure that the servlet handles doGet(...) -- Aravind - Original Message - From: naveen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, August 26, 2001 9:29 PM Subject: how to make a servlet as the home page hi , I am using tomcat and apache, I want to make a servlet as the home page of my web site, when i access http://www.mysite.com/, a servlet needs to be called and the most important thing in this is I need to access HTTP variables like Remote Host, etc. thanks in advance
RE: how to make a servlet as the home page
Ok, if you're using apache, then the first thing apache does when it gets a request for a directory is look for the DirectoryIndex instruction. typically this will be set to index.html index.htm index.jsp etc. The way this works is that apache will first check index.html, then index.htm, then index.jsp and serve whichever comes first. the second part of the equation is the JkMount directives. Say you create a directive JkMount /MyHomePageServlet ajp13 then you can set DirectoryIndex MyHomePageServlet index.html index.htm index.jsp and afaik apache should route the request for / to tomcat, and tomcat will know how to serve /MyHomePageServlet. just a warning this is all theory, I haven't tested it, but I think the concepts are right. hth, cheesr dim - Original Message - From: naveen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, August 26, 2001 9:29 PM Subject: how to make a servlet as the home page hi , I am using tomcat and apache, I want to make a servlet as the home page of my web site, when i access http://www.mysite.com/, a servlet needs to be called and the most important thing in this is I need to access HTTP variables like Remote Host, etc. thanks in advance
Re: how to make a servlet as the home page
Why don't you just have the welcome page in the web.xml contain: jsp:forward page=/map* / and have /map* mapped in web.xml to a servlet? I don't understand why you think going to a servlet in a problem? -Original Message- From: Aravind Naidu [EMAIL PROTECTED] To: [EMAIL PROTECTED] [EMAIL PROTECTED] Date: Sunday, August 26, 2001 7:52 PM Subject: RE: how to make a servlet as the home page Create an index.html with the following text HTML HEAD meta http-equiv=REFRESH CONTENT=0; URL=/servlet/com.acme.XYZServlet /HEAD /HTML Ensure that the servlet handles doGet(...) -- Aravind - Original Message - From: naveen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, August 26, 2001 9:29 PM Subject: how to make a servlet as the home page hi , I am using tomcat and apache, I want to make a servlet as the home page of my web site, when i access http://www.mysite.com/, a servlet needs to be called and the most important thing in this is I need to access HTTP variables like Remote Host, etc. thanks in advance
Configuring tomcat to run with apache on linux
I need help, everytime i start tomcat, i get this address already exist error... anyone had encountered this? pls help...
Bugs in Tomcat 3.2.2/3.2.3 on Linux (RH 7.1)?
Hello everyone, I started to deploy tomcat 3.2.3 on a newly installed RH 7.1 system, with the following configuration kernel-2.4.3-12 (upgraded from RH errata) apacheconf-0.7-2 (RH 7.1 default) apache-manual-1.3.19-5 (RH 7.1 default) apache-1.3.19-5 (RH 7.1 default) mod_ssl-2.8.1-5 (RH 7.1 default) jdk-1.3.1-fcs (Sun J2SDK for RH) ant-1.3-2 (jakarta's distribution http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/rpms/) tomcat-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-mod-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-manual-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-webapps-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) http://neptune:8080/examples/jsp/snp/snoop.jsp is working OK, but http://neptune:8080/examples/jsp/num/numguess.jsp generate the following Is this a bug in Tomcat distribution or a bug in the JDK? If I want to run on Linux (preferably RH), what is the good combination of kernel/jdk/tomcat/ant/apache that is most stable/well tested. All suggestions are really appreciated. 2001-08-27 10:03:13 - Ctx( /examples ): Exception in: R( /examples + /jsp/num/numguess.jsp + null) - javax.servlet.ServletException at java.lang.Throwable.init(Throwable.java:96) at java.lang.Exception.init(Exception.java:44) at javax.servlet.ServletException.init(ServletException.java) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java) at org.apache.tomcat.core.Handler.service(Handler.java) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java) at org.apache.tomcat.core.ContextManager.service(ContextManager.java) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java) at java.lang.Thread.run(Thread.java:498) Root cause: java.lang.StackOverflowError at at java.beans.Beans.instantiate(Beans.java:57) at jsp.num._0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0._jspService( _0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0.java:75) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java) at org.apache.tomcat.core.Handler.service(Handler.java) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java) at org.apache.tomcat.core.ContextManager.service(ContextManager.java) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java) at java.lang.Thread.run(Thread.java:498) Nguyen Thanh Phong Tel: 84-8-837 25 06/837 25 07 Saigon Software Development Company (SDC)Fax: 84-8-837 25 11 10 Co Giang Street, Dist I, HCMC Email: [EMAIL PROTECTED] Vietnam
Re: Bugs in Tomcat 3.2.2/3.2.3 on Linux (RH 7.1)?
The same error is generated with IBMJava2-SDK-1.3-5.0 for Linux BTW, I'm aware that Tomcat 3.3 is released but I want to integrate Tomcat+JBoss, which doesn't support Tomcat 3.3 yet (or at least I can't find in the download page of Jboss), so I want to try Tomcat 3.2.x Stack trace followed (cut paste from browser) Error: 500 Location: /examples/jsp/num/numguess.jsp Internal Servlet Error: javax.servlet.ServletException at java.lang.Throwable.(Throwable.java:96) at java.lang.Exception.(Exception.java:44) at javax.servlet.ServletException.(ServletException.java) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java) at org.apache.tomcat.core.Handler.service(Handler.java) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java) at org.apache.tomcat.core.ContextManager.service(ContextManager.java) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java) at java.lang.Thread.run(Thread.java:498) Root cause: java.lang.StackOverflowError at at java.beans.Beans.instantiate(Beans.java:57) at jsp.num._0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0._jspService( _0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0.java:75) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java) at org.apache.tomcat.core.Handler.service(Handler.java) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java) at org.apache.tomcat.core.ContextManager.service(ContextManager.java) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java) at java.lang.Thread.run(Thread.java:498) - Original Message - From: Nguyen Thanh Phong [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, August 27, 2001 10:26 AM Subject: Bugs in Tomcat 3.2.2/3.2.3 on Linux (RH 7.1)? Hello everyone, I started to deploy tomcat 3.2.3 on a newly installed RH 7.1 system, with the following configuration kernel-2.4.3-12 (upgraded from RH errata) apacheconf-0.7-2 (RH 7.1 default) apache-manual-1.3.19-5 (RH 7.1 default) apache-1.3.19-5 (RH 7.1 default) mod_ssl-2.8.1-5 (RH 7.1 default) jdk-1.3.1-fcs (Sun J2SDK for RH) ant-1.3-2 (jakarta's distribution http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/rpms/) tomcat-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-mod-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-manual-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) tomcat-webapps-3.2.3-1 (Henri Gomez ftp.falsehope.com/home/gomez/tomcat) http://neptune:8080/examples/jsp/snp/snoop.jsp is working OK, but http://neptune:8080/examples/jsp/num/numguess.jsp generate the following Is this a bug in Tomcat distribution or a bug in the JDK? If I want to run on Linux (preferably RH), what is the good combination of kernel/jdk/tomcat/ant/apache that is most stable/well tested. All suggestions are really appreciated. 2001-08-27 10:03:13 - Ctx( /examples ): Exception in: R( /examples + /jsp/num/numguess.jsp + null) - javax.servlet.ServletException at java.lang.Throwable.init(Throwable.java:96) at java.lang.Exception.init(Exception.java:44) at javax.servlet.ServletException.init(ServletException.java) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java) at org.apache.tomcat.core.Handler.service(Handler.java) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java) at org.apache.tomcat.core.ContextManager.service(ContextManager.java) at
Virtual hosting
How can I do virtual hosting in tomcat. Do I have to make change in server.xml only or do I have to make any other change in apache or tomcat folder. Please let me know if anyone has done it successfully. __ Do You Yahoo!? Make international calls for as low as $.04/minute with Yahoo! Messenger http://phonecard.yahoo.com/
Re: OutOfMemory - Set Java Heap Size?
Many thanks, Craig, Aravind and Shaun, for your comments. They are most appreciated. I set the TOMCAT_OPTS to -server -Xms64m -Xmx192m as you suggested Shaun... I wasn't aware of the HotSpot application, I'm now reading up in it. Thanks for the tip. Unfortunately, I still cannot launch a 7th Tomcat process, and I don't understand why not. I feel I'm missing something, but I just can't figure it out. 6 works, but adding a seventh raises the OutOfMemoryError. It does appear from the console output that Tomcat fails when it tries to start a PoolTCPConnector. I start two connectors for each application (ie, Tomcat process), one is an Ajp13ConnectionHandler, the second an Ajp12ConnectionHandler which I understand is required for Tomcat to be closed down. I've included one of my server.xml files below, just in case there is a glaring error in there. There's an xml for each application, they are all the same except for the different ports I've assigned, and the log and work file names etc. Any further suggestions would be most appreciated, I'm have a minor heart attack at thought of having to buy one server for every 6 small jsp applications I want to run! Thanks, Max Hugen ?xml version=1.0 encoding=ISO-8859-1? Server !-- Debug low-level events in XmlMapper startup -- xmlmapper:debug level=0 / Logger name=tc_log path=logs/isp_tomcat.log verbosityLevel = INFORMATION / Logger name=servlet_log path=logs/isp_servlet.log verbosityLevel = INFORMATION / Logger name=JASPER_LOG path=logs/isp_jasper.log verbosityLevel = INFORMATION / ContextManager debug=0 workDir=work_isp showDebugInfo=true !-- Interceptors -- !-- ContextInterceptor className=org.apache.tomcat.context.LogEvents -- ContextInterceptor className=org.apache.tomcat.context.AutoSetup / ContextInterceptor className=org.apache.tomcat.context.WebXmlReader / !-- Uncomment out if you have JDK1.2 and want to use policy ContextInterceptor className=org.apache.tomcat.context.PolicyInterceptor / -- ContextInterceptor className=org.apache.tomcat.context.LoaderInterceptor / ContextInterceptor className=org.apache.tomcat.context.DefaultCMSetter / ContextInterceptor className=org.apache.tomcat.context.WorkDirInterceptor / !-- Request processing -- RequestInterceptor className=org.apache.tomcat.request.SessionInterceptor noCookies=false / !-- Find the container ( context and prefix/extension map ) for a request. -- RequestInterceptor className=org.apache.tomcat.request.SimpleMapper1 debug=0 / !-- Non-standard invoker, for backward compat. ( /servlet/* ) -- RequestInterceptor className=org.apache.tomcat.request.InvokerInterceptor prefix=/servlet/ debug=0 / !-- default handler - static files and dirs. -- RequestInterceptor className=org.apache.tomcat.request.StaticInterceptor debug=0 suppress=false / !-- Plug a session manager. You can plug in more advanced session modules. -- RequestInterceptor className=org.apache.tomcat.session.StandardSessionInterceptor / !-- Check if the request requires an authenticated role. -- RequestInterceptor className=org.apache.tomcat.request.AccessInterceptor debug=0 / !-- Check permissions using the simple xml file. You can plug more advanced authentication modules. -- RequestInterceptor className=org.apache.tomcat.request.SimpleRealm debug=0 / !-- Loaded last since JSP's that load-on-startup use request handling -- ContextInterceptor className=org.apache.tomcat.context.LoadOnStartupInterceptor / !-- Connectors -- Connector className=org.apache.tomcat.service.PoolTcpConnector Parameter name=handler value=org.apache.tomcat.service.connector.Ajp13ConnectionHandler/ Parameter name=port value=8104/ /Connector Connector className=org.apache.tomcat.service.PoolTcpConnector Parameter name=handler value=org.apache.tomcat.service.connector.Ajp12ConnectionHandler/ Parameter name=port value=8204/ /Connector Context path= docBase=/home/sites/site4/web/det-isp debug=0 reloadable=true trusted=false /Context /ContextManager /Server