-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Mark,
On 12/17/13, 6:27 AM, Mark Thomas wrote: > On 17/12/2013 11:16, Jose María Zaragoza wrote: >> 2013/12/17 André Warnier <a...@ice-sa.com>: >>> Hi. Without having any idea really of the precise mechanism >>> behind database connections, I can still imagine that with the >>> possibility of pooled connections to said database(s), it may >>> be difficult to detect such a change in the corresponding >>> context.xml and apply them "on the fly". Even more so if such >>> connections could be shared between different applications. >> >> >> Thanks, but I didn't said that I neeed to apply changes "on the >> fly". Indeed, I said "Restart the web application is not a >> problem" >> >> I only wan't to have to redeploy the web application to modify >> META-INF/context.xml and apply changes. > > How do you feel about a Tomcat upgrade? > > Automatic deployment has had a bit of an overhaul in Tomcat 8 and > those changes have been back-ported to 7.0.x for the next release. > The behaviour in a number of edge cases is now clearly defined: > http://ci.apache.org/projects/tomcat/tomcat8/docs/config/automatic-deployment.html > > In your case, you'd want to deploy as a WAR with unpackWARs set to > true. Then, any time you edit the META-INF/context.xml in the > unpacked directory the web application will be redeployed using the > new context.xml > > This might work with 6 but I can't remember (it is a long time > since I looked at the 6.0.x automatic deployment code). My experience has been that, specifically with JNDI resources, the resource is not touched during the reload procedure. So, for instance, if the JNDI name doesn't change but the URL does, the application does in fact require a re-deployment. Is that intentional behavior, or just a result of the implementation we happen to currently have? Is it reasonable to modify Tomcat such that the JNDI resource is disposed and re-built during an application reload? Of course, this would only make sense for resources defined in a webapp's Context/Resource, not for global resources. This would also make it possible to package JDBC drivers along with the web application and not cause ClassLoader pinning. If the above change were made, a redeployment would not be completely necessary, even if it does turn out to be the best solution. - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.15 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQIcBAEBCAAGBQJSswmdAAoJEBzwKT+lPKRYdDoP/06VSHikoitoKKIRG1tVdFne EBKJBF9VtZeHlOkPlCpbrYVOHEgmOs8cci3/0FbWhfooxIU7GwZfKO1Ry2vC/WD3 U/jNpzLqa67VU9iTBk8NYku2Bj0NPlVtEpdGgihZNKEN8Z6JyHuk0H/q0XuYs7/k BlKq/csPHaWNG607PKlPJlWuHgRKeh37iFXdzwB3//HeUP/b/vtF8iS9ZuqtKpTo VObyseuX8dat9VrAjxsh5A5w0Ly6M9y3JF2vb6rlf8+55jEN/xcMCELdUx4pPoEu RA4q4EhMNdkLBIn/AUuyCXTHF2kcVRH8dqhBH9AsU5XrZRzGS7r/BiRd3YfaKqqN aP8Te2JJSMrWZbJ3E2m+akv542+JSwXBtLMT+SvvWSQHLqWUkYcmPcIOd9Ht5ARQ FRV8TUUjJA8gNXBA1lUm0UJJxzzX2BsvidLWhos0FHN0/Rb5Guj+Tdp8iAJorPWb gOnjxJYWMyDz3xL7s9cBr8hRTcqI/eqzF2HGAr2vPqY//29P6329T4SKq3GZ1EIn qpy7Hej/kYP/edSkPAbi3Jhy0Hw88pLzKWek3DfxY3x8ABbUSUM+M1nCGBcuFGrJ LwwxQPgqh1uGvMGHU2CooZBE7wiajHAm7Nq9oIy6jm+Ho//tg+F1o9orgpzPTvsZ Vl7FApejtEzftQ4R5cRz =uYBw -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org