Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-72077

moodle_read_slave_trait: additional debug logging

XMLWordPrintable

    • MOODLE_311_STABLE
    • MOODLE_500_STABLE
    • MDL-72077-ro-debug
    • Hide

      1. Add following to config.php

      $CFG->debug = 15;
      $CFG->debugdisplay = 1;
      $CFG->dboptions['readonly'] = [
          'instance' => ['host.that.is.not'],
          'connecttimeout' => 1
      ];

      2. Load Homepage in browser
      3. Confirm messages appear regarding db connection appear in error log

      Show
      1. Add following to config.php $CFG->debug = 15 ; $CFG->debugdisplay = 1 ; $CFG->dboptions[ 'readonly' ] = [     'instance' => [ 'host.that.is.not' ],     'connecttimeout' => 1 ]; 2. Load Homepage in browser 3. Confirm messages appear regarding db connection appear in error log
    • Hide

      Code verified against automated checks.

      Checked MDL-72077 using repository: https://github.com/catalyst/moodle

      More information about this report

      Built on: Mon 04 Nov 2024 09:46:41 PM UTC

      Show
      Code verified against automated checks. Checked MDL-72077 using repository: https://github.com/catalyst/moodle main (0 errors / 0 warnings) [branch: MDL-72077-ro-debug | CI Job ] More information about this report Built on: Mon 04 Nov 2024 09:46:41 PM UTC

      Under normal condition the dml layer should never emit any debugging, but if there are any issues with the switching of database connections to the replica then currently these are silent failures. We want to gracefully fall back to the primary connection and be silent to the end user but we still need to emit debugging so site admins have visibility of the problem.

      This patch add some debugging() to track success of readonly connections.

            x-iy David Adamson
            srdjan Srdjan Jankovic
            Peter Burnett Peter Burnett
            Jun Pataleta Jun Pataleta
            Kim Jared Lucas Kim Jared Lucas
            Votes:
            0 Vote for this issue
            Watchers:
            18 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 hour, 9 minutes
                1h 9m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.