Mercurial > hg > orthanc-databases
changeset 19:38e23471d132
more visibility on the index creation
author | am@osimis.io |
---|---|
date | Tue, 10 Jul 2018 11:05:37 +0200 |
parents | dfc7002add9c |
children | aacb651833f5 |
files | PostgreSQL/NEWS PostgreSQL/Plugins/PostgreSQLIndex.cpp |
diffstat | 2 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/PostgreSQL/NEWS Tue Jul 10 07:15:13 2018 +0200 +++ b/PostgreSQL/NEWS Tue Jul 10 11:05:37 2018 +0200 @@ -1,6 +1,13 @@ Pending changes in the mainline =============================== +Important remark when upgrading from an older version of the Plugin: +* The plugin will create a new index to improve search performances. + This can take several minutes at Orthanc startup. Orthanc will not + be available during this period. + On a 100000 studies DB, we've observed that the creation of this index + took around 10 minutes. + * Migration into the "orthanc-databases" repository * Full refactoring to share code with MySQL * Fix issue 41 (Additional range IdentifierConstraintType in Orthanc)
--- a/PostgreSQL/Plugins/PostgreSQLIndex.cpp Tue Jul 10 07:15:13 2018 +0200 +++ b/PostgreSQL/Plugins/PostgreSQLIndex.cpp Tue Jul 10 11:05:37 2018 +0200 @@ -129,12 +129,13 @@ **/ try { - LOG(INFO) << "Trying to enable trigram matching on the PostgreSQL database to speed up wildcard searches. This may take several minutes"; // we've observed 9 minutes on DB with 100000 studies + LOG(WARNING) << "Trying to enable trigram matching on the PostgreSQL database to speed up wildcard searches. This may take several minutes"; // we've observed 9 minutes on DB with 100000 studies db->Execute( "CREATE EXTENSION pg_trgm; " "CREATE INDEX DicomIdentifiersIndexValues2 ON DicomIdentifiers USING gin(value gin_trgm_ops);"); SetGlobalIntegerProperty(*db, t, Orthanc::GlobalProperty_HasTrigramIndex, 1); + LOG(WARNING) << "Trigram index has been created"; } catch (Orthanc::OrthancException&) {