CMS 3D CMS Logo

WaitingService.cc
Go to the documentation of this file.
1 #include "WaitingService.h"
5 
6 namespace edmtest {
7  namespace test_acquire {
8 
10  : count_(0),
11  numberOfStreamsToAccumulate_(pset.getUntrackedParameter<unsigned int>("streamsToAccumulate", 8)),
12  secondsToWaitForWork_(pset.getUntrackedParameter<unsigned int>("secondsToWaitForWork", 1)) {
15  }
16 
18  if (server_) {
19  server_->stop();
20  }
21  }
22 
24  caches_.resize(count_.load());
25  server_ = std::make_unique<test_acquire::WaitingServer>(
27  server_->start();
28  }
29 
31  if (server_) {
32  server_->stop();
33  }
34  server_.reset();
35  }
36  } // namespace test_acquire
37 } // namespace edmtest
38 
void watchPreallocate(Preallocate::slot_type const &iSlot)
std::atomic< unsigned int > count_
void watchPostEndJob(PostEndJob::slot_type const &iSlot)
std::unique_ptr< WaitingServer > server_
#define DEFINE_FWK_SERVICE(type)
Definition: ServiceMaker.h:97
const unsigned int numberOfStreamsToAccumulate_
void preallocate(edm::service::SystemBounds const &)
WaitingService(edm::ParameterSet const &pset, edm::ActivityRegistry &iRegistry)