[ 
https://issues.apache.org/jira/browse/QPID-6551?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pavel Moravec closed QPID-6551.
-------------------------------

> [C++ broker]: linearstore raising JERR_LFCR_SEQNUMNOTFOUND after sending many 
> DTX transactions
> ----------------------------------------------------------------------------------------------
>
>                 Key: QPID-6551
>                 URL: https://issues.apache.org/jira/browse/QPID-6551
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Broker
>            Reporter: Pavel Moravec
>            Assignee: Pavel Moravec
>             Fix For: 0.33
>
>         Attachments: JERR_LFCR_SEQNUMNOTFOUND.patch
>
>
> Sending many DTX transactions (such that tpl journal requires >64k journal 
> files) causes a transaction fails with JERR_LFCR_SEQNUMNOTFOUND journal error:
> jexception 0x0500 LinearFileController::find() threw 
> JERR_LFCR_SEQNUMNOTFOUND: File sequence number not found (fileSeqNumber=0)
> Reproducer:
> nohup ./src/qpidd --load-module=src/linearstore.so --efp-file-size=32 
> --log-to-file=/tmp/qpidd.log &
> # the --efp-file-size parameter is just for faster reproducer
> ./src/tests/qpid-txtest --dtx=yes --check=no --init=yes --tx-count=10 
> --total-messages=1000 --size=1
> nohup ./src/tests/qpid-txtest --dtx=yes --check=no --init=no 
> --tx-count=200000 --size=1 &
> After a (longer) while, linearstore raises JERR_LFCR_SEQNUMNOTFOUND and 
> subsequently various other exceptions/errors.
> The root cause is:
> - qpid/linearstore/journal/txn_map.h declares uint16_t pfid_
> - but it needs to store file sequence number stored as uint64_t elsewhere
> - for 65536th journal file (of tpl journal), re-casting uint64_t to uint16_t 
> returns obvious zero
> - but there is no file number zero in the journal 
> Fix just being tested:
> $ svn diff
> Index: qpid/linearstore/journal/txn_map.cpp
> ===================================================================
> --- qpid/linearstore/journal/txn_map.cpp      (revision 1680527)
> +++ qpid/linearstore/journal/txn_map.cpp      (working copy)
> @@ -36,7 +36,7 @@
>  
>  txn_data_t::txn_data_t(const uint64_t rid,
>                         const uint64_t drid,
> -                       const uint16_t pfid,
> +                       const uint64_t pfid,
>                         const uint64_t foffs,
>                         const bool enq_flag,
>                         const bool tpc_flag,
> Index: qpid/linearstore/journal/txn_map.h
> ===================================================================
> --- qpid/linearstore/journal/txn_map.h        (revision 1680527)
> +++ qpid/linearstore/journal/txn_map.h        (working copy)
> @@ -39,7 +39,7 @@
>      {
>          uint64_t rid_;      ///< Record id for this operation
>          uint64_t drid_;     ///< Dequeue record id for this operation
> -        uint16_t pfid_;     ///< Physical file id, to be used when 
> transferring to emap on commit
> +        uint64_t pfid_;     ///< Physical file id, to be used when 
> transferring to emap on commit
>          uint64_t foffs_;    ///< Offset in file for this record
>          bool enq_flag_;     ///< If true, enq op, otherwise deq op
>          bool tpc_flag_;     ///< 2PC transaction if true
> @@ -47,7 +47,7 @@
>          bool aio_compl_;    ///< Initially false, set to true when record 
> AIO returns
>          txn_data_t(const uint64_t rid,
>                     const uint64_t drid,
> -                   const uint16_t pfid,
> +                   const uint64_t pfid,
>                     const uint64_t foffs,
>                     const bool enq_flag,
>                     const bool tpc_flag,
> $



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