As outlined in the parent issue, we need a D8 replacement for the D7 RulesLog class, which was a transient singleton object used to collect (in memory) Rules debug messages so they could be optionally rendered as a debug log on the screen and optionally forwarded to the core dblog, controlled by Rules system variables, for storage in the database.

Steps that need to be taken:

  1. Overhaul the Rules debug settings. #3102614: Change Rules configuration settings Assigned to: tr
  2. Create a logger (not logger channel) analogous to DbLog which will be used to store Rules debug logs in a data structure. This will be the replacement for the D7 RulesLog class. #3103439: Create RulesDebugLog logger to hold temporary debug logs Assigned to: tr
  3. Update RulesDebugLoggerChannel logger channel created by #3101194: Rename logger.channel.rules to logger.channel.rules_debug to use the new logger described above and to preprocess the variables supplied via log() so as to compute everything that needs to be stored for use in the on-screen log. #3103555: Update RulesDebugLoggerChannel Assigned to: tr
  4. Implement code to retrieve logs and build render array from logs. Port all theming code - theme functions, JavaScript and CSS that was used in D7 to render and provide style and actions to the on-screen debug log. Conditionally display debug logs on screen (if settings permit) and (if settings permit) forward them to the system dblog. #3104109: Implement rendering of debug logs to screen and database Assigned to: tr

Comments

TR created an issue. See original summary.

tr’s picture

Title: Implement conditional logging and on-screen rendering in RulesDebugLoggingChannel » [meta] Implement conditional logging and on-screen rendering in RulesDebugLoggingChannel
Assigned: Unassigned » tr
Issue summary: View changes

This is going to have to be done in a number of stages, as there are many parts to it. Correspondingly, I've updated the issue summary and turned this into a meta. I'm assigning this to myself since I've already done the work; I just have to polish it and post the patches.

tr’s picture

tr’s picture

tr’s picture

Issue summary: View changes

Consolidated last two steps because they have a lot of commonality and you can't do one without the other.

tr’s picture

Status: Active » Needs review

Switching this to "Needs review"

The only step left is in #3104109: Implement rendering of debug logs to screen and database. Please review that issue.

tr’s picture

tr’s picture

Status: Needs review » Fixed

#3104109: Implement rendering of debug logs to screen and database has been committed, so this meta is complete. If you find any problems with this please open a new issue as a follow-up.

jonathan1055’s picture

Good work. Thank you.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.