MS RFC 28: Redesign of LOG/DEBUG output mechanisms

Daniel Morissette dmorissette at MAPGEARS.COM
Fri Jun 15 14:42:43 EDT 2007


Frank Warmerdam wrote:
> 
> I am somewhat conflicted about "DEBUG ON" not being enough to enable
> actual debug output.  I think it is unfortunately that this and the
> MS_ERRORFILE setting will be required.  I'd suggest that we should have
> MS_ERRORFILE default to "stderr" which is roughly the behavior now for
> msDebug() if built into the binaries.  But then we are likely to have a
> lot of error noise showing up in the logs that perhaps does not belong.
> 

I see your point, but then that could also be seen as a feature: if you 
unset MS_ERRORFILE then that disables debug output without having to 
walk through the whole mapfile to remove all DEBUG statements.

I'm flexible as long as we can agree on something that makes sense to 
the users and doesn't result in polluting the log files unexpectedly.

What do others think?

> 
> I would be happy to review the raster related msDebug() calls and set
> appropriate error levels.
> 

Noted.

BTW, it could also be interesting to catch GDAL's CPLDebug calls, 
perhaps if DEBUG >= 3 is set a the top-level in the mapfile or something 
like that? Unfortunately we have to rely on the map-level debug level 
for that since we cannot easily take advantage of the debug level set in 
each of the GDAL/OGR layers to handle output from CPLDebug.


> I assume that DEBUG=MSDEBUG will disappear from the version string, since
> debugging will always be compiled in?
> 

Correct. I'll add a note about that in the RFC (backwards 
incompatibilities).

Daniel
-- 
Daniel Morissette
http://www.mapgears.com/



More information about the mapserver-dev mailing list