changeset 6885:276aa95f145a streaming

removed ServerContext::transcoderThreadPool_
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 01 Jun 2026 17:04:06 +0200
parents 12125996722c
children ee907f0d911b
files OrthancServer/Sources/ServerContext.cpp OrthancServer/Sources/ServerContext.h
diffstat 2 files changed, 7 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/OrthancServer/Sources/ServerContext.cpp	Mon Jun 01 17:01:26 2026 +0200
+++ b/OrthancServer/Sources/ServerContext.cpp	Mon Jun 01 17:04:06 2026 +0200
@@ -612,13 +612,14 @@
 
       if (transcoder_.get() != NULL)
       {
-        transcoderThreadPool_.reset(new ThreadPool);
-        transcoderThreadPool_->SetCountThreads(2);  // TODO-Streaming - Parameter
-        transcoderThreadPool_->SetLoggingThreadName("TRANSCODER");
-        transcoderThreadPool_->SetDequeueTimeout(100);
-        transcoderThreadPool_->Start();
+        boost::shared_ptr<ThreadPool> pool(new ThreadPool);
+        pool.reset(new ThreadPool);
+        pool->SetCountThreads(2);  // TODO-Streaming - Parameter
+        pool->SetLoggingThreadName("TRANSCODER");
+        pool->SetDequeueTimeout(100);
+        pool->Start();
 
-        transcoderReader_.reset(new DataSourceReader(transcoderThreadPool_, new TranscoderDataSource(transcoder_, storageAreaReader_)));
+        transcoderReader_.reset(new DataSourceReader(pool, new TranscoderDataSource(transcoder_, storageAreaReader_)));
         transcoderReader_->SetMetricsConfiguration(
           DataSourceReader::MetricsConfiguration(metricsRegistry_,
                                                  METRICS_TRANSCODER_CACHE_SIZE_MB,
--- a/OrthancServer/Sources/ServerContext.h	Mon Jun 01 17:01:26 2026 +0200
+++ b/OrthancServer/Sources/ServerContext.h	Mon Jun 01 17:04:06 2026 +0200
@@ -49,7 +49,6 @@
   class ServerTranscoder;
   class SharedArchive;
   class StorageCommitmentReports;
-  class ThreadPool;
   
 
   /**
@@ -291,7 +290,6 @@
     // For streaming
     boost::shared_ptr<DataSourceReader>                storageAreaReader_;
     boost::shared_ptr<DataSourceReader>                dicomReader_;
-    boost::shared_ptr<ThreadPool>                      transcoderThreadPool_;
     boost::shared_ptr<DataSourceReader>                transcoderReader_;
     boost::shared_ptr<DicomSequentialReader::Factory>  dicomSequentialReaderFactory_;