Mercurial > hg > orthanc
changeset 6951:07201dc3b5b8 streaming tip
more info in /system
| author | Alain Mazy <am@orthanc.team> |
|---|---|
| date | Wed, 17 Jun 2026 10:37:44 +0200 |
| parents | 66648e78eccb |
| children | |
| files | OrthancServer/Sources/OrthancConfiguration.cpp OrthancServer/Sources/OrthancConfiguration.h OrthancServer/Sources/OrthancRestApi/OrthancRestSystem.cpp OrthancServer/Sources/main.cpp |
| diffstat | 4 files changed, 23 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/OrthancServer/Sources/OrthancConfiguration.cpp Tue Jun 16 09:31:10 2026 +0200 +++ b/OrthancServer/Sources/OrthancConfiguration.cpp Wed Jun 17 10:37:44 2026 +0200 @@ -49,7 +49,6 @@ static const char* const DICOM_LOSSY_TRANSCODING_QUALITY = "DicomLossyTranscodingQuality"; static const char* const CONFIG_LOADER_THREADS = "LoaderThreads"; static const char* const CONFIG_ZIP_LOADER_THREADS = "ZipLoaderThreads"; // for backward compatibility only -static const char* const CONFIG_CONCURRENT_JOBS = "ConcurrentJobs"; namespace Orthanc @@ -1369,6 +1368,16 @@ unsigned int OrthancConfiguration::GetConcurrentJobs() const { - return GetUnsignedIntegerParameter(CONFIG_CONCURRENT_JOBS, 2); + return GetUnsignedIntegerParameter(ORTHANC_CONFIG_CONCURRENT_JOBS, 2); + } + + unsigned int OrthancConfiguration::GetHttpThreadsCount() const + { + return GetUnsignedIntegerParameter(ORTHANC_CONFIG_HTTP_THREADS_COUNT, 50); + } + + unsigned int OrthancConfiguration::GetDicomThreadsCount() const + { + return GetUnsignedIntegerParameter(ORTHANC_CONFIG_DICOM_THREADS_COUNT, 4); } }
--- a/OrthancServer/Sources/OrthancConfiguration.h Tue Jun 16 09:31:10 2026 +0200 +++ b/OrthancServer/Sources/OrthancConfiguration.h Wed Jun 17 10:37:44 2026 +0200 @@ -53,6 +53,9 @@ #define ORTHANC_CONFIG_DICOM_DEFAULT_RETRIEVE_METHOD "DicomDefaultRetrieveMethod" #define ORTHANC_CONFIG_PATIENT_LEVEL_ENABLED "PatientLevelEnabled" #define ORTHANC_CONFIG_READ_ONLY "ReadOnly" +#define ORTHANC_CONFIG_CONCURRENT_JOBS "ConcurrentJobs" +#define ORTHANC_CONFIG_HTTP_THREADS_COUNT "HttpThreadsCount" +#define ORTHANC_CONFIG_DICOM_THREADS_COUNT "DicomThreadsCount" #define ORTHANC_CONFIG_STORAGE_LOADER_THREADS "StorageLoaderThreads" #define ORTHANC_CONFIG_STORAGE_MEMORY_CAPACITY "StorageMemoryCapacity" @@ -283,6 +286,10 @@ unsigned int GetConcurrentJobs() const; + unsigned int GetHttpThreadsCount() const; + + unsigned int GetDicomThreadsCount() const; + void Format(std::string& result) const; void SetDefaultEncoding(Encoding encoding);
--- a/OrthancServer/Sources/OrthancRestApi/OrthancRestSystem.cpp Tue Jun 16 09:31:10 2026 +0200 +++ b/OrthancServer/Sources/OrthancRestApi/OrthancRestSystem.cpp Wed Jun 17 10:37:44 2026 +0200 @@ -177,6 +177,9 @@ result[ORTHANC_CONFIG_MAXIMUM_PATIENT_COUNT] = lock.GetConfiguration().GetMaximumPatientCount(); // New in Orthanc 1.12.4 result[ORTHANC_CONFIG_MAXIMUM_STORAGE_MODE] = lock.GetConfiguration().GetMaximumStorageMode(); // New in Orthanc 1.11.3 result[ORTHANC_CONFIG_DICOM_DEFAULT_RETRIEVE_METHOD] = lock.GetConfiguration().GetDicomDefaultRetrieveMethod(); + result[ORTHANC_CONFIG_CONCURRENT_JOBS] = lock.GetConfiguration().GetConcurrentJobs(); + result[ORTHANC_CONFIG_HTTP_THREADS_COUNT] = lock.GetConfiguration().GetHttpThreadsCount(); + result[ORTHANC_CONFIG_DICOM_THREADS_COUNT] = lock.GetConfiguration().GetDicomThreadsCount(); } {
--- a/OrthancServer/Sources/main.cpp Tue Jun 16 09:31:10 2026 +0200 +++ b/OrthancServer/Sources/main.cpp Wed Jun 17 10:37:44 2026 +0200 @@ -1118,7 +1118,7 @@ httpDescribeErrors = lock.GetConfiguration().GetBooleanParameter("HttpDescribeErrors", true); // HTTP server - httpServer.SetThreadsCount(lock.GetConfiguration().GetUnsignedIntegerParameter("HttpThreadsCount", 50)); + httpServer.SetThreadsCount(lock.GetConfiguration().GetHttpThreadsCount()); httpServer.SetPortNumber(lock.GetConfiguration().GetHttpPort()); std::set<std::string> httpBindAddresses; lock.GetConfiguration().GetSetOfStringsParameter(httpBindAddresses, "HttpBindAddresses"); @@ -1396,7 +1396,7 @@ dicomServer.SetCalledApplicationEntityTitleCheck(lock.GetConfiguration().GetBooleanParameter("DicomCheckCalledAet", false)); dicomServer.SetAssociationTimeout(lock.GetConfiguration().GetUnsignedIntegerParameter("DicomScpTimeout", 30)); dicomServer.SetPortNumber(lock.GetConfiguration().GetDicomPort()); - dicomServer.SetThreadsCount(lock.GetConfiguration().GetUnsignedIntegerParameter("DicomThreadsCount", 4)); + dicomServer.SetThreadsCount(lock.GetConfiguration().GetDicomThreadsCount()); dicomServer.SetApplicationEntityTitle(lock.GetConfiguration().GetOrthancAET()); // Configuration of DICOM TLS for Orthanc SCP (since Orthanc 1.9.0)
