Uploaded image for project: 'StoRM'
  1. StoRM
  2. STOR-1510

Storage space info creation timestamp must not be overwritten during UPDATE queries

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 1.11.22
    • 1.11.21
    • backend
    • Security Level: Public (Visbile by non-authn users.)
    • None

      Updates to storage space info table are done with queries that involve also the CREATED field which shouldn't involved. This generates some not consistent values stored on database. For example, after a bootstrap with an empty table, this is the status of the table:

      MariaDB [storm_be_ISAM]> select CREATED from storage_space;
      +---------------------+
      | CREATED             |
      +---------------------+
      | 2022-01-13 18:10:05 |
      | 2022-01-13 19:10:05 |
      | 2022-01-13 18:10:05 |
      | 2022-01-13 18:10:05 |
      | 2022-01-13 19:10:05 |
      | 2022-01-13 19:10:05 |
      | 2022-01-13 18:10:05 |
      +---------------------+
      

      This probably happens because records are created at boot and as soon as the first round of du gets its results, the records are updated involving the CREATED field. Try to fix this removing CREATED from the UPDATE query.

            vianello Enrico Vianello
            vianello Enrico Vianello
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: