Mercurial > hg > orthanc
comparison OrthancServer/Sources/main.cpp @ 4792:434843934307 storage-cache
Added a StorageCache in the StorageAccessor
author | Alain Mazy <am@osimis.io> |
---|---|
date | Thu, 30 Sep 2021 12:14:19 +0200 |
parents | ec8aef42a7db |
children | 7afbb54bd028 |
comparison
equal
deleted
inserted
replaced
4790:9754d5f2f38a | 4792:434843934307 |
---|---|
1519 } | 1519 } |
1520 catch (...) | 1520 catch (...) |
1521 { | 1521 { |
1522 context.GetIndex().SetMaximumStorageSize(0); | 1522 context.GetIndex().SetMaximumStorageSize(0); |
1523 } | 1523 } |
1524 | |
1525 try | |
1526 { | |
1527 uint64_t size = lock.GetConfiguration().GetUnsignedIntegerParameter("MaximumStorageCacheSize", 128); | |
1528 context.SetMaximumStorageCacheSize(size * 1024 * 1024); | |
1529 } | |
1530 catch (...) | |
1531 { | |
1532 context.SetMaximumStorageCacheSize(128); | |
1533 } | |
1524 } | 1534 } |
1525 | 1535 |
1526 { | 1536 { |
1527 ServerContextConfigurator configurator(context, plugins); // This calls "OrthancConfiguration::SetServerIndex()" | 1537 ServerContextConfigurator configurator(context, plugins); // This calls "OrthancConfiguration::SetServerIndex()" |
1528 | 1538 |