diff SQLite/Plugins/IndexPlugin.cpp @ 234:d1b124d116c1

PostgreSQL index plugin handles retries for collisions between multiple writers
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 08 Apr 2021 10:50:01 +0200
parents c8e06b41feec
children 16aac0287485
line wrap: on
line diff
--- a/SQLite/Plugins/IndexPlugin.cpp	Tue Apr 06 15:07:27 2021 +0200
+++ b/SQLite/Plugins/IndexPlugin.cpp	Thu Apr 08 10:50:01 2021 +0200
@@ -60,7 +60,9 @@
     {
       /* Register the SQLite index into Orthanc */
       OrthancDatabases::IndexBackend::Register(
-        new OrthancDatabases::SQLiteIndex(context, "index.db"));  // TODO parameter
+        new OrthancDatabases::SQLiteIndex(context, "index.db"),   // TODO parameter
+        1 /* only 1 connection is possible with SQLite */,
+        0 /* no collision is possible, as SQLite has a global lock */);
     }
     catch (Orthanc::OrthancException& e)
     {