Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-11030

Invalid iterator used when marking a table for deletion in Workgen

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • 5
    • StorEng - Defined Pipeline

      Error signature:
       

      May 03 06:53:55 ip-172-31-40-113 bash[98259]: /srv/testy/wiredtiger/bench/workgen/workgen.cpp:539: ASSERT failed: itr != icontext->_dyn_tint.end()
      May 03 06:53:57 ip-172-31-40-113 bash[98257]: /srv/testy/workloads/sample/sample.sh: line 13: 98259 Aborted                 (core dumped) python3 ${workload_dir}/sample/sample_run.py --home ${database_dir} --keep
      

      This is the function we are in:

      /*
       * The table specified by the dynamic table iterator is flagged for deletion and added to the
       * pending delete list. If the table has a mirror, the mirror is also flagged for deletion and added
       * to the pending delete list.
       */
      void
      WorkloadRunner::schedule_table_for_drop(
        const std::map<std::string, tint_t>::iterator &itr, std::vector<std::string> &pending_delete)
      {
          ContextInternal *icontext = _workload->_context->_internal;
          ASSERT(itr != icontext->_dyn_tint.end());
          VERBOSE(*_workload, "Flagging pending delete for: " << itr->first);
          icontext->_dyn_table_runtime[itr->second]._pending_delete = true;
      
          ASSERT(
            std::find(pending_delete.begin(), pending_delete.end(), itr->first) == pending_delete.end());
          pending_delete.push_back(itr->first);
      }
      

      It seems that the iterator has an invalid position.

            Assignee:
            etienne.petrel@mongodb.com Etienne Petrel
            Reporter:
            etienne.petrel@mongodb.com Etienne Petrel
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: