Skip to content

Commit

Permalink
WT-7143 Collect data on failing assert for sweep current dhandle. (#6288
Browse files Browse the repository at this point in the history
)
  • Loading branch information
ddanderson committed Feb 9, 2021
1 parent b18bc0a commit 4155ec5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/cursor/cur_file.c
Expand Up @@ -624,6 +624,12 @@ __curfile_reopen(WT_CURSOR *cursor, bool check_only)
* If the data handle can't be reopened, it is a candidate for sweep, and that should never
* happen if any session (including ours) is actively using it.
*/
if (!can_reopen && dhandle == session->dhandle)
WT_RET(__wt_msg(session,
"%s: current dhandle may be swept: flags 0x%" PRIx32 " inuse 0x%" PRId32
" ref 0x%" PRIu32 " xref 0x%" PRIu32,
dhandle->name, dhandle->flags, dhandle->session_inuse, dhandle->session_ref,
dhandle->excl_ref));
WT_ASSERT(session, can_reopen || dhandle != session->dhandle);
return (can_reopen ? 0 : WT_NOTFOUND);
}
Expand Down

0 comments on commit 4155ec5

Please sign in to comment.