Kim van der Riet created QPID-6230:
--------------------------------------

             Summary: [linearstore] qpid-qls-analyze fails when analyzing empty 
journal
                 Key: QPID-6230
                 URL: https://issues.apache.org/jira/browse/QPID-6230
             Project: Qpid
          Issue Type: Bug
          Components: C++ Broker
            Reporter: Kim van der Riet
            Assignee: Kim van der Riet


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:
{noformat}
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'
{noformat}

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>}}




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to