What's That Noise?! [Ian Kallen's Weblog]

« Whiskers on Kittens | Main | hReview: Nobody... »

20060222 Wednesday February 22, 2006

Making Velocity Be Quiet About Resource Loading

I'd never dug into where velocity's annoying messages were coming from but I decided enough is enough already. These tiresome messages from velocity were showing up on every page load:

2006-02-22 12:08:02 StandardContext[/webapp] Velocity   [info] ResourceManager : found /path/to/resource.vm with loader org.apache.velocity.tools.view.servlet.WebappLoader
Such messages might be good for debugging your setup but once you're up and running, they're just obnoxious. They definitely weren't coming from the log4j.properties in the webapp. So I took a look at velocity's defaults. The logging properties that velocity ships with in velocity.properties concern display of stacktraces but the constant chatter in Tomcat's logs weren't in there either. So I unwrapped the velocity source and found it in org.apache.velocity.runtime.RuntimeConstants -- all I had to do is add this to velocity.properties and there was peace:
resource.manager.logwhenfound = false
Ah, much better!

They shoulda named that property resource.manager.cmon.feel.the.noise, seriously.

( Feb 22 2006, 12:40:20 PM PST ) Permalink


Comments:

Post a Comment:

Comments are closed for this entry.