Remove references to TDB2::read_only

A TC replica is always read-write.
This commit is contained in:
Dustin J. Mitchell 2022-04-23 18:30:48 +00:00 committed by Tomas Babej
parent f452100588
commit 35c8ce2ccb
3 changed files with 1 additions and 22 deletions

View file

@ -851,8 +851,7 @@ int Context::dispatch (std::string &out)
assert (c);
// The command know whether they need a GC.
if (c->needs_gc () &&
! tdb2.read_only ())
if (c->needs_gc ())
{
run_gc = config.getBoolean ("gc");
tdb2.gc ();
@ -862,13 +861,6 @@ int Context::dispatch (std::string &out)
run_gc = false;
}
/*
// Only read-only commands can be run when TDB2 is read-only.
// TODO Implement TDB2::read_only
if (tdb2.read_only () && !c->read_only ())
throw std::string ("");
*/
// This is something that is only needed for write commands with no other
// filter processing.
if (c->accepts_modifications () &&