The testcase is aborted during the call of clean_upmap_tp
thread. The function(clean_pg_upmaps) spawns a number
of worker threads to process a PGMapper job. The worker
thread fetch a job from the queue and then process the
job and call process_finish the job. The process function
of PGMapper class destroying the object and as worker thread
call _process_finish function it crashes because job pointer
has become a dangling pointer.
Solution: To avoid a crash destroy the object in _process_finish
instead of doing in _process.
Fixes: https://tracker.ceph.com/issues/62934
Signed-off-by: Mohit Agrawal <moagrawa@redhat.com>
else
i->job->process(i->pool, i->begin, i->end);
i->job->finish_one();
- delete i;
}
void ParallelPGMapper::queue(
}
void _process(Item *i, ThreadPool::TPHandle &h) override;
+ void _process_finish(Item *i) override { delete i;}
void _clear() override {
ceph_assert(_empty());