realm configuration
Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name cheers Nathan -- Nathan Coast Managing Director Codeczar Ltd mob : (852) 9049 5581 tel : (852) 2834 8733 fax : (852) 2834 8755 web : http://www.codeczar.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat and IIS Authorization
Hi, Sorry, I thought you had it setup and wanted only to know how to pass NTLM to Tomcat. For IIS-Tomcat in general you will need to install and configure the JK1.2.8 connector. http://jakarta.apache.org/tomcat/connectors-doc/ Cheers, Allistair. -Original Message- From: Denny Lee [mailto:[EMAIL PROTECTED] Sent: 01 March 2005 18:45 To: tomcat-user@jakarta.apache.org Subject: Re: Tomcat and IIS Authorization Hello Allistair, I looked at your blog but I am still lost as to how to setup IIS and Tomcat. I saw that you mentioned you have it setup but did not specify how to do so. -Original Message- Check out the NTLM part in my Tomcat 5.5 blog www.adcworks.com/blog Cheers, Allistair. -Original Message- From: Denny Lee [mailto:[EMAIL PROTECTED] Sent: 01 March 2005 17:26 To: tomcat-user@jakarta.apache.org Subject: Tomcat and IIS Authorization Hello All, I am creating a web app that has users and admins and I need to limit certain configuration pages only to admins. I must use NTLM to authenticate users into the web site and somehow get the credential to determine if the user has sufficient access or not. How can I do this? Can I do this through IIS? So far I got authentication part working using jcfis but I can't seem to get the role of the user. I tried tagish JAAS but keep getting missing LoginModule error. Any help would be great. Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE --- QAS Ltd. Developers of QuickAddress Software a href=http://www.qas.com;www.qas.com/a Registered in England: No 2582055 Registered in Australia: No 082 851 474 --- /FONT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Migration from Tomcat 4.1 to Tomcat 5.0
Kiran Patel wrote: I have a application runing on Tomcat 4.1. I want to change to Tomcat 5.0. I already installed Tomcat 5.0.28 and configured server.xml and web.xml according to the document. But when I click startup.bat, I get the error windows can not find '-Djava.endorsed.dirs=' . I get the same error with starting startup.bat from Tomcat 4.1, but the start tomcat from Tomcat 4.1 is working fine. I am running my web apps from Tomcat 4.1 without any problem. What am I doing wrong? Please help me. I need to change to newer version due to performance issue. I will appreciate any help. Hi Kiran! Try to install your Tomcat as an operating system service by using service.bat. This script sets the parameter java.endorsed.dirs. Having Tomcat as service is more convenient as it can be started automatically after booting, you don't have an extra DOS box and so on. Kind regards, Wolfgang - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Migration from Tomcat 4.1 to Tomcat 5.0
Kiran Patel schrieb: get the error windows can not find '-Djava.endorsed.dirs=' hi! look at your environment-variables JAVA_HOME should be set correctly! hth -Christian - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
authentication does not work if web-app provides a JAX-RPC service AND JSP
Hi, If I enable the snippet below I can access my Web Services but if I call a JSP I'm facing a weird error. Using BASIC-auth-method I can sign-in and I'm being forwarded to the appropriate page, but the JSP-expressions within this page are not evaluated (Hello ${user.name}). With FORM-auth-method I will be forwarded to a page called-url/$%7Burl%7D. So the problem seems to be the same. I have a simple web-application which manages some data and allows anybody to get this data via Web Services (JAX-RPC). Only Admins should modify data with JSPs, so I would like to use the built-in security-constraint of tomcat. Thanks for your help in advance. -- Tobias web-app [...] security-constraint web-resource-collection web-resource-nameAdminPages/web-resource-name url-pattern/pages/*/url-pattern url-pattern/faces/*/url-pattern url-pattern/services/*/url-pattern /web-resource-collection auth-constraint role-nameadmin/role-name /auth-constraint /security-constraint security-role role-nameadmin/role-name /security-role login-config auth-methodFORM/auth-method form-login-config form-login-page/pages/logon.jsp/form-login-page form-error-page/pages/logonerr.jsp/form-error-page /form-login-config /login-config [...] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Include other contexts
Ok, I gave this a test run, so from app1 I called req.getRequestDispatcher(/app2).include(req,res); However, it seems that doing this loops i.e. re-requests app1 rather than passing the request to app2. It this an error with Tomcat or a misunderstanding by me? PJ Peter Johnson wrote: it would seem to be as simple as req.getRequestDispatcher(newuri).include(req,res); PJ Peter Johnson wrote: Thanks for the quick reply QM ... I'd be writing both the parent and child apps. Basically the parent would act as a broker to the child apps and perform the decoration. I guess SiteMesh does a form of automated screen scraping. I would do this so that all child apps may have a common look-n-feel and there would be a global navigation. I will look into RequestDispatcher#include() as it sounds similar to what I'd be after. PJ QM wrote: On Wed, Mar 02, 2005 at 11:53:52AM +1100, Peter Johnson wrote: : I was just wondering if it was possible to pass a request to another : context within the same host and capture the output. If it is, any : suggestions on the best way to do so? You could make a URL call to the app (java.net.URL and other similar implementations). Either that, or RequestDispatcher#include() (Though something tells me that requires an in-context URL. Check the docs to be sure.) It sounds like you're screen scraping, though, in which case you'd be better off trying to find some common data format that app A and app B can share. (If, of course, you have some control or influence over App A.) If app A changes the format of the data (common with websites) then app B has to play catch-up with its parsing. : Basically, I am planning to use SiteMesh for site templating however : would prefer to deploy many of the apps as individual apps. So somehow I : would like to call another context and then have SiteMesh decorate the : response. Are you using this setup for branding, then, or something else? I may have some suggestions, but knowing your end-goal may help. -QM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: realm configuration
Use a view -Tim Nathan Coast wrote: Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jsvc.exec error on FC3
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Bill Barker wrote: | Chong Yu Meng [EMAIL PROTECTED] wrote in message | news:[EMAIL PROTECTED] | | The daemon starts up ok, but when shutting down, I get this error: | | Feb 28, 2005 3:23:40 PM org.apache.coyote.http11.Http11Protocol pause | INFO: Pausing Coyote HTTP/1.1 on http-8080 | jsvc.exec error: Service exit with a return value of 143 | | When I do a shutdown using the shutdown.sh script, Tomcat shuts down | gracefully. | | Is there a way to shutdown jsvc gracefully? | | Yes. Don't use the version that ships with Tomcat. Hi Bill, I just downloaded and compiled the source version from the Commons website (http://www.apache.org/dist/jakarta/commons/daemon/binaries/). Unfortunately, I still get the same error. Any ideas? Perhaps you could point me to the site you downloaded your jsvc sources from, because the date stamp on the two sites I visited were different -- although the results were the same. - -- ~ -- ~ Pascal Chong -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFCJaUgmVdpiRJSldgRAo8/AJ0QnHZ9OAiWCnYZ307u+2f1MyMOAwCgksRt h0KffKXJ+tk+cU3JXD3TT7U= =Vgbu -END PGP SIGNATURE- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: realm configuration
Just done this this morning: CREATE VIEW fw_user_roles AS SELECT USERS.USER_NAME AS USER_NAME, ROLES.NAME AS ROLE_NAME FROM fw_users AS USERS, fw_user_role_rltns AS RLTNS , fw_roles AS ROLES WHERE USERS.DATA_KEY = RLTNS.PRIMARY_KEY AND ROLES.DATA_KEY = RLTNS.SECONDARY_KEY ORDER BY USER_NAME, ROLE_NAME Unfortunately looks like I may have to update my version of mysql to 5.??? -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: 02 March 2005 11:24 To: Tomcat Users List Subject: Re: realm configuration Use a view -Tim Nathan Coast wrote: Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: newbie having problems with MySQL JDBC/JNDI Datasource example
In your context definition, you have Resource name=TestDB.. In your web.xml, you have res-ref-namejdbc/TestDB/res-ref-name These two need to match. If one is jdbc/TestDB, so must the other. --David Darryl Wagoner wrote: Greetings, Not sure if this made it the first time. I didn't see it show up on the list I am trying to get the example in the MySQL JDBC/JNDI HOWTO to work and I am missing something. I get this error: My webapp directory is /DBTest. What am I missing? thanks -darryl --- Error Page --- *type* Exception report *message* *description* _The server encountered an internal error () that prevented it from fulfilling this request._ *exception* javax.servlet.ServletException: Unable to get connection, DataSource invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null' org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:845) org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:778) org.apache.jsp.testDB_jsp._jspService(org.apache.jsp.testDB_jsp:81) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:325) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) *root cause* javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid: org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null' org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.getConnection(QueryTagSupport.java:276) org.apache.taglibs.standard.tag.common.sql.QueryTagSupport.doStartTag(QueryTagSupport.java:159) org.apache.jsp.testDB_jsp._jspx_meth_sql_query_0(org.apache.jsp.testDB_jsp:100) org.apache.jsp.testDB_jsp._jspService(org.apache.jsp.testDB_jsp:58) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:325) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:245) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) --- Server.xml --- ?xml version='1.0' encoding='utf-8'? !-- $Id$ -- Server Listener className=org.apache.catalina.mbeans.ServerLifecycleListener/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListen er/ GlobalNamingResources Environment name=simpleValue type=java.lang.Integer value=30/ Resource auth=Container description=User database that can be updated an d saved name=UserDatabase type=org.apache.catalina.UserDatabase pathname=conf/tomcat-users.xml factory=org.apache.catalina.users.MemoryUs erDatabaseFactory/ /GlobalNamingResources Service name=Catalina Connector port=8080 redirectPort=8443 maxSpareThreads=75 maxThreads=150 minSpareThreads=25 /Connector Connector port=8081 proxyName=dax.shecora.com proxyPort=80 redirectPort=8443 maxSpareThreads=75 maxThreads=150 minSpareThreads=25 /Connector Connector port=8009 protocol=AJP/1.3 protocolHandlerClassName=org.apache.jk.server.JkCoyoteHandler redirectPort=8443 /Connector Engine defaultHost=localhost name=Catalina Host appBase=webapps name=localhost Context path=/DBTest docBase=DBTest debug=5 reloadable=true crossContext=true Resource name=TestDB type=javax.sql.DataSource password=javadude driverClassName=com.mysql.jdbc.Driver maxIdle=2 maxWait=5000 username=javauser url=jdbc:mysql://localhost:3306/javatest?autoReconnect=true maxActive=4/ /Context --- web.xml --- ?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 xmlns=http://java.sun.com/xml/ns/j2ee; xmlns:xsi=http://www.w3.org/20 01/XMLSchema-instance xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ ns/j2ee/web-app_2_4.xsd version=2.4 descriptionMySQL Test App/description resource-ref descriptionDB Connection/description res-ref-namejdbc/TestDB/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref /web-app - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: realm configuration
I guess (I don't use mysql) -Tim Mark Benussi wrote: Just done this this morning: CREATE VIEW fw_user_roles AS SELECT USERS.USER_NAME AS USER_NAME, ROLES.NAME AS ROLE_NAME FROM fw_users AS USERS, fw_user_role_rltns AS RLTNS , fw_roles AS ROLES WHERE USERS.DATA_KEY = RLTNS.PRIMARY_KEY AND ROLES.DATA_KEY = RLTNS.SECONDARY_KEY ORDER BY USER_NAME, ROLE_NAME Unfortunately looks like I may have to update my version of mysql to 5.??? -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: 02 March 2005 11:24 To: Tomcat Users List Subject: Re: realm configuration Use a view -Tim Nathan Coast wrote: Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DBCP Object not closed- urgent help reuired.
Hi friends, i've a program that takes in date from the user in a text box.Everything works fine except the log files shows something like this: -- (Http11Protocol.java:738) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) DBCP object created 2005-03-01 23:06:58 by the following code was never closed: java.lang.Exception at org.apache.commons.dbcp.AbandonedTrace.init(AbandonedTrace.java:96) at org.apache.commons.dbcp.AbandonedTrace.init(AbandonedTrace.java:79) at org.apache.commons.dbcp.DelegatingStatement.init(DelegatingStatement.java:60) at org.apache.commons.dbcp.DelegatingConnection.createStatement(DelegatingConnection.java:173) at org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.createStatement(PoolingDataSource.java:209) at com.ResSet.getResultSet(ResSet.java:30) at com.TournamentDollars.retArrayList(TournamentDollars.java:119) at org.apache.jsp.BonusReleased_jsp._jspService(org.apache.jsp.BonusReleased_jsp:158) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.jasper.servlet.JspServletWrapper.service -- whereas i am calling the close method at the end of my JSP,after i am finished with my data display.The close method that i call is: --- public void close() { try { results.close(); } catch (Exception ex) {} try { st.close(); } catch (Exception ex) {} try { con.close(); } catch (Exception ex) {} } Please help me friends asap,it's really urgent for me,your help would be really appreciated.Waitin for your replies, bye
RE: JDBCStore JTDS
Ok, I am not sure if anyone knows this and the documentation for tomcat does not indicate if you can use parameter /parameter for configuring a JDBCStore. Here is an example that I have seen in the tomcat documentation, with the modification for jtds that does not work. Manager className=org.apache.catalina.session.PersistentManager Store className=org.apache.catalina.session.JDBCStore connectionURL=jdbc:jtds:sqlserver://10.113.2.60/propsys;user=webuser;password=password driverName=net.sourceforge.jtds.jdbc.Driver sessionIdCol=session_id sessionValidCol=valid_session sessionMaxInactiveCol=max_inactive sessionLastAccessedCol=last_access sessionTable=tomcat_sessions sessionAppCol=app_context sessionDataCol=session_data / /Manager However, if it would support the same configuration style as dbcp, I would not be having these problems. Partial example provided below. Manager className=org.apache.catalina.session.PersistentManager Store parameter nameurl/name valuejdbc:jtds:sqlserver://10.113.2.60/propsys/value /parameter parameter nameuser/name valuesomeuser/value ... From: Randall Svancara [mailto:[EMAIL PROTECTED] Sent: Tue 3/1/2005 2:22 PM To: Tomcat Users List; Jason Bainbridge Subject: RE: JDBCStore JTDS Sorry to sound like more of an idiot, but can you provide an example of passing the connectionName and Connection password as parameters. Thanks, Randall -Original Message- From: Jason Bainbridge [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 01, 2005 1:36 PM To: Tomcat Users List Subject: Re: JDBCStore JTDS Try passing connectionName and connectionPassword as parameters instead of through the ConnectionURL. It isn't seeing them in the URL and trying to sign you on with Windows Credentials that you don't have. It is possibl;e if you change the semicolon after propsys to a ? then it might also work. On Wed, 23 Feb 2005 13:00:25 -0700, Randall Svancara [EMAIL PROTECTED] wrote: Anyone have any luck using the JTDS driver for Micro(Caugh..Caugh) SQL Server and persistent session management using JDCBStore. I am currently experiencing a problem connecting with jtds. Here is my configuration for my JDBCStore... Manager className=org.apache.catalina.session.PersistentManager Store className=org.apache.catalina.session.JDBCStore connectionURL=jdbc:jtds:sqlserver://10.113.2.60/propsys;user=webuser; pa ssword=password driverName=net.sourceforge.jtds.jdbc.Driver sessionIdCol=session_id sessionValidCol=valid_session sessionMaxInactiveCol=max_inactive sessionLastAccessedCol=last_access sessionTable=tomcat_sessions sessionAppCol=app_context sessionDataCol=session_data / /Manager I recieve this error when trying to use the driver/ConnectionURL to connect to the database. Feb 23, 2005 7:52:35 AM org.apache.catalina.session.JDBCStore getConnection SEVERE: A SQL exception occurred java.sql.SQLException: Single-Sign-On is only supported on Windows. Please specify a user name. Any help/advice/hints would be appreciated. Of course, my platform is Linux and single sign on is not what I want anyway. Randall - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: realm configuration
That sql isn't mysql specific. Should work for you fine. -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: 02 March 2005 12:33 To: Tomcat Users List Subject: Re: realm configuration I guess (I don't use mysql) -Tim Mark Benussi wrote: Just done this this morning: CREATE VIEW fw_user_roles AS SELECT USERS.USER_NAME AS USER_NAME, ROLES.NAME AS ROLE_NAME FROM fw_users AS USERS, fw_user_role_rltns AS RLTNS , fw_roles AS ROLES WHERE USERS.DATA_KEY = RLTNS.PRIMARY_KEY AND ROLES.DATA_KEY = RLTNS.SECONDARY_KEY ORDER BY USER_NAME, ROLE_NAME Unfortunately looks like I may have to update my version of mysql to 5.??? -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: 02 March 2005 11:24 To: Tomcat Users List Subject: Re: realm configuration Use a view -Tim Nathan Coast wrote: Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5.5.7 - Windows service not starting when set to automatic
I'm running Tomcat 5.5.7 on a Windows XP sp1 and I can't seem to get the Tomcat service to startup automactically when the machine boots up. I do have the service startup type set to automatic. Has anyone encountered this problem? If so, how did you get the service to start up automatically? Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat clustering and NotSerializableException
This will be a problem if the requests from the frames use the same Struts form. Else it should be fine, since the framework will set the request into the Struts form for each request, so transient will still work. - Jim From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Sent: Wed 3/2/2005 12:17 PM To: Tomcat Users List Subject: RE: Tomcat clustering and NotSerializableException From: Sng Wee Jim [mailto:[EMAIL PROTECTED] Subject: RE: Tomcat clustering and NotSerializableException Indeed a reference to the HttpServletRequest is held in my Struts form (session-scope). The problem went away once I added transient to the attribute. How do you handle the situation of having multiple concurrent requests on the same session? This can easily happen with frames, users clicking refresh, etc. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. The information in this email is confidential and is intended solely for the addressee(s). Access to this email by anyone else is unauthorized. If you are not an intended recipient, please notify the sender of this email immediately. You should not copy, use or disseminate the information contained in the email. Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Capco. http://www.capco.com/
Re: newbie having problems with MySQL JDBC/JNDI Datasource example
David, I have been looking at this off and on for weeks and could not see the problem. I changed the context to be jdbc/TestDB and it worked. Thank you very much David Smith wrote: In your context definition, you have Resource name=TestDB.. In your web.xml, you have res-ref-namejdbc/TestDB/res-ref-name These two need to match. If one is jdbc/TestDB, so must the other. --David -- Darryl Wagoner - WA1GON Evil triumphs when good men do nothing. - Edmund Burke [1729-1797] Join the TrustedQSL mailing list. An Open Source solution. Post message: [EMAIL PROTECTED] Subscribe: [EMAIL PROTECTED] List owner: [EMAIL PROTECTED] http://www.trustedQSL.org - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
On Mar 1, 2005, at 6:45 PM, Remy Maucherat wrote: On Tue, 01 Mar 2005 18:18:49 -0500, Adrian Robert [EMAIL PROTECTED] wrote: However, I can't seem to find the right combination of log4j.properties lines, or maybe I'm trying something impossible. (I can't find good docs on the uses of log4j.properties when used inside the hierarchical classloading context that tomcat provides.) What keeps happening is that the webapp's log statements keep going into the global tomcat log. Would I be better off with JDK logging instead? I am working at the moment on a small package (which will be an implementation of java.util.logging) which will allow you doing that using the JDK logging. The main issue with it as supplied in the JDK is that there is only one global configuration per JVM. The trick is to make that per classloader, with delegation, so that webapps are isolated. At the moment, I think log4j is your only choice (unfortunately, I'm no expert, so I can't give you tricks with this particular configuration). In the same package, I will also provide a handler with daily rotation. It should be done by the end of the week (it doesn't work at the moment, I'm busy debugging ;) ). Great news. I'm happy to help test this. I'd rather use JDK logging than log4j if possible to avoid an additional deployment dependency. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Multiple instances
Hello, Iam trying setting up multiple instances of Tomcat 552. I saw that in tomcat 4 you can do that with defining CATALINE_BASE for each new application pointing to the same Tomcat installation. Problem is that for Tomcat 5.5 there are no startup and shutdown scripts (windows..only Tomcat5.exe). HAs any one an idea how top that?? And what;s the best approach? Thanx, Maarten -Oorspronkelijk bericht- Van: Sng Wee Jim [mailto:[EMAIL PROTECTED] Verzonden: Wednesday, March 02, 2005 3:06 PM Aan: Tomcat Users List Onderwerp: RE: Tomcat clustering and NotSerializableException This will be a problem if the requests from the frames use the same Struts form. Else it should be fine, since the framework will set the request into the Struts form for each request, so transient will still work. - Jim From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Sent: Wed 3/2/2005 12:17 PM To: Tomcat Users List Subject: RE: Tomcat clustering and NotSerializableException From: Sng Wee Jim [mailto:[EMAIL PROTECTED] Subject: RE: Tomcat clustering and NotSerializableException Indeed a reference to the HttpServletRequest is held in my Struts form (session-scope). The problem went away once I added transient to the attribute. How do you handle the situation of having multiple concurrent requests on the same session? This can easily happen with frames, users clicking refresh, etc. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. The information in this email is confidential and is intended solely for the addressee(s). Access to this email by anyone else is unauthorized. If you are not an intended recipient, please notify the sender of this email immediately. You should not copy, use or disseminate the information contained in the email. Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Capco. http://www.capco.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
On Mar 2, 2005, at 12:25 AM, Jacob Kjome wrote: You first talk about ServletContext.log(), but then talk about log4j loggers in your app. These are two completely separate things. Which were you focusing on? With your setup, it it makes sense that ServletContext.log() messages are going to catalina.log. However, if you have log4j.jar in WEB-INF/lib and your application log4j logging is going to catalina.log, then your setup is different than what you describe here. There is quite simply no way that can happen given the setup you've described. They should go to bar.log since that's the only appender that your application's log4j configuration can see. In any case, you don't need a separate log4j.jar in WEB-INF/lib for ServletContext.log() messages to go to app-specific log files. Just define those in your log4j.properties just like you have defined the host logger. Here's my setup for Log4j-1.2.9 in common/classes.log4j.properties (You can use log4j.xml when using Log4j-1.3 because it uses a the new JoranConfigurator which doesn't define a log4j.dtd. The current DOMConfigurator's dtd defines the logger name attribute as an ID and the host and context logger names that Tomcat uses characters not allowed in attributes of type id) Thanks for your input.. I realize I wasn't clear about one thing. I don't want to define webapp-specific logging in the tomcat-global log4j.properties file. Instead, I want individual log4j.properties stored under webapp/*/WEB-INF/classes to cause logging to web-app specific files, without the container needing to be hard-coded for the webapps it is hosting. I was trying to achieve this with multiple separate log4j.properties, one in the container (common/classes/) for the uncaught stack trace and other general logging, and others in each webapp. With my setup below I was expecting to get THREE files: catalina.out (with stdout/err), tomcat.log (with the container's log4j output), and bar.log (with the webapp's log4j output, which I changed from ServletContext.log() to use Logger.info()). Instead, I got only catalina.out and tomcat.log, the latter containing everything that I thought the webapp would be sending to bar.log. ... log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localho st].[/myapp]=INFO, MYAPP log4j.additivity.org.apache.catalina.core.ContainerBase.[Catalina].[loc alhost].[/myapp]=false I don't understand this bracket notation. Is it documented anywhere? Is interpretation of it something implemented by tomcat or by log4j? Would it help me achieve what I'm trying to get without changing my webapp's code away from ServletContext.log()? BTW, you don't need commons-logging in your webapp. It is only Tomcat that needs it, so just put it in common/lib, not WEB-INF/lib. You can continue to put log4j.jar in both places if you desire. Otherwise, you can also use a repository selector to separate webapp logging with a single log4j.jar in common/lib. This makes more sense to start doing with Log4j-1.3, though, using the ContextJNDISelector. You get the same effect by having log4j.jar in WEB-INF/lib since the classloader isolation will, effectively, create logging isolation per webapp. Hmm.. I'm using log4j-1.2.9. I had the jar in both places but wasn't getting the isolation since my webapp was still pumping things into tomcat.log according to the container's log4j.properties.. However, I'm creating the logger in a static block in one of my webapp's classes -- could that have been the issue? At 06:18 PM 3/1/2005 -0500, you wrote: I'm having trouble approximating the earlier tomcat per-context Logger functionality using log4j under tomcat-5.5. Basically, I would like to have one file coming out under $CATALINA_BASE/logs/ per web application context. This appears to be no longer possible through ServletContext.log(). So I tried using log4j: 1) put log4j.jar, commons-logging.jar in common/lib AND webapps/*/WEB-INF/lib 2) put log4j.properties in common/classes AND webapps/*/WEB-INF/classes However, I can't seem to find the right combination of log4j.properties lines, or maybe I'm trying something impossible. (I can't find good docs on the uses of log4j.properties when used inside the hierarchical classloading context that tomcat provides.) What keeps happening is that the webapp's log statements keep going into the global tomcat log. Would I be better off with JDK logging instead? common/classes/log4j.properties --- log4j.rootLogger info, R log4j.appender.R org.apache.log4j.RollingFileAppender log4j.appender.R.File ${catalina.base}/logs/tomcat.log log4j.appender.R.MaxFileSize 10MB log4j.appender.R.MaxBackupIndex10 log4j.appender.R.layoutorg.apache.log4j.PatternLayout log4j.appender.R.layout.ConversionPattern %p %t %c - %m%n
Re: newbie having problems with MySQL JDBC/JNDI Datasource example
No problem. Amazing what an extra set of eyes will catch, isn't it? Enjoy! David Darryl Wagoner wrote: David, I have been looking at this off and on for weeks and could not see the problem. I changed the context to be jdbc/TestDB and it worked. Thank you very much David Smith wrote: In your context definition, you have Resource name=TestDB.. In your web.xml, you have res-ref-namejdbc/TestDB/res-ref-name These two need to match. If one is jdbc/TestDB, so must the other. --David - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Migration from Tomcat 4.1 to Tomcat 5.0
Thank you. I setup an environment variable JAVS_HOME and it is working now. Now, I have another question. How to setup a context? In Tomcat 4.1, I have it in server.xml. What I found from the documentation is that to create a separate file for context, but I don't know where to put the file and what to include in it. The context for my webapps in server.xml is as follow. Please help. !-- Class Act App Context -- Context path=/CA docBase=ca debug=0 reloadable=true Logger className=org.apache.catalina.logger.FileLogger prefix=localhost_ca_log. suffix=.txt timestamp=true/ ResourceParams name=jdbc/cms !-- DBCP -- parameternamefactory/namevalueorg.apache.commons.dbcp.BasicDataSourceFactory/value/parameter !-- Maximum number of dB connections in pool. Make sure you configure your mysqld max_connections large enough to handle all of your db connections. Set to 0 for no limit. -- parameternamemaxActive/namevalue100/value/parameter !-- Maximum number of idle dB connections to retain in pool. Set to 0 for no limit. -- parameternamemaxIdle/namevalue30/value/parameter !-- Maximum time to wait for a dB connection to become available in ms, in this example 10 seconds. An Exception is thrown if this timeout is exceeded. Set to -1 to wait indefinitely. -- parameternamemaxWait/namevalue1/value/parameter !-- dB username and password for dB connections -- parameternameusername/namevaluesa/value/parameter parameternamepassword/namevalueadmin/value/parameter !-- Class name for JDBC driver -- parameternamedriverClassName/namevaluesun.jdbc.odbc.JdbcOdbcDriver/value/parameter !-- The JDBC connection url for connecting to your dB -- parameternameurl/namevaluejdbc:odbc:cms-rms/value/parameter /ResourceParams /Context Kiran Patel Software Engineer Solutions Inc. 817.637.9060 [Work] hi! look at your environment-variables JAVA_HOME should be set correctly! hth -Christianx
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
On Wed, 02 Mar 2005 09:22:33 -0500, Adrian Robert [EMAIL PROTECTED] wrote: ... log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localho st].[/myapp]=INFO, MYAPP log4j.additivity.org.apache.catalina.core.ContainerBase.[Catalina].[loc alhost].[/myapp]=false I don't understand this bracket notation. Is it documented anywhere? Is interpretation of it something implemented by tomcat or by log4j? Would it help me achieve what I'm trying to get without changing my webapp's code away from ServletContext.log()? The logger names used in Tomcat are documented in the configuration pages. For example for webapps, it's here, in the Logging paragraph: http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html -- x Rémy Maucherat Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unexplained message in mod_jk.log
I get errors like this in mod_jk.log when running Apache/1.3.33 (Unix) mod_jk/1.2.8 mod_ssl/2.8.22 OpenSSL/0.9.7e with Tomcat 5.0.28 on SPARC/Solaris 8. I did the compile itself on SPARC/Solaris 9, but used --host=sparc-sun-solaris2.8 when configuring mod_jk (Apache didn't appear to have a similar option, unless I just didn't see it). I've compiled Apache, mod_jk, mod_ssl and OpenSSL myself with gcc/gnuMake, and downloaded a precompiled Tomcat. I don't see any actual problems with anything else, only these errors in the log. [Wed Mar 02 12:09:09 2005] [info] jk_handler::mod_jk.c (1691): Service returned error=1 with status=200 for worker=ajp13 [Wed Mar 02 12:10:25 2005] [info] jk_handler::mod_jk.c (1691): Service returned error=1 with status=500 for worker=ajp13 [Wed Mar 02 12:56:20 2005] [info] jk_handler::mod_jk.c (1691): Service returned error=1 with status=400 for worker=ajp13 At other times, I've seen other HTTP status codes in the status= field. I have turned JkLogLevel up to debug, and I see nothing else indicating a problem to me. A sample: ... [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (700): Attempting to map URI '/app/my/uri' from 9 maps [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/your/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/our/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/their/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/his/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/her/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/no/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map context URI '/app/my/uri' [Wed Mar 02 11:19:08 2005] [23554:0] [debug] map_uri_to_worker::jk_uri_worker_map.c (808): Found a suffix match ajp13 - *.jsp [Wed Mar 02 11:19:08 2005] [23554:0] [debug] wc_get_worker_for_name::jk_worker.c (92): found a worker ajp13 [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_get_endpoint::jk_ajp_common.c (2050): created new endpoint for worker ajp13 [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_marshal_into_msgb::jk_ajp_common.c (551): ajp marshaling done [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_service::jk_ajp_common.c (1594): processing with 3 retries [Wed Mar 02 11:19:08 2005] [23554:0] [debug] jk_open_socket::jk_connect.c (159): try to connect socket = 9 to 127.0.0.1:PORT [Wed Mar 02 11:19:08 2005] [23554:0] [debug] jk_open_socket::jk_connect.c (177): after connect ret = 0 [Wed Mar 02 11:19:08 2005] [23554:0] [debug] jk_open_socket::jk_connect.c (192): jk_open_socket, set TCP_NODELAY to on [Wed Mar 02 11:19:08 2005] [23554:0] [debug] jk_open_socket::jk_connect.c (229): connected sd = 9 [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_connect_to_endpoint::jk_ajp_common.c (838): connected sd = 9 to 127.0.0.1:PORT [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_connection_tcp_send_message::jk_ajp_common.c (883): sending to ajp13 pos=4 len=487 max=8192 [Wed Mar 02 11:19:08 2005] [23554:0] [debug] ajp_send_request::jk_ajp_common.c (1199): request body to send 0 - request body to resend 0 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from ajp13 pos=0 len=167 max=8192 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_unmarshal_response::jk_ajp_common.c (606): status = 200 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_unmarshal_response::jk_ajp_common.c (613): Number of headers is = 3 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_unmarshal_response::jk_ajp_common.c (669): Header[0] [Set-Cookie] = [JSESSIONID=A_SESSION_ID; Path=/app; Secure] [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_unmarshal_response::jk_ajp_common.c (669): Header[1] [Content-Type] = [text/html;charset=ISO-8859-1] [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_unmarshal_response::jk_ajp_common.c (669): Header[2] [Content-Length] = [838] [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from ajp13 pos=0 len=842 max=8192 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from ajp13 pos=0 len=2 max=8192 [Wed Mar 02 11:19:09 2005] [23554:0] [debug] ajp_done::jk_ajp_common.c (1942): recycling connection cache slot=0 * [Wed Mar 02 11:19:09 2005] [23554:0] [info] jk_handler::mod_jk.c (1691): Service returned error=1 with status=200
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
On Wed, 02 Mar 2005 09:21:08 -0500, Adrian Robert [EMAIL PROTECTED] wrote: On Mar 1, 2005, at 6:45 PM, Remy Maucherat wrote: On Tue, 01 Mar 2005 18:18:49 -0500, Adrian Robert [EMAIL PROTECTED] wrote: However, I can't seem to find the right combination of log4j.properties lines, or maybe I'm trying something impossible. (I can't find good docs on the uses of log4j.properties when used inside the hierarchical classloading context that tomcat provides.) What keeps happening is that the webapp's log statements keep going into the global tomcat log. Would I be better off with JDK logging instead? I am working at the moment on a small package (which will be an implementation of java.util.logging) which will allow you doing that using the JDK logging. The main issue with it as supplied in the JDK is that there is only one global configuration per JVM. The trick is to make that per classloader, with delegation, so that webapps are isolated. At the moment, I think log4j is your only choice (unfortunately, I'm no expert, so I can't give you tricks with this particular configuration). In the same package, I will also provide a handler with daily rotation. It should be done by the end of the week (it doesn't work at the moment, I'm busy debugging ;) ). Great news. I'm happy to help test this. I'd rather use JDK logging than log4j if possible to avoid an additional deployment dependency. Actually, this is still an extra dependency: you have to add a JAR (10KB at the moment, but it'll likely grow to 12KB once I finish the needed extensions to the standard java.util.logging) for the core (the LogManager) and the rotating file handler (the JDK impl's handler don't have anything which rotates). It works by providing a replacement impementation for the JDK's LogManager which keeps a per classloader set of loggers. This is configured using a per classloader logging.properties (same format as the main logging.properties of the JDK, but with a few additional tricks to allow more flexibility with defining handlers and assigning them to loggers whenever needed). Properties files are simple, and are a good default. If no logging.properties exist anywhere, the JDK configuration will be used. Support for other configuration sources can be done using separate LogManager implementations. At the moment, the code will live in the Tomcat CVS, but the general consensus is to migrate it to commons eventually. We'll see. I don't know either if it will be included in the Tomcat binary; at the moment, I'd say it will not. The seed code for the new LogManager (which is attached to bug 33143) is here: http://issues.apache.org/bugzilla/attachment.cgi?id=14036 It doesn't actually work, and all it does is separate logger instances (which is quite good already, as you can programmatically set levels, assign handlers, etc, but you need to code for java.util.logging to use that). So I'm working on extending it at the moment to allow non programmatical configuration, where your webapp can simply be coded for commons-logging. -- x Rémy Maucherat Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Multiple instances
From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: Multiple instances Please don't hijack existing e-mail threads; if you have a new question, start a new message. Problem is that for Tomcat 5.5 there are no startup and shutdown scripts (windows..only Tomcat5.exe). Use the .zip download, not the .exe. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RequestDispatcher.forward: a bug?
Hi, (I work on Tomcat 5.0.30). When my servlet (http://myVhost/proxy/testProxy) forward to another servlet : try { ServletContext ctx = getServletContext(); ctx = ctx.getContext(/myNewContext); RequestDispatcher dispatcher = ctx.getRequestDispatcher(/myNewServlet); dispatcher.forward(request, response); } catch (Exception e) {e.printStackTrace();} (in server.xml, in the Context /proxy of myVhost, I put crossContext=true) If the Context /myNewContext is deployed in myVhost, the HTTPresponse is : HTTP/1.1 200 OK ... response of myNewServlet If the Context /myNewContext is not deployed, the HTTPresponse is : HTTP/1.1 404 /myNewServlet :-( 1) In other servlets containers, I read that ctx.getRequestDispatcher(...) returns null if the resource is absent. So, Why Tomcat reacts differently ? Is it a bug ? 2) In my case, I'd want to forward to myNewServlet if it is present, BUT, if it is absent, I'd want to call another url distant (with httpclient)... How can I do this with Tomcat ? Thanks in advance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: RequestDispatcher.forward: a bug?
getRequestDispatcher() will always return a servlet. (The default servlet) -Tim Lionel Farbos wrote: Hi, (I work on Tomcat 5.0.30). When my servlet (http://myVhost/proxy/testProxy) forward to another servlet : try { ServletContext ctx = getServletContext(); ctx = ctx.getContext(/myNewContext); RequestDispatcher dispatcher = ctx.getRequestDispatcher(/myNewServlet); dispatcher.forward(request, response); } catch (Exception e) {e.printStackTrace();} (in server.xml, in the Context /proxy of myVhost, I put crossContext=true) If the Context /myNewContext is deployed in myVhost, the HTTPresponse is : HTTP/1.1 200 OK ... response of myNewServlet If the Context /myNewContext is not deployed, the HTTPresponse is : HTTP/1.1 404 /myNewServlet :-( 1) In other servlets containers, I read that ctx.getRequestDispatcher(...) returns null if the resource is absent. So, Why Tomcat reacts differently ? Is it a bug ? 2) In my case, I'd want to forward to myNewServlet if it is present, BUT, if it is absent, I'd want to call another url distant (with httpclient)... How can I do this with Tomcat ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: RequestDispatcher.forward: a bug?
Yes : it's my problem. ctx.getContext(/myNewContext) always return a Context (even if myNewContext is not deployed :-( and ctx.getRequestDispatcher(/myNewServlet) always return a dispatcher (even if myNewServlet is not here :-( So How can I avoid a 404 ? On Wed, 02 Mar 2005 10:24:37 -0500 Tim Funk [EMAIL PROTECTED] wrote: getRequestDispatcher() will always return a servlet. (The default servlet) -Tim Lionel Farbos wrote: Hi, (I work on Tomcat 5.0.30). When my servlet (http://myVhost/proxy/testProxy) forward to another servlet : try { ServletContext ctx = getServletContext(); ctx = ctx.getContext(/myNewContext); RequestDispatcher dispatcher = ctx.getRequestDispatcher(/myNewServlet); dispatcher.forward(request, response); } catch (Exception e) {e.printStackTrace();} (in server.xml, in the Context /proxy of myVhost, I put crossContext=true) If the Context /myNewContext is deployed in myVhost, the HTTPresponse is : HTTP/1.1 200 OK ... response of myNewServlet If the Context /myNewContext is not deployed, the HTTPresponse is : HTTP/1.1 404 /myNewServlet :-( 1) In other servlets containers, I read that ctx.getRequestDispatcher(...) returns null if the resource is absent. So, Why Tomcat reacts differently ? Is it a bug ? 2) In my case, I'd want to forward to myNewServlet if it is present, BUT, if it is absent, I'd want to call another url distant (with httpclient)... How can I do this with Tomcat ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Some trouble compiling mod_jk (solved, actually)
Hi, I have managed to compile the mod_jk shared object that comes with jakarta-tomcat-5.5.7-src.tar.gz. That could have been easier! Here's a problem I encountered on Red Hat ES 4, just wanted to share. If anyone thinks this belongs into bugzilla, I will gladly add it. Running ant native yields a libtool error that stops the build process in compile and link mode: libtool: compile: unable to infer tagged configuration libtool: compile: specify a tag with `--tag' libtool: link: unable to infer tagged configuration libtool: link: specify a tag with `--tag' ...which is not nice. Apparently the 'tag' can be set to anything -- I haven't found out what it actually is for from the libtool documentation (!!) This is libtool-1.5.6-4 The workaround: Edit jakarta-tomcat-connectors/jk/jkant/java/org/apache/jk/ant/compilers/LibtoolCompiler.java jakarta-tomcat-connectors/jk/jkant/java/org/apache/jk/ant/compilers/LibtoolLink.java and add cmd.createArgument().setValue(--tag=something); after the existing. cmd.createArgument().setValue(--mode=compile); There might be a way to give the So Task an appropriate argument, too. But I think not. On to the next problem. -- David Tonhofer M-PLIFY S.A. Resp. Informatique 47, av. de la Liberté L-1931 Luxembourg Tel: +352 261846-52 Fax: +352 261846-46 Mob: +352 021-139031 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
startup script not working
Hi, I am downloading distribution Tomcat 5.5.7.zip and unzip it. When I try to run the startup script the CMD prompt window show up, throw an error and closes automatically. So Anyone know what the error could be?? There is no errorlog sterr or something else available. Please help!! Maarten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Migration from Tomcat 4.1 to Tomcat 5.0
On Mar 2, 2005, at 9:39 AM, Kiran Patel wrote: Thank you. I setup an environment variable JAVS_HOME and it is working now. Now, I have another question. How to setup a context? In Tomcat 4.1, I have it in server.xml. What I found from the documentation is that to create a separate file for context, but I don't know where to put the file and what to include in it. The context for my webapps in server.xml is as follow. Please help. Put the Context tag and everything it contains in a file named CA.xml (maybe the name can be anything) and put it in $CATALINA_BASE/conf/Catalina/localhost/ . You can also toss it in a META-INF directory under your web-app, but I'm not sure if this goes at the top level or under WEB-INF. !-- Class Act App Context -- Context path=/CA docBase=ca debug=0 reloadable=true Logger className=org.apache.catalina.logger.FileLogger prefix=localhost_ca_log. suffix=.txt timestamp=true/ ResourceParams name=jdbc/cms !-- DBCP -- parameternamefactory/ namevalueorg.apache.commons.dbcp.BasicDataSourceFactory/value/ parameter !-- Maximum number of dB connections in pool. Make sure you configure your mysqld max_connections large enough to handle all of your db connections. Set to 0 for no limit. -- parameternamemaxActive/namevalue100/value/parameter !-- Maximum number of idle dB connections to retain in pool. Set to 0 for no limit. -- parameternamemaxIdle/namevalue30/value/parameter !-- Maximum time to wait for a dB connection to become available in ms, in this example 10 seconds. An Exception is thrown if this timeout is exceeded. Set to -1 to wait indefinitely. -- parameternamemaxWait/namevalue1/value/parameter !-- dB username and password for dB connections -- parameternameusername/namevaluesa/value/parameter parameternamepassword/namevalueadmin/value/parameter !-- Class name for JDBC driver -- parameternamedriverClassName/ namevaluesun.jdbc.odbc.JdbcOdbcDriver/value/parameter !-- The JDBC connection url for connecting to your dB -- parameternameurl/namevaluejdbc:odbc:cms-rms/value/ parameter /ResourceParams /Context Kiran Patel Software Engineer Solutions Inc. 817.637.9060 [Work] hi! look at your environment-variables JAVA_HOME should be set correctly! hth -Christianx - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
I don't know about Tomcat 5.5 specifically, but in Tomcat 5.0, startup.bat calls catalina.bat which calls setclasspath.bat. You'll see it runs the following, and if it can't find any of the files (probably because your JAVA_HOME is a JRE and not a JDK), it'll call exit and close your window: if not exist %JAVA_HOME%\bin\java.exe goto noJavaHome if not exist %JAVA_HOME%\bin\javaw.exe goto noJavaHome if not exist %JAVA_HOME%\bin\jdb.exe goto noJavaHome if not exist %JAVA_HOME%\bin\javac.exe goto noJavaHome It's kinda hard to see the meaningful error message from this batch file when the window closes. I've always wondered if this is a bug? Jay [www.vtgroup.com] -Original Message- From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Sent: Sunday, May 02, 2004 10:02 AM To: tomcat-user@jakarta.apache.org Subject: startup script not working Hi, I am downloading distribution Tomcat 5.5.7.zip and unzip it. When I try to run the startup script the CMD prompt window show up, throw an error and closes automatically. So Anyone know what the error could be?? There is no errorlog sterr or something else available. Please help!! Maarten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: startup script not working When I try to run the startup script the CMD prompt window show up, throw an error and closes automatically. The startup.bat script does little other than kick off catalina.bat. You can run catalina.bat directly in your currrent command prompt window to see whatever error messages are being displayed - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: startup script not working
On Sun, 2 May 2004 17:01:44 +0200, Bedrijven.nl [EMAIL PROTECTED] wrote: Hi, I am downloading distribution Tomcat 5.5.7.zip and unzip it. When I try to run the startup script the CMD prompt window show up, throw an error and closes automatically. So Anyone know what the error could be?? There is no errorlog sterr or something else available. Please help!! Is your JAVA_HOME environment variable set to the root directory of a JDK install? Something like C:\JDK_1.4.2_02 Try opening up a command prompt and then running startup.bat from there so you can see what settings get picked up for your environment variables. Regards, -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jspISAPI solution?
I've created a new thread, just in case this got lost in the shuffle... Does anyone know anything about the below solution (+ or -) and/or recommend (or not recommend) it? Thanks, -Matt On Mon, 28 Feb 2005, Matt wrote: Something else you may want to look into (and I'd LOVE to hear feedback on from this list?) is the following: http://jspisapi.neurospeech.com/ We are now using this on our production IIS 6 server, mostly due to the conflciting, or at least the lack of concise and authoratative, docs out there (and mostly due to timing - this needed to be setup ASAP for a professor). I don't directly maintain the IIS 6 server, and its admin got antsy waiting for us to iron-out the confugration issues (and dreading future changes taking as much effort, like SSL support) with Tomcat and went with this instead ($50). Was this wise? Anyone? I'm curious (and not in front of this system now either) if it uses jk2 or jk and what version, and anything else it may be doing. Thanks, -Matt On Mon, 28 Feb 2005, Fadil wrote: Thanks a lot I'll test this ASAP. Unfortunately, I must setup IIS6 / Tomcat because it's my production environement and I've no choice : I don't want to learn dotnet !! I'm a beginner J2EE developper. [snip] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
EJB
Dear Friends, please tell me, whether server TomCat with EJB is able to work Thank you for answer. Best regards, Sergey Bogomolov --- Centre Of New Technologies phone +7 (095) 783-2601 ext. 214 (8-hours HotLine) fax783-2601 mailto: [EMAIL PROTECTED], [EMAIL PROTECTED] ---
RE: startup script not working
This is my error... D:\Tomcat557\bincatalina run Using CATALINA_BASE: D:\Tomcat557 Using CATALINA_HOME: D:\Tomcat557 Using CATALINA_TMPDIR: D:\Tomcat557\temp Using JAVA_HOME: C:\jdk java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:271) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:409) Caused by: java.lang.NoSuchMethodError: javax.management.ObjectName.quote(Ljava/ lang/String;)Ljava/lang/String; at org.apache.catalina.mbeans.MBeanUtils.createObjectName(MBeanUtils.jav a:1232) at org.apache.catalina.mbeans.MBeanUtils.createMBean(MBeanUtils.java:651 ) at org.apache.catalina.mbeans.GlobalResourcesLifecycleListener.createMBe ans(GlobalResourcesLifecycleListener.java:216) at org.apache.catalina.mbeans.GlobalResourcesLifecycleListener.createMBe ans(GlobalResourcesLifecycleListener.java:146) at org.apache.catalina.mbeans.GlobalResourcesLifecycleListener.createMBe ans(GlobalResourcesLifecycleListener.java:108) at org.apache.catalina.mbeans.GlobalResourcesLifecycleListener.lifecycle Event(GlobalResourcesLifecycleListener.java:80) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl eSupport.java:119) at org.apache.catalina.core.StandardServer.start(StandardServer.java:676 ) at org.apache.catalina.startup.Catalina.start(Catalina.java:537) ... 6 more anyone any idea??? -Oorspronkelijk bericht- Van: Caldarale, Charles R [mailto:[EMAIL PROTECTED] Verzonden: Wednesday, March 02, 2005 5:14 PM Aan: Tomcat Users List Onderwerp: RE: startup script not working From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: startup script not working When I try to run the startup script the CMD prompt window show up, throw an error and closes automatically. The startup.bat script does little other than kick off catalina.bat. You can run catalina.bat directly in your currrent command prompt window to see whatever error messages are being displayed - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
java.lang.ClassNotFoundException : What have I missed here?
Hello, I'm developing Tomcat apps using Eclipse with the Tomcat plugin. I thought I layed out my directory structure correctly but Tomcat is still failing to locate my Java class. Here's my setup. Java src file location: C:\eclipse\workspace\Nuthin\WEB-INF\src\com\visualio\business\NuthinClass.java Java src file: package com.visualio.business; import java.io.*; import javax.servlet.http.*; import javax.servlet.*; public class NuthinClass extends HttpServlet { public void doGet (HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { PrintWriter out = res.getWriter(); out.println(Nuthin from nuthin leaves nuthin ...); out.close(); } } Java class location: C:\eclipse\workspace\Nuthin\WEB-INF\classes\com\visualio\business\NuthinClass.class My web.xml file: ?xml version=1.0 encoding=UTF-8? !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-namenuthin/servlet-name servlet-classNuthinClass/servlet-class /servlet servlet-mapping servlet-namenuthin/servlet-name url-pattern/nuthin/url-pattern /servlet-mapping /web-app Relevant Tomcat config file location: C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\Catalina\localhost\Nuthin.xml Relevant Tomcat config file contents: Context path=/Nuthin reloadable=true docBase=C:\eclipse\workspace\Nuthin workDir=C:\eclipse\workspace\Nuthin\work / When I try and run http://localhost:8080/Nuthin/nuthin I get: exception javax.servlet.ServletException: Wrapper cannot find servlet class NuthinClass or a class it depends on org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) root cause java.lang.ClassNotFoundException: NuthinClass org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1332) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1181) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) Can someone please clarify what I missed in my configuration? Thanks, Douglass Turner email: douglass_dot_turner_at_gmail_dot_com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.ClassNotFoundException : What have I missed here?
your web.xml needs to have servlet servlet-namenuthin/servlet-name servlet-classcom.visualio.business.NuthinClass/servlet-class /servlet instead of just the class name. On Wed, 2 Mar 2005 11:30:24 -0500, Douglass Turner [EMAIL PROTECTED] wrote: Hello, I'm developing Tomcat apps using Eclipse with the Tomcat plugin. I thought I layed out my directory structure correctly but Tomcat is still failing to locate my Java class. Here's my setup. Java src file location: C:\eclipse\workspace\Nuthin\WEB-INF\src\com\visualio\business\NuthinClass.java Java src file: package com.visualio.business; import java.io.*; import javax.servlet.http.*; import javax.servlet.*; public class NuthinClass extends HttpServlet { public void doGet (HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { PrintWriter out = res.getWriter(); out.println(Nuthin from nuthin leaves nuthin ...); out.close(); } } Java class location: C:\eclipse\workspace\Nuthin\WEB-INF\classes\com\visualio\business\NuthinClass.class My web.xml file: ?xml version=1.0 encoding=UTF-8? !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-namenuthin/servlet-name servlet-classNuthinClass/servlet-class /servlet servlet-mapping servlet-namenuthin/servlet-name url-pattern/nuthin/url-pattern /servlet-mapping /web-app Relevant Tomcat config file location: C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\Catalina\localhost\Nuthin.xml Relevant Tomcat config file contents: Context path=/Nuthin reloadable=true docBase=C:\eclipse\workspace\Nuthin workDir=C:\eclipse\workspace\Nuthin\work / When I try and run http://localhost:8080/Nuthin/nuthin I get: exception javax.servlet.ServletException: Wrapper cannot find servlet class NuthinClass or a class it depends on org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) root cause java.lang.ClassNotFoundException: NuthinClass org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1332) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1181) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) Can someone please clarify what I missed in my configuration? Thanks, Douglass Turner email: douglass_dot_turner_at_gmail_dot_com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.ClassNotFoundException : What have I missed here?
Thanks so much Jason. That was it. Cheers, Douglass Turner On Wed, 2 Mar 2005 10:39:41 -0600, Jason Bainbridge [EMAIL PROTECTED] wrote: your web.xml needs to have servlet servlet-namenuthin/servlet-name servlet-classcom.visualio.business.NuthinClass/servlet-class /servlet instead of just the class name. On Wed, 2 Mar 2005 11:30:24 -0500, Douglass Turner [EMAIL PROTECTED] wrote: Hello, I'm developing Tomcat apps using Eclipse with the Tomcat plugin. I thought I layed out my directory structure correctly but Tomcat is still failing to locate my Java class. Here's my setup. Java src file location: C:\eclipse\workspace\Nuthin\WEB-INF\src\com\visualio\business\NuthinClass.java Java src file: package com.visualio.business; import java.io.*; import javax.servlet.http.*; import javax.servlet.*; public class NuthinClass extends HttpServlet { public void doGet (HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { PrintWriter out = res.getWriter(); out.println(Nuthin from nuthin leaves nuthin ...); out.close(); } } Java class location: C:\eclipse\workspace\Nuthin\WEB-INF\classes\com\visualio\business\NuthinClass.class My web.xml file: ?xml version=1.0 encoding=UTF-8? !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-namenuthin/servlet-name servlet-classNuthinClass/servlet-class /servlet servlet-mapping servlet-namenuthin/servlet-name url-pattern/nuthin/url-pattern /servlet-mapping /web-app Relevant Tomcat config file location: C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\Catalina\localhost\Nuthin.xml Relevant Tomcat config file contents: Context path=/Nuthin reloadable=true docBase=C:\eclipse\workspace\Nuthin workDir=C:\eclipse\workspace\Nuthin\work / When I try and run http://localhost:8080/Nuthin/nuthin I get: exception javax.servlet.ServletException: Wrapper cannot find servlet class NuthinClass or a class it depends on org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) root cause java.lang.ClassNotFoundException: NuthinClass org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1332) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1181) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) Can someone please clarify what I missed in my configuration? Thanks, Douglass Turner email: douglass_dot_turner_at_gmail_dot_com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com -- Douglass Turner voice/sms: +354 895 5077 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.ClassNotFoundException : What have I missed here?
Error In web.xml You write: servlet-classNuthinClass/servlet-class Correctly to specify a package: servlet-classcom.visualio.business.NuthinClass/servlet-class Sergey Bogomolov - Original Message - From: Douglass Turner [EMAIL PROTECTED] To: tomcat-user@jakarta.apache.org Sent: Wednesday, March 02, 2005 7:30 PM Subject: java.lang.ClassNotFoundException : What have I missed here? Hello, I'm developing Tomcat apps using Eclipse with the Tomcat plugin. I thought I layed out my directory structure correctly but Tomcat is still failing to locate my Java class. Here's my setup. Java src file location: C:\eclipse\workspace\Nuthin\WEB-INF\src\com\visualio\business\NuthinClass.java Java src file: package com.visualio.business; import java.io.*; import javax.servlet.http.*; import javax.servlet.*; public class NuthinClass extends HttpServlet { public void doGet (HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException { PrintWriter out = res.getWriter(); out.println(Nuthin from nuthin leaves nuthin ...); out.close(); } } Java class location: C:\eclipse\workspace\Nuthin\WEB-INF\classes\com\visualio\business\NuthinClass.class My web.xml file: ?xml version=1.0 encoding=UTF-8? !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-namenuthin/servlet-name servlet-classNuthinClass/servlet-class /servlet servlet-mapping servlet-namenuthin/servlet-name url-pattern/nuthin/url-pattern /servlet-mapping /web-app Relevant Tomcat config file location: C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\Catalina\localhost\Nuthin.xml Relevant Tomcat config file contents: Context path=/Nuthin reloadable=true docBase=C:\eclipse\workspace\Nuthin workDir=C:\eclipse\workspace\Nuthin\work / When I try and run http://localhost:8080/Nuthin/nuthin I get: exception javax.servlet.ServletException: Wrapper cannot find servlet class NuthinClass or a class it depends on org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) root cause java.lang.ClassNotFoundException: NuthinClass org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1332) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1181) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738) org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) java.lang.Thread.run(Thread.java:595) Can someone please clarify what I missed in my configuration? Thanks, Douglass Turner email: douglass_dot_turner_at_gmail_dot_com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jspISAPI solution?
I've used it since 08/04 on an IIS v5 Tomcat v4 system. It's okay but it has some major bugs. The biggest glitch is that it spits out random strings in the returned HTML which can make the page render incorrectly. My pages display fine when I'm viewing them locally, but when I go to a local computer training center and view them my HTML tables come out all wrong. Looking at source code shows extra 2000 strings and other random strings in the source. JspISAPI support says that this problem only happens when connecting through one particular proxy server (and an older version at that). However, pages served through JspISAPI will not validate using the W3C's validator (though directly through Tomcat they do). Also my cached pages on Yahoo also display the HTML table problem. My decision. It's buggy and either no longer supported or poorly supported. Last week I found a project on sourceforge that does the same thing: http://iisrelayj.sourceforge.net/ I installed it on a test system. Couldn't get v3 to work but v2 worked. Using this my pages did at least validate using W3Cs validator. They also don't have the random strings when viewing them through a spider simulator. I haven't gotten to the local computer training center to see if my HTML tables are rendering correctly. At 11:22 AM 3/2/2005, Matt wrote: I've created a new thread, just in case this got lost in the shuffle... Does anyone know anything about the below solution (+ or -) and/or recommend (or not recommend) it? Thanks, -Matt On Mon, 28 Feb 2005, Matt wrote: Something else you may want to look into (and I'd LOVE to hear feedback on from this list?) is the following: http://jspisapi.neurospeech.com/ We are now using this on our production IIS 6 server, mostly due to the conflciting, or at least the lack of concise and authoratative, docs out there (and mostly due to timing - this needed to be setup ASAP for a professor). I don't directly maintain the IIS 6 server, and its admin got antsy waiting for us to iron-out the confugration issues (and dreading future changes taking as much effort, like SSL support) with Tomcat and went with this instead ($50). Was this wise? Anyone? I'm curious (and not in front of this system now either) if it uses jk2 or jk and what version, and anything else it may be doing. Thanks, -Matt On Mon, 28 Feb 2005, Fadil wrote: Thanks a lot I'll test this ASAP. Unfortunately, I must setup IIS6 / Tomcat because it's my production environement and I've no choice : I don't want to learn dotnet !! I'm a beginner J2EE developper. [snip] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Session state Tomcat 5.5.4
I'm experiencing, what I believe to be, strange behavior with Tomcat 5.5.4. I'm using Oracle connection pooling and the pool is initialized, and connections made to the database, upon startup. I can query the v$session view to verify that the connections were made. I put the connection pool object in the Application context. My problem is this, when Tomcat encounters some sort of error, like can't find a JSP page for example, the session seems to be invalidated and the connection pool object is unreachable. However, the connections still exist. Again, querying the v$session view indicates the connections are still there. At this point, I'm forced to restart Tomcat, which resolves the problem. Any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: RE: startup script not working Caused by: java.lang.NoSuchMethodError: javax.management.ObjectName.quote(Ljava/lang/String;)Ljava/lang/String; It looks like you're trying to use Tomcat 5.5.7 with a 1.4 JDK. You can either install a 5.0 JRE (or 1.5 JDK), or download and use the compat.zip package from the Tomcat download area. See RUNNING.txt for details. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: EJB
== Date: Wed, 2 Mar 2005 19:23:19 +0300 From: Bogomolov Sergey [EMAIL PROTECTED] To: tomcat-user@jakarta.apache.org Subject: EJB == Dear Friends, please tell me, whether server TomCat with EJB is able to work Thank you for answer. Best regards, Sergey Bogomolov Hi, Sergey, Tomcat is a web application container (i.e. for JSP and Servlet) You need a EJB container to manage them (such as JBoss), then connect Tomcat and EJB container. With JBoss you can have Tomcat embedded too. Bye G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
Try commenting out the listeners in server.xml: Listener className=org.apache.catalina.mbeans.ServerLifecycleListener / Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener / Listener className=org.apache.catalina.storeconfig.StoreConfigLifecycleListener/ Or upgrade the JMX package --On Wednesday, March 02, 2005 5:22 PM +0100 Bedrijven.nl [EMAIL PROTECTED] wrote: Caused by: java.lang.NoSuchMethodError: javax.management.ObjectName.quote(Ljava/ lang/String;)Ljava/lang/String; at - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
ok..the errors are away by commenting out. But now the next error shows up: D:\Tomcat557\bincatalina run Using CATALINA_BASE: D:\Tomcat557 Using CATALINA_HOME: D:\Tomcat557 Using CATALINA_TMPDIR: D:\Tomcat557\temp Using JAVA_HOME: C:\jdk java.lang.NoSuchMethodError: org.apache.commons.logging.LogFactory.release(Ljava /lang/ClassLoader;)V at org.apache.catalina.loader.WebappClassLoader.stop(WebappClassLoader.j ava:1499) at org.apache.catalina.loader.WebappLoader.stop(WebappLoader.java:706) at org.apache.catalina.core.StandardContext.stop(StandardContext.java:43 08) at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java :892) at org.apache.catalina.startup.HostConfig.undeployApps(HostConfig.java:1 147) at org.apache.catalina.startup.HostConfig.stop(HostConfig.java:1119) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java :312) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl eSupport.java:119) at org.apache.catalina.core.ContainerBase.stop(ContainerBase.java:1051) at org.apache.catalina.core.ContainerBase.stop(ContainerBase.java:1063) at org.apache.catalina.core.StandardEngine.stop(StandardEngine.java:445) at org.apache.catalina.core.StandardService.stop(StandardService.java:51 2) at org.apache.catalina.core.StandardServer.stop(StandardServer.java:717) Any idea's??? When i install it as a service everything is ok, but I won't do that because i want to set up multiple instances with the use of catalina_base Maarten -Oorspronkelijk bericht- Van: David Tonhofer, m-plify S.A. [mailto:[EMAIL PROTECTED] Verzonden: Wednesday, March 02, 2005 5:49 PM Aan: Tomcat Users List Onderwerp: RE: startup script not working Try commenting out the listeners in server.xml: Listener className=org.apache.catalina.mbeans.ServerLifecycleListener / Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener / Listener className=org.apache.catalina.storeconfig.StoreConfigLifecycleListener/ Or upgrade the JMX package --On Wednesday, March 02, 2005 5:22 PM +0100 Bedrijven.nl [EMAIL PROTECTED] wrote: Caused by: java.lang.NoSuchMethodError: javax.management.ObjectName.quote(Ljava/ lang/String;)Ljava/lang/String; at - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Altering default HTTP header fields for serving static content
If you really want the browser not to cache images, you are better off putting a timestamp on the end of the requests - as no-cache does not convince every browser all of the time... ie: http://localhost/image.gif?78927842303 On Mar 2, 2005, at 6:46 AM, [EMAIL PROTECTED] wrote: Is there a way to alter the default HTTP header fields when a request is made to Tomcat for static content? I would like to be able to add the Cache-Control general header field with value no-cache when serving images so they are not cached on the client side. Can anyone please help? I've tried looking everywhere but can't find a solution. Thanks in advance... David - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
Quoting Adrian Robert [EMAIL PROTECTED]: On Mar 2, 2005, at 12:25 AM, Jacob Kjome wrote: You first talk about ServletContext.log(), but then talk about log4j loggers in your app. These are two completely separate things. Which were you focusing on? With your setup, it it makes sense that ServletContext.log() messages are going to catalina.log. However, if you have log4j.jar in WEB-INF/lib and your application log4j logging is going to catalina.log, then your setup is different than what you describe here. There is quite simply no way that can happen given the setup you've described. They should go to bar.log since that's the only appender that your application's log4j configuration can see. In any case, you don't need a separate log4j.jar in WEB-INF/lib for ServletContext.log() messages to go to app-specific log files. Just define those in your log4j.properties just like you have defined the host logger. Here's my setup for Log4j-1.2.9 in common/classes.log4j.properties (You can use log4j.xml when using Log4j-1.3 because it uses a the new JoranConfigurator which doesn't define a log4j.dtd. The current DOMConfigurator's dtd defines the logger name attribute as an ID and the host and context logger names that Tomcat uses characters not allowed in attributes of type id) Thanks for your input.. I realize I wasn't clear about one thing. I don't want to define webapp-specific logging in the tomcat-global log4j.properties file. Instead, I want individual log4j.properties stored under webapp/*/WEB-INF/classes to cause logging to web-app specific files, without the container needing to be hard-coded for the webapps it is hosting. Understandable. I was a little dismayed to see that what had been more automatic in Tomcat-5.0.xx had become less so in Tomcat-5.5. What I mean is, in Tomcat-5.0.xx, one could add a Logger to the context configuration file, deploy that with the webapp, and dynamically get a log file for ServletContext.log() output. In Tomcat-5.5, one has to have this in the logger config file at Tomcat startup, therefore forcing one to predict the apps that will be deployed to the appserver during runtime. Of course, Tomcat could continue to use the Logger syntax, but only have it mean to programatically use the currently configured logger implementation to add the logger to the existing config rather than literally create a catalina logger which no longer exists. This would continue to make Tomcat-5.5 more involved in logging than it should, though. I think Yoav Shapira has it right when he says that Tomcat should not really be directly involved in logging, but use the external implementation. I'm not sure what the solution is. Probably needs more discussion. I was trying to achieve this with multiple separate log4j.properties, one in the container (common/classes/) for the uncaught stack trace and other general logging, and others in each webapp. With my setup below I was expecting to get THREE files: catalina.out (with stdout/err), tomcat.log (with the container's log4j output), and bar.log (with the webapp's log4j output, which I changed from ServletContext.log() to use Logger.info()). Instead, I got only catalina.out and tomcat.log, the latter containing everything that I thought the webapp would be sending to bar.log. And this should have worked. It works in every case I have ever tried. I suggest you double and triple check that you have log4j.jar in both common/lib and WEB-INF/lib and make sure you have log4j.properties in both common/classes and WEB-INF/classes. One thing that can trip people up is having a log4j.xml file somewhere in the classpath, whether it is in a jar or in WEB-INF/classes. Log4j looks for log4j.xml first and only looks for log4j.properties if it doesn't find it. If a rogue log4j.xml file is sitting in the classpath somewhere your webapp might be using it rather than the log4j.properties you think it is using. This is one of the reasons I always use XML config files rather than property files. I only use log4j.properties for Tomcat-5.5 because of incompatibilities with Tomcat-5.5 context and host logger names and Log4j-1.2.x's dtd. Again, Log4j-1.3 solves this be no longer having a DTD. ... log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localho st].[/myapp]=INFO, MYAPP log4j.additivity.org.apache.catalina.core.ContainerBase.[Catalina].[loc alhost].[/myapp]=false I don't understand this bracket notation. Is it documented anywhere? Is interpretation of it something implemented by tomcat or by log4j? Would it help me achieve what I'm trying to get without changing my webapp's code away from ServletContext.log()? See Remy's message about this. It is detailed in the Tomcat docs. BTW, you don't need commons-logging in your webapp. It is only Tomcat that needs it, so just put it in common/lib, not WEB-INF/lib. You can continue to put
RE: startup script not working
You need to upgrade to the latest commons-logging. See: http://jakarta.apache.org/commons/logging/api/index.html You still seem to have logging 1.0.2 =:-o http://jakarta.apache.org/commons/logging/commons-logging-1.0.2/docs/api/ Make sure that you have the packages at the version described in the build.properties (or higher), like these: commons-beanutils.loc=${base-jakarta.loc}/commons/beanutils/binaries/commons-beanutils-1.7.0.tar.gz commons-launcher.loc=${base-jakarta.loc}/commons/launcher/binaries/launcher-0.9.tar.gz commons-daemon.loc=${base-jakarta.loc}/commons/daemon/binaries/commons-daemon-1.0.tar.gz commons-digester.loc=${base-jakarta.loc}/commons/digester/binaries/commons-digester-1.6.tar.gz commons-el.loc=${base-jakarta.loc}/commons/el/binaries/commons-el-1.0.tar.gz commons-logging.loc=${base-jakarta.loc}/commons/logging/binaries/commons-logging-1.0.4.tar.gz commons-modeler.loc=${base-jakarta.loc}/commons/modeler/binaries/modeler-1.1.tar.gz xerces.loc=${base-xml.loc}/xerces-j/binaries/Xerces-J-bin.2.6.2.tar.gz jdt.loc=http://sunsite.informatik.rwth-aachen.de/eclipse/downloads/drops/R-3.0.1-200409161125/eclipse-JDT-3.0.1.zip log4j.loc=${base-logging.loc}/log4j/1.2.9/logging-log4j-1.2.9.tar.gz commons-dbcp-src.loc=${base-jakarta.loc}/commons/dbcp/source/commons-dbcp-1.2.1-src.tar.gz commons-httpclient.loc=${base-jakarta.loc}/commons/httpclient/binary/commons-httpclient-2.0.tar.gz commons-pool-src.loc=${base-jakarta.loc}/commons/pool/source/commons-pool-1.2-src.tar.gz commons-collections.loc=${base-jakarta.loc}/commons/collections/binaries/commons-collections-3.1.tar.gz commons-collections-src.loc=${base-jakarta.loc}/commons/collections/source/commons-collections-3.1-src.tar.gz commons-fileupload.loc=${base-jakarta.loc}/commons/fileupload/binaries/commons-fileupload-1.0.tar.gz jmx.loc=${base-sf.loc}/mx4j/mx4j-2.1.0.zip junit.loc=${base-sf.loc}/junit/junit3.8.1.zip struts.loc=${base-struts.loc}/binaries/struts-1.2.6.tar.gz jaxen.loc=${base-sf.loc}/jaxen/jaxen-1.0-FCS.tar.gz saxpath.loc=${base-sf.loc}/saxpath/saxpath-1.0.tar.gz --On Sunday, May 02, 2004 6:01 PM +0200 Bedrijven.nl [EMAIL PROTECTED] wrote: java.lang.NoSuchMethodError: org.apache.commons.logging.LogFactory.release(Ljava /lang/ClassLoader;)V - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: startup script not working
From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: RE: startup script not working ok..the errors are away by commenting out. You really can't comment those lines out. As I said before, you must use the proper JRE/JDK or the Compat.zip package. No shortcuts here. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: EJB
On Wed, 2 Mar 2005 19:23:19 +0300 Bogomolov Sergey [EMAIL PROTECTED] wrote: Dear Friends, please tell me, whether server TomCat with EJB is able to work no : Tomcat is a servlet container. For EJBs, you can use full J2EE servers like JBoss, JOnAS, WebSphere, WebLogic, ... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Multiple instances
On 02.03.2005 16:13, Caldarale, Charles R wrote: From: Bedrijven.nl [mailto:[EMAIL PROTECTED] Subject: Multiple instances Please don't hijack existing e-mail threads; if you have a new question, start a new message. I don't see that the OP has hijacked any existing thread (which seems to be the exeption, not the rule, lately). Regards mks - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SV: Cluster: will session listeners got called again after replication?
listeners will not be invoked on a state transfer, as it is not considered an event. when a new member joins the cluster, it requests a state transfer from one of the other members. Joseph Lam wrote: I have it turned on already. But seems that after a node is killed and then started up again, even though it can pick up the sessions from the other nodes, my HttpSessionBindingListener and HttpSessionListener were not called at all during the replication. Joseph On Fri, 25 Feb 2005, Filip Hanik - Dev Lists wrote: there is a flag you can set so that listeners don't get called, its optional its called notifyListenersOnReplication, see server.xml for example, default is true Filip Jesper Ekberg wrote: Hello! My first mail to this list. :) I have read it for a long time tho. We have a tried to cluster 3 Tomcat 5.5.7 machines and I found that HttpSessionBindingListener will be notified when the session is replicated and the machine crashes. I think this must be a bug?? The scenario: 3 Tomcat 5.5.7 machines on Windows 2003 Server (I know, not my fault ;)). JK2 Connector for load balancing. I log on and session is created and is replicated correctly to all machines. I shut down the server that I'm working on. The session is destroyed and method valueUnbound is called on the crashed machine. It seems odd to me that the method valueUnbound is called when the session is replicated, the session still lives on the other Tomcat machines. Sorry for my sometimes bad English ;) //Jesper -Ursprungligt meddelande- Från: Joseph Lam [mailto:[EMAIL PROTECTED] Skickat: den 24 februari 2005 08:44 Till: Tomcat Users List Ämne: Cluster: will session listeners got called again after replication? Anyone knows when a session is replicated to other nodes, will the HttpSessionBindingListener and HttpSessionAttributeListener objects be notified again? On the receiver nodes, how can I detect when a session from the sender node comes in so that I can do something with it? Joseph - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat runtime configuration changes
Hi *, We have read some docs, but so far we haven't found any solution for our problem. If it's mentioned in the doc, and we missed it, sorry. Just say us where we can find it :-) 1. Is it possible to switch off connectors or services while tomcat is running? If not, is there anything to remove a service from the config, and force tomcat to reread the configuration - not with the admin application, but by e.g. a command line interface or by writing our own application and using some API? (which one?) Btw, are there any docs available for the admin application? 2. Can we stop and start web apps manually - again, not by using any web app, but with a command line or by using an API? 3. Is it possible to deploy several web apps into tomcat, and configuring that tomcat only starts up one specific web app? The other web apps should not be available, until we start it up manually - even if requests are coming in. Any help is greatly appreciated, Thanks in advance, Ciao Christian smime.p7s Description: S/MIME cryptographic signature
RE: [OT] Multiple instances
From: Markus Schönhaber [mailto:[EMAIL PROTECTED] Subject: Re: Multiple instances I don't see that the OP has hijacked any existing thread (which seems to be the exeption, not the rule, lately). IIRC, the original post contained a completely unrelated message from Sng Wee Jim at the bottom. There is something a bit odd going on, though: the archive at marc.theaimsgroup.com doesn't seem to have the beginning of the thread we're currently in ... - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat on Windows 2003 server
Can anyone tell me if Tomcat 5.0.2x runs reliably on Windows 2003 server? If so, what are the minimum system requirements? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to approximate tomcat-5.0/4.x/3.x logging in 5.5?
On Wed, 2 Mar 2005 11:09:56 -0600, Jacob Kjome [EMAIL PROTECTED] wrote: Quoting Adrian Robert [EMAIL PROTECTED]: exists. This would continue to make Tomcat-5.5 more involved in logging than it should, though. I think Yoav Shapira has it right when he says that Tomcat should not really be directly involved in logging, but use the external implementation. I'm not sure what the solution is. Probably needs more discussion. That's the idea. Logging services should be external, rather than proprietary to Tomcat. the problem comes that we need some kind of defaults (like the current one, which is use whatever java.util.logging defaults are configured). Hmm.. I'm using log4j-1.2.9. I had the jar in both places but wasn't getting the isolation since my webapp was still pumping things into tomcat.log according to the container's log4j.properties.. However, I'm creating the logger in a static block in one of my webapp's classes -- could that have been the issue? Do you have webapp libraries sitting in a shared classloader such as shared/lib or common/lib? That would do it. 1. Make sure all your application classes are in WEB-INF/lib or WEB-INF/classes 2. Make sure log4j.jar is in WEB-INF/lib (remove commons-logging.jar if it is there. If you don't specifically need it, it can, and will, cause problems for you) 3. Make sure log4j.jar and commons-logging.jar (not commons-logging-api.jar!!!) are in common/lib 4. Make sure you have log4j.properties in both common/classes and WEB-INF/classes. You might even want to switch to using a log4j.xml config file for your webapp just to be sure that you aren't picking another log4j.xml file improperly distributed in a jar file. If you do all the above, logging should work as you expect. Note that for ServletContext.log() statements to go to context-specific files, you will still have to define the loggers as detailed in the example log4j.properties that I sent in my previous email. It's a bit tricky sometimes. For example, getting the container logger a bit too early, when the context CL isn't set to the webapp CL (it doesn't exist yet) can get you a logger based on the main configuration. That's an issue with the current CVS code, but I think it should be ok with the version used here (although it's tough to be 100% sure). -- x Rémy Maucherat Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat on Windows 2003 server
We have it running on Win2K3 w/ IIS 6, so I imagine the requirements are about the same as Win2K3 (if only b/c you intend to run Tomcat on Win2K3), that is, if you can run Win2K3 reliably, then adding Tomcat (and JDK 1.5) isn't going to be much of an issue...having extra RAM can never hurt, but if you're running a server, that also shouldn't be an issue. Thanks, -Matt On Wed, 2 Mar 2005 [EMAIL PROTECTED] wrote: Can anyone tell me if Tomcat 5.0.2x runs reliably on Windows 2003 server? If so, what are the minimum system requirements? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Matthew Kozak Rutgers University-Camden [EMAIL PROTECTED] ** They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety. -Ben Franklin ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Re: Tomcat on Windows 2003 server
I appreciate the response. Have a good day. Ron From: Matt [EMAIL PROTECTED] Date: 2005/03/02 Wed PM 01:08:17 CST To: Tomcat Users List tomcat-user@jakarta.apache.org Subject: Re: Tomcat on Windows 2003 server We have it running on Win2K3 w/ IIS 6, so I imagine the requirements are about the same as Win2K3 (if only b/c you intend to run Tomcat on Win2K3), that is, if you can run Win2K3 reliably, then adding Tomcat (and JDK 1.5) isn't going to be much of an issue...having extra RAM can never hurt, but if you're running a server, that also shouldn't be an issue. Thanks, -Matt On Wed, 2 Mar 2005 [EMAIL PROTECTED] wrote: Can anyone tell me if Tomcat 5.0.2x runs reliably on Windows 2003 server? If so, what are the minimum system requirements? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Matthew Kozak Rutgers University-Camden [EMAIL PROTECTED] ** They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety. -Ben Franklin ** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jk2 problem
It seems as though my jk2 configuration isn't failing over properly. If a tomcat machine drops, it compensates properly. However, if a single application on one of the tomcat machines fails then apache/jk2 keeps that faulty app in the mix. When a user gets directed to a tomcat instance where the app is working, all is fine. However, jk2 still continues to route requests to the machine where the app is broken or missing.. is there something I can do to fix this? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unexplained message in mod_jk.log
Richard Russell wrote: [Wed Mar 02 12:09:09 2005] [info] jk_handler::mod_jk.c (1691): Service returned error=1 with status=200 for worker=ajp13 This is the client error, probably meaning that the client has closed the connection before sending all the data expected. (like setting content-length and no data send). This is a new log message added to 1.2.8, so... Nothing to worry about :) Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Include other contexts
It is me ... I wasn't calling the other context rather just a resource within the context Peter Johnson wrote: Ok, I gave this a test run, so from app1 I called req.getRequestDispatcher(/app2).include(req,res); However, it seems that doing this loops i.e. re-requests app1 rather than passing the request to app2. It this an error with Tomcat or a misunderstanding by me? PJ Peter Johnson wrote: it would seem to be as simple as req.getRequestDispatcher(newuri).include(req,res); PJ Peter Johnson wrote: Thanks for the quick reply QM ... I'd be writing both the parent and child apps. Basically the parent would act as a broker to the child apps and perform the decoration. I guess SiteMesh does a form of automated screen scraping. I would do this so that all child apps may have a common look-n-feel and there would be a global navigation. I will look into RequestDispatcher#include() as it sounds similar to what I'd be after. PJ QM wrote: On Wed, Mar 02, 2005 at 11:53:52AM +1100, Peter Johnson wrote: : I was just wondering if it was possible to pass a request to another : context within the same host and capture the output. If it is, any : suggestions on the best way to do so? You could make a URL call to the app (java.net.URL and other similar implementations). Either that, or RequestDispatcher#include() (Though something tells me that requires an in-context URL. Check the docs to be sure.) It sounds like you're screen scraping, though, in which case you'd be better off trying to find some common data format that app A and app B can share. (If, of course, you have some control or influence over App A.) If app A changes the format of the data (common with websites) then app B has to play catch-up with its parsing. : Basically, I am planning to use SiteMesh for site templating however : would prefer to deploy many of the apps as individual apps. So somehow I : would like to call another context and then have SiteMesh decorate the : response. Are you using this setup for branding, then, or something else? I may have some suggestions, but knowing your end-goal may help. -QM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Strange WAR file creation error
Hello, I am trying to create a WAR file of the following directoy: duglaDataModel/ duglaDataModel/DataController.as duglaDataModel/duglaDataModel.mxml duglaDataModel/Employee.as duglaDataModel/employees.xml duglaDataModel/locations.xml duglaDataModel/WEB-INF/ duglaDataModel/WEB-INF/classes/ duglaDataModel/WEB-INF/web.xml So I cd to duglaDataModel and type: jar cvf c:\downloads\duglaDataModel .war . But this fails with and exception: added manifest adding: DataController.as(in = 958) (out= 452)(deflated 52%) adding: duglaDataModel.mxml(in = 2378) (out= 637)(deflated 73%) adding: Employee.as(in = 391) (out= 210)(deflated 46%) adding: employees.xml(in = 468) (out= 154)(deflated 67%) adding: locations.xml(in = 225) (out= 80)(deflated 64%) adding: WEB-INF/(in = 0) (out= 0)(stored 0%) adding: WEB-INF/classes/(in = 0) (out= 0)(stored 0%) adding: WEB-INF/web.xmljava.util.zip.ZipException: attempt to write past end of STORED entry at java.util.zip.ZipOutputStream.write(ZipOutputStream.java:264) at sun.tools.jar.Main.addFile(Main.java:614) at sun.tools.jar.Main.create(Main.java:412) at sun.tools.jar.Main.run(Main.java:142) at sun.tools.jar.Main.main(Main.java:903) Why? Note, as far as I can tell the directory is just fine since I can copy it into webapps and the application works. I just can't WAR'ize the directory. Any ideas? Thanks, Douglass Turner email: douglass_dot_turner_at_gmail_dot_com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
5.5.7 Filter Issue
Hi all, I am including another context's servlet output however the filter that should be applied isn't. e.g. seems to be doing context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | --| rather than context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | ---Filter -- Servlet | Any ideas? PJ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 5.5.7 Filter Issue
Correction it is doing context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | -- Servlet | Peter Johnson wrote: Hi all, I am including another context's servlet output however the filter that should be applied isn't. e.g. seems to be doing context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | --| rather than context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | ---Filter -- Servlet | Any ideas? PJ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Write file to browser tomcat error
Hi, I am using the code below in a jsp to write a jar file to the browser so that user can download it. However, after the user hit download to save the file, the tomcat server display an error caused by flushing the buffer. Does anyone know why it happens? Thank you for your help --- try{ String disHeader = Attachment;Filename=\ + jarName +\; response.setHeader(Content-Disposition, disHeader); response.setContentType(APPLICATION/OCTET-STREAM); FileInputStream fileInputStream = new FileInputStream(jarFile); int i; while ((i=fileInputStream.read())!=-1) { out.write(i); } fileInputStream.close(); out.close(); //This line gives the problem } catch(Exception e) // file IO errors { System.out.println(# file error); e.printStackTrace(); } error: org.apache.jasper.runtime.PageContext: Internal error flushing the buffer in release() - Celebrate Yahoo!'s 10th Birthday! Yahoo! Netrospective: 100 Moments of the Web
Looking for Java programmers
I am looking for 1-2 mid level Java programmers for a job in Marina Del Rey,California. The operating system we use is Linux, the web servers Tomcat/Apache and programming language Java, Python, Jython, Perl, PHP. Network and Linux knowledge a definite plus. There is a lot of potential for growth, and learning in our company. Only interested candidates need to apply, no third parties please. Resumes (zipped docs only) accepted only by email, please do not call. -- Manish Poddar Development Team Manager - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Looking for Java programmers
test - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Looking for Java programmers
I'll send you my resume Saturday, I'm on vacation. -Original Message- From: Manish Poddar [EMAIL PROTECTED] Sent: Mar 2, 2005 2:59 PM To: Tomcat Users List tomcat-user@jakarta.apache.org Subject: Looking for Java programmers I am looking for 1-2 mid level Java programmers for a job in Marina Del Rey,California. The operating system we use is Linux, the web servers Tomcat/Apache and programming language Java, Python, Jython, Perl, PHP. Network and Linux knowledge a definite plus. There is a lot of potential for growth, and learning in our company. Only interested candidates need to apply, no third parties please. Resumes (zipped docs only) accepted only by email, please do not call. -- Manish Poddar Development Team Manager - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Looking for Java programmers
Sounds like an exciting vacation...monitoring the Tomcat User List... -Original Message- From: John Najarian [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 02, 2005 3:51 PM To: Tomcat Users List Subject: Re: Looking for Java programmers I'll send you my resume Saturday, I'm on vacation. -Original Message- From: Manish Poddar [EMAIL PROTECTED] Sent: Mar 2, 2005 2:59 PM To: Tomcat Users List tomcat-user@jakarta.apache.org Subject: Looking for Java programmers I am looking for 1-2 mid level Java programmers for a job in Marina Del Rey,California. The operating system we use is Linux, the web servers Tomcat/Apache and programming language Java, Python, Jython, Perl, PHP. Network and Linux knowledge a definite plus. There is a lot of potential for growth, and learning in our company. Only interested candidates need to apply, no third parties please. Resumes (zipped docs only) accepted only by email, please do not call. -- Manish Poddar Development Team Manager - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Keep Alive
I am using Tomcat as my web server. I am using AXIS for SOAP. I notice via ethereal that the are a lot of port opening from the client side for the HTTP (SOAP) requests. I would like to keep the socket open for the client. How do I make the tomcat server keep the socket open? Is there a setting in the server configuration that can do this? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: realm configuration
thanks for your suggestions, I started to dig around in the code, and also looked at a jaas login module from jboss. the jboss solution is to have a login module that takes two parameters (queries) 1) to return credentials for a username 2) to return the rolenames for a username this is exactly what JDBCRealm and DataSourceRealm do except they construct the query Strings from parameters StringBuffer sb = new StringBuffer(SELECT ); sb.append(userCredCol); sb.append( FROM ); sb.append(userTable); sb.append( WHERE ); sb.append(userNameCol); sb.append( = ?); preparedCredentials = dbConnection.prepareStatement(sb.toString()); StringBuffer sb = new StringBuffer(SELECT ); sb.append(roleNameCol); sb.append( FROM ); sb.append(userRoleTable); sb.append( WHERE ); sb.append(userNameCol); sb.append( = ?); preparedRoles = dbConnection.prepareStatement(sb.toString()); Unfortunately the methods that construct these strings are private so I can't simply override them. I have hacked around with the code and produced my own security realm class that works. My solution takes the following config parameters: credentialsQuery=SELECT password FROM User WHERE emailAddress =? rolesQuery=SELECT name FROM Role r, User u, user_roles ur WHERE u.id = ur.user_id AND r.id = ur.role_id AND u.emailAddress = ? I think with a bit of refactoring the existing DB realm classes would support this enabling any db structure (without the need for a view). cheers Nathan Nathan Coast wrote: Hi, I have the following db structure for my user / role tables: User User-Role Role -- --- -- id -- user_id usernamerold_id --- id passwordrolename Is there a realm implementation that support this structure? AFAICT, the JDBC and DataSourceRealm classes require the following structure: User User-Role -- --- username -- username passwordrole_name cheers Nathan -- Nathan Coast Managing Director Codeczar Ltd mob : (852) 9049 5581 tel : (852) 2834 8733 fax : (852) 2834 8755 web : http://www.codeczar.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
I can´t make work my servlet
Title: Mensaje Hi, everyone I´ve a serius problem to call the servlet. This is my first implementation, and I cannot make the servlet work. I send you the code (ziped), it´s very simple, but I don´t know if the web.xml is well done. Thanks for everything Hernán D. Pezzano - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can we know when the Response is finished? or other solution.
Hi, In one of my page, when the page is loading -- it is a page with large ammount of data from database, I clicked a button. I see the exception on the monitor window: Connection reset by peer: socket write error. The detal error is attached. This message might be harmless. I think it is because the response has not finished the task. Is there a way to know the response is finished and the socket is idle? Anybody has some suggestion? Any setting in tomcat? Thanks. Mar 2, 2005 5:09:11 PM org.apache.jk.server.JkCoyoteHandler action SEVERE: Error in action code java.net.SocketException: Connection reset by peer: socket write error at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:489) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:697) at org.apache.jk.server.JkCoyoteHandler.action(JkCoyoteHandler.java:487) at org.apache.coyote.Response.action(Response.java:226) at org.apache.coyote.Response.finish(Response.java:348) at org.apache.coyote.tomcat5.OutputBuffer.close(OutputBuffer.java:328) at org.apache.coyote.tomcat5.CoyoteResponse.finishResponse(CoyoteResponse.java: 497) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:209) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:339) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:415) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:716) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:650) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:829) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav a:688) at java.lang.Thread.run(Thread.java:534) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Stream closed errors from JSP tags under load
We have a Struts based application deployed on JBoss 3.2.6 (Uses Tomcat 5.0.28). In our production environment under load the servers throw Stream closed errors and after that the servers do not work and forced to restart. We have not seen this problem in test regions where the load is lower. We have tried disabling tag pooling in Tomcat, but that does not seem to help fix the problems. Does any one else have similar issues in production environment? Any help in this matter is greatly appreciated. The server encountered an internal error () that prevented it from fulfilling this request. exception java.io.IOException: Stream closed org.apache.jasper.runtime.BodyContentImpl.ensureOpen(BodyContentImpl.java:576) org.apache.jasper.runtime.BodyContentImpl.write(BodyContentImpl.java:140) org.apache.jasper.runtime.BodyContentImpl.write(BodyContentImpl.java:157) org.apache.jsp.protected_.security.AvailApplications_jsp._jspService(AvailApplications_jsp.java:210) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94) javax.servlet.http.HttpServlet.service(HttpServlet.java:810) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236) javax.servlet.http.HttpServlet.service(HttpServlet.java:810) org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069) org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455) com.citistreet.id.i401k.struts.util.PwebRequestProcessor.processForwardConfig(PwebRequestProcessor.java:96) org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279) org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482) citistreet.id.struts.action.AbstractController.process(AbstractController.java:141) com.citistreet.id.i401k.struts.action.Controller.process(Controller.java:142) org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507) javax.servlet.http.HttpServlet.service(HttpServlet.java:697) citistreet.id.struts.action.AbstractController.service(AbstractController.java:108) com.citistreet.id.i401k.struts.action.Controller.service(Controller.java:118) javax.servlet.http.HttpServlet.service(HttpServlet.java:810) citistreet.id.servlet.filter.AbstractFilter.doFilter(AbstractFilter.java:79) citistreet.id.servlet.filter.AbstractFilter.doFilter(AbstractFilter.java:79) com.citistreet.id.i401k.servlet.filter.TimingFilter.doFilter(TimingFilter.java:54) org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75) Thanks Purush __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: jspISAPI solution?
JspIsapi is good but I don't know if they have already fixed some old issues before. 1. Like request.getRemoteUser(), where it fails to yield values on other browsers othen than IE. 2. Have problems on windows xp clients. hangs. please confirm these issues to their tech support akash kava's hotmail messenger. before akash told me that they're planning to make tomcat plugins to IIS. regards aris I've created a new thread, just in case this got lost in the shuffle... Does anyone know anything about the below solution (+ or -) and/or recommend (or not recommend) it? Thanks, -Matt On Mon, 28 Feb 2005, Matt wrote: Something else you may want to look into (and I'd LOVE to hear feedback on from this list?) is the following: http://jspisapi.neurospeech.com/ We are now using this on our production IIS 6 server, mostly due to the conflciting, or at least the lack of concise and authoratative, docs out there (and mostly due to timing - this needed to be setup ASAP for a professor). I don't directly maintain the IIS 6 server, and its admin got antsy waiting for us to iron-out the confugration issues (and dreading future changes taking as much effort, like SSL support) with Tomcat and went with this instead ($50). Was this wise? Anyone? I'm curious (and not in front of this system now either) if it uses jk2 or jk and what version, and anything else it may be doing. Thanks, -Matt On Mon, 28 Feb 2005, Fadil wrote: Thanks a lot I'll test this ASAP. Unfortunately, I must setup IIS6 / Tomcat because it's my production environement and I've no choice : I don't want to learn dotnet !! I'm a beginner J2EE developper. [snip] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Only a type can be imported. com.mycompany.InputAttributes resolves to a package
Every once in a while when I am compiling JSPs I get this error: type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: Unable to compile class for JSP Generated servlet error: Only a type can be imported. com.mycompany.InputAttributes resolves to a package No new imports have been added to the JSP file (only minor text changes) and the exact same classes were imported correctly in the previous compilation. The only thing that clears this up is a restart of tomcat (version 5.5 on Solaris-SPARC). Has anyone else seen this behaviour? How can it be stopped? Thanks, August - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unable to initialize TldLocationsCache: no !/ in spec
Ok, I've searched the archives and Googled for this, but I can't find the answer. If I create a page with the following at the top: %@ taglib prefix=c uri=http://java.sun.com/jsp/jstl/core; % and save it in the root of my web site, it executes just fine. If I create a subdirectory and have the exact same line (or any taglib directive), I get the following error: org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: no !/ in spec org.apache.jasper.compiler.TldLocationsCache.init(TldLocationsCache.java :248) org.apache.jasper.compiler.TldLocationsCache.getLocation(TldLocationsCac he.java:219) org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationCon text.java:475) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:417) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1539) org.apache.jasper.compiler.Parser.parse(Parser.java:126) org.apache.jasper.compiler.ParserController.doParse(ParserController.jav a:220) org.apache.jasper.compiler.ParserController.parse(ParserController.java: 101) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:203) org.apache.jasper.compiler.Compiler.compile(Compiler.java:461) org.apache.jasper.compiler.Compiler.compile(Compiler.java:442) org.apache.jasper.compiler.Compiler.compile(Compiler.java:430) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.ja va:511) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja va:274) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java: 292) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236) javax.servlet.http.HttpServlet.service(HttpServlet.java:810) What am I doing wrong? I'm using Tomcat 5.0.25 on Mac OS X. I do have other sites setup the exact same way on the same machine and I can create files in subdirectories without a problem. I can't think of anything that I did different with this setup. What other information could I provide that would be useful? I really appreciate any advice. Thanks! Derek - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Socket level communications from within Tomcat?
Is it possible to start a socket server from code called by Tomcat? Specifically, is it possible to run the server side of RMI communication from code called by ServletContainerListener.contextInitialized()? I seem to recall that an old version of Tomcat did not allow this. Is this still true of Tomcat 5.*? I believe this issue is documented, but I can't find it. Thanks, bw - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to send hidden variables to next page
Thanks to everyone for the response. My problem solved. I could able to find help by googling and my table issue has been solved. Thanks again. --- U K Laxmi [EMAIL PROTECTED] wrote: Thanks David for the reply. Yes i could able to submit using javascript. Usually i use submit button. If submit button not available, i'm using javascript submit as mentioned by the syntax. Table problem, still finding ways to do it. Going thro' tutorials on HTML. --- David da Guia Carvalho [EMAIL PROTECTED] wrote: I dont know but looks like you are doing somethings wrong... hidden fildes are a great choice... better them use GET method... About the table think... use Iframe and do a submit to it... Whem you submit you use normal submit button or javascript??? If you are submiting with normal button try to use Javascript is much better! Example: !-- AT HEADER -- script language=javascript function submitform() { // FOR LOCAL FORM... where the form name is myform document.myform.submit(); //OR FOR IFRAME FORM... where the IFRAME name is myframe and the FORM name is myform1 window.frames.myframe.document.myform1.submit(); } /script !-- AT BODY The link to submit: -- A HREF=javascript: submitform()SUBMIT HERE!!!/A You can also make MANY variations on it... like pass values in the function from the external frame to a filed on iframe. Example: !-- AT HEADER -- script language=javascript function submitform(val1) { //CHANGE THE VALUE OF A FIELD ON IFRAME... where myfield is the name of the filed... window.frames.myframe.document.myform1.myfield.value=val1; //FOR IFRAME FORM... where the IFRAME name is myframe and the FORM name is myform1 window.frames.myframe.document.myform1.submit(); } /script !-- AT BODY -- A HREF=javascript: submitform(VALUEOFF1)SUBMIT HERE/A I make some dynamic tables based on users choies! Works very well. Best Regards, -- David da Guia Carvalho Animus Tecnologia da Informação Tel.: (21) 3525-8800 Fax: (21) 3525-8801 http://www.animus-ti.com.br On Feb 25, 2005 03:44 AM, U K Laxmi [EMAIL PROTECTED] wrote: Thanks David for the info. Sure to do some reading. I could able to pass the hidden variables to next page. It's just i'm using one hidden variable named 'package' which was doing all the problem. I just changed it to something else and now it's working. Still table issue not solved. I'm gooling ... for the solution. --- David Smith [EMAIL PROTECTED] wrote: This is getting into territory where you'd be better off doing some googling or buying a good javascript cookbook. I havn't bought any of those books recently although I've had good experience with subjects from Wrox Publishing and O'Reilly Associates in the past. Visit Amazon. They even support a rating scheme where people can voice their opinion. On the Delete issue, you could do a server-side rewrite of a link that invokes an action to delete a row as in: a href=http://localhost:8080/mywebapp/deleteRow.do?recordNum=10;Delete Me/a That's just a basic GET form request. Again, find a good book, do some reading. --David U K Laxmi wrote: Thanks David for the solution. To be frank, i really don't know how to code it. Will you give a sample code snippet? I'm using apache2, tomcat 5.5.7 on Win 2K machine. One more problem. I've a form and also submit button. I've number of text fields in it. On entering some data and focus losts from that field, i call a javascript function, i set number of hidden values and call a JSP using location.href of Javascript. But hidden values are not getting passed to jsp.I'm getting null. Why? How to overcome this? Pls help. One more requirement what i've is: i'VE A FORM WITH FORM ELEMENTS IN IT AND A 'aDD' BUTTON. After filling theform, if the user clicks on 'Add' button, the contents gets added aas row into a HTML table located below that form. That way user can add n number of rows to the bottom table. In the table, i need a 'Delete' button. After selecting any row, if the user clicks on 'Delete' button, it should get deleted from the table. I guess it can be possible. But it's a big challenge to me as i know only ABCD of HTML Javascript. If anybody can direct me to a good HTML/Javascritp forum also fine. If i get a solution directly, it's wonderful. Thanks a lot. Sorry again if it's not the right place to post this. --- David Smith [EMAIL PROTECTED] wrote: === message truncated === __ Celebrate Yahoo!'s 10th Birthday! Yahoo! Netrospective: 100 Moments of
display my index.jsp as default
I have placed my directory under %catalina_home%/webapps/ now i want to configure tomcat to display my index.jsp page by entering only http://localhost:8080/; what changes should i make. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
How do I configure the Tomcat admin app to read and write a JDBCRealm user database?
Not so new Tomcat user here, but looking to learn more about what is going in there and what I can make it do for me! I have configured server.xml in tomcat to read users, groups, and roles using mysql easily and successfully. Now I would like to edit these tables from tomcat as well - seems like the admin tool is the ideal place to do this - 'cept it seems to only work with xml text files. Is there a document explaining how to go about this? Is it possible? THANKS - Yossie - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: Tomcat on Windows 2003 server
We have 3 Tomcat instances on 3 different machines and all machines have Windows 2003 Server. This works fine. Each machine have 2048MB RAM and one 3Ghz CPU. I don't know the minimum system requirements. -Ursprungligt meddelande- Från: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Skickat: den 2 mars 2005 19:41 Till: tomcat-user@jakarta.apache.org Ämne: Tomcat on Windows 2003 server Can anyone tell me if Tomcat 5.0.2x runs reliably on Windows 2003 server? If so, what are the minimum system requirements? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 5.5.7 Filter Issue
After some further logging within the filter it would appear that the following is happening context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | |---Filter -- Servlet ---| |-Filter -- Servlet -- Servlet ---| --- Filter -- Servlet ---| However, after the response if filtered the first time it isn't applied again on the second round so hence it would appear not to be being applied. Can't see why it is doing a second round though. Peter Johnson wrote: Correction it is doing context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | -- Servlet | Peter Johnson wrote: Hi all, I am including another context's servlet output however the filter that should be applied isn't. e.g. seems to be doing context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | --| rather than context1 context2 |--| |--| -- Filter -- Servlet -- Servlet | ---Filter -- Servlet | Any ideas? PJ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]