my ($self, @docids) = @_;
my $eidx = eidx_init($self);
for my $docid (@docids) {
- $eidx->idx_shard($docid)->ipc_do('xdb_remove', $docid);
- $eidx->{oidx}->delete_by_num($docid);
+ $eidx->remove_doc($docid);
$eidx->{oidx}->{dbh}->do(<<EOF, undef, $docid);
DELETE FROM xref3 WHERE docid = ?
EOF
$git->cat_async($oidhex, \&_remove_if_local, $self);
}
}
- $git->cat_async_wait;
+ $git->async_wait_all;
remove_docids($self, @docids);
\@docids;
}
return unless -e $dir;
my $old = delete $self->{-tmp_err};
my $pfx = POSIX::strftime('%Y%m%d%H%M%S', gmtime(time));
- my $err = File::Temp->new(TEMPLATE => "$pfx.$$.lei_storeXXXX",
+ my $err = File::Temp->new(TEMPLATE => "$pfx.$$.err-XXXX",
SUFFIX => '.err', DIR => $dir);
open STDERR, '>>', $err->filename or die "dup2: $!";
STDERR->autoflush(1); # shared with shard subprocesses
# Mail we import into lei are private, so headers filtered out
# by -mda for public mail are not appropriate
local @PublicInbox::MDA::BAD_HEADERS = ();
- $self->{-wq_no_bcast} = 1;
$self->wq_workers_start("lei/store $dir", 1, $lei->oldset, {
lei => $lei,
-err_wr => $w,