On 3/20/2013 7:39 AM, Toke Eskildsen wrote:
On Wed, 2013-03-20 at 01:52 +0100, Jan Høydahl wrote:
By default the query logs could end up in ${solr.data.dir} with name
<core>-querylog-YYMMDD.log and auto rotate daily. For back compat
there should be a way to continue logging queries through slf4j as
today, but that should be off by default.

What is gained by logging queries outside of the standard logging
framework? Wouldn't it be better to create a logger with an agreed-upon
name, such as "queries" or "interaction"?

When I review logs to see queries and Solr's response, I generally want to see those queries in context with the other INFO logs. The only way I can imagine that a separate query log would be useful is if each full query logged had a unique identifier and a log entry with that identifier were to go into the main log at INFO. This would not reduce the number of lines in the main log, but it might reduce the *size* of the main log.

Most of my queries are longer than the 1024 characters that jetty's request log can show, and therefore they take up a lot of space in the main log. That's one thing in favor of separating them, but I would require the ability to map them back to their relative position in the main log.

A "best of everything" approach would be to let the admin decide whether they want queries in the main log or in a query log. If they want them separate, there should be an option to use unique identifiers to link the two logs.


Finding the right balance for WARN, INFO, and DEBUG is a tricky problem, and different people will have different opinions about what goes where.

It's been my experience that when I put the level at WARN, very little gets logged outside of exceptions for client timeouts and malformed queries. Is this a good thing, or an indication that the warn level is not used enough?

I have the sense that when I choose between INFO and WARN, I'm basically choosing between logging and not logging. The shift should be more gradual than that. It could be that my Solr install is just running so well that there's nothing to report at WARN, so ERROR is all I really get.

When I put it at INFO, it's extremely chatty. My main concern with INFO logging is that certain individual log entries are important, but display too much information. This is why I filed SOLR-4547.

There is probably some logging that's currently at INFO that should be moved to DEBUG, but I think that a lot of what's currently at INFO is useful. I would have to research more to say for sure. I have not looked into whether any of the DEBUG logging should be moved to TRACE.

Thanks,
Shawn


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to