CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
edm::service::SiteLocalConfigService Class Reference

#include <SiteLocalConfigService.h>

Inheritance diagram for edm::service::SiteLocalConfigService:
edm::SiteLocalConfig

Public Member Functions

std::vector< std::string > const & dataCatalogs (void) const override
 
unsigned int debugLevel () const override
 
bool enablePrefetching () const override
 
std::string const & localConnectPrefix () const override
 
std::string const & localConnectSuffix () const override
 
std::string const lookupCalibConnect (std::string const &input) const override
 
std::string const rfioType (void) const override
 
 SiteLocalConfigService (ParameterSet const &pset)
 
std::string const & siteName () const override
 
std::string const * sourceCacheHint () const override
 
double const * sourceCacheMinFree () const override
 
std::string const * sourceCacheTempDir () const override
 
std::string const * sourceCloneCacheHint () const override
 
std::vector< std::string > const * sourceNativeProtocols () const override
 
std::string const * sourceReadHint () const override
 
unsigned int const * sourceTimeout () const override
 
unsigned int const * sourceTTreeCacheSize () const override
 
struct addrinfo const * statisticsDestination () const override
 
std::set< std::string > const * statisticsInfo () const override
 
bool useLocalConnectString () const override
 
 ~SiteLocalConfigService () override
 
- Public Member Functions inherited from edm::SiteLocalConfig
 SiteLocalConfig ()
 
virtual ~SiteLocalConfig ()
 

Static Public Member Functions

static void fillDescriptions (ConfigurationDescriptions &descriptions)
 

Private Member Functions

void computeStatisticsDestination ()
 
std::string const frontierConnect (std::string const &servlet) const
 
void parse (std::string const &url)
 

Private Attributes

std::string m_cacheHint
 
std::string const * m_cacheHintPtr
 
double m_cacheMinFree
 
double const * m_cacheMinFreePtr
 
std::string m_cacheTempDir
 
std::string const * m_cacheTempDirPtr
 
std::string m_cloneCacheHint
 
std::string const * m_cloneCacheHintPtr
 
bool m_connected
 
std::vector< std::string > m_dataCatalogs
 
unsigned int m_debugLevel
 
bool m_enablePrefetching
 
bool const * m_enablePrefetchingPtr
 
std::string m_frontierConnect
 
std::string m_localConnectPrefix
 
std::string m_localConnectSuffix
 
std::vector< std::string > m_nativeProtocols
 
std::vector< std::string > const * m_nativeProtocolsPtr
 
std::string m_readHint
 
std::string const * m_readHintPtr
 
std::string m_rfioType
 
std::string m_siteName
 
edm::propagate_const< struct
addrinfo * > 
m_statisticsAddrInfo
 
std::string m_statisticsDestination
 
std::set< std::string > m_statisticsInfo
 
bool m_statisticsInfoAvail
 
unsigned int m_timeout
 
unsigned int const * m_timeoutPtr
 
unsigned int m_ttreeCacheSize
 
unsigned int const * m_ttreeCacheSizePtr
 
std::string m_url
 
bool m_useLocalConnectString = false
 

Static Private Attributes

static const std::string m_statisticsDefaultPort = "3334"
 

Detailed Description

Definition at line 29 of file SiteLocalConfigService.h.

Constructor & Destructor Documentation

edm::service::SiteLocalConfigService::SiteLocalConfigService ( ParameterSet const &  pset)
explicit

Definition at line 77 of file SiteLocalConfigService.cc.

References computeStatisticsDestination(), mps_splice::entry, edm::ParameterSet::exists(), edm::ParameterSet::getUntrackedParameter(), m_cacheHint, m_cacheHintPtr, m_cacheMinFree, m_cacheMinFreePtr, m_cacheTempDir, m_cacheTempDirPtr, m_cloneCacheHint, m_cloneCacheHintPtr, m_debugLevel, m_enablePrefetching, m_enablePrefetchingPtr, m_localConnectPrefix, m_localConnectSuffix, m_nativeProtocols, m_nativeProtocolsPtr, m_readHint, m_readHintPtr, m_statisticsDestination, m_statisticsInfo, m_statisticsInfoAvail, m_timeout, m_timeoutPtr, m_ttreeCacheSize, m_ttreeCacheSizePtr, m_url, m_useLocalConnectString, eostools::move(), parse(), and AlCaHLTBitMon_QueryRunRegistry::string.

78  : m_url(pset.getUntrackedParameter<std::string>("siteLocalConfigFileUrl", defaultURL())),
81  m_rfioType("castor"),
82  m_connected(false),
84  m_cacheTempDirPtr(nullptr),
86  m_cacheMinFreePtr(nullptr),
87  m_cacheHint(),
88  m_cacheHintPtr(nullptr),
90  m_cloneCacheHintPtr(nullptr),
91  m_readHint(),
92  m_readHintPtr(nullptr),
93  m_ttreeCacheSize(0U),
94  m_ttreeCacheSizePtr(nullptr),
95  m_timeout(0U),
96  m_timeoutPtr(nullptr),
97  m_debugLevel(0U),
98  m_enablePrefetching(false),
99  m_enablePrefetchingPtr(nullptr),
101  m_nativeProtocolsPtr(nullptr),
103  m_statisticsAddrInfo(nullptr),
104  m_statisticsInfoAvail(false),
105  m_siteName() {
106  this->parse(m_url);
107 
108  //apply overrides
109  overrideFromPSet("overrideSourceCacheTempDir", pset, m_cacheTempDir, m_cacheTempDirPtr);
110  overrideFromPSet("overrideSourceCacheMinFree", pset, m_cacheMinFree, m_cacheMinFreePtr);
111  overrideFromPSet("overrideSourceCacheHintDir", pset, m_cacheHint, m_cacheHintPtr);
112  overrideFromPSet("overrideSourceCloneCacheHintDir", pset, m_cloneCacheHint, m_cloneCacheHintPtr);
113  overrideFromPSet("overrideSourceReadHint", pset, m_readHint, m_readHintPtr);
114  overrideFromPSet("overrideSourceNativeProtocols", pset, m_nativeProtocols, m_nativeProtocolsPtr);
115  overrideFromPSet("overrideSourceTTreeCacheSize", pset, m_ttreeCacheSize, m_ttreeCacheSizePtr);
116  overrideFromPSet("overrideSourceTimeout", pset, m_timeout, m_timeoutPtr);
117  overrideFromPSet("overridePrefetching", pset, m_enablePrefetching, m_enablePrefetchingPtr);
118  const std::string *tmpStringPtr = nullptr;
119  overrideFromPSet("overrideStatisticsDestination", pset, m_statisticsDestination, tmpStringPtr);
121  std::vector<std::string> tmpStatisticsInfo;
122  std::vector<std::string> const *tmpStatisticsInfoPtr = nullptr;
123  overrideFromPSet("overrideStatisticsInfo", pset, tmpStatisticsInfo, tmpStatisticsInfoPtr);
124  if (tmpStatisticsInfoPtr) {
125  m_statisticsInfoAvail = true;
126  m_statisticsInfo.clear();
127  for (auto &entry : tmpStatisticsInfo) {
129  }
130  }
131 
132  if (pset.exists("debugLevel")) {
133  m_debugLevel = pset.getUntrackedParameter<unsigned int>("debugLevel");
134  }
135  if (pset.exists("overrideUseLocalConnectString")) {
136  m_useLocalConnectString = pset.getUntrackedParameter<bool>("overrideUseLocalConnectString");
137  }
138  if (pset.exists("overrideLocalConnectPrefix")) {
139  m_localConnectPrefix = pset.getUntrackedParameter<std::string>("overrideLocalConnectPrefix");
140  }
141  if (pset.exists("overrideLocalConnectSuffix")) {
142  m_localConnectSuffix = pset.getUntrackedParameter<std::string>("overrideLocalConnectSuffix");
143  }
144  }
std::vector< std::string > m_dataCatalogs
std::vector< std::string > const * m_nativeProtocolsPtr
edm::propagate_const< struct addrinfo * > m_statisticsAddrInfo
def move
Definition: eostools.py:511
std::vector< std::string > m_nativeProtocols
list entry
Definition: mps_splice.py:68
edm::service::SiteLocalConfigService::~SiteLocalConfigService ( )
override

Definition at line 146 of file SiteLocalConfigService.cc.

References m_statisticsAddrInfo.

146  {
147  if (m_statisticsAddrInfo) {
148  freeaddrinfo(m_statisticsAddrInfo);
149  m_statisticsAddrInfo = nullptr;
150  }
151  }
edm::propagate_const< struct addrinfo * > m_statisticsAddrInfo

Member Function Documentation

void edm::service::SiteLocalConfigService::computeStatisticsDestination ( )
private

Definition at line 452 of file SiteLocalConfigService.cc.

References alignCSCRings::e, query::host, m_statisticsAddrInfo, m_statisticsDefaultPort, m_statisticsDestination, query::port, submitPVValidationJobs::split(), and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by SiteLocalConfigService().

452  {
453  std::vector<std::string> inputStrings;
454  boost::split(inputStrings, m_statisticsDestination, boost::is_any_of(":"));
455  const std::string &host = inputStrings[0];
456  const std::string &port = (inputStrings.size() > 1) ? inputStrings[1] : m_statisticsDefaultPort;
457  struct addrinfo *res;
458  struct addrinfo hints;
459  memset(&hints, '\0', sizeof(hints));
460  hints.ai_socktype = SOCK_DGRAM;
461  hints.ai_flags = AI_ADDRCONFIG;
462  hints.ai_family = AF_UNSPEC;
463  int e = getaddrinfo(host.c_str(), port.c_str(), &hints, &res);
464  if (e != 0) {
465  // Silent failure - there's no way to report non-fatal failures from here.
466  return;
467  }
468  m_statisticsAddrInfo = res;
469  }
static const std::string m_statisticsDefaultPort
int port
Definition: query.py:116
edm::propagate_const< struct addrinfo * > m_statisticsAddrInfo
string host
Definition: query.py:115
std::vector< std::string > const & edm::service::SiteLocalConfigService::dataCatalogs ( void  ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 153 of file SiteLocalConfigService.cc.

References Exception, m_connected, m_dataCatalogs, m_url, and createJobs::tmp.

153  {
154  if (!m_connected) {
155  //throw cms::Exception("Incomplete configuration")
156  // << "Valid site-local-config not found at " << m_url;
157  // Return PoolFileCatalog.xml for now
158  static std::vector<std::string> const tmp{"file:PoolFileCatalog.xml"};
159  return tmp;
160  }
161 
162  if (m_dataCatalogs.empty()) {
163  throw cms::Exception("Incomplete configuration") << "Did not find catalogs in event-data section in " << m_url;
164  }
165 
166  return m_dataCatalogs;
167  }
std::vector< std::string > m_dataCatalogs
tmp
align.sh
Definition: createJobs.py:716
unsigned int edm::service::SiteLocalConfigService::debugLevel ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 256 of file SiteLocalConfigService.cc.

References m_debugLevel.

bool edm::service::SiteLocalConfigService::enablePrefetching ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 252 of file SiteLocalConfigService.cc.

References m_enablePrefetchingPtr.

252  {
254  }
void edm::service::SiteLocalConfigService::fillDescriptions ( ConfigurationDescriptions descriptions)
static

Definition at line 471 of file SiteLocalConfigService.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::addOptionalUntracked(), submitPVResolutionJobs::desc, edm::ParameterSetDescription::setComment(), and AlCaHLTBitMon_QueryRunRegistry::string.

471  {
473  desc.setComment("Service to translate logical file names to physical file names.");
474 
475  desc.addOptionalUntracked<std::string>("siteLocalConfigFileUrl", std::string())
476  ->setComment(
477  "Specify the file containing the site local config. Empty string will load from default directory.");
478  desc.addOptionalUntracked<std::string>("overrideSourceCacheTempDir");
479  desc.addOptionalUntracked<double>("overrideSourceCacheMinFree");
480  desc.addOptionalUntracked<std::string>("overrideSourceCacheHintDir");
481  desc.addOptionalUntracked<std::string>("overrideSourceCloneCacheHintDir")
482  ->setComment("Provide an alternate cache hint for fast cloning.");
483  desc.addOptionalUntracked<std::string>("overrideSourceReadHint");
484  desc.addOptionalUntracked<std::vector<std::string> >("overrideSourceNativeProtocols");
485  desc.addOptionalUntracked<unsigned int>("overrideSourceTTreeCacheSize");
486  desc.addOptionalUntracked<unsigned int>("overrideSourceTimeout");
487  desc.addOptionalUntracked<unsigned int>("debugLevel");
488  desc.addOptionalUntracked<bool>("overridePrefetching")
489  ->setComment("Request ROOT to asynchronously prefetch I/O during computation.");
490  desc.addOptionalUntracked<std::string>("overrideStatisticsDestination")
491  ->setComment(
492  "Provide an alternate network destination for I/O statistics (must be in the form of host:port).");
493  desc.addOptionalUntracked<std::vector<std::string> >("overrideStatisticsInfo")
494  ->setComment(
495  "Provide an alternate listing of statistics to send (comma separated list; current options are 'dn' or "
496  "'nodn'). If left blank, all information is snet (including DNs).");
497  desc.addOptionalUntracked<bool>("overrideUseLocalConnectString");
498  desc.addOptionalUntracked<std::string>("overrideLocalConnectPrefix");
499  desc.addOptionalUntracked<std::string>("overrideLocalConnectSuffix");
500  descriptions.add("SiteLocalConfigService", desc);
501  }
std::string const edm::service::SiteLocalConfigService::frontierConnect ( std::string const &  servlet) const
private

Definition at line 169 of file SiteLocalConfigService.cc.

References Exception, m_connected, m_frontierConnect, m_url, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by lookupCalibConnect(), and parse().

169  {
170  if (!m_connected) {
171  throw cms::Exception("Incomplete configuration") << "Valid site-local-config not found at " << m_url;
172  }
173 
174  if (m_frontierConnect.empty()) {
175  throw cms::Exception("Incomplete configuration")
176  << "Did not find frontier-connect in calib-data section in " << m_url;
177  }
178 
179  if (servlet.empty()) {
180  return m_frontierConnect;
181  }
182 
183  // Replace the last component of every "serverurl=" piece (up to the
184  // next close-paren) with the servlet
185  std::string::size_type nextparen = 0;
186  std::string::size_type serverurl, lastslash;
187  std::string complexstr = "";
188  while ((serverurl = m_frontierConnect.find("(serverurl=", nextparen)) != std::string::npos) {
189  complexstr.append(m_frontierConnect, nextparen, serverurl - nextparen);
190  nextparen = m_frontierConnect.find(')', serverurl);
191  lastslash = m_frontierConnect.rfind('/', nextparen);
192  complexstr.append(m_frontierConnect, serverurl, lastslash - serverurl + 1);
193  complexstr.append(servlet);
194  }
195  complexstr.append(m_frontierConnect, nextparen, m_frontierConnect.length() - nextparen);
196 
197  return complexstr;
198  }
uint16_t size_type
std::string const & edm::service::SiteLocalConfigService::localConnectPrefix ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 272 of file SiteLocalConfigService.cc.

References m_localConnectPrefix.

std::string const & edm::service::SiteLocalConfigService::localConnectSuffix ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 273 of file SiteLocalConfigService.cc.

References m_localConnectSuffix.

std::string const edm::service::SiteLocalConfigService::lookupCalibConnect ( std::string const &  input) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 200 of file SiteLocalConfigService.cc.

References frontierConnect(), input, and AlCaHLTBitMon_QueryRunRegistry::string.

200  {
201  static std::string const proto = "frontier://";
202 
203  if (input.substr(0, proto.length()) == proto) {
204  // Replace the part after the frontier:// and before either an open-
205  // parentheses (which indicates user-supplied options) or the last
206  // slash (which indicates start of the schema) with the complex
207  // parenthesized string returned from frontierConnect() (which
208  // contains all the information needed to connect to frontier),
209  // if that part is a simple servlet name (non-empty and not
210  // containing special characters)
211  // Example connect strings where servlet is replaced:
212  // frontier://cms_conditions_data/CMS_COND_ECAL
213  // frontier://FrontierInt/CMS_COND_ECAL
214  // frontier://FrontierInt(retrieve-ziplevel=0)/CMS_COND_ECAL
215  // Example connect strings left untouched:
216  // frontier://cmsfrontier.cern.ch:8000/FrontierInt/CMS_COND_ECAL
217  // frontier://(serverurl=cmsfrontier.cern.ch:8000/FrontierInt)/CMS_COND_ECAL
218  std::string::size_type startservlet = proto.length();
219  // if user supplied extra parenthesized options, stop servlet there
220  std::string::size_type endservlet = input.find('(', startservlet);
221  if (endservlet == std::string::npos) {
222  endservlet = input.rfind('/', input.length());
223  }
224  std::string servlet = input.substr(startservlet, endservlet - startservlet);
225  if ((!servlet.empty()) && (servlet.find_first_of(":/)[]") == std::string::npos)) {
226  if (servlet == "cms_conditions_data") {
227  // use the default servlet from site-local-config.xml
228  servlet = "";
229  }
230  return proto + frontierConnect(servlet) + input.substr(endservlet);
231  }
232  }
233  return input;
234  }
uint16_t size_type
static std::string const input
Definition: EdmProvDump.cc:47
std::string const frontierConnect(std::string const &servlet) const
void edm::service::SiteLocalConfigService::parse ( std::string const &  url)
private

Definition at line 275 of file SiteLocalConfigService.cc.

References validate_alignment_devdb10_cfg::catalog, Exception, frontierConnect(), m_cacheHint, m_cacheHintPtr, m_cacheMinFree, m_cacheMinFreePtr, m_cacheTempDir, m_cacheTempDirPtr, m_cloneCacheHint, m_cloneCacheHintPtr, m_connected, m_dataCatalogs, m_enablePrefetching, m_enablePrefetchingPtr, m_frontierConnect, m_localConnectPrefix, m_localConnectSuffix, m_nativeProtocols, m_nativeProtocolsPtr, m_readHint, m_readHintPtr, m_rfioType, m_siteName, m_statisticsDestination, m_statisticsInfo, m_statisticsInfoAvail, m_timeout, m_timeoutPtr, m_ttreeCacheSize, m_ttreeCacheSizePtr, m_useLocalConnectString, submitPVValidationJobs::split(), AlCaHLTBitMon_QueryRunRegistry::string, and mps_check::timeout.

Referenced by SiteLocalConfigService().

275  {
276  tinyxml2::XMLDocument doc;
277  auto loadErr = doc.LoadFile(url.c_str());
278  if (loadErr != tinyxml2::XML_SUCCESS) {
279  return;
280  }
281 
282  // The Site Config has the following format
283  // <site-local-config>
284  // <site name="FNAL">
285  // <event-data>
286  // <catalog url="trivialcatalog_file:/x/y/z.xml"/>
287  // <rfiotype value="castor"/>
288  // </event-data>
289  // <calib-data>
290  // <catalog url="trivialcatalog_file:/x/y/z.xml"/>
291  // <frontier-connect>
292  // ... frontier-interpreted server/proxy xml ...
293  // </frontier-connect>
294  // <local-connect>
295  // <connectString prefix="anything1" suffix="anything2"/>
296  // </local-connect>
297  // </calib-data>
298  // <source-config>
299  // <cache-temp-dir name="/a/b/c"/>
300  // <cache-hint value="..."/>
301  // <read-hint value="..."/>
302  // <ttree-cache-size value="0"/>
303  // <native-protocols>
304  // <protocol prefix="dcache"/>
305  // <protocol prefix="file"/>
306  // </native-protocols>
307  // </source-config>
308  // </site>
309  // </site-local-config>
310  auto rootElement = doc.RootElement();
311 
312  for (auto site = rootElement->FirstChildElement("site"); site != nullptr;
313  site = site->NextSiblingElement("site")) {
314  // Parse the site name
315  m_siteName = safe(site->Attribute("name"));
316 
317  // Parsing of the event data section
318  {
319  auto eventData = site->FirstChildElement("event-data");
320  if (eventData) {
321  auto catalog = eventData->FirstChildElement("catalog");
322  if (catalog) {
323  m_dataCatalogs.push_back(safe(catalog->Attribute("url")));
324  catalog = catalog->NextSiblingElement("catalog");
325  while (catalog) {
326  m_dataCatalogs.push_back(safe(catalog->Attribute("url")));
327  catalog = catalog->NextSiblingElement("catalog");
328  }
329  }
330  auto rfiotype = eventData->FirstChildElement("rfiotype");
331  if (rfiotype) {
332  m_rfioType = safe(rfiotype->Attribute("value"));
333  }
334  }
335  }
336 
337  // Parsing of the calib-data section
338  {
339  auto calibData = site->FirstChildElement("calib-data");
340 
341  if (calibData) {
342  auto frontierConnect = calibData->FirstChildElement("frontier-connect");
343 
344  if (frontierConnect) {
345  m_frontierConnect = _toParenString(*frontierConnect);
346  }
347  auto localConnect = calibData->FirstChildElement("local-connect");
348  if (localConnect) {
349  if (frontierConnect) {
350  throw cms::Exception("Illegal site local configuration")
351  << "It is illegal to include both frontier-connect and local-connect in the same XML file";
352  }
354  auto connectString = localConnect->FirstChildElement("connectString");
355  if (connectString) {
356  m_localConnectPrefix = safe(connectString->Attribute("prefix"));
357  m_localConnectSuffix = safe(connectString->Attribute("suffix"));
358  }
359  }
360  }
361  }
362 
363  // Parsing of the source config section
364  {
365  auto sourceConfig = site->FirstChildElement("source-config");
366 
367  if (sourceConfig) {
368  auto cacheTempDir = sourceConfig->FirstChildElement("cache-temp-dir");
369 
370  if (cacheTempDir) {
371  m_cacheTempDir = safe(cacheTempDir->Attribute("name"));
373  }
374 
375  auto cacheMinFree = sourceConfig->FirstChildElement("cache-min-free");
376 
377  if (cacheMinFree) {
378  //TODO what did xerces do if it couldn't convert?
379  m_cacheMinFree = cacheMinFree->DoubleAttribute("value");
381  }
382 
383  auto cacheHint = sourceConfig->FirstChildElement("cache-hint");
384 
385  if (cacheHint) {
386  m_cacheHint = safe(cacheHint->Attribute("value"));
388  }
389 
390  auto cloneCacheHint = sourceConfig->FirstChildElement("clone-cache-hint");
391 
392  if (cloneCacheHint) {
393  m_cloneCacheHint = safe(cloneCacheHint->Attribute("value"));
395  }
396 
397  auto readHint = sourceConfig->FirstChildElement("read-hint");
398 
399  if (readHint) {
400  m_readHint = safe(readHint->Attribute("value"));
402  }
403 
404  auto ttreeCacheSize = sourceConfig->FirstChildElement("ttree-cache-size");
405 
406  if (ttreeCacheSize) {
407  m_ttreeCacheSize = ttreeCacheSize->UnsignedAttribute("value");
409  }
410 
411  auto timeout = sourceConfig->FirstChildElement("timeout-in-seconds");
412 
413  if (timeout) {
414  m_timeout = timeout->UnsignedAttribute("value");
416  }
417 
418  auto statsDest = sourceConfig->FirstChildElement("statistics-destination");
419 
420  if (statsDest) {
421  m_statisticsDestination = safe(statsDest->Attribute("endpoint"));
422  if (m_statisticsDestination.empty()) {
423  m_statisticsDestination = safe(statsDest->Attribute("name"));
424  }
425  std::string tmpStatisticsInfo = safe(statsDest->Attribute("info"));
426  boost::split(m_statisticsInfo, tmpStatisticsInfo, boost::is_any_of("\t ,"));
427  m_statisticsInfoAvail = !tmpStatisticsInfo.empty();
428  }
429 
430  auto prefetching = sourceConfig->FirstChildElement("prefetching");
431 
432  if (prefetching) {
433  m_enablePrefetching = prefetching->BoolAttribute("value");
435  }
436 
437  auto nativeProtocol = sourceConfig->FirstChildElement("native-protocols");
438 
439  if (nativeProtocol) {
440  for (auto child = nativeProtocol->FirstChildElement(); child != nullptr;
441  child = child->NextSiblingElement()) {
442  m_nativeProtocols.push_back(safe(child->Attribute("prefix")));
443  }
445  }
446  }
447  }
448  }
449  m_connected = true;
450  }
std::vector< std::string > m_dataCatalogs
int timeout
Definition: mps_check.py:53
std::vector< std::string > const * m_nativeProtocolsPtr
std::vector< std::string > m_nativeProtocols
std::string const frontierConnect(std::string const &servlet) const
std::string const edm::service::SiteLocalConfigService::rfioType ( void  ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 236 of file SiteLocalConfigService.cc.

References m_rfioType.

std::string const & edm::service::SiteLocalConfigService::siteName ( void  ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 270 of file SiteLocalConfigService.cc.

References m_siteName.

std::string const * edm::service::SiteLocalConfigService::sourceCacheHint ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 242 of file SiteLocalConfigService.cc.

References m_cacheHintPtr.

242 { return m_cacheHintPtr; }
double const * edm::service::SiteLocalConfigService::sourceCacheMinFree ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 240 of file SiteLocalConfigService.cc.

References m_cacheMinFreePtr.

std::string const * edm::service::SiteLocalConfigService::sourceCacheTempDir ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 238 of file SiteLocalConfigService.cc.

References m_cacheTempDirPtr.

238 { return m_cacheTempDirPtr; }
std::string const * edm::service::SiteLocalConfigService::sourceCloneCacheHint ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 244 of file SiteLocalConfigService.cc.

References m_cloneCacheHintPtr.

244 { return m_cloneCacheHintPtr; }
std::vector< std::string > const * edm::service::SiteLocalConfigService::sourceNativeProtocols ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 258 of file SiteLocalConfigService.cc.

References m_nativeProtocolsPtr.

258  {
259  return m_nativeProtocolsPtr;
260  }
std::vector< std::string > const * m_nativeProtocolsPtr
std::string const * edm::service::SiteLocalConfigService::sourceReadHint ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 246 of file SiteLocalConfigService.cc.

References m_readHintPtr.

246 { return m_readHintPtr; }
unsigned int const * edm::service::SiteLocalConfigService::sourceTimeout ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 250 of file SiteLocalConfigService.cc.

References m_timeoutPtr.

250 { return m_timeoutPtr; }
unsigned int const * edm::service::SiteLocalConfigService::sourceTTreeCacheSize ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 248 of file SiteLocalConfigService.cc.

References m_ttreeCacheSizePtr.

248 { return m_ttreeCacheSizePtr; }
struct addrinfo const * edm::service::SiteLocalConfigService::statisticsDestination ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 262 of file SiteLocalConfigService.cc.

References m_statisticsAddrInfo.

262  {
263  return m_statisticsAddrInfo;
264  }
edm::propagate_const< struct addrinfo * > m_statisticsAddrInfo
std::set< std::string > const * edm::service::SiteLocalConfigService::statisticsInfo ( ) const
overridevirtual

Implements edm::SiteLocalConfig.

Definition at line 266 of file SiteLocalConfigService.cc.

References m_statisticsInfo, and m_statisticsInfoAvail.

266  {
267  return m_statisticsInfoAvail ? &m_statisticsInfo : nullptr;
268  }
bool edm::service::SiteLocalConfigService::useLocalConnectString ( ) const
overridevirtual

Member Data Documentation

std::string edm::service::SiteLocalConfigService::m_cacheHint
private

Definition at line 73 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

std::string const* edm::service::SiteLocalConfigService::m_cacheHintPtr
private

Definition at line 74 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceCacheHint().

double edm::service::SiteLocalConfigService::m_cacheMinFree
private

Definition at line 71 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

double const* edm::service::SiteLocalConfigService::m_cacheMinFreePtr
private

Definition at line 72 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceCacheMinFree().

std::string edm::service::SiteLocalConfigService::m_cacheTempDir
private

Definition at line 69 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

std::string const* edm::service::SiteLocalConfigService::m_cacheTempDirPtr
private

Definition at line 70 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceCacheTempDir().

std::string edm::service::SiteLocalConfigService::m_cloneCacheHint
private

Definition at line 75 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

std::string const* edm::service::SiteLocalConfigService::m_cloneCacheHintPtr
private

Definition at line 76 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceCloneCacheHint().

bool edm::service::SiteLocalConfigService::m_connected
private

Definition at line 68 of file SiteLocalConfigService.h.

Referenced by dataCatalogs(), frontierConnect(), and parse().

std::vector<std::string> edm::service::SiteLocalConfigService::m_dataCatalogs
private

Definition at line 65 of file SiteLocalConfigService.h.

Referenced by dataCatalogs(), and parse().

unsigned int edm::service::SiteLocalConfigService::m_debugLevel
private

Definition at line 83 of file SiteLocalConfigService.h.

Referenced by debugLevel(), and SiteLocalConfigService().

bool edm::service::SiteLocalConfigService::m_enablePrefetching
private

Definition at line 84 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

bool const* edm::service::SiteLocalConfigService::m_enablePrefetchingPtr
private

Definition at line 85 of file SiteLocalConfigService.h.

Referenced by enablePrefetching(), parse(), and SiteLocalConfigService().

std::string edm::service::SiteLocalConfigService::m_frontierConnect
private

Definition at line 66 of file SiteLocalConfigService.h.

Referenced by frontierConnect(), and parse().

std::string edm::service::SiteLocalConfigService::m_localConnectPrefix
private

Definition at line 95 of file SiteLocalConfigService.h.

Referenced by localConnectPrefix(), parse(), and SiteLocalConfigService().

std::string edm::service::SiteLocalConfigService::m_localConnectSuffix
private

Definition at line 96 of file SiteLocalConfigService.h.

Referenced by localConnectSuffix(), parse(), and SiteLocalConfigService().

std::vector<std::string> edm::service::SiteLocalConfigService::m_nativeProtocols
private

Definition at line 86 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

std::vector<std::string> const* edm::service::SiteLocalConfigService::m_nativeProtocolsPtr
private

Definition at line 87 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceNativeProtocols().

std::string edm::service::SiteLocalConfigService::m_readHint
private

Definition at line 77 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

std::string const* edm::service::SiteLocalConfigService::m_readHintPtr
private

Definition at line 78 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceReadHint().

std::string edm::service::SiteLocalConfigService::m_rfioType
private

Definition at line 67 of file SiteLocalConfigService.h.

Referenced by parse(), and rfioType().

std::string edm::service::SiteLocalConfigService::m_siteName
private

Definition at line 93 of file SiteLocalConfigService.h.

Referenced by parse(), and siteName().

edm::propagate_const<struct addrinfo*> edm::service::SiteLocalConfigService::m_statisticsAddrInfo
private
const std::string edm::service::SiteLocalConfigService::m_statisticsDefaultPort = "3334"
staticprivate

Definition at line 90 of file SiteLocalConfigService.h.

Referenced by computeStatisticsDestination().

std::string edm::service::SiteLocalConfigService::m_statisticsDestination
private
std::set<std::string> edm::service::SiteLocalConfigService::m_statisticsInfo
private

Definition at line 91 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and statisticsInfo().

bool edm::service::SiteLocalConfigService::m_statisticsInfoAvail
private

Definition at line 92 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and statisticsInfo().

unsigned int edm::service::SiteLocalConfigService::m_timeout
private

Definition at line 81 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

unsigned int const* edm::service::SiteLocalConfigService::m_timeoutPtr
private

Definition at line 82 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceTimeout().

unsigned int edm::service::SiteLocalConfigService::m_ttreeCacheSize
private

Definition at line 79 of file SiteLocalConfigService.h.

Referenced by parse(), and SiteLocalConfigService().

unsigned int const* edm::service::SiteLocalConfigService::m_ttreeCacheSizePtr
private

Definition at line 80 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and sourceTTreeCacheSize().

std::string edm::service::SiteLocalConfigService::m_url
private

Definition at line 64 of file SiteLocalConfigService.h.

Referenced by dataCatalogs(), frontierConnect(), and SiteLocalConfigService().

bool edm::service::SiteLocalConfigService::m_useLocalConnectString = false
private

Definition at line 94 of file SiteLocalConfigService.h.

Referenced by parse(), SiteLocalConfigService(), and useLocalConnectString().