From eec3d818681cdee05504d8580b92c4a450264430 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 21 Mar 2023 23:07:28 +0000 Subject: [PATCH] cindex: show shard number in progress message Otherwise it may be confusing to see the `$nr' value walk backwards if some shards are indexing at a slower pace. --- lib/PublicInbox/CodeSearchIdx.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/PublicInbox/CodeSearchIdx.pm b/lib/PublicInbox/CodeSearchIdx.pm index 97c563bd2..ee2d9a47e 100644 --- a/lib/PublicInbox/CodeSearchIdx.pm +++ b/lib/PublicInbox/CodeSearchIdx.pm @@ -186,7 +186,7 @@ sub shard_index { # via wq_io_do last if $quit; # likely SIGPIPE ++$nr; if ($max <= 0 && !$PublicInbox::Search::X{CLOEXEC_UNSET}) { - progress($self, $nr); + progress($self, "[$n] $nr"); $self->{xdb}->commit_transaction; $max = $batch_bytes; $self->{xdb}->begin_transaction; -- 2.47.2