Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-14679 META: DB layer 2.0
  3. MDL-22076

On database dispose() check/warn/drop any remaining temp tables...

    XMLWordPrintable

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0
    • Component/s: Database SQL/XMLDB
    • Labels:
      None
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE

      Description

      As far as not all DB handle temp tables in the same way, we have right not one moodle_temptables class applied to mysql/mssql/oracle to provide cross-db handing.

      The last point we need to cover is what happens with created temptables on moodle_database disposal, as far as not all DBs drop the remaining temp tables automatically (yes oracle temp tables are persistent).

      So, I'm:

      • moving the temptables stuff from mysql/mssql/oracle implementations to general moodle_database.
      • same for sql_generators stuff (move to parent class).
      • implement pgsql_temptables class (doing nothing but registering the created/dropped temptables).
      • modify moodle_database->dispose to call moodle_temptables->dispose()
      • temptables->dispose() will emit one error_log() and automatically drop any temp table if necessary

        Attachments

          Activity

            People

            • Assignee:
              stronk7 Eloy Lafuente (stronk7)
              Reporter:
              stronk7 Eloy Lafuente (stronk7)
              Tester:
              Nobody
              Participants:
              Component watchers:
              Jake Dallimore, Jun Pataleta
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                24/Nov/10