Uploaded image for project: 'Qpid'
  1. Qpid
  2. QPID-6230

[linearstore] qpid-qls-analyze fails when analyzing empty journal

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.30
    • 0.31
    • C++ Broker
    • None

    Description

      If a new queue is created through QMF but never used, the store creates a queue directory and places an uninitialized journal file into it. If qpid-qls-analyze is used to look at this store, it fails with and error message:

      Traceback (most recent call last):
        File "/usr/bin/qpid-qls-analyze", line 109, in <module>
          M.run()
        File "/usr/bin/qpid-qls-analyze", line 97, in run
          self.jrnl_recovery_mgr.run()
        File "/usr/bin/qlslibs/anal.py", line 73, in run
          jrnl.recover(self.high_rid_counter)
        File "/usr/bin/qlslibs/anal.py", line 358, in recover
          self._check_alignment()
        File "/usr/bin/qlslibs/anal.py", line 423, in _check_alignment
          remaining_sblks = self.last_record_offset % qlslibs.utils.DEFAULT_SBLK_SIZE
      TypeError: unsupported operand type(s) for %: 'NoneType' and 'int'
      

      Thanks to Jitka Kocnova for finding this bug. Method to reproduce:

      Using a clean store:
      qpid-config add queue q --durable

      then stop the broker and analyze:
      qpid-qls-analyze --stats <store-path>

      Attachments

        Activity

          People

            kpvdr Kim van der Riet
            kpvdr Kim van der Riet
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: