DateTool and locale setting
Christopher Schultz <[email protected]> Tue, 11 Feb 2014 19:59:41 -0500
| Newsgroups | gmane.comp.jakarta.velocity.user |
|---|---|
| Message-ID | <[email protected]> |
All, Umm... I probably should have noticed this long before today, but I just observed a problem with my configuration and I wanted to make sure that my (new) understanding of the DateTool is correct. So, I had DateTool configured to be an "application" level tool. That appears to have been a mistake. What I just observed is that the first user to trigger the creation of the DateTool tool ends up permanently-setting the locale for the tool to their preferred locale. Whoops. So the solution should be simply to change the "scope" of the tool from application to session, right? I should have realized that DateTool wasn't tied to the servlet API in any way, so sniffing the locale from the request (which is what I expected) is not really a possibility. Duh. Thanks, -chris
signature.asc
(application/pgp-signature, 924 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQIcBAEBCAAGBQJS+sd9AAoJEBzwKT+lPKRYxLoP/i8RY6rpaAKLrgjAga8TuFQU RFeNSLAUmC3Vn5wu6wxotmajmIr/c9vFYpG1CDx3eMXZ+2Ai6uJjuEiZEFoGgZu0 o3i3QsLjkGs342buDbgzTDjTC5yXmYOhEulxE51K9pwi+2ToUCbPsMiQ/H1s6D5E 5n+R12vv/jVTAPN8HQAMAmrbQs3Zb91uVU/JzUSHq9swEK+LwiBrmFhUokhISWui f1m/+NsUmg6QlKOnRBl7sSj/AUJi/q9+Y3eI/ekPMUk96wznjl44K0k/FdWexPP5 VhnQfvWN/0ooEvAosTbylbSWyOqFHKLVMMa1TS+s1OsI4gm8WdoZmwA0nTm9vhwn gWor4iimLf2+IulAE0J2NUdVMm6d+l9H0bGJJpT50oQP44Hr/V8EdPUVgMbLPSjP pyVZKMHInlNWY0Qs4tfmq6nsaGm1aFIN9dqIQdpnVuLcnm7rts3HHtvEp8EF7n4U DyxyL1w2YTMRzXk8a33rbTl17c/AD22367jWSO9kqw0fN4q729i0yF+HDuJjj1Ja 670afSaA7TMAbknxSd4Nyb3psm53xGp26Hhg67BYtu+DO6uEmTFtYnw4E92s1Eyz 9VQFzBXHKHpJX9HzI+9im6JnAIbXtUAXXQxdoY50S4lirAgeYcYksfRk3fn01rN3 6+W3ABEVXrtxtSfhJaqQ =5Edt -----END PGP SIGNATURE-----