Context mapping and war
When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? My mapping looks like this: Context path=/mywebapp docBase=mywebapp debug=99 reloadable=true Resource name=jdbc/pmisDS auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/mywebappDS parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value50/value /parameter parameter namemaxIdle/name value5/value /parameter parameter namemaxWait/name value1/value /parameter parameter namelogAbandoned/name valuetrue/value /parameter parameter nameremoveAbandoned/name valuetrue/value /parameter parameter nameremoveAbandonedTimeout/name value60/value /parameter parameter nameusername/name valueuser/value /parameter parameter namepassword/name valuepass/value /parameter parameter namedriverClassName/name valuecom.jnetdirect.jsql.JSQLDriver/value /parameter parameter nameurl/name valuejdbc:JSQLConnect://mydb/database=name/value /parameter /ResourceParams /Context Any suggestions would be greatly appreciated. Thanks, Jesse
RE: Context mapping and war
I'm running Tomcat 4.1.30 When I try to hit the app, I get a 404. I believe this is known behavior for Tomcat 4 Is it different for Tomcat 5? Thanks, Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:43 AM To: Tomcat Users List Subject: RE: Context mapping and war Which version of Tomcat? I believe this is known behavior for Tomcat 4, if you define a context element pointing to a war fail. There should be no problem with functionality; can you verify? A War is not required to be extracted in order for it to load properly. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:42 AM To: [EMAIL PROTECTED] Subject: Context mapping and war When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? My mapping looks like this: Context path=/mywebapp docBase=mywebapp debug=99 reloadable=true Resource name=jdbc/pmisDS auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/mywebappDS parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value50/value /parameter parameter namemaxIdle/name value5/value /parameter parameter namemaxWait/name value1/value /parameter parameter namelogAbandoned/name valuetrue/value /parameter parameter nameremoveAbandoned/name valuetrue/value /parameter parameter nameremoveAbandonedTimeout/name value60/value /parameter parameter nameusername/name valueuser/value /parameter parameter namepassword/name valuepass/value /parameter parameter namedriverClassName/name valuecom.jnetdirect.jsql.JSQLDriver/value /parameter parameter nameurl/name valuejdbc:JSQLConnect://mydb/database=name/value /parameter /ResourceParams /Context Any suggestions would be greatly appreciated. Thanks, Jesse - 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: Context mapping and war
That works! There's no way to make it extract though? Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:53 AM To: Tomcat Users List Subject: RE: Context mapping and war Change you docbase to 'mywebapp.war' and retry. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:52 AM To: 'Tomcat Users List' Subject: RE: Context mapping and war I'm running Tomcat 4.1.30 When I try to hit the app, I get a 404. I believe this is known behavior for Tomcat 4 Is it different for Tomcat 5? Thanks, Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:43 AM To: Tomcat Users List Subject: RE: Context mapping and war Which version of Tomcat? I believe this is known behavior for Tomcat 4, if you define a context element pointing to a war fail. There should be no problem with functionality; can you verify? A War is not required to be extracted in order for it to load properly. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:42 AM To: [EMAIL PROTECTED] Subject: Context mapping and war When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? My mapping looks like this: Context path=/mywebapp docBase=mywebapp debug=99 reloadable=true Resource name=jdbc/pmisDS auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/mywebappDS parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value50/value /parameter parameter namemaxIdle/name value5/value /parameter parameter namemaxWait/name value1/value /parameter parameter namelogAbandoned/name valuetrue/value /parameter parameter nameremoveAbandoned/name valuetrue/value /parameter parameter nameremoveAbandonedTimeout/name value60/value /parameter parameter nameusername/name valueuser/value /parameter parameter namepassword/name valuepass/value /parameter parameter namedriverClassName/name valuecom.jnetdirect.jsql.JSQLDriver/value /parameter parameter nameurl/name valuejdbc:JSQLConnect://mydb/database=name/value /parameter /ResourceParams /Context Any suggestions would be greatly appreciated. Thanks, Jesse - 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]
RE: Context mapping and war
The app works fine running from the war, it's just sometimes we have to send a hotfix and it's easier for someone to be able to just drop a jsp or a class file in the directory. I'll take a look at TC5, we'd probably switch to that eventually anyway. Thanks, Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 10:24 AM To: Tomcat Users List Subject: RE: Context mapping and war Is there a need to? Unless your accessing files directly through the file system, it is not required... In TC5, you can add this context to your war, and it should expand (given the host configuration options defined). -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 10:14 AM To: 'Tomcat Users List' Subject: RE: Context mapping and war That works! There's no way to make it extract though? Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:53 AM To: Tomcat Users List Subject: RE: Context mapping and war Change you docbase to 'mywebapp.war' and retry. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:52 AM To: 'Tomcat Users List' Subject: RE: Context mapping and war I'm running Tomcat 4.1.30 When I try to hit the app, I get a 404. I believe this is known behavior for Tomcat 4 Is it different for Tomcat 5? Thanks, Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:43 AM To: Tomcat Users List Subject: RE: Context mapping and war Which version of Tomcat? I believe this is known behavior for Tomcat 4, if you define a context element pointing to a war fail. There should be no problem with functionality; can you verify? A War is not required to be extracted in order for it to load properly. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:42 AM To: [EMAIL PROTECTED] Subject: Context mapping and war When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? My mapping looks like this: Context path=/mywebapp docBase=mywebapp debug=99 reloadable=true Resource name=jdbc/pmisDS auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/mywebappDS parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value50/value /parameter parameter namemaxIdle/name value5/value /parameter parameter namemaxWait/name value1/value /parameter parameter namelogAbandoned/name valuetrue/value /parameter parameter nameremoveAbandoned/name valuetrue/value /parameter parameter nameremoveAbandonedTimeout/name value60/value /parameter parameter nameusername/name valueuser/value /parameter parameter namepassword/name valuepass/value /parameter parameter namedriverClassName/name valuecom.jnetdirect.jsql.JSQLDriver/value /parameter parameter nameurl/name valuejdbc:JSQLConnect://mydb/database=name/value /parameter /ResourceParams /Context Any suggestions would be greatly appreciated. Thanks, Jesse - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional
RE: Context mapping and war
So in TC5, the conext is part of the war file, and I don't need to do anything separate? All that info can be in the war file? Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 10:24 AM To: Tomcat Users List Subject: RE: Context mapping and war Is there a need to? Unless your accessing files directly through the file system, it is not required... In TC5, you can add this context to your war, and it should expand (given the host configuration options defined). -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 10:14 AM To: 'Tomcat Users List' Subject: RE: Context mapping and war That works! There's no way to make it extract though? Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:53 AM To: Tomcat Users List Subject: RE: Context mapping and war Change you docbase to 'mywebapp.war' and retry. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:52 AM To: 'Tomcat Users List' Subject: RE: Context mapping and war I'm running Tomcat 4.1.30 When I try to hit the app, I get a 404. I believe this is known behavior for Tomcat 4 Is it different for Tomcat 5? Thanks, Jesse -Original Message- From: D'Alessandro, Arthur [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:43 AM To: Tomcat Users List Subject: RE: Context mapping and war Which version of Tomcat? I believe this is known behavior for Tomcat 4, if you define a context element pointing to a war fail. There should be no problem with functionality; can you verify? A War is not required to be extracted in order for it to load properly. -Original Message- From: Jesse Vitrone [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 9:42 AM To: [EMAIL PROTECTED] Subject: Context mapping and war When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? My mapping looks like this: Context path=/mywebapp docBase=mywebapp debug=99 reloadable=true Resource name=jdbc/pmisDS auth=Container type=javax.sql.DataSource/ ResourceParams name=jdbc/mywebappDS parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value50/value /parameter parameter namemaxIdle/name value5/value /parameter parameter namemaxWait/name value1/value /parameter parameter namelogAbandoned/name valuetrue/value /parameter parameter nameremoveAbandoned/name valuetrue/value /parameter parameter nameremoveAbandonedTimeout/name value60/value /parameter parameter nameusername/name valueuser/value /parameter parameter namepassword/name valuepass/value /parameter parameter namedriverClassName/name valuecom.jnetdirect.jsql.JSQLDriver/value /parameter parameter nameurl/name valuejdbc:JSQLConnect://mydb/database=name/value /parameter /ResourceParams /Context Any suggestions would be greatly appreciated. Thanks, Jesse - 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
RE: Context mapping and war
Thanks, for now, I think I'm just going to set the docBase to be the war file. Jesse -Original Message- From: Chong Yu Meng [mailto:[EMAIL PROTECTED] Sent: Thursday, March 18, 2004 11:35 AM To: Tomcat Users List Subject: Re: Context mapping and war Jesse Vitrone wrote: When I try to install my application, I put the war file in the webapps directory, and in the server.xml I add a context mapping. When I start Tomcat, my war file isn't getting extracted. Unpack wars is set to true: Host name=localhost debug=0 appBase=webapps unpackWARs=true autoDeploy=true If I comment out my context, the war gets extracted, but I need the context mapping. Once the war is extracted, I can put the context mapping in and everything works fine. Any idea why my war isn't getting extracted when the mapping is in there? Here's what I think is the reason, but I may be wrong ... If you are deploying a WAR file, Tomcat doesn't need to know anything about it initially (that is, no context entry in server.xml). You just create a directory, drop the WAR package there and start Tomcat. The WAR file will get unpackaged. No entry will be added into server.xml though. If you add the context mapping before deploying the WAR file, Tomcat assumes that you know what you are doing and automatically expects a web application at the docBase location, not a WAR file. If it finds a WAR file, it will assume that there is an error (because it is not finding what it expects to find). Am I close ? Anyway, whatever the reason, I don't think switching to Tomcat 5 will change this behaviour. I've done a little testing with WAR packages -- though not extensively. -- We must respect the other fellow's religion, but only in the sense and to the extent that we respect his theory that his wife is beautiful and his children are smart. -- Henry Mencken ++ | Pascal Chong | | email: [EMAIL PROTECTED] | || | Please visit my site at : http://cymulacrum.net| | If you're using my documentation, please read the Terms and| | and Conditions at http://cymulacrum.net/terms.html | ++ - 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]