From 8b1950055d51d4360e596446e5ac0f41008e357d Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Fri, 7 Aug 2020 01:14:06 +0000 Subject: index+xcpdb: rename `--no-sync' to `--no-fsync' We'll continue supporting `--no-sync' even if its yet-to-make it it into a release, but the term `sync' is overloaded in our codebase which may be confusing to new hackers and users. None of our our code nor dependencies issue the sync(2) syscall, either, only fsync(2) and fdatasync(2). --- script/public-inbox-index | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'script') diff --git a/script/public-inbox-index b/script/public-inbox-index index a52fb1bf..dc9bdde1 100755 --- a/script/public-inbox-index +++ b/script/public-inbox-index @@ -14,9 +14,9 @@ PublicInbox::Admin::require_or_die('-index'); use PublicInbox::Xapcmd; my $compact_opt; -my $opt = { quiet => -1, compact => 0, maxsize => undef, sync => 1 }; -GetOptions($opt, qw(verbose|v+ reindex rethread compact|c+ jobs|j=i prune sync! - xapianonly|xapian-only +my $opt = { quiet => -1, compact => 0, maxsize => undef, fsync => 1 }; +GetOptions($opt, qw(verbose|v+ reindex rethread compact|c+ jobs|j=i prune + fsync|sync! xapianonly|xapian-only indexlevel|L=s maxsize|max-size=s batchsize|batch-size=s sequentialshard|seq-shard|sequential-shard)) or die "bad command-line args\n$usage"; @@ -73,7 +73,7 @@ for my $ibx (@ibxs) { if ($opt->{compact} >= 2) { PublicInbox::Xapcmd::run($ibx, 'compact', $compact_opt); } - $ibx->{-no_sync} = 1 if !$opt->{sync}; + $ibx->{-no_fsync} = 1 if !$opt->{fsync}; my $ibx_opt = $opt; if (defined(my $s = $ibx->{indexsequentialshard})) { -- cgit v1.2.3-24-ge0c7