| The Gaudi Framework v27r1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

DataOnDemandSvc.cpp
Go to the documentation of this file.
1 // ============================================================================
2 // Include files
3 // ============================================================================
4 // STD & STL
5 // ============================================================================
6 #include <string>
7 #include <set>
8 #include <map>
9 #include <math.h>
10 // ============================================================================
11 // GaudiKernel
12 // ============================================================================
13 #include "GaudiKernel/MsgStream.h"
14 #include "GaudiKernel/AttribStringParser.h"
15 #include "GaudiKernel/DataObject.h"
16 #include "GaudiKernel/IAlgorithm.h"
17 #include "GaudiKernel/ISvcLocator.h"
18 #include "GaudiKernel/IAlgManager.h"
19 #include "GaudiKernel/IIncidentSvc.h"
20 #include "GaudiKernel/DataIncident.h"
21 #include "GaudiKernel/IDataProviderSvc.h"
22 #include "GaudiKernel/IToolSvc.h"
23 #include "GaudiKernel/TypeNameString.h"
24 #include "GaudiKernel/ToStream.h"
25 #include "GaudiKernel/Chrono.h"
26 #include "GaudiKernel/LockedChrono.h"
27 #include "GaudiKernel/Property.h"
28 // ============================================================================
29 // Local
30 // ============================================================================
31 #include "DataOnDemandSvc.h"
32 // ============================================================================
33 // Boost
34 // ============================================================================
35 #include "boost/format.hpp"
36 #include "boost/algorithm/string/predicate.hpp"
37 // ============================================================================
38 // Constructors and Destructor
39 // ============================================================================
40 DataOnDemandSvc::DataOnDemandSvc
41 ( const std::string& name, ISvcLocator* svc )
42 : base_class( name, svc )
43 {
44 // ==========================================================================
45 declareProperty
46 ( "IncidentName" ,
47 m_trapType ,
48 "The type of handled Incident" ) ;
49 //
50 declareProperty ( "DataSvc" , m_dataSvcName ) ;
51 //
52 declareProperty ( "UsePreceedingPath" , m_partialPath ) ;
53 declareProperty
54 ( "Dump" ,
55 m_dump ,
56 "Dump the configuration and stastics" ) ->
57 declareUpdateHandler ( &DataOnDemandSvc::update_dump , this ) ;
58 //
59 declareProperty
60 ( "PreInitialize" ,
61 m_init ,
62 "Flag to (pre)initialize all algorithms" ) ;
63 declareProperty
64 ( "AllowPreInitializeFailure" ,
65 m_allowInitFailure ,
66 "Allow (pre)initialization of algorithms to fail without stopping the application" ) ;
67 //
68 declareProperty ( "Algorithms" , m_algMapping ) ->
69 declareUpdateHandler ( &DataOnDemandSvc::update_2 , this ) ;
70 declareProperty ( "Nodes" , m_nodeMapping ) ->
71 declareUpdateHandler ( &DataOnDemandSvc::update_3 , this ) ;
72 //
73 declareProperty ( "AlgMap" , m_algMap ) ->
74 declareUpdateHandler ( &DataOnDemandSvc::update_1 , this ) ;
75 declareProperty ( "NodeMap" , m_nodeMap ) ->
76 declareUpdateHandler ( &DataOnDemandSvc::update_1 , this ) ;
77
78 declareProperty ( "Prefix" , m_prefix ) ;
79
80 declareProperty("NodeMappingTools", m_nodeMapTools,
81 "List of tools of type IDODNodeMapper");
82 declareProperty("AlgMappingTools", m_algMapTools,
83 "List of tools of type IDODAlgMapper");
84 // ==========================================================================
85 }
86 // ============================================================================
87 // Update handler
88 // ============================================================================
89 void DataOnDemandSvc::update_1 ( Property& p )
90 {
91 verbose() << " I am update handler for property " << p << endmsg ;
92 // force update
93 m_updateRequired = true ;
94 }
95 // ============================================================================
96 // Update handler
97 // ============================================================================
98 void DataOnDemandSvc::update_3 ( Property& /* p */ )
99 {
100 warning()
101 << "The property 'Nodes' is obsolete, switch to map-like 'NodeMap' "
102 << " = { 'data' : 'type' } "
103 << endmsg ;
104 // force update
105 m_updateRequired = true ;
106 }
107 // ============================================================================
108 // Update handler
109 // ============================================================================
110 void DataOnDemandSvc::update_2 ( Property& /* p */ )
111 {
112 warning()
113 << "The property 'Algorithms' is obsolete, switch to map-like 'AlgMap' "
114 << " = { 'data' : 'algorithm' } "
115 << endmsg ;
116 // force update
117 m_updateRequired = true ;
118 }
119 // ============================================================================
120 // Update handler
121 // ============================================================================
122 void DataOnDemandSvc::update_dump ( Property& /* p */ )
123 {
124 // no action if not yet initialized
125 if ( FSMState() < Gaudi::StateMachine::INITIALIZED ) { return ; }
126 // dump the configuration:
127 if ( m_dump ) { dump ( MSG::ALWAYS ) ; }
128 }
129 // ============================================================================
130 // anonymous namespace to hide few local functions
131 // ============================================================================
132 namespace
133 {
134 // ==========================================================================
140 inline std::string no_prefix
141 ( const std::string& value ,
142 const std::string& prefix )
143 {
144 return boost::algorithm::starts_with(value,prefix) ?
145 value.substr( prefix.size() ) : value ;
146 }
147 // ==========================================================================
154 template <class MAP>
155 inline size_t add_prefix ( MAP& _map , const std::string& prefix )
156 {
157 // empty prefix
158 if ( prefix.empty() ) { return 0 ; } // RETURN
160 auto it = std::find_if_not( _map.begin(), _map.end(),
161 [&](typename MAP::const_reference i) {
162 return boost::algorithm::starts_with(i.first,prefix);
163 } );
164 if ( it == _map.end() ) return 0 ;
165 std::string key = prefix + it->first ;
166 std::string value = std::move(it->second); // steal the value we're about to erase..
167 _map.erase ( it ) ;
168 _map[ key ] = std::move(value); // and move it into its new location
169 return 1 + add_prefix ( _map , prefix ) ; // RETURN, recursion
170 //
171 }
172 // ==========================================================================
178 template <class SET>
179 inline size_t get_dir ( const std::string& object , SET& _set )
180 {
181 std::string::size_type ifind = object.rfind('/') ;
182 // stop recursion
183 if ( std::string::npos == ifind ) { return 0 ; } // RETURN
184 if ( 0 == ifind ) { return 0 ; }
185 //
186 const std::string top = std::string( object , 0 , ifind) ;
187 _set.insert( top ) ;
188 return 1 + get_dir ( top , _set ) ; // RETURN, recursion
189 }
190 // ==========================================================================
196 template <class MAP, class SET>
197 inline size_t get_dirs ( const MAP& _map, SET& _set )
198 {
199 size_t size = _set.size() ;
200 for ( const auto& item : _map )
201 { get_dir ( item.first , _set ) ; }
202 return _set.size() - size ;
203 }
204 // ==========================================================================
205 } // end of anonymous namespace
206
207 void DataOnDemandSvc::i_setNodeHandler(const std::string &name, const std::string &type){
208 ClassH cl = TClass::GetClass(type.c_str()) ;
209 if (!cl) {
210 warning()
211 << "Failed to access dictionary class for "
212 << name << " of type:" << type << endmsg;
213 }
214 m_nodes[name] = Node(cl, false, type);
215 }
216
217 StatusCode DataOnDemandSvc::i_setAlgHandler(const std::string &name, const Gaudi::Utils::TypeNameString &alg){
218 Leaf leaf(alg.type(), alg.name());
219 if (m_init)
220 {
221 StatusCode sc = configureHandler(leaf);
222 if (sc.isFailure()) {
223 if (m_allowInitFailure) {
224 // re-store the content of the leaf object to try again to initialize
225 // the algorithm later (on demand)
226 leaf = Leaf(alg.type(), alg.name());
227 }
228 else
229 return sc;
230 }
231 }
232 m_algs[name] = leaf;
233 return StatusCode::SUCCESS;
234 }
235
236 // ============================================================================
237 // update the content of Data-On-Demand actions
238 // ============================================================================
239 StatusCode DataOnDemandSvc::update ()
240 {
241 if ( !m_updateRequired ) { return StatusCode::SUCCESS ; }
242
244 StatusCode sc = setupNodeHandlers() ; // convert "Nodes" new "NodeMap"
245 if ( sc.isFailure() )
246 {
247 error() << "Failed to setup old \"Nodes\"" << endmsg ;
248 return sc ;
249 }
251 sc = setupAlgHandlers() ; // convert "Algorithms" into "AlgMap"
252 if ( sc.isFailure() )
253 {
254 error() << "Failed to setup old \"Algorithms\"" << endmsg ;
255 return sc ;
256 }
258 add_prefix ( m_algMap , m_prefix ) ;
260 add_prefix ( m_nodeMap , m_prefix ) ;
262 std::set<std::string> dirs ;
263 if ( m_partialPath ){ get_dirs ( m_algMap , dirs ) ; }
264 if ( m_partialPath ){ get_dirs ( m_nodeMap , dirs ) ; }
265 //
266 auto _e = dirs.find("/Event") ;
267 if ( dirs.end() != _e ) { dirs.erase( _e ) ; }
268 // add all directories as nodes
269 for ( const auto& dir : dirs )
270 {
271 if ( m_algMap .end () == m_algMap .find ( dir ) &&
272 m_nodeMap .end () == m_nodeMap .find ( dir ) )
273 m_nodeMap [dir] = "DataObject" ;
274 }
275 //
276 m_algs .clear () ;
277 m_nodes .clear () ;
278 //
280 for ( const auto& alg : m_algMap )
281 {
282 if (i_setAlgHandler(alg.first, alg.second).isFailure())
283 return StatusCode::FAILURE;
284 }
286 for ( const auto& node : m_nodeMap )
287 {
288 i_setNodeHandler(node.first, node.second);
289 }
291 m_updateRequired = false ;
292 //
293 return StatusCode::SUCCESS ;
294 }
295 //=============================================================================
296 // Inherited Service overrides:
297 //=============================================================================
298 StatusCode DataOnDemandSvc::initialize()
299 {
300 // initialize the Service Base class
301 StatusCode sc = Service::initialize();
302 if ( sc.isFailure() ) { return sc; }
303 sc = setup();
304 if ( sc.isFailure() ) { return sc; }
305 //
306 if ( m_dump ) { dump ( MSG::INFO ) ; }
307 else if ( msgLevel(MSG::DEBUG) ) { dump ( MSG::DEBUG ) ; }
308 //
309 if ( m_init ) { return update () ; }
310 //
311 return StatusCode::SUCCESS ;
312 }
313 // ============================================================================
314 // finalization of the service
315 // ============================================================================
316 StatusCode DataOnDemandSvc::finalize()
317 {
318 //
319 info()
320 << "Handled \"" << m_trapType << "\" incidents: "
321 << m_statAlg << "/" << m_statNode << "/" << m_stat << "(Alg/Node/Total)."
322 << endmsg ;
323 if ( m_dump || msgLevel(MSG::DEBUG) )
324 {
325 info()
326 << m_total.outputUserTime
327 ( "Algorithm timing: Mean(+-rms)/Min/Max:%3%(+-%4%)/%6%/%7%[ms] " , System::milliSec )
328 << m_total.outputUserTime ( "Total:%2%[s]" , System::Sec ) << endmsg ;
329 info()
330 << m_timer_nodes.outputUserTime
331 ( "Nodes timing: Mean(+-rms)/Min/Max:%3%(+-%4%)/%6%/%7%[ms] " , System::milliSec )
332 << m_timer_nodes.outputUserTime ( "Total:%2%[s]" , System::Sec ) << endmsg ;
333 info()
334 << m_timer_algs .outputUserTime
335 ( "Algs timing: Mean(+-rms)/Min/Max:%3%(+-%4%)/%6%/%7%[ms] " , System::milliSec )
336 << m_timer_algs .outputUserTime ( "Total:%2%[s]" , System::Sec ) << endmsg ;
337 info()
338 << m_timer_all .outputUserTime
339 ( "All timing: Mean(+-rms)/Min/Max:%3%(+-%4%)/%6%/%7%[ms] " , System::milliSec )
340 << m_timer_all .outputUserTime ( "Total:%2%[s]" , System::Sec ) << endmsg ;
341 }
342 // dump it!
343 if ( m_dump ) { dump ( MSG::INFO , false ) ; }
344 else if ( msgLevel(MSG::DEBUG) ) { dump ( MSG::DEBUG , false ) ; }
345 //
346 if ( m_incSvc )
347 {
348 m_incSvc->removeListener(this, m_trapType);
349 m_incSvc.reset();
350 }
351 m_algMgr.reset();
352 m_dataSvc.reset();
353 if (m_toolSvc) { // we may not have retrieved the ToolSvc
354 // Do not call releaseTool if the ToolSvc was already finalized.
355 if (SmartIF<IStateful>(m_toolSvc)->FSMState() > Gaudi::StateMachine::CONFIGURED) {
356 for(const auto& i : m_nodeMappers ) m_toolSvc->releaseTool(i).ignore();
357 for(const auto& i : m_algMappers ) m_toolSvc->releaseTool(i).ignore();
358 } else {
359 warning() << "ToolSvc already finalized: cannot release tools. Check options." << endmsg;
360 }
361 m_nodeMappers.clear();
362 m_algMappers.clear();
363 m_toolSvc.reset();
364 }
365 return Service::finalize();
366 }
367 // ============================================================================
369 // ============================================================================
370 StatusCode DataOnDemandSvc::reinitialize()
371 {
372 // reinitialize the Service Base class
373 if ( m_incSvc )
374 {
375 m_incSvc -> removeListener ( this , m_trapType );
376 m_incSvc.reset();
377 }
378 m_algMgr.reset();
379 m_dataSvc.reset();
380 for(const auto& i : m_nodeMappers ) m_toolSvc->releaseTool(i).ignore();
381 m_nodeMappers.clear();
382 for(const auto& i : m_algMappers ) m_toolSvc->releaseTool(i).ignore();
383 m_algMappers.clear();
384 m_toolSvc.reset();
385 //
386 StatusCode sc = Service::reinitialize();
387 if ( sc.isFailure() ) { return sc; }
388 //
389 sc = setup() ;
390 if ( sc.isFailure() ) { return sc; }
391 //
392 if ( m_dump ) { dump ( MSG::INFO ) ; }
393 else if ( msgLevel(MSG::DEBUG) ) { dump ( MSG::DEBUG ) ; }
394 //
395 return StatusCode::SUCCESS ;
396 }
397 // ============================================================================
398 // setup service
399 // ============================================================================
400 StatusCode DataOnDemandSvc::setup()
401 {
402 if ( !(m_algMgr = serviceLocator()) ) // assignment meant
403 {
404 error() << "Failed to retrieve the IAlgManager interface." << endmsg;
405 return StatusCode::FAILURE;
406 }
407
408 if ( !(m_incSvc = serviceLocator()->service("IncidentSvc")) ) // assignment meant
409 {
410 error() << "Failed to retrieve Incident service." << endmsg;
411 return StatusCode::FAILURE;
412 }
413 m_incSvc->addListener(this, m_trapType);
414
415 if ( !(m_dataSvc = serviceLocator()->service(m_dataSvcName)) ) // assignment meant
416 {
417 error()
418 << "Failed to retrieve the data provider interface of "
419 << m_dataSvcName << endmsg;
420 return StatusCode::FAILURE;
421 }
422
423 // No need to get the ToolSvc if we are not using tools
424 if (!(m_nodeMapTools.empty() && m_algMapTools.empty())) {
425 if ( !(m_toolSvc = serviceLocator()->service("ToolSvc")) ) // assignment meant
426 {
427 error() << "Failed to retrieve ToolSvc" << endmsg;
428 return StatusCode::FAILURE;
429 }
430
431 // load the node mapping tools
432 IDODNodeMapper *nodetool = nullptr;
433 for(const auto& i : m_nodeMapTools) {
434 const StatusCode sc = m_toolSvc->retrieveTool(i, nodetool);
435 if (sc.isFailure()) return sc;
436 m_nodeMappers.push_back(nodetool);
437 }
438 IDODAlgMapper *algtool = nullptr;
439 for(const auto& i : m_algMapTools) {
440 const StatusCode sc = m_toolSvc->retrieveTool(i, algtool);
441 if (sc.isFailure()) return sc;
442 m_algMappers.push_back(algtool);
443 }
444 }
445 return update();
446 }
447 // ============================================================================
448 // setup node handlers
449 // ============================================================================
450 StatusCode DataOnDemandSvc::setupNodeHandlers()
451 {
452 std::string nam, typ, tag;
453 StatusCode sc = StatusCode::SUCCESS;
454 // Setup for node leafs, where simply a constructor is called...
455 for (auto node: m_nodeMapping)
456 {
457 using Parser = Gaudi::Utils::AttribStringParser;
458 for (auto attrib: Parser(node)) {
459 switch( ::toupper(attrib.tag[0]) ) {
460 case 'D':
461 tag = std::move(attrib.value);
462 break;
463 case 'T':
464 nam = std::move(attrib.value);
465 break;
466 }
467 }
468 if ( m_algMap .end () != m_algMap .find ( tag ) ||
469 m_nodeMap .end () != m_nodeMap .find ( tag ) )
470 {
471 warning()
472 << "The obsolete property 'Nodes' redefines the action for '"
473 + tag + "' to be '" +nam+"'"
474 << endmsg ;
475 }
476 m_nodeMap[tag] = nam ;
477 }
478 //
479 m_updateRequired = true ;
480 //
481 return sc;
482 }
483 // ============================================================================
484 // setup algorithm handlers
485 // ============================================================================
486 StatusCode DataOnDemandSvc::setupAlgHandlers()
487 {
488 std::string typ, tag;
489
490 for (auto alg: m_algMapping)
491 {
492 using Parser = Gaudi::Utils::AttribStringParser;
493 for (auto attrib: Parser(alg)) {
494 switch( ::toupper(attrib.tag[0]) ) {
495 case 'D':
496 tag = std::move(attrib.value);
497 break;
498 case 'T':
499 typ = std::move(attrib.value);
500 break;
501 }
502 }
503 Gaudi::Utils::TypeNameString item(typ);
504 if ( m_algMap .end () != m_algMap .find ( tag ) ||
505 m_nodeMap .end () != m_nodeMap .find ( tag ) )
506 {
507 warning()
508 << "The obsolete property 'Algorithms' redefines the action for '"
509 + tag + "' to be '" +item.type() +"/"+item.name()+"'"
510 << endmsg ;
511 }
512 m_algMap[tag] = item.type() + "/" + item.name() ;
513 }
514 m_updateRequired = true ;
515 return StatusCode::SUCCESS;
516 }
517 // ============================================================================
519 // ============================================================================
520 StatusCode DataOnDemandSvc::configureHandler(Leaf& l)
521 {
522 if ( l.algorithm ) { return StatusCode::SUCCESS ; }
523 if ( ! m_algMgr ) { return StatusCode::FAILURE ; }
524 l.algorithm = m_algMgr->algorithm(l.name, false);
525 if ( l.algorithm ) { return StatusCode::SUCCESS ; }
526 // create it!
527 StatusCode sc = m_algMgr->createAlgorithm ( l.type , l.name , l.algorithm , true ) ;
528 if ( sc.isFailure() )
529 {
530 error()
531 << "Failed to create algorithm "
532 << l.type << "('" << l.name<< "')" << endmsg;
533 l.algorithm = nullptr ;
534 return sc ; // RETURN
535 }
536 if ( l.algorithm->isInitialized() ) { return StatusCode:: SUCCESS ;}
537 // initialize it!
538 sc = l.algorithm -> sysInitialize () ;
539 if ( sc.isFailure() )
540 {
541 error()
542 << "Failed to initialize algorithm "
543 << l.type << "('" << l.name<< "')" << endmsg;
544 l.algorithm = nullptr ;
545 return sc ; // RETURN
546 }
547 if ( Gaudi::StateMachine::RUNNING == l.algorithm->FSMState() )
548 { return StatusCode::SUCCESS ; }
549 // run it!
550 sc = l.algorithm->sysStart() ;
551 if ( sc.isFailure() )
552 {
553 error()
554 << "Failed to 'run' algorithm "
555 << l.type << "('" << l.name<< "')" << endmsg;
556 l.algorithm = nullptr ;
557 return sc ; // RETURN
558 }
559 return StatusCode::SUCCESS ;
560 }
561
562 // local algorithms
563 namespace {
566 struct ToolGetter {
568 std::string path;
570 ToolGetter(std::string _path): path(std::move(_path)) {}
572 inline std::string operator() (IDODNodeMapper *t) const {
573 return t->nodeTypeForPath(path);
574 }
576 inline Gaudi::Utils::TypeNameString operator() (IDODAlgMapper *t) const {
577 return t->algorithmForPath(path);
578 }
579 };
580
583 inline bool isGood(const std::string& r) {return !r.empty();}
584 inline bool isGood(const Gaudi::Utils::TypeNameString& r) {return !r.name().empty();}
586
589 class Finder {
590 const ToolGetter getter;
591 const std::vector<IDODNodeMapper*> &nodes;
592 const std::vector<IDODAlgMapper*> &algs;
594 template <class R, class C>
595 R find(const C& l) const {
596 for(auto& i : l ){
597 auto result = getter(i);
598 if (isGood(result)) return result;
599 }
600 return R{""};
601 }
602 public:
604 Finder(std::string _path,
605 const std::vector<IDODNodeMapper*> &_nodes,
606 const std::vector<IDODAlgMapper*> &_algs)
607 : getter(std::move(_path)), nodes(_nodes), algs(_algs) {
608 }
610 inline std::string node() const {
611 return find<std::string>(nodes);
612 }
614 inline Gaudi::Utils::TypeNameString alg() const {
615 return find<Gaudi::Utils::TypeNameString>(algs);
616 }
617
618 };
619
620 }
621
622 // ===========================================================================
623 // IIncidentListener interfaces overrides: incident handling
624 // ===========================================================================
625 void DataOnDemandSvc::handle ( const Incident& incident )
626 {
627
628 Gaudi::Utils::LockedChrono timer ( m_timer_all , m_locked_all ) ;
629
630 ++m_stat ;
631 // proper incident type?
632 if ( incident.type() != m_trapType ) { return ; } // RETURN
633 const DataIncident* inc = dynamic_cast<const DataIncident*>(&incident);
634 if ( ! inc ) { return ; } // RETURN
635 // update if needed!
636 if ( m_updateRequired ) { update() ; }
637
638 if ( msgLevel(MSG::VERBOSE) )
639 {
640 verbose()
641 << "Incident: [" << incident.type () << "] "
642 << " = " << incident.source ()
643 << " Location:" << inc->tag() << endmsg;
644 }
645 // ==========================================================================
646 Gaudi::StringKey tag ( inc->tag() ) ;
647 // ==========================================================================
648 auto icl = m_nodes.find ( tag ) ;
649 if ( icl != m_nodes.end() )
650 {
651 StatusCode sc = execHandler ( tag , icl->second ) ;
652 if ( sc.isSuccess() ) { ++m_statNode ; }
653 return ; // RETURN
654 }
655 // ==========================================================================
656 auto ialg = m_algs.find ( tag ) ;
657 if ( ialg != m_algs.end() )
658 {
659 StatusCode sc = execHandler ( tag , ialg->second ) ;
660 if ( sc.isSuccess() ) { ++m_statAlg ; }
661 return ; // RETURN
662 }
663 // ==========================================================================
664 // Fall back on the tools
665 if (m_toolSvc) {
666 if ( msgLevel(MSG::VERBOSE))
667 verbose() << "Try to find mapping with mapping tools" << endmsg;
668 Finder finder(no_prefix(inc->tag(), m_prefix), m_nodeMappers, m_algMappers);
669 // - try the node mappers
670 std::string node = finder.node();
671 if (isGood(node)) {
672 // if one is found update the internal node mapping and try again.
673 if (msgLevel(MSG::VERBOSE))
674 verbose() << "Found Node handler: " << node << endmsg;
675 i_setNodeHandler(inc->tag(), node);
676 handle(incident);
677 --m_stat; // avoid double counting because of recursion
678 return;
679 }
680 // - try alg mappings
681 Gaudi::Utils::TypeNameString alg = finder.alg();
682 if (isGood(alg)) {
683 // we got an algorithm, update alg map and try to handle again
684 if (msgLevel(MSG::VERBOSE))
685 verbose() << "Found Algorithm handler: " << alg << endmsg;
686 i_setAlgHandler(inc->tag(), alg).ignore();
687 handle(incident);
688 --m_stat; // avoid double counting because of recursion
689 return;
690 }
691 }
692 }
693 // ===========================================================================
694 // execute the handler
695 // ===========================================================================
696 StatusCode
697 DataOnDemandSvc::execHandler ( const std::string& tag, Node& n)
698 {
699
700 Gaudi::Utils::LockedChrono timer ( m_timer_nodes , m_locked_nodes ) ;
701
702 if ( n.executing ) { return StatusCode::FAILURE ; } // RETURN
703
704 Protection p(n.executing);
705
706 std::unique_ptr<DataObject> object;
707
708 if ( n.dataObject ) { object.reset( new DataObject() ) ; }
709 else
710 {
711 // try to recover the handler
712 if ( !n.clazz ) { n.clazz = TClass::GetClass(n.name.c_str()) ; }
713 if ( !n.clazz )
714 {
715 error()
716 << "Failed to get dictionary for class '"
717 << n.name
718 << "' for location:" << tag << endmsg;
719 return StatusCode::FAILURE ; // RETURN
720 }
721
722 object.reset( reinterpret_cast<DataObject*>(n.clazz->New()) );
723
724 if ( !object )
725 {
726 error()
727 << "Failed to create an object of type:"
728 << n.clazz->GetName() << " for location:" << tag
729 << endmsg;
730 return StatusCode::FAILURE ; // RETURN
731 }
732 }
733 //
734 StatusCode sc = m_dataSvc->registerObject(tag, object.release() );
735 if ( sc.isFailure() )
736 {
737 error() << "Failed to register an object of type:"
738 << n.name << " at location:" << tag
739 << endmsg;
740 return sc ; // RETURN
741 }
742 ++n.num ;
743 //
744 return StatusCode::SUCCESS ;
745 }
746 // ===========================================================================
747 // execute the handler
748 // ===========================================================================
749 StatusCode
750 DataOnDemandSvc::execHandler(const std::string& tag, Leaf& l)
751 {
752 Gaudi::Utils::LockedChrono timer ( m_timer_algs , m_locked_algs ) ;
753 //
754 if ( l.executing ) { return StatusCode::FAILURE ; } // RETURN
755 //
756 if ( ! l.algorithm )
757 {
758 StatusCode sc = configureHandler ( l ) ;
759 if ( sc.isFailure() )
760 {
761 error()
762 << "Failed to configure handler for: "
763 << l.name << "[" << l.type << "] " << tag << endmsg;
764 return sc ; // RETURN
765 }
766 }
767 //
768 Chrono atimer ( m_total ) ;
769 //
770 Protection p(l.executing);
771 StatusCode sc = l.algorithm->sysExecute();
772 if ( sc.isFailure() )
773 {
774 error() << "Failed to execute the algorithm:"
775 << l.algorithm->name() << " for location:" << tag << endmsg;
776 return sc ; // RETURN
777 }
778 ++l.num ;
779 //
780 return StatusCode::SUCCESS ;
781 }
782 // ============================================================================
783 /* dump the content of DataOnDemand service
784 * @param level the printout level
785 * @param mode the printout mode
786 */
787 // ============================================================================
788 void DataOnDemandSvc::dump
789 ( const MSG::Level level ,
790 const bool mode ) const
791 {
792 if ( m_algs.empty() && m_nodes.empty() ) { return ; }
793
794 typedef std::pair<std::string,std::string> Pair ;
795 std::map<std::string,Pair> _m ;
796 for ( auto& alg : m_algs )
797 {
798 auto check = _m.find(alg.first) ;
799 if ( _m.end() != check )
800 {
801 warning() << " The data item is activated for '"
802 << check->first << "' as '" << check->second.first << "'" << endmsg ;
803 }
804 const Leaf& l = alg.second ;
805 std::string nam = ( l.name == l.type ? l.type : (l.type+"/"+l.name) ) ;
806 //
807 if ( !mode && 0 == l.num ) { continue ; }
808 //
809 std::string val ;
810 if ( mode ) { val = ( ! l.algorithm ) ? "F" : "T" ; }
811 else { val = std::to_string( l.num ) ; }
812 //
813 _m[ no_prefix ( alg.first , m_prefix ) ] = { nam , val } ;
814 }
815 // nodes:
816 for ( const auto& node : m_nodes )
817 {
818 auto check = _m.find(node.first) ;
819 if ( _m.end() != check )
820 {
821 warning() << " The data item is already activated for '"
822 << check->first << "' as '" << check->second.first << "'" << endmsg ;
823 }
824 const Node& n = node.second ;
825 std::string nam = "'" + n.name + "'" ;
826 //
827 std::string val ;
828
829 if ( !mode && 0 == n.num ) { continue ; }
830
831 if ( mode ) { val = ( 0 == n.clazz ) ? "F" : "T" ; }
832 else { val = std::to_string( n.num ) ; }
833 //
834 _m[ no_prefix ( node.first , m_prefix ) ] = { nam , val } ;
835 }
836 //
837 if ( _m.empty() ) { return ; }
838
839 // find the correct formats
840 size_t n1 = 0 ;
841 size_t n2 = 0 ;
842 size_t n3 = 0 ;
843 for ( const auto& i : _m )
844 {
845 n1 = std::max ( n1 , i.first.size() ) ;
846 n2 = std::max ( n2 , i.second.first.size() ) ;
847 n3 = std::max ( n3 , i.second.second.size() ) ;
848 }
849 if ( 10 > n1 ) { n1 = 10 ; }
850 if ( 10 > n2 ) { n2 = 10 ; }
851 if ( 60 < n1 ) { n1 = 60 ; }
852 if ( 60 < n2 ) { n2 = 60 ; }
853 //
854
855 const std::string _f = " | %%1$-%1%.%1%s | %%2$-%2%.%2%s | %%3$%3%.%3%s |" ;
856 boost::format _ff ( _f ) ;
857 _ff % n1 % n2 % n3 ;
858
859 const std::string _format = _ff.str() ;
860
861 auto& msg = msgStream(level);
862
863 if ( mode ) { msg << "Data-On-Demand Actions enabled for:" ; }
864 else { msg << "Data-On-Demand Actions has been used for:" ; }
865
866 boost::format fmt1( _format) ;
867 fmt1 % "Address" % "Creator" % ( mode ? "S" : "#" ) ;
868 //
869 const std::string header = fmt1.str() ;
870 std::string line = std::string( header.size() , '-' ) ;
871 line[0] = ' ' ;
872
873 msg << '\n' << line
874 << '\n' << header
875 << '\n' << line ;
876
877 // make the actual printout:
878 for ( const auto& item : _m )
879 {
880 boost::format fmt( _format) ;
881 msg << '\n' <<
882 ( fmt % item.first % item.second.first % item.second.second ) ;
883 }
884
885 msg << '\n' << line << endmsg ;
886
887 }
888 // ============================================================================
892 DECLARE_COMPONENT(DataOnDemandSvc)
893 // ============================================================================
894
895 // ============================================================================
896 // The END
897 // ============================================================================
DataOnDemandSvc::i_setNodeHandler
void i_setNodeHandler(const std::string &name, const std::string &type)
Internal method to initialize a node handler.
Definition: DataOnDemandSvc.cpp:207
Gaudi::Utils::AttribStringParser
Parse attribute strings allowing iteration over the various attributes.
Definition: AttribStringParser.h:30
IAlgManager::algorithm
virtual SmartIF< IAlgorithm > & algorithm(const Gaudi::Utils::TypeNameString &typeName, const bool createIf=true)=0
Returns a smart pointer to a service.
DataOnDemandSvc::m_timer_all
ChronoEntity m_timer_all
Definition: DataOnDemandSvc.h:284
Service::initialize
StatusCode initialize() override
Definition: Service.cpp:68
Gaudi::StateMachine::INITIALIZED
Definition: StateMachine.h:15
SmartIF< IStateful >
Service::serviceLocator
SmartIF< ISvcLocator > & serviceLocator() const override
Retrieve pointer to service locator.
Definition: Service.cpp:324
DataOnDemandSvc::Node::name
std::string name
Definition: DataOnDemandSvc.h:120
std::string::empty
T empty(T...args)
DataOnDemandSvc.h
ISvcLocator
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Definition: ISvcLocator.h:25
format
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".
Definition: MsgStream.cpp:119
DataOnDemandSvc::Node::num
unsigned long num
Definition: DataOnDemandSvc.h:121
Incident::type
const std::string & type() const
Access to the incident type.
Definition: Incident.h:41
Gaudi::StateMachine::CONFIGURED
Definition: StateMachine.h:14
DataOnDemandSvc::ClassH
TClass * ClassH
Definition: DataOnDemandSvc.h:97
gaudiComponentHelp.name
name
Definition: gaudiComponentHelp.py:28
DataOnDemandSvc
The DataOnDemandSvc listens to incidents typically triggered by the data service of the configurable ...
Definition: DataOnDemandSvc.h:90
Service::finalize
StatusCode finalize() override
Definition: Service.cpp:193
IAlgorithm::sysStart
virtual StatusCode sysStart()=0
Startup method invoked by the framework.
DataOnDemandSvc::m_timer_algs
ChronoEntity m_timer_algs
Definition: DataOnDemandSvc.h:283
GaudiMP.FdsRegistry.msg
tuple msg
Definition: FdsRegistry.py:8
Service::FSMState
Gaudi::StateMachine::State FSMState() const override
Definition: Service.h:57
MsgStream.h
CommonMessagingBase::info
MsgStream & info() const
shortcut for the method msgStream(MSG::INFO)
Definition: CommonMessaging.h:124
DataOnDemandSvc::m_stat
ulonglong m_stat
Definition: DataOnDemandSvc.h:280
validate_patch.check
def check(path)
Definition: validate_patch.py:152
Incident::source
const std::string & source() const
Access to the source of the incident.
Definition: Incident.h:47
IAlgorithm.h
DataOnDemandSvc::m_nodeMappers
std::vector< IDODNodeMapper * > m_nodeMappers
Definition: DataOnDemandSvc.h:290
StatusCode::isSuccess
bool isSuccess() const
Test for a status code of SUCCESS.
Definition: StatusCode.h:76
DataOnDemandSvc::Leaf::type
std::string type
Definition: DataOnDemandSvc.h:152
DataOnDemandSvc::m_incSvc
SmartIF< IIncidentSvc > m_incSvc
Incident service.
Definition: DataOnDemandSvc.h:240
DataOnDemandSvc::handle
void handle(const Incident &incident) override
IIncidentListener interfaces overrides: incident handling.
Definition: DataOnDemandSvc.cpp:625
DataOnDemandSvc::Leaf::algorithm
IAlgorithm * algorithm
Definition: DataOnDemandSvc.h:150
std::to_string
T to_string(T...args)
CommonMessagingBase::verbose
MsgStream & verbose() const
shortcut for the method msgStream(MSG::VERBOSE)
Definition: CommonMessaging.h:130
MSG::DEBUG
Definition: IMessageSvc.h:18
IAlgManager::createAlgorithm
virtual StatusCode createAlgorithm(const std::string &algtype, const std::string &algname, IAlgorithm *&alg, bool managed=false, bool checkIfExists=true)=0
Create an instance of a algorithm type that has been declared beforehand and assigns to it a name...
DataOnDemandSvc::m_algMapTools
std::vector< std::string > m_algMapTools
Definition: DataOnDemandSvc.h:291
DataOnDemandSvc::m_trapType
std::string m_trapType
Trap name.
Definition: DataOnDemandSvc.h:248
std
STL namespace.
DataOnDemandSvc::m_locked_nodes
bool m_locked_nodes
Definition: DataOnDemandSvc.h:285
DataOnDemandSvc::Leaf
Definition: DataOnDemandSvc.h:148
DataOnDemandSvc::m_dataSvcName
std::string m_dataSvcName
Data service name.
Definition: DataOnDemandSvc.h:250
Chrono.h
std::set::end
T end(T...args)
DataOnDemandSvc::m_nodeMapping
Setup m_nodeMapping
Mapping to nodes.
Definition: DataOnDemandSvc.h:263
DataOnDemandSvc::Leaf::executing
bool executing
Definition: DataOnDemandSvc.h:154
Chrono
A small utility class for chronometry of user codes.
Definition: Chrono.h:25
DataOnDemandSvc::m_algMap
Map m_algMap
the major configuration property { 'data' : 'algorithm' }
Definition: DataOnDemandSvc.h:271
DataOnDemandSvc::m_statAlg
ulonglong m_statAlg
Definition: DataOnDemandSvc.h:278
System::milliSec
Definition: Timing.h:51
SET
#define SET(x)
MSG::VERBOSE
Definition: IMessageSvc.h:17
merge_files.sc
int sc
Definition: merge_files.py:167
DataOnDemandSvc::initialize
StatusCode initialize() override
Inherited Service overrides: Service initialization.
Definition: DataOnDemandSvc.cpp:298
IToolSvc.h
std::map
STL class.
StatusCode::isFailure
bool isFailure() const
Test for a status code of FAILURE.
Definition: StatusCode.h:86
GaudiPluginService.cpluginsvc.n
list n
Definition: cpluginsvc.py:217
IToolSvc::retrieveTool
StatusCode retrieveTool(const std::string &type, T *&tool, const IInterface *parent=nullptr, bool createIf=true)
Retrieve specified tool sub-type with tool dependent part of the name automatically assigned...
Definition: IToolSvc.h:145
Gaudi::StringKey
The helper class to represent the efficient "key" for access.
Definition: StringKey.h:35
System::Sec
Definition: Timing.h:51
IAlgorithm::sysExecute
virtual StatusCode sysExecute()=0
System execution. This method invokes the execute() method of a concrete algorithm.
DECLARE_COMPONENT
#define DECLARE_COMPONENT(type)
Definition: PluginService.h:36
std::string
STL class.
DataOnDemandSvc::m_dataSvc
SmartIF< IDataProviderSvc > m_dataSvc
Data provider reference.
Definition: DataOnDemandSvc.h:244
DataOnDemandSvc::m_statNode
ulonglong m_statNode
Definition: DataOnDemandSvc.h:279
ISvcLocator::service
StatusCode service(const Gaudi::Utils::TypeNameString &name, T *&svc, bool createIf=true)
Templated method to access a service by name.
Definition: ISvcLocator.h:78
Service::name
const std::string & name() const override
Retrieve name of the service.
Definition: Service.cpp:319
DataOnDemandSvc::Node::clazz
ClassH clazz
the actual class
Definition: DataOnDemandSvc.h:119
MSG::Level
Level
Definition: IMessageSvc.h:15
std::vector::push_back
T push_back(T...args)
CommonMessagingBase::error
MsgStream & error() const
shortcut for the method msgStream(MSG::ERROR)
Definition: CommonMessaging.h:118
IDODNodeMapper
Interface of tools used by the DataOnDemandSvc to choose the type of node to be created at a path...
Definition: IDODNodeMapper.h:17
DataOnDemandSvc::m_algMapping
Setup m_algMapping
Mapping to algorithms.
Definition: DataOnDemandSvc.h:261
plotSpeedupsPyRoot.line
tuple line
Definition: plotSpeedupsPyRoot.py:164
GaudiUtils::Map::end
iterator end()
Definition: Map.h:132
Gaudi::Utils::TypeNameString
Helper class to parse a string of format "type/name".
Definition: TypeNameString.h:9
IDataProviderSvc.h
gaudirun.type
string type
Definition: gaudirun.py:151
DataOnDemandSvc::setup
StatusCode setup()
Setup routine (called by (re-) initialize.
Definition: DataOnDemandSvc.cpp:400
CommonMessagingBase::warning
MsgStream & warning() const
shortcut for the method msgStream(MSG::WARNING)
Definition: CommonMessaging.h:121
DataOnDemandSvc::Leaf::num
unsigned long num
Definition: DataOnDemandSvc.h:153
DataOnDemandSvc::m_allowInitFailure
bool m_allowInitFailure
flag to allow DataOnDemand initialization to succeed even if the (pre)initialization of the algorithm...
Definition: DataOnDemandSvc.h:259
StatusCode::FAILURE
Definition: StatusCode.h:29
IIncidentSvc.h
DataOnDemandSvc::execHandler
StatusCode execHandler(const std::string &tag, Leaf &leaf)
Execute leaf handler (algorithm)
Definition: DataOnDemandSvc.cpp:750
StatusCode::SUCCESS
Definition: StatusCode.h:30
StatusCode
This class is used for returning status codes from appropriate routines.
Definition: StatusCode.h:26
DataOnDemandSvc::update_dump
void update_dump(Property &)
update handler for 'Dump' property
Definition: DataOnDemandSvc.cpp:122
DataOnDemandSvc::setupNodeHandlers
StatusCode setupNodeHandlers()
Initialize node handlers.
Definition: DataOnDemandSvc.cpp:450
std::set::erase
T erase(T...args)
GaudiUtils::Map::find
iterator find(const key_type &key)
Definition: Map.h:149
DataOnDemandSvc::Protection
Helper class of the DataOnDemandSvc.
Definition: DataOnDemandSvc.h:103
IDODAlgMapper::algorithmForPath
virtual Gaudi::Utils::TypeNameString algorithmForPath(const std::string &path)=0
For the given path, returns a TypeNameString object identifying the algorithm to be run to produce th...
DataOnDemandSvc::m_nodeMapTools
std::vector< std::string > m_nodeMapTools
Definition: DataOnDemandSvc.h:289
dump_component_properties.value
list value
Definition: dump_component_properties.py:12
DataOnDemandSvc::m_nodes
NodeMap m_nodes
Map of "empty" objects to be placed as intermediate nodes.
Definition: DataOnDemandSvc.h:267
end
auto end(reverse_wrapper< T > &w)
Definition: reverse.h:47
DataOnDemandSvc::m_prefix
std::string m_prefix
Definition: DataOnDemandSvc.h:275
Service::reinitialize
StatusCode reinitialize() override
Definition: Service.cpp:282
DataOnDemandSvc::dump
void dump(const MSG::Level level, const bool mode=true) const
dump the content of DataOnDemand service
Definition: DataOnDemandSvc.cpp:789
std::vector::clear
T clear(T...args)
std::max
T max(T...args)
LockedChrono.h
std::move
T move(T...args)
Gaudi::Utils::Histos::path
GAUDI_API std::string path(const AIDA::IBaseHistogram *aida)
get the path in THS for AIDA histogram
Definition: HistoTableFormat.cpp:191
gaudirun.l
dictionary l
Definition: gaudirun.py:421
std::pair< std::string, std::string >
DataOnDemandSvc::m_partialPath
bool m_partialPath
Flag to allow for the creation of partial leaves.
Definition: DataOnDemandSvc.h:252
GaudiPython.Bindings.DataObject
DataObject
Definition: Bindings.py:50
ChronoEntity::outputUserTime
std::string outputUserTime() const
print the chrono ;
Definition: ChronoEntity.cpp:85
std::find_if_not
T find_if_not(T...args)
std::string::size
T size(T...args)
Gaudi::StateMachine::RUNNING
Definition: StateMachine.h:16
std::set< std::string >
DataOnDemandSvc::m_algMappers
std::vector< IDODAlgMapper * > m_algMappers
Definition: DataOnDemandSvc.h:292
DataOnDemandSvc::Leaf::name
std::string name
Definition: DataOnDemandSvc.h:151
IDODAlgMapper
Interface of tools used by the DataOnDemandSvc to choose the algorithm to be run to produce the data ...
Definition: IDODAlgMapper.h:17
Property
Property base class allowing Property* collections to be "homogeneous".
Definition: Property.h:38
HiveAlgSequencer.top
tuple top
Definition: HiveAlgSequencer.py:29
std::vector< IDODNodeMapper * >
DataOnDemandSvc::m_algMgr
SmartIF< IAlgManager > m_algMgr
Algorithm manager.
Definition: DataOnDemandSvc.h:242
std::unique_ptr
STL class.
DataOnDemandSvc::m_toolSvc
SmartIF< IToolSvc > m_toolSvc
Data provider reference.
Definition: DataOnDemandSvc.h:246
Gaudi::Utils::LockedChrono
Helper object, useful for measurement of CPU-performance of highly-recursive structures, e.g.
Definition: LockedChrono.h:52
DataOnDemandSvc::Node::executing
bool executing
Definition: DataOnDemandSvc.h:122
DataOnDemandSvc::m_algs
AlgMap m_algs
Map of algorithms to handle incidents.
Definition: DataOnDemandSvc.h:265
DataOnDemandSvc::m_dump
bool m_dump
flag to force the printout
Definition: DataOnDemandSvc.h:254
DataOnDemandSvc::m_init
bool m_init
flag to warm up the configuration
Definition: DataOnDemandSvc.h:256
Gaudi::Utils::TypeNameString::type
const std::string & type() const
Definition: TypeNameString.h:22
DataOnDemandSvc::m_timer_nodes
ChronoEntity m_timer_nodes
Definition: DataOnDemandSvc.h:282
Property.h
std::string::c_str
T c_str(T...args)
Incident
Base class for all Incidents (computing events).
Definition: Incident.h:17
DataOnDemandSvc::m_updateRequired
bool m_updateRequired
Definition: DataOnDemandSvc.h:274
IIncidentSvc::addListener
virtual void addListener(IIncidentListener *lis, const std::string &type="", long priority=0, bool rethrow=false, bool singleShot=false)=0
Add listener.
DataOnDemandSvc::Node::dataObject
bool dataObject
trivial object? DataObject?
Definition: DataOnDemandSvc.h:124
DataOnDemandSvc::DataOnDemandSvc
DataOnDemandSvc(const std::string &name, ISvcLocator *svc)
Standard initializing service constructor.
Definition: DataOnDemandSvc.cpp:41
DataOnDemandSvc::finalize
StatusCode finalize() override
Inherited Service overrides: Service finalization.
Definition: DataOnDemandSvc.cpp:316
TypeNameString.h
ana.item
tuple item
print s1,s2
Definition: ana.py:146
AttribStringParser.h
CommonMessaging
Definition: CommonMessaging.h:58
std::string::substr
T substr(T...args)
IAlgManager.h
GaudiUtils::Map::clear
void clear()
Definition: Map.h:178
Service::service
StatusCode service(const std::string &name, const T *&psvc, bool createIf=true) const
Access a service by name, creating it if it doesn't already exist.
Definition: Service.h:144
gaudirun.level
level
Definition: gaudirun.py:261
IToolSvc::releaseTool
virtual StatusCode releaseTool(IAlgTool *tool)=0
Release the tool.
DataOnDemandSvc::m_total
ChronoEntity m_total
Definition: DataOnDemandSvc.h:277
SmartIF::reset
void reset(TYPE *ptr=nullptr)
Set the internal pointer to the passed one disposing of the old one.
Definition: SmartIF.h:88
IAlgorithm::isInitialized
virtual bool isInitialized() const =0
check if the algorithm is initialized properly
DataOnDemandSvc::m_nodeMap
Map m_nodeMap
the major configuration property { 'data' : 'type' }
Definition: DataOnDemandSvc.h:273
IIncidentSvc::removeListener
virtual void removeListener(IIncidentListener *lis, const std::string &type="")=0
Remove listener.
DataIncident
Data service incident class.
Gaudi::Utils::TypeNameString::name
const std::string & name() const
Definition: TypeNameString.h:23
ToStream.h
implementation of various functions for streaming.
StatusCode::ignore
void ignore() const
Definition: StatusCode.h:108
Test.header
list header
Definition: Test.py:33
DataOnDemandSvc::setupAlgHandlers
StatusCode setupAlgHandlers()
Initialize leaf handlers.
Definition: DataOnDemandSvc.cpp:486
DataOnDemandSvc::Node
Helper class of the DataOnDemandSvc.
Definition: DataOnDemandSvc.h:115
IDODNodeMapper::nodeTypeForPath
virtual std::string nodeTypeForPath(const std::string &path)=0
For the given path, returns a the type name of the object to be created at the path.
MSG::INFO
Definition: IMessageSvc.h:19
IDataProviderSvc::registerObject
virtual StatusCode registerObject(const std::string &fullPath, DataObject *pObject)=0
Register object with the data store.
DataIncident.h
CommonMessagingBase::msgLevel
MSG::Level msgLevel() const
get the output level from the embedded MsgStream
Definition: CommonMessaging.h:136
ana.i
list i
Definition: ana.py:128
DataOnDemandSvc::i_setAlgHandler
StatusCode i_setAlgHandler(const std::string &name, const Gaudi::Utils::TypeNameString &alg)
Internal method to initialize an algorithm handler.
Definition: DataOnDemandSvc.cpp:217
ISvcLocator.h
DataOnDemandSvc::configureHandler
StatusCode configureHandler(Leaf &leaf)
Configure handler for leaf.
Definition: DataOnDemandSvc.cpp:520
DataOnDemandSvc::update_2
void update_2(Property &p)
Definition: DataOnDemandSvc.cpp:110
toupper
void toupper(std::string &s)
Definition: StatusCodeSvc.cpp:10
MSG::ALWAYS
Definition: IMessageSvc.h:23
DataOnDemandSvc::m_locked_algs
bool m_locked_algs
Definition: DataOnDemandSvc.h:286
endmsg
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
Definition: MsgStream.h:244
DataOnDemandSvc::update_3
void update_3(Property &p)
Definition: DataOnDemandSvc.cpp:98
DataOnDemandSvc::update_1
void update_1(Property &p)
Definition: DataOnDemandSvc.cpp:89
DataOnDemandSvc::reinitialize
StatusCode reinitialize() override
Inherited Service overrides: Service reinitialization.
Definition: DataOnDemandSvc.cpp:370
DataOnDemandSvc::update
StatusCode update()
update the handlers
Definition: DataOnDemandSvc.cpp:239
DataObject.h
Service::sysInitialize
StatusCode sysInitialize() override
Initialize Service.
Definition: Service.cpp:26
DataOnDemandSvc::m_locked_all
bool m_locked_all
Definition: DataOnDemandSvc.h:287