add cfsetting debug="true|false"

Description

we can turn off debugging output
https://docs.lucee.org/reference/tags/setting.html#attribute-showdebugoutput

we can turn off logging for a section of a page

https://docs.lucee.org/reference/tags/processingdirective.html#attribute-executionlog

we can detect debug mode
https://docs.lucee.org/reference/functions/isdebugmode.html

but we can't disable saving a debug log, per request.

  • useful not to record logs from bots

  • long processing which may generate very large debug logs, which may sit around in memory

  • programatically decide which debug logs to save (i.e per session, or user etc)

Environment

None

Activity

Show:
Zac Spitzer
September 17, 2020, 2:57 PM

getPageContext().getDebugger().reset(); // clear logs

Zac Spitzer
4 days ago

this is easy enough to do, the code calls config all the time

pageContext.getConfig().debug()

the solution is to add a local boolean debug to pageContext, add a debug() to pageContext and change all the config.debug() to call pageContext.debug() instead

Assignee

Unassigned

Reporter

Zac Spitzer

Priority

New

Labels

Fix versions

None

Affects versions

Configure