I want close one session in JSP
I want destroy one session, but include the JavaBean with it. I tried whit session.invalidate();, but don't work. What can I do to all JavaBeans like this jsp:useBean id=login scope=session class=jsptutorial.Login / been destroyed. that don't exist anymore. Best Regards. Owen. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: I want close one session in JSP
Hi Owen I'm not sure I understand you. Isn't the bean stored in the session? In that case it will get garbage collected because the session scope doesn't exist after you've called session.invalidate(). Markus On söndag, juni 9, 2002, at 09:37 , Anibal Constante Brito wrote: I want destroy one session, but include the JavaBean with it. I tried whit session.invalidate();, but don't work. What can I do to all JavaBeans like this jsp:useBean id=login scope=session class=jsptutorial.Login / been destroyed. that don't exist anymore. Best Regards. Owen. -- To unsubscribe, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] For additional commands, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: web.xml parsing error on startup.
Hi Nik, Read the error message carfully and change the order of the elements to conform to the error message (i.e. servlet before welcome-file-list). I had the same problem some time ago. Order do matter! Markus On söndag, juni 9, 2002, at 04:01 , [EMAIL PROTECTED] wrote: Hello, I am using JDK1.4 and Tomcat 4.0.3, lately, I've been having this problems: Starting service Tomcat-Standalone Apache Tomcat/4.0.3 PARSE error at line 29 column 11 org.xml.sax.SAXParseException: The content of element type web-app must match (icon?,display-name?,description?,distributable?,context- param*,filter*,filter- mapping*,listener*,servlet*,servlet-mapping*,session- config?,mime-mapping*,welco me-file-list?,error-page*,taglib*,resource-env-ref*,resource- ref*,security-const raint*,login-config?,security-role*,env-entry*,ejb- ref*,ejb-local-ref*). Starting service Tomcat-Apache Apache Tomcat/4.0.3 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Help with JNDI Catalina 4 (May 30 build)
Hi, I am trying to use JNDI to access some resources.I wonder if someone knows how to use the GlobalNamingResources. Here is a snippet from my server.xml GlobalNamingResources !-- the file based cache for all web applications -- Resource name=rohas/filecache auth=Container type=com.rohas.cache.FileCache / ResourceParams name=rohas/filecache parameter namefactory/name valuecom.rohas.cache.FileCacheFactory/value /parameter parameter namecacheDir/name value/tmp/cache/value /parameter /ResourceParams . I have then defined a link to this in my context as follows :- Context path= docBase=www.compuvision.co.uk debug=0 reloadable=true crossContext=false cookies=true ResourceLink name=rohas/filecache global=rohas/filecache type=com.rohas.cache.FileCache / The code to load the resource is defined as follows ::- /* Get the file cache from the context via JNDI */ initCtx = new InitialContext(); envCtx = (Context)initCtx.lookup(java:comp/env); /* retrieve the file cache */ fileCache = (FileCache)envCtx.lookup(rohas/filecache); The resource is loaded as part of the startup for my servlet. When I start catalina I get the following error:- javax.naming.NameNotFoundException: Name rohas is not bound in this Context at org.apache.naming.NamingContext.lookup(Unknown Source) at org.apache.naming.NamingContext.lookup(Unknown Source) at com.rohas.util.MasterServlet.init(MasterServlet.java:76) at javax.servlet.GenericServlet.init(GenericServlet.java:258) at org.apache.catalina.core.StandardWrapper.loadServlet(Unknown Source) at org.apache.catalina.core.StandardWrapper.load(Unknown Source) at org.apache.catalina.core.StandardContext.loadOnStartup(Unknown Source) at org.apache.catalina.core.StandardContext.start(Unknown Source) One answer could be to define the resources in each context, but this is a pain as I am probably going to have about 6/7 contexts each of which use this shared resource. Can anybody help ? Am I using the global resources in completely the wrong way ??? Regards, Arshad
Re: problem..plz help me out
hi jake well if port 80 works with the url http://localhost:80/examples/servlet/snoop than whatz worng with sachar context.. and i have not written .class in the end still not working ... and WEB-INF is in caps..cos i know tomcat 4 have web-Inf in caps still help me out guys plz... Puneet --- Jacob Kjome [EMAIL PROTECTED] wrote: 2 things I see wrong with your scenario. 1. When you refer to a servlet, you don't append .class to the end of the servlet name. For instance, you wrote: http://localhost:80/examples/servlet/abc.class which should be: http://localhost:80/examples/servlet/abc 2. You are going through port 80 which is where a normal webserver would be listening. Tomcat listens on port 8080 by default. Unless you are fronting Tomcat with another web server, such as Apache, and using a web connector (and have the configuration for the web connector correct for each context you are accessing) you will not be able to ask Tomcat to serve up .jsp's or servlets. Try your connection like this: http://localhost:8080/examples/servlet/abc That will go directly to Tomcat rather than pass through a web server with a connector. If this works, then your issue is narrowed down to configuring your web connector properly. If it doesn't work, then we can look at other issues such as installing Tomcat in a path with spaces in the directory names. Note: I'm assuming that a class, which is a servlet, exists in the default package (eg... WEB-INF/classes) and is named abc.class for the above link to work. Jake At 12:22 PM 6/8/2002 -0700, you wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help me I really stuck .. With this mail Im sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..im in need badly and afater spending so much time here I some time feel like crying and Im in such a place and in such a part of India..where I cant get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml )I have send the file also plz check it and tell me any mistake if u find) 3) Im getting 404 error ..no servlet found 4) And Im able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Ill be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the
Re: problem..plz help me out
--- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3) Iím getting 404 error ..no servlet found 4) And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA (Unix) with a password value of changeit for both the certificate and the keystore itself. By default, DNS lookups are enabled when a web application calls request.getRemoteHost(). This can have an adverse impact on performance, so you can disable it by setting the enableLookups attribute to false. When DNS lookups are disabled, request.getRemoteHost() will return the String version of the IP address of the remote client. -- !-- Define a non-SSL HTTP/1.1 Connector
Locale Problem Using IIS 5.0 and isapi_redirector
When a request for a servlet or JSP is redirected via IIS the locale within the request is changed. For example, I have set my browser to use Dutch Language if I run the Snoop servlet with the following url http://localhost:8080/examples/servlet/snoop the locale is reported as 'nl' If I then run the servlet via IIS http://localhost/examples/servlet/snoop the locale is reported as 'en_GB' Is there any way of maintaining the original request locale. Regards Tony
Re: mail list of JSP?
On Sun, 9 Jun 2002, Anibal Constante Brito wrote: Hello people: Any of you know a mail list of JSP for ask some question? Sun has the jsp-interest list. Check http://archives.java.sun.com for a list of all sun's java related list (there's also servlet-interest, which is likely of interest to people who post here). From that link, you can do various things, like subscribe/unsubscribe those lists, and search their archives. Milt Epstein Research Programmer Systems and Technology Services (STS) Campus Information Technologies and Educational Services (CITES) University of Illinois at Urbana-Champaign (UIUC) [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Connection pooling doesn't work for me ... Help !!
Hello everyone, I read the tomcat jndi how to manual. searched the mailing list archive. and did everything which has made other happily get a connection from the jndi of the pool but I just can't do it. DataSource ds = (javax.sql.DataSource) initCtx.lookup(java:comp/env/jdbc/MPSSource); return ds.getConnection(); / RETURNS NULL !! _ Send and receive Hotmail on your mobile device: http://mobile.msn.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Connection pooling doesn't work for me ... Help !!
Hello everyone, I read the tomcat jndi how to manual. searched the mailing list archive. and did everything which has made other happily get a connection from the jndi of the pool but I just can't do it. DataSource ds = (javax.sql.DataSource) initCtx.lookup(java:comp/env/jdbc/MPSSource); return ds.getConnection(); / RETURNS NULL !! _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Help Connection pooling doesn't work for me
Hello All, Sorry for the previous half typed mail... IE just decided to send the mail on its own. I make the following call in my Java code DataSource ds = (javax.sql.DataSource) initCtx.lookup(java:comp/env/jdbc/DBSource); return ds.getConnection(); // RETURNS NULL Here the ds.getConnection() is returning me null. I have been thru the jndi manual and this list archive... but I just can't get this. I also tried the same code on weblogic and it worked perfectly. Please help me ... below is the entries which I have made in verious config files. Please poing the mistake in this because I am just lost here. server.xml - Resource name=jdbc/DBSource auth=CONTAINER type=javax.sql.DataSource/ ResourceParams name=jdbc/DBSource parameternameuser/namevaluemyuser/value/parameter parameternamepassword/namevaluemypwd/value/parameter parameter namedriverClassName/name valueoracle.jdbc.driver.OracleDriver/value /parameter parameter namedriverName/name valuejdbc:oracle:thin:@localhost:1521:AAA/value /parameter /ResourceParams web.xml -- resource-ref res-ref-namejdbc/DBSource/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth res-sharing-scopeShareable/res-sharing-scope /resource-ref regards, Abhishek. _ Chat with friends online, try MSN Messenger: http://messenger.msn.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Problem with encodeRedirectURL
This is working correctly. The sessionid is not a query string. see the servlet 2.2 specification for further details. What is the problem that you are encountering? It appears that the url is being formed improperly somewhere and not jsessionid. From: Ujjwala Thakar [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Problem with encodeRedirectURL Date: Sat, 08 Jun 2002 16:26:04 + Hello, I refered this URL http://archive.covalent.net/jakarta/tomcat-user/2001/08/0111.xml Did you get the solution for this? I am having the same problem. If you got the solution, please answer. [EMAIL PROTECTED] _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] --- Todd Kaplinger mailTo:[EMAIL PROTECTED] _ Chat with friends online, try MSN Messenger: http://messenger.msn.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
creating filter valves
Goal: to keep items in a directory from being accessed without going thru the web site Method: create a filter valve that checks that the referrer is from the same url (not hack proof, but good enough) Problem: when I specify my filter valve, it looks like it is being ignored completely; no error if the filter class isn't there and the filter doesn't do anything. Question: can one create one's own subclass of FilterRequestValve? is there a better method? Config: Context path=/wt/images docBase=wt/images Logger className=org.apache.catalina.logger.FileLogger prefix=localhost_wt_log. suffix=.txt timestamp=true/ Valve className=org.apache.catalina.valves.RefererValve allow=http://www.wt.net// /Context thanx! -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: problem..plz help me out
I'm on win me platform .. and i don't understand one thing if a servlet works fine with this url http://localhost:8080/examples/servlet/abc then whatz worng with http://puneet:8080/servlet/abc or http://puneet:8080/sachar/servlet/abc i have done what exactly written in server.xml if u can help me out plz do that..this is my 4th day without work Puneet --- puneet sachar [EMAIL PROTECTED] wrote: --- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1)no .class and .jsp working only html is working 2)I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3)Iím getting 404 error ..no servlet found 4)And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias
Re: problem..plz help me out
I'm on win me platform .. and i don't understand one thing if a servlet works fine with this url http://localhost:8080/examples/servlet/abc then whatz worng with http://puneet:8080/servlet/abc or http://puneet:8080/sachar/servlet/abc i have done what exactly written in server.xml if u can help me out plz do that..this is my 4th day without work Puneet --- puneet sachar [EMAIL PROTECTED] wrote: --- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1)no .class and .jsp working only html is working 2)I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3)Iím getting 404 error ..no servlet found 4)And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias
Re: problem..plz help me out
I'm on win me platform .. and i don't understand one thing if a servlet works fine with this url http://localhost:8080/examples/servlet/abc then whatz worng with http://puneet:8080/servlet/abc or http://puneet:8080/sachar/servlet/abc i have done what exactly written in server.xml if u can help me out plz do that..this is my 4th day without work Puneet --- puneet sachar [EMAIL PROTECTED] wrote: --- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1)no .class and .jsp working only html is working 2)I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3)Iím getting 404 error ..no servlet found 4)And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias
Re: problem..plz help me out
I'm on win me platform .. and i don't understand one thing if a servlet works fine with this url http://localhost:8080/examples/servlet/abc then whatz worng with http://puneet:8080/servlet/abc or http://puneet:8080/sachar/servlet/abc i have done what exactly written in server.xml if u can help me out plz do that..this is my 4th day without work Puneet --- puneet sachar [EMAIL PROTECTED] wrote: --- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1)no .class and .jsp working only html is working 2)I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3)Iím getting 404 error ..no servlet found 4)And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias
JasperException
Hello, I'm trying to use a jsp page with a JavaBean and getting the following error: org.apache.jasper.JasperException: Unable to compile class for JSP The jsp page is very simple: html head titleTEST PAGE/title /head body jsp:useBean is=usr class=study.User / %= usr.getId() % /body /html The funny thing is that I can use this code within W2K, but it don't works under WinXP. I have a similar problem to access JDBC. It works at W2K but don't at WinXP. I looked at all configurations trying to find something different but all seems equal in both systems (I mean the environment variables). Any idea what's going on? Thanks in advance, Juan José Velázquez Garcia Web Development www.htmlspider.com.br -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: problem..plz help me out
Hi, What is in your server.xml. Have you defined a virtual host for puneet, and how have you defined the Context. Send yout server.xml as an attachment and we should be able to see what the problem is. Do you get a response by trying http://localhost:8080/yourcontext/servlet/abc (replace yourcontext with the name of your context). Regards, Arshad - Original Message - From: puneet sachar [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 6:51 PM Subject: Re: problem..plz help me out I'm on win me platform .. and i don't understand one thing if a servlet works fine with this url http://localhost:8080/examples/servlet/abc then whatz worng with http://puneet:8080/servlet/abc or http://puneet:8080/sachar/servlet/abc i have done what exactly written in server.xml if u can help me out plz do that..this is my 4th day without work Puneet --- puneet sachar [EMAIL PROTECTED] wrote: --- Markus Kirsten [EMAIL PROTECTED] wrote: Does the example servlets and JSP work? Which platform do you use? Markus On lördag, juni 8, 2002, at 09:22 , puneet sachar wrote: Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meÖI really stuck .. With this mail Iím sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..iím in need badly and afater spending so much time here I some time feel like crying Ö and Iím in such a place and in such a part of India..where I canít get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xmlÖ)I have send the file also plz check it and tell me any mistake if u find) 3) Iím getting 404 error ..no servlet found 4) And Iím able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Iíll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established
Using bean is JSP files
Hi all, Is there any difference between the following code in order to use bean? %@ page import=java.sql.*% jsp:useBean id=connection class=br.fua.ppgi.ConnectionBean scope=session/ %@ page import=java.sql.*,br.fua.ppgi.*% jsp:useBean id=connection class=ConnectionBean scope=session/ The former code (I followed the core servlets and JSP book's idea) is doing well , but the latter code (I followed the Web Development with JavaServer Pages book's idea) shows me an error on the browser as: javax.servlet.ServletException: ConnectionBean ... ... root cause java.lang.InstantiationException: ConnectionBean ... ... Could anyone help me? Regards, Lin. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: web.xml parsing error on startup.
Thank you, that was the problem- strangely enough! with regards, Nik On Sun, 09 June 2002, Markus Kirsten wrote: In-Reply-To: [EMAIL PROTECTED] Content-Transfer-Encoding: quoted-printable To: Tomcat Users List [EMAIL PROTECTED] Delivered-To: [EMAIL PROTECTED] Delivered-To: mailing list [EMAIL PROTECTED] Received: (cpmta 6130 invoked from network); 9 Jun 2002 01:52:40 -0700 Received: from 192.18.49.131 (HELO nagoya.betaversion.org) by smtp.c009.snv.cp.net (209.228.34.110) with SMTP; 9 Jun 2002 01:52:40 -0700 Received: (qmail 5274 invoked by uid 97); 9 Jun 2002 08:52:30 - Received: (qmail 5262 invoked by uid 98); 9 Jun 2002 08:52:29 - X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Content-Length: 1115 Content-Type: text/plain; charset=ISO-8859-1; format=flowed X-Antivirus: nagoya (v4198 created Apr 24 2002) Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm List-Subscribe: mailto:[EMAIL PROTECTED] X-Received: 9 Jun 2002 08:52:40 GMT List-Unsubscribe: mailto:[EMAIL PROTECTED] Precedence: bulk List-Post: mailto:[EMAIL PROTECTED] Subject: Re: web.xml parsing error on startup. List-Help: mailto:[EMAIL PROTECTED] From: Markus Kirsten [EMAIL PROTECTED] List-Id: Tomcat Users List tomcat-user.jakarta.apache.org Return-Path: [EMAIL PROTECTED] Mime-Version: 1.0 (Apple Message framework v482) Reply-To: Tomcat Users List [EMAIL PROTECTED] Date: Sun, 9 Jun 2002 10:52:28 +0200 Message-Id: [EMAIL PROTECTED] X-Mailer: Apple Mail (2.482) Hi Nik, Read the error message carfully and change the order of the elements to conform to the error message (i.e. servlet before welcome-file-list). I had the same problem some time ago. Order do matter! Markus On söndag, juni 9, 2002, at 04:01 , [EMAIL PROTECTED] wrote: Hello, I am using JDK1.4 and Tomcat 4.0.3, lately, I've been having this problems: Starting service Tomcat-Standalone Apache Tomcat/4.0.3 PARSE error at line 29 column 11 org.xml.sax.SAXParseException: The content of element type web-app must match (icon?,display-name?,description?,distributable?,context- param*,filter*,filter- mapping*,listener*,servlet*,servlet-mapping*,session- config?,mime-mapping*,welco me-file-list?,error-page*,taglib*,resource-env-ref*,resource- ref*,security-const raint*,login-config?,security-role*,env-entry*,ejb- ref*,ejb-local-ref*). Starting service Tomcat-Apache Apache Tomcat/4.0.3 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Get your FREE personalized e-mail at http://www.canada.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Using bean in JSP files
Mensagem Original Assunto: Using bean is JSP files De: [EMAIL PROTECTED] Data: Sun, June 9, 2002 2:12 pm Para: [EMAIL PROTECTED] Hi all, Is there any difference between the following code in order to use bean? %@ page import=java.sql.*% jsp:useBean id=connection class=br.fua.ppgi.ConnectionBean scope=session/ %@ page import=java.sql.*,br.fua.ppgi.*% jsp:useBean id=connection class=ConnectionBean scope=session/ The former code (I followed the core servlets and JSP book's idea) is doing well , but the latter code (I followed the Web Development with JavaServer Pages book's idea) shows me an error on the browser as: javax.servlet.ServletException: ConnectionBean root cause java.lang.InstantiationException: ConnectionBean Could anyone help me? Regards, Lin. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: A Connection Pool in JNDI that works!
Hi I've posted a solution see Generic DataSource Resource Factory Available. JDBC Data Source on the tomcat user maillist. Tony - Original Message - From: James Ward [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Saturday, June 08, 2002 4:59 PM Subject: A Connection Pool in JNDI that works! Wow, this has been a fun one. It should have been an easy little stroll in the park, but due to my idioticness, it turned into a sour climb up Everest. So, I embarked on mission to get a connection pool working as a JNDI Resource. I found very little info on the subject, thus the reason for me posting this info here. Here goes... (BTW: This is for Tomcat 4) I started out using the standard JDBC Data Source documentation found in the Tomcat 4 JNDI Resources HOW-TO. It worked fine, but then I discovered there was no built-in connection pooling. Bummer. So, I ended up implementing the Apache commons dbcp found at: http://jakarta.apache.org/builds/jakarta-commons/nightly/commons-dbcp/ This is for mySQL but it should be very easy to change the config for any database. Here is a snippet from my server.xml file: !-- Put this within a Context -- Resource name=jdbc/MyDB auth=Container type=javax.sql.DataSource / ResourceParams name=jdbc/MyDB parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namedriverClassName/name valueorg.gjt.mm.mysql.Driver/value /parameter parameter namemaxActive/name value2/value /parameter parameter namemaxIdle/name value2/value /parameter parameter nameusername/name valuemyUsername/value /parameter parameter namepassword/name valuemyPassword/value /parameter parameter namemaxWait/name value-1/value /parameter parameter nameurl/name valuejdbc:mysql://myhost:3306/mydatabase/value /parameter /ResourceParams I also discovered that I don't need to declare the resources in my web.xml like the documentation stated. Now you can just use this code snippet to get a DataSource and a Connection: Context initCtx = new InitialContext(); Context envCtx = (Context) initCtx.lookup (java:comp/env); DataSource ds = (DataSource)envCtx.lookup(jdbc/MyDB); conn = (Connection)ds.getConnection(); Another thing to note is that I have the latest commons-dbcp, commons-collection, commons-pool, and mysql jars in my common/lib dir. Now why did that take me so long to figure out? You really don't want to know. I am just an idiot. But I hope that my toils will help someone. Thanks to Craig for this post: http://www.geocrawler.com/archives/3/193/2002/4/0/8407853/ Which was about the only thing I could find with Google that was of help. -James -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Connection pooling doesn't work for me ... Help !!
Hi I've posted a solution see Generic DataSource Resource Factory Available. JDBC Data Source on the tomcat user maillist. Tony - Original Message - From: abhishek srivastava [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 7:56 AM Subject: Connection pooling doesn't work for me ... Help !! Hello everyone, I read the tomcat jndi how to manual. searched the mailing list archive. and did everything which has made other happily get a connection from the jndi of the pool but I just can't do it. DataSource ds = (javax.sql.DataSource) initCtx.lookup(java:comp/env/jdbc/MPSSource); return ds.getConnection(); / RETURNS NULL !! _ Send and receive Hotmail on your mobile device: http://mobile.msn.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Connection Pools in JNDI - I've attached a solution
Due to the lack of support for certain data base types with the default DataSource resource factory, I developed a generic datasource resource factory org.apache.naming.factory.DataSourceFactory. This resource factor allows you to create any object which implements the javax.sql.DataSource interface. It uses a simple introspection techique discover the properties of the DataSource implementation your trying to instantiate and then matches these properties with the values supplied in the ResourceParams parameter elements. The version supplied with this e-mail supports properties of the following types String, int, short, long, float, double, byte, char and boolean. I've attached 3 files src.zip (which contains the source code), rf.jar a packaged version which you can place in your common\lib directory and a readme file which explains how to use the DataSourceFactory. Regards Anthony Dodd rf.jar Description: Binary data CONTENTS 1. INTRODUCTION 2. CREATING AN ORACLE DATASOURCE 3. CREATING A SQL SERVER DATASOURCE USING DATADIRECTS' CONNECTJDBC 4. CREATING AN ORACLE CONNECTION POOLED DATASOURCE 5. CREATING A SQL SERVER CONNECTION POOLED DATA SOURCE USING DATADIRECTS' CONNECTJDBC 6. CLASSCASTEXCEPTION WHEN NARROWING JNDI REFERENCED OBJECTS 7. FINALLY 1. INTRODUCTION Due to the lack of support for certain data base types with the default DataSource resource factory, I developed a generic datasource resource factory org.apache.naming.factory.DataSourceFactory. This resource factor allows you to create any object which implements the javax.sql.DataSource interface. It uses a simple introspection techique discover the properties of the DataSource implementation your trying to instantiate and then matches these properties with the values supplied in the ResourceParams parameter elements. The version supplied with this e-mail supports properties of the following types String, int, short, long, float, double, byte, char and boolean. If you supply the following parameter parameter namedebug/name valuetrue/true /parameter it will trace out its activity to the jvm.stdout, or where ever System.out has been redirected. 2. CREATING AN ORACLE DATASOURCE The following example shows the server.xml and web.xml (WEB-INF subdirectory of your web application) needed to create a datasource from Oracles' DataSource implementation 'oracle.jdbc.pool.OracleDataSource'. server.xml --- Context ... !-- Create DataSource -- Resource name=jdbc/MYORACLEDATASOURCE reloadable=true auth=Container type=oracle.jdbc.pool.OracleDataSource/ ResourceParams name=jdbc/MYORACLEDATASOURCE parameter namefactory/name valueorg.apache.naming.factory.DataSourceFactory/value /parameter parameter namedescription/name valueOracle DataSource/value /parameter parameter nameserverName/name value192.168.152.2/value /parameter parameter nameportNumber/name value1521/value /parameter parameter namedatabaseName/name valuemydatabase/value /parameter parameter namedriverType/name valuethin/value /parameter parameter nameuser/name valuescott/value /parameter parameter namepassword/name valuetiger/value /parameter /ResourceParams /Context web.xml - ?xml version=1.0? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.2//EN http://java.sun.com/j2ee/dtds/web-app_2_2.dtd; web-app resource-ref descriptionOracle DataSource/description res-ref-namejdbc/MYORACLEDATASOURCE/res-ref-name res-typeoracle.jdbc.pool.OracleDataSource/res-type res-authContainer/res-auth /resource-ref /web-app 3. CREATING A SQL SERVER DATASOURCE USING DATADIRECTS' CONNECTJDBC The following example shows the server.xml and web.xml (WEB-INF subdirectory of your web application) needed to create a datasource from DataDirects' ConnectJDBC DataSurce implementation 'com.ddtek.jdbcx.sqlserver.SQLServerDataSource'. DataDirect/Merant were the people who developed the odbcjdbc bridge used in the early days when connecting to SQL 7.0 databases. Microsoft are currently using a version of DataDirects ConnectJDBC to deliver there own JDBC 2 implementation for SQL Server 2000. At the time of writing the Microsoft version appears to be extremely problematic. I've also shown a sample JSP page using this resource. server.xml - Context ... !-- Create DataSource -- Resource name=jdbc/MYSSQLDATASOURCE reloadable=true auth=Container type=com.ddtek.jdbcx.sqlserver.SQLServerDataSource/ ResourceParams name=jdbc/MYSSQLDATASOURCE
RE: problem..plz help me out
perhaps we could see a chunk of the log files. Does Tomcat log the receiving of the request, is there an exception, etc. -Original Message- From: puneet sachar [mailto:[EMAIL PROTECTED]] Sent: Saturday, June 08, 2002 1:22 PM To: Xinji Gu Subject: problem..plz help me out Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help meI really stuck .. With this mail Im sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..im in need badly and afater spending so much time here I some time feel like crying and Im in such a place and in such a part of India..where I cant get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml)I have send the file also plz check it and tell me any mistake if u find) 3) Im getting 404 error ..no servlet found 4) And Im able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me Ill be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Tomcat 4.0.3 and Mod JK problem
Ok, I figured out what is causing this but not why. If I hit my server with an IP address i.e. 172.28.101.132, it causes the error below and I get a 400- Bad Request in the browser. However, if I telnet to 172.28.101.132 port 80, the server will successfully serve a page. Could this be a network problem or is it a server.xml configuration problem? Thanks, Subir -Original Message- From: Subir Sengupta To: '[EMAIL PROTECTED]' Sent: 6/8/02 9:06 PM Subject: Tomcat 4.0.3 and Mod JK problem Hi, I have Tomcat running on my dev box, with no problems. I moved tomcat over to another server and I now start getting this error: StandardEngine[Walmart]: Mapping server name '172.28.101.132' StandardEngine[Walmart]: Trying a direct match StandardEngine[Walmart]: Trying an alias match StandardEngine[Walmart]: Trying the default host StandardEngine[Walmart]: Mapping server name '172.28.101.132' StandardEngine[Walmart]: Trying a direct match StandardEngine[Walmart]: Trying an alias match StandardEngine[Walmart]: Trying the default host Here are snippets from my workers.properties and server.xml files. workers.properties # The workers that your plugins should create and work with # worker.list=ajp12,ajp13-0 worker.ajp13-0.port=8009 worker.ajp13-0.host=localhost worker.ajp13-0.type=ajp13 # /AJP13WORKERS server.xml Server port=8011 shutdown=SHUTDOWN debug=0 Service name=Tomcat 4.0.3 Connector className=org.apache.ajp.tomcat4.Ajp13Connector port=8009 minProcessors=5 maxProcessors=256 acceptCount=10 debug=0 /Connector The site will still serve pages but it keeps repeating the above message. Any ideas about what would cause this are appreciated. Thanks, Subir Subir Sengupta (E-mail).vcf Subir Sengupta (E-mail).vcf ATT129216.txt -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Tomcat 4.0.3 and Mod JK problem
Update. I added an Alias element - Alias172.28.101.132/Alias inside my Host element, and the error went away. So, the question now is, why do I need to alias the servers IP address? Thanks, Subir -Original Message- From: Subir Sengupta To: ''[EMAIL PROTECTED]' ' Sent: 6/9/02 1:32 PM Subject: RE: Tomcat 4.0.3 and Mod JK problem Ok, I figured out what is causing this but not why. If I hit my server with an IP address i.e. 172.28.101.132, it causes the error below and I get a 400- Bad Request in the browser. However, if I telnet to 172.28.101.132 port 80, the server will successfully serve a page. Could this be a network problem or is it a server.xml configuration problem? Thanks, Subir -Original Message- From: Subir Sengupta To: '[EMAIL PROTECTED]' Sent: 6/8/02 9:06 PM Subject: Tomcat 4.0.3 and Mod JK problem Hi, I have Tomcat running on my dev box, with no problems. I moved tomcat over to another server and I now start getting this error: StandardEngine[Walmart]: Mapping server name '172.28.101.132' StandardEngine[Walmart]: Trying a direct match StandardEngine[Walmart]: Trying an alias match StandardEngine[Walmart]: Trying the default host StandardEngine[Walmart]: Mapping server name '172.28.101.132' StandardEngine[Walmart]: Trying a direct match StandardEngine[Walmart]: Trying an alias match StandardEngine[Walmart]: Trying the default host Here are snippets from my workers.properties and server.xml files. workers.properties # The workers that your plugins should create and work with # worker.list=ajp12,ajp13-0 worker.ajp13-0.port=8009 worker.ajp13-0.host=localhost worker.ajp13-0.type=ajp13 # /AJP13WORKERS server.xml Server port=8011 shutdown=SHUTDOWN debug=0 Service name=Tomcat 4.0.3 Connector className=org.apache.ajp.tomcat4.Ajp13Connector port=8009 minProcessors=5 maxProcessors=256 acceptCount=10 debug=0 /Connector The site will still serve pages but it keeps repeating the above message. Any ideas about what would cause this are appreciated. Thanks, Subir Subir Sengupta (E-mail).vcf Subir Sengupta (E-mail).vcf ATT129216.txt -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: creating filter valves
oops. retract that. the config lines cited below were actually commented out when trying to resolve another problem. I don't know if the ReferrerValve class will work yet but at least the server complains if it can't find it. Took a little work to figure out where to put it and how to get it there but now there is only testing to do! thanx! At 11:11 AM -0500 6/9/02, Chuck Griffith wrote: Goal: to keep items in a directory from being accessed without going thru the web site Method: create a filter valve that checks that the referrer is from the same url (not hack proof, but good enough) Problem: when I specify my filter valve, it looks like it is being ignored completely; no error if the filter class isn't there and the filter doesn't do anything. Question: can one create one's own subclass of FilterRequestValve? is there a better method? Config: Context path=/wt/images docBase=wt/images Logger className=org.apache.catalina.logger.FileLogger prefix=localhost_wt_log. suffix=.txt timestamp=true/ Valve className=org.apache.catalina.valves.RefererValve allow=http://www.wt.net// /Context thanx! -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- --/\ Chuck Griffith / \_ ^^ [EMAIL PROTECTED]/ / \ ___ http://www.winternet.com/~chuckg /v^v^v^v\ _/ \ ^^ ftp://ftp.winternet.com/users/chuckg/incoming / \/ \\ http://www.nargs.org / / \\ / \\ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Using bean in JSP files
Mauricio Tia Ni Gong Lin wrote: Hi all, Is there any difference between the following code in order to use bean? %@ page import=java.sql.*% jsp:useBean id=connection class=br.fua.ppgi.ConnectionBean scope=session/ %@ page import=java.sql.*,br.fua.ppgi.*% jsp:useBean id=connection class=ConnectionBean scope=session/ The JSP 1.2 specification actually states that the class attribute should contain the fully qualified name of the class. To quote: The fully qualified name of the class that defines the implementation of the object. The class name is case sensitive. Regards, James Williamson www.nameonthe.net The former code (I followed the core servlets and JSP book's idea) is doing well , but the latter code (I followed the Web Development with JavaServer Pages book's idea) shows me an error on the browser as: javax.servlet.ServletException: ConnectionBean root cause java.lang.InstantiationException: ConnectionBean Could anyone help me? Regards, Lin. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: JasperException
Interesting problem. I would keep the generated .java file and compile the .java source from the command line. There must be something different between the two machines. From: Juan [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: JasperException Date: Sun, 09 Jun 2002 15:01:19 -0300 Hello, I'm trying to use a jsp page with a JavaBean and getting the following error: org.apache.jasper.JasperException: Unable to compile class for JSP The jsp page is very simple: html head titleTEST PAGE/title /head body jsp:useBean is=usr class=study.User / %= usr.getId() % /body /html The funny thing is that I can use this code within W2K, but it don't works under WinXP. I have a similar problem to access JDBC. It works at W2K but don't at WinXP. I looked at all configurations trying to find something different but all seems equal in both systems (I mean the environment variables). Any idea what's going on? Thanks in advance, Juan José Velázquez Garcia Web Development www.htmlspider.com.br -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] --- Todd Kaplinger mailTo:[EMAIL PROTECTED] _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: problem..plz help me out
Why not just install tomcat 3.3.1 which is easier to get up and running. It is also easier to become familiar with the what the server.xml does and what each xml tag does by reading the tomcat users guide and server.xml configuration guide. Make user you become very familiar with these two documents as they are the most important informtion wise to get tomcat up and running. Once you have tomcat 3.3.1 running and everythings ok then maybe upgrade to tomcat 4.0.3. It is completely rebuilt from the ground up but at least you will have experience configuring and installing tomcat 3.3.1 when you decide to start on the lastest version. Nathan. - Original Message - From: puneet sachar [EMAIL PROTECTED] To: Xinji Gu [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 7:22 AM Subject: problem..plz help me out Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help me.I really stuck .. With this mail I'm sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..i'm in need badly and afater spending so much time here I some time feel like crying . and I'm in such a place and in such a part of India..where I can't get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml.)I have send the file also plz check it and tell me any mistake if u find) 3) I'm getting 404 error ..no servlet found 4) And I'm able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me I'll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool
Newbie can't deploy web own JSP
Greetings, I have Tomcat4-4.0.3 configured to run with Apache. I am trying to deploy my own simple web application but have had no success. My application (actually copied from a book) consists of a bean called (JSPCal/Cal.class) and a jsp page to display a Calendar by calling the bean's methods. I am running RedHat Linux version 7.3 on my tomcat server. What steps do I have to do to install my own web app? I did the following: 1. Created an alias for the directory in httpd.conf Alias /baz-jsp/ /var/tomcat4/webapps/baz-jsp/ 2. I copied the same information for the Directory entry that I had down for the examples application. 3. I created /var/tomcat4/webapps/baz-jsp with the subdirectories jsp and WEB-INF. I copied the web.xml from the /var/tomcat4/webapps/examples directory. I didn't change much. I don't understand web.xml, but most of it looked like system-y stuff (like the filter entries). The there were the names of some servlets but nothing about JSP's. So I did not add information about my Cal.jsp or my bean JSPCal.class in the web.xml. 4. I created a classes subdirectory of WEB-INF and put Cal.class (the bean) there. I put Cal.jsp in the jsp subdirectory of /var/tomcat4/webapps/baz-jsp. 5. Back in /etc/httpd/conf/httpd.conf, I created an entry for baz-jsp using the same WarpConnection as for examples. 6. Basically I tried to get baz-jsp looking like examples, as configured. By the way, I have never been successful in getting the opening page for tomcat to display...the famous one that shows the in the upper left corner. I get to the examples by pointing my browser at http://mail.baz-tech.com/examples/. (This should be inaccessible from outside my firewall.) This gives my an index of three directories. When I tried the same thing as http://mail.baz-tech.com/baz-jsp/ I got an error message in the browser, Resource not available. Can anyone tell me the basics of setting up a web application, or point me to any good resources on the subject? Thanks for your time. Bryan Zimmer -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Deploying a war
Is there a how-to on deploying a war file to Tomcat? My war deploys correctly with Weblogic and HPAS. I haven't found step by step instructions in the Tomcat doc on how to do this (and what xml files to modify). Same question with setting up a connection pools and datasources. Thanks in advance. Steve -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: web.xml DTD
Thanks Craig, the DTD from servlet.jar was just what I needed. -August --- Craig R. McClanahan [EMAIL PROTECTED] wrote: On Fri, 7 Jun 2002, August Detlefsen wrote: Date: Fri, 7 Jun 2002 16:54:28 -0700 (PDT) From: August Detlefsen [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED], [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: web.xml DTD Where can I find the DTD for web.xml? I want to make sure I have the elements in the correct order. It is in the servlet specification, which you can download from: http://java.sun.com/products/servlet/download.html You can also extract the DTDs that Tomcat uses from the servlet.jar file that is in the common/lib subdirectory -- it looks at these internal copies so that DTD validation can occur even if your server is not connected to the Internet. Thanks, August Craig -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: problem..plz help me out
Puneet, You've made things harder for yourself by defining a separate engine in your server.xml, it's much easier to reuse an existing engine. Have you taken a look at the appBase and docBase attributes, is your application really in $TOMCAT_HOME/webapps/sachar/? Regards, James Williamson www.nameonthe.net From: puneet sachar [EMAIL PROTECTED] To: Xinji Gu [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 7:22 AM Subject: problem..plz help me out Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help me.I really stuck .. With this mail I'm sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..i'm in need badly and afater spending so much time here I some time feel like crying . and I'm in such a place and in such a part of India..where I can't get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml.)I have send the file also plz check it and tell me any mistake if u find) 3) I'm getting 404 error ..no servlet found 4) And I'm able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me I'll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 4.0 documentation bundle for more detailed instructions): * Download and install JSSE 1.0.2 or later, and put the JAR files into $JAVA_HOME/jre/lib/ext. * Execute: %JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA (Windows) $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA (Unix) with a password value of changeit for both the certificate and the keystore itself. By default, DNS lookups are enabled when a web application calls
RE: problem..plz help me out
I have been having the same problem as sachar, and I believe my problem is that I don't understand everything with tomcat 4. To remedy this, I'm going to get tomcat 3.3 and see if I can get that running. Can someone verify that Tomcat 3.3 and Tomcat 4 can be both be installed on a Linux server (assuming only one is running) without issues? Thanks. Scott -Original Message- From: Nathan Smith [mailto:[EMAIL PROTECTED]] Sent: Sunday, June 09, 2002 5:00 PM To: Tomcat Users List Subject: Re: problem..plz help me out Why not just install tomcat 3.3.1 which is easier to get up and running. It is also easier to become familiar with the what the server.xml does and what each xml tag does by reading the tomcat users guide and server.xml configuration guide. Make user you become very familiar with these two documents as they are the most important informtion wise to get tomcat up and running. Once you have tomcat 3.3.1 running and everythings ok then maybe upgrade to tomcat 4.0.3. It is completely rebuilt from the ground up but at least you will have experience configuring and installing tomcat 3.3.1 when you decide to start on the lastest version. Nathan. - Original Message - From: puneet sachar [EMAIL PROTECTED] To: Xinji Gu [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 7:22 AM Subject: problem..plz help me out Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help me.I really stuck .. With this mail I'm sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..i'm in need badly and afater spending so much time here I some time feel like crying . and I'm in such a place and in such a part of India..where I can't get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml.)I have send the file also plz check it and tell me any mistake if u find) 3) I'm getting 404 error ..no servlet found 4) And I'm able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me I'll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on
RE: problem..plz help me out
Hi Scott, It cans without any problem, you may even run them at the same time on different ports. Regards, Sébastien -Message d'origine- De : Scott Seidl [mailto:[EMAIL PROTECTED]] Envoyé : lun. 10 juin 2002 2:11 À : 'Tomcat Users List' Objet : RE: problem..plz help me out I have been having the same problem as sachar, and I believe my problem is that I don't understand everything with tomcat 4. To remedy this, I'm going to get tomcat 3.3 and see if I can get that running. Can someone verify that Tomcat 3.3 and Tomcat 4 can be both be installed on a Linux server (assuming only one is running) without issues? Thanks. Scott -Original Message- From: Nathan Smith [mailto:[EMAIL PROTECTED]] Sent: Sunday, June 09, 2002 5:00 PM To: Tomcat Users List Subject: Re: problem..plz help me out Why not just install tomcat 3.3.1 which is easier to get up and running. It is also easier to become familiar with the what the server.xml does and what each xml tag does by reading the tomcat users guide and server.xml configuration guide. Make user you become very familiar with these two documents as they are the most important informtion wise to get tomcat up and running. Once you have tomcat 3.3.1 running and everythings ok then maybe upgrade to tomcat 4.0.3. It is completely rebuilt from the ground up but at least you will have experience configuring and installing tomcat 3.3.1 when you decide to start on the lastest version. Nathan. - Original Message - From: puneet sachar [EMAIL PROTECTED] To: Xinji Gu [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 7:22 AM Subject: problem..plz help me out Hi friends, this is my 4th mail regarding my single complain.. I have install the tomcat 4.0.3 and its doing fine as far .html files are concern but no .class and .jsp files are running on it I have asked 9-10 times abt same question again and again and I got nothing from u guys there Plz help me.I really stuck .. With this mail I'm sending my server.xml file and web.xml file which is in my virtualhost/WEB-INF/ I know it is very tough for u to go in these files and see for errors but plz..i'm in need badly and afater spending so much time here I some time feel like crying . and I'm in such a place and in such a part of India..where I can't get ant local computer guy with whom I can discuss ..plz do me a little favour Here are my problems 1) no .class and .jsp working only html is working 2) I have done all changes which were to made in server.xml.)I have send the file also plz check it and tell me any mistake if u find) 3) I'm getting 404 error ..no servlet found 4) And I'm able to excess the .class file vis http://localhost:80/examples/servlet/abc.class But not by making my own virtual host aand not even the default root directory what i have is my own context named sachar and when i go .http://puneet:80/sachar/servlet/HelloworldServlet error -- 404 See friends ..if u can help me I'll be very grateful to u Puneet __ Do You Yahoo!? Yahoo! - Official partner of 2002 FIFA World Cup http://fifaworldcup.yahoo.com ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app servlet servlet-nameMyExample/servlet-name servlet-classHelloWorldExample/servlet-class run-as descriptionSecurity role for anonymous access/description role-nametomcat/role-name /run-as /servlet servlet-mapping servlet-nameMyExample/servlet-name url-pattern/sachar/servlet/snoop/url-pattern url-pattern/servlet/*/url-pattern /servlet-mapping /web-app !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Tomcat-Standalone !-- A Connector represents an endpoint by which requests are
RE: tomcat question
I am glad that helped. This might be that by the time apache tries to handle the /servlets the request has already been passed off to Tomcat. Just a theory. -James -Original Message- From: Ben Cox [mailto:[EMAIL PROTECTED]] Sent: Saturday, June 08, 2002 6:14 PM To: Tomcat Users List Cc: Carlos Pizano Subject: Re: tomcat question This is very helpful. Seems to work quite well. I put in: BrowserMatch .* nokeepalive downgrade-1.0 force-response-1.0 which even works for telnet if you put a User-Agent header in there. Interestingly, we'd tried: Location /servlets SetEnv downgrade-1.0 force-response-1.0 /Location in the same virtual host, and it didn't work. Any idea why not? Thanks for your help, James! Ben James Ward wrote: Ben, I am not sure if this works, but on one of my servers that has a very similar configuration to yours (Tomcat Apache) we might have fixed this. We are doing this in a Virtual Host: BrowserMatch Mozilla/2 nokeepalive downgrade-1.0 force-response-1.0 You could adapt that to always force the downgrade and response to HTTP1.0 instead of HTTP1.1 if that is what you want. We had to implement this because of IE's SSL problems. Hope that helps. -James -Original Message- From: Ben Cox [mailto:[EMAIL PROTECTED]] Sent: Saturday, June 08, 2002 3:24 PM To: Tomcat Users List Cc: Carlos Pizano Subject: Re: tomcat question Keith, et.al, Is there any way to do disable chunking on Tomcat 3.0? We are running a somewhat older application on it with jdk1.2.2, and Apache 1.3.12, on Red Hat Linux (kernel 2.4.17). We've ended up in a bit of a time crunch, need to get rid of chunking, and would be spared some time and pressure if we could upgrade and test all of these later, and more thoroughly, since it's a live server. If it's at all possible to easily disable chunking with this combination, we'd sure love to hear how! Thanks, Ben Keith Wannamaker wrote: tomcat questionThere was a bug in j-t-c that was fixed a few days ago that caused requests to be chunked even if the content-length was known. You should build tomcat-util from jakarta-tomcat-connectors and replace the one in your tomcat install with it. Otherwise, you could always use the http10 connector instead. Keith -Original Message- From: Carlos Pizano [mailto:[EMAIL PROTECTED]] Sent: Thursday, June 06, 2002 5:04 PM To: [EMAIL PROTECTED] Subject: tomcat question Sorry to bother you, but I have searched a lot for this question... to no avail. How can I disable chunking (Transfer-Encoding: chunked) output on Tomcat ? It seems that anything served with Tomcat is chunked. I need to disable that behavior that HTTP1.1 says is optional... Thanks in advance, Carlos Pizano Chief Technology Officer Elisar Software Corporation 2500 Louisiana Blvd. NE Suite 400 Albuquerque, NM 87110 Tel: (505)884-1918 Fax: (505)884-1806 [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] For additional commands, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] For additional commands, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] For additional commands, e-mail: mailto:tomcat-user- [EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: JasperException
I ran into a similar problem with the jdk1.3.* under linux. My only solution was to use the IBM JDK1.3.1. Compiles fine with that. Are you running the exact same jdk on both machines, or is the one on XP different? Nic Holbrook Todd Kaplinger wrote: Interesting problem. I would keep the generated .java file and compile the .java source from the command line. There must be something different between the two machines. From: Juan [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: JasperException Date: Sun, 09 Jun 2002 15:01:19 -0300 Hello, I'm trying to use a jsp page with a JavaBean and getting the following error: org.apache.jasper.JasperException: Unable to compile class for JSP The jsp page is very simple: html head titleTEST PAGE/title /head body jsp:useBean is=usr class=study.User / %= usr.getId() % /body /html The funny thing is that I can use this code within W2K, but it don't works under WinXP. I have a similar problem to access JDBC. It works at W2K but don't at WinXP. I looked at all configurations trying to find something different but all seems equal in both systems (I mean the environment variables). Any idea what's going on? Thanks in advance, Juan José Velázquez Garcia Web Development www.htmlspider.com.br -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] --- Todd Kaplinger mailTo:[EMAIL PROTECTED] _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Tomcat+Apache
TRY THIS LINK http://www.codesta.com/knowledge/technical/tomcat_warp_apache/page_01.jsp -Original Message- From: Vico Palomino, José Antonio [mailto:[EMAIL PROTECTED]] Sent: Friday, June 07, 2002 6:44 PM To: 'Tomcat Users List' Subject: Tomcat+Apache Importance: High Hello! My english is bad, sorry. I need integrated Tomcat with Apache. :-? Please help! PD: si alguien sabe como integrar Tomcat bajo apache con una RedHat que me eche un cablecito, por favor. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Tomcat/Apache/mod_webapp *bump*
Hi, We've done extensive searching of the archives and the web but failed to come up with a solution that works. Anybody cast some light on this? We're trying to get a multiple-webapp installation of Tomcat 4.0.3 on RedHat 7.2 with Apache 1.3 and mod_webapp (and JDK 1.4). Apache works fine, Tomcat works fine standalone, but when we link them together it fails to work. All were installed from binaries, the Apache install was part of a Nusphere install. We want to run two domains on one Tomcat Server, so the server.xml looks like the following: Server port=8005 shutdown=SHUTDOWN debug=0 Service name=Tomcat-Apache Connector className=org.apache.catalina.connector.warp.WarpConnector port=8008 minProcessors=1 maxProcessors=50 scheme=http enableLookups=true appBase=webapps acceptCount=10 debug=0/ Engine className=org.apache.catalina.connector.warp.WarpEngine name=Tomcat-Apache debug=0 Logger className=org.apache.catalina.logger.FileLogger prefix=apache_log. suffix=.txt timestamp=true/ Realm className=org.apache.catalina.realm.MemoryRealm / Host className = org.apache.catalina.connector.warp.WarpHost name=www.mytopfive.com debug=0 appBase=webapps/mytopfive unpackWARs=true Context path= docBase=. debug=0 / /Host Host className = org.apache.catalina.connector.warp.WarpHost name=www.404th.net debug=0 appBase=webapps/404th unpackWARs=true Context path= docBase=. debug=0 / /Host /Engine /Service /Server The JSP's for each webapp are in the webapps/[webapp-name] directory, hence the Context. Both were deployed from IBM Websphere Studio Application Developer 4.0.3 generated .war's. The httpd.conf looks like the following (extract) : LoadModule webapp_module libexec/mod_webapp.so AddModule mod_webapp.c ServerName 62.3.69.188 NameVirtualHost * WebAppConnection warpConnection warp localhost:8008 VirtualHost * ServerName www.404th.net DocumentRoot /usr/local/tomcat/jakarta-tomcat-4.0.3/webapps/404th WebAppDeploy 404th warpConnection / /VirtualHost VirtualHost * ServerName www.mytopfive.com DocumentRoot /usr/local/tomcat/jakarta-tomcat-4.0.3/webapps/mytopfive WebAppDeploy mytopfive warpConnection / /VirtualHost We have also tried this configuration with the WebAppDeploy . warpConnection / per an example at www.codesta.com, but get no better results. Tomcat seems to start up and initialise the webapps fine, and the logs reveal no issues. The logs also reveal good connections from the Apache mod_webapp when we start Apache, and Apache puts out what appears to be good news at the command line. However, loading either of those domains in a browser gets a 'The page cannot be displayed'. Other static sites are served fine through Apache. Any ideas? Thanks very very much. James and Catherine -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: JasperException
At 19:23 9/6/2002 -0600, you wrote: I ran into a similar problem with the jdk1.3.* under linux. My only solution was to use the IBM JDK1.3.1. Compiles fine with that. Are you running the exact same jdk on both machines, or is the one on XP different? No. Both jdk are the same. The only difference is where Tomcat is installed, but the environment variables were adapted to point to the right directories. Juan José Velázquez Garcia Web Development www.htmlspider.com.br -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Using security
Hai i am using tomcat 4.0.3 with jdk1.4 . i am using security manager with authorization policy file set. but security manager could only read Principal based entries.when i am specifying both code and principal based entries in the policy it is not working.Please help me if you know the solution. thanks in advance -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Help for a new guy?
Hello. I'm trying to run Tomcat 4 with Apache 2.0.36 using mod_jk on a Linux system when I start Apache the following error happens: mod_jk is not supported for this verson of Apache why is this? please help -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Deploying a war
Hi I've posted my solution see Generic DataSource Resource Factory Available. JDBC Data Source on the tomcat user maillist. Tony - Original Message - From: Steve Ahlstrom [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, June 09, 2002 3:14 PM Subject: Deploying a war Is there a how-to on deploying a war file to Tomcat? My war deploys correctly with Weblogic and HPAS. I haven't found step by step instructions in the Tomcat doc on how to do this (and what xml files to modify). Same question with setting up a connection pools and datasources. Thanks in advance. Steve -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]