xapian-db: remove locks, transaction levels

Simplify xapian-db: locks should go elsewhere; transaction level add
too much complication.
This commit is contained in:
Dirk-Jan C. Binnema
2024-05-26 11:42:50 +03:00
parent e978a58400
commit c05b28e761
4 changed files with 66 additions and 117 deletions

View File

@ -41,6 +41,7 @@ XapianDb::wdb()
{
if (read_only())
throw std::runtime_error("database is read-only");
return std::get<Xapian::WritableDatabase>(db_);
}
@ -106,7 +107,7 @@ XapianDb::XapianDb(const std::string& db_path, Flavor flavor):
if (flavor == Flavor::CreateOverwrite)
set_timestamp(MetadataIface::created_key);
mu_debug("created {} / {} (batch-size: {})", flavor, *this, batch_size_);
mu_debug("created {}", *this);
}
void