CETDDS.h
Go to the documentation of this file.
1 #ifndef _RMS_CETDDS_H
2 #define _RMS_CETDDS_H
3 
4 /* This file (CETDDS.h) was created by Ron Rechenmacher <ron@fnal.gov> on
5  Jan 21, 2010. "TERMS AND CONDITIONS" governing this file are in the README
6  or COPYING file. If you do not have such a file, one can be obtained by
7  contacting Ron or Fermi Lab in Batavia IL, 60510, phone: 630-840-3000.
8  $RCSfile: CETDDS.h,v $
9  rev="$Revision: 1.26.12.1 $$Date: 2019/09/27 00:07:31 $";
10  */
11 
12 #include "ccpp_dds_dcps.h"
13 #include "rms/base/RmsCloseable.h"
14 #include "rms/provider/CheckStatus.h"
15 #include "rms/base/RmsRuntimeException.h"
16 #include "rms/provider/ProcessSignalHandler.h"
17 
18 #include <NovaDAQUtilities/EnvVarCache.h>
19 #include <string>
20 #include <iostream>
21 #include <boost/algorithm/string/replace.hpp>
22 #include <boost/interprocess/smart_ptr/unique_ptr.hpp>
23 #include <sys/time.h>
24 #include "boost/bind.hpp"
25 
26 // -- DDS Includes
27 #include <dds/domain.hpp>
28 #include <dds/topic.hpp>
29 #include <dds/reader.hpp>
30 #include <dds/traits.hpp>
31 
32 
33 #define CETDDS_DEBUG 0
34 #define CETDDS_EXTRA_DEBUG 0
35 #define CETDDS_DEBUG1 0
36 
37 #define declare_dds_message(TOPIC) REGISTER_TOPIC_TRAITS(TOPIC)
38 
39 namespace gov {
40 
41 namespace fnal {
42 
43 namespace cd {
44 
45 namespace rms {
46 
47  template <typename D> struct Deleter {
48  void operator()(D *p) {
49  assert( p != NULL );
50  delete p;
51  }
52  };
53 
54 namespace provider {
55 
56 
58  std::string const& topic_name );
59 
61  std::string const& topic_name );
62 
63 typedef std::pair<std::string, std::vector<std::string> > dds_topic_filter_t;
64 
65 dds_topic_filter_t& create_topic_filter_for(dds_topic_filter_t & filter, std::string const& type_name,
66  std::string const& topic_name );
67 
68 std::string unique_topic_name_for(std::string const& extended_topic_name );
69 
70 bool string2bool (std::string const& bool_string );
71 
72 
73 
74 void dumpReceivedSamples( dds::SampleInfoSeq const& infoSeq,
75  const unsigned int length, const int status );
76 
77 
78 template < class TT_ > class DDSTopicWriterClass
79 : virtual public base::RmsCloseable, public base::Notifiable
80 {
81 public:
82 
83  DDSTopicWriterClass( char const * topic_name );
84  DDSTopicWriterClass( char const * topic_name, char const * partition_name );
86 
87  int write( TT_ const& mm );
88  void close() throw();
89  bool hasBeenClosed() throw();
90 
91 private:
92  void init(std::string const& topic_name, std::string const& partition_name);
93  void waitForNetworkServices();
94 
95 private:
96  boost::shared_ptr< dds::DataWriter< TT_ > > writer;
97 
98  volatile bool _hasBeenClosed;
99  double _startTime;
101 };
102 
103 template < class TT_ > class DDSTopicReaderClass
104 : virtual public base::RmsCloseable, public base::Notifiable
105 {
106 public:
107 
108  DDSTopicReaderClass( char const * topic_name );
109  DDSTopicReaderClass( char const * topic_name, char const * partition_name );
111 
112  int take_nowait( TT_ & mm );
113  int take_timed_wait( TT_ & mm, unsigned int usec );
114  int take_wait( TT_ & mm );
115  void close() throw();
116  bool hasBeenClosed() throw();
117 
118 private:
119  void init(std::string const& topic_name, std::string const& partition_name);
120  int take_timed_wait( TT_ & topicdata, dds::Duration_t const& duration );
121  void receiveMessage(boost::shared_ptr< dds::DataReader<TT_> > & reader,
122  TT_ & topicdata, dds::ReturnCode_t & status);
123 
124  void dummyHandler() {};
125  void statusConditionHandler(boost::shared_ptr< dds::DataReader<TT_> > & reader);
126 
127 private:
128  boost::shared_ptr< dds::DataReader<TT_> > reader;
129  boost::interprocess::unique_ptr< dds::WaitSet, Deleter<dds::WaitSet> > wait_set;
130 
131  volatile bool _hasBeenClosed;
132 };
133 
134 
135 ///////////////////////////////////////////////////////////////////////////////
136 
137 // DomainParticipant Singleton
138 
140 {
141 public:
142  static DPSingleton& Instance() {
143  static DPSingleton singleton;
144  return singleton;
145  }
146 
147  void disconnect_participant();
148  void connect_participant();
149  void reconnect_participant();
150 
151  // adds / removes base::Notifiable to/from the exit notification list maintained by ProcessSignalHandler
152  void addToCleanupList(base::Notifiable* notifiable);
153  void removeFromCleanupList(base::Notifiable* notifiable);
154 
155 
156 protected:
157  template <class TT_> friend class DDSTopicWriterClass;
158  template <class TT_> friend class DDSTopicReaderClass;
159 
160  dds::DomainParticipant& get_participant();
161 
162 // Other non-static member functions
163 private:
164  boost::interprocess::unique_ptr<dds::DomainParticipant,Deleter<dds::DomainParticipant> > dp;
165 
166  DPSingleton(); // Private constructor
168  signalHandler.release();
169  }; // Private constructor
170 
171  DPSingleton( const DPSingleton& ); // Prevent copy-construction
172  DPSingleton& operator=( const DPSingleton& ); // Prevent assignment
173 
174 private:
175  //closes DDS connections upon receiving a process signal, e.g. SIGINT, and SIGTERM
177 
178 };
179 
180 // - - - - - - - - - - - - - - - - - - - - - - - - -
181 
182 template < class TT_ >
184 {
185 #if CETDDS_DEBUG
186  std::cout << topic_name << "\n" << "hello\n";
187 #endif
188 
189  init( std::string(topic_name), std::string("unknown"));
190 }
191 
192 template < class TT_ >
193 DDSTopicWriterClass< TT_ >::DDSTopicWriterClass( char const * topic_name, char const * partition_name )
194 {
195 #if CETDDS_DEBUG
196  std::cout << topic_name << "\n" << "hello\n";
197 #endif
198 
199  init( std::string(topic_name), std::string(partition_name));
200 }
201 
202 template < class TT_ >
204 {
205  try {
206  this->close();
207 
208  DPSingleton::Instance().removeFromCleanupList(this);
209  }
210  catch ( ... ) {
211  std::cerr << "Exception calling close() in in DDSTopicWriterClass."
212  << std::endl;
213  }
214 }
215 
216 
217 template < class TT_ >
219 {
220 #if CETDDS_DEBUG
221  std::cout << topic_name << "\n" << "hello\n";
222 #endif
223 
224  init( std::string(topic_name), std::string("unknown"));
225 }
226 
227 template < class TT_ >
228 DDSTopicReaderClass< TT_ >::DDSTopicReaderClass( char const * topic_name, char const * partition_name )
229 {
230 #if CETDDS_DEBUG
231  std::cout << topic_name << "\n" << "hello\n";
232 #endif
233 
234  init( std::string(topic_name), std::string(partition_name));
235 }
236 
237 template < class TT_ >
239 {
240  try {
241  this->close();
242 
243  DPSingleton::Instance().removeFromCleanupList(this);
244  }
245  catch ( ... ) {
246  std::cerr << "Exception calling close() in in DDSTopicReaderClass."
247  << std::endl;
248  }
249 }
250 
251 
252 template < class TT_ >
253 void DDSTopicWriterClass< TT_ >::init( std::string const& topic_name, std::string const& partition_name )
254 try
255 {
256  _startupDone = false;
257  _hasBeenClosed = false;
258 
259  SignalInhibitor sig;
260  dds::DomainParticipant dp(DPSingleton::Instance().get_participant());
261 
262  typename dds::topic_type_support<TT_>::type topicTS;
263 
264  //FIXME:GAL DDSLEAK
265  char * name =topicTS.get_type_name();
266  std::string type_name( name );
267  DDS::string_free(name);
268  //FIXME:GAL DDSLEAK
269 
270  const bool isContentFilteredTopicsEnabled = string2bool(
271  novadaq::EnvVarCache::getInstance().getEnvVar("RMS_ENABLE_CONTENT_FILTERED_TOPICS"));
272 
273  std::string extended_topic_name( isContentFilteredTopicsEnabled ?
274  create_content_filtered_topic_name_for(type_name, topic_name ):
275  create_extended_topic_name_for( type_name, topic_name ) );
276 
277  //create topic
278  dds::TopicQos topicQoS(dp);
279 
280  dp->get_default_topic_qos(topicQoS);
281 
282  const bool printTopicName =
283  string2bool(novadaq::EnvVarCache::getInstance().getEnvVar("RMS_PRINT_TOPICS"));
284  if (printTopicName) {
285  std::cout << "Writer topic = " << extended_topic_name
286  << ", partition = " << partition_name << std::endl;
287  }
288  dds::Topic<TT_> topic(dp, extended_topic_name, type_name, topicQoS );
289 
290  //creating publisher
291  dds::Publisher publisher (dp, partition_name);
292 
293  //create writer
294  dds::DataWriterQos writerQoS(dp, topicQoS );
295  writerQoS.set_auto_dispose(true);
296  // 7/21/15 ELF: Set writerQoS History policy to try and avoid "silently dropped" messages
297  writerQoS.history.kind = DDS::KEEP_ALL_HISTORY_QOS;
298 
299 
300  writer.reset(new dds::DataWriter<TT_>(publisher,topic, writerQoS ) );
301 
302  struct timeval now;
303  gettimeofday( &now, NULL );
304  _startTime = ( double ) now.tv_sec + ((( double ) now.tv_usec ) / 1000000.0 );
305 
306  DPSingleton::Instance().addToCleanupList( this );
307 
308 #if CETDDS_DEBUG
309  std::cout << "DDSTopicWriterClass creation time = " << startTime << std::endl;
310 #endif
311 }
312 catch (...)
313 {
314  close();
315 }
316 
317 template < class TT_ >
318 void DDSTopicReaderClass< TT_ >::init( std::string const& topic_name, std::string const& partition_name )
319 try
320 {
321  _hasBeenClosed = false;
322 
323  SignalInhibitor sig;
324  dds::DomainParticipant dp(DPSingleton::Instance().get_participant());
325 
326  typename dds::topic_type_support<TT_>::type topicTS;
327  //FIXME:GAL DDSLEAK
328  char * name =topicTS.get_type_name();
329  std::string type_name( name );
330  DDS::string_free(name);
331  //FIXME:GAL DDSLEAK
332 
333  const bool isContentFilteredTopicsEnabled = string2bool(
334  novadaq::EnvVarCache::getInstance().getEnvVar("RMS_ENABLE_CONTENT_FILTERED_TOPICS"));
335 
336  std::string extended_topic_name( isContentFilteredTopicsEnabled ?
337  create_content_filtered_topic_name_for(type_name, topic_name ):
338  create_extended_topic_name_for( type_name, topic_name ) );
339  //create topic
340  dds::TopicQos topicQoS(dp);
341  dp->get_default_topic_qos(topicQoS);
342 
343  const bool printTopicName =
344  string2bool(novadaq::EnvVarCache::getInstance().getEnvVar("RMS_PRINT_TOPICS"));
345  if (printTopicName) {
346  std::cout << "Reader topic = " << extended_topic_name
347  << ", partition = " << partition_name << std::endl;
348  }
349 
350  dds::Topic<TT_> topic(dp, extended_topic_name, type_name, topicQoS);
351 
352  //creating subscriber
353  dds::Subscriber subscriber(dp, partition_name);
354 
355  //create reader
356  dds::DataReaderQos readerQoS(dp, topicQoS );
357 
358  if ( isContentFilteredTopicsEnabled ) {
359  dds_topic_filter_t content_filter;
360  create_topic_filter_for(content_filter,type_name, topic_name);
361 
362  //each content filtered topic name must be unique within a client and must be different
363  //from the topic name given to dds::Topic constructor (undocumented feature)
364  dds::ContentFilteredTopic<TT_>content_filtered_topic(dp,unique_topic_name_for(extended_topic_name),
365  topic,content_filter.first,content_filter.second);
366 
367  reader.reset(new dds::DataReader<TT_>( subscriber, content_filtered_topic, readerQoS ));
368  }
369  else {
370  reader.reset(new dds::DataReader<TT_>( subscriber, topic, readerQoS ));
371  }
372 
373  dds::ReadCondition read_condition = reader->create_readcondition(
374  boost::bind(&DDSTopicReaderClass< TT_ >::dummyHandler,this),
375  DDS::ANY_SAMPLE_STATE,DDS::ANY_VIEW_STATE, DDS::ANY_INSTANCE_STATE );
376 
377  /*
378  dds::StatusCondition status_condition = reader->create_statuscondition(
379  boost::bind(&DDSTopicReaderClass< TT_ >::statusConditionHandler,this,reader),
380  DDS::SAMPLE_LOST_STATUS);
381  */
382  wait_set.reset(new dds::WaitSet);
383  wait_set->attach(read_condition);
384  //wait_set->attach(status_condition);
385 
386  DPSingleton::Instance().addToCleanupList( this );
387 }
388 catch (...)
389 {
390  close();
391 }
392 
393 
394 template < class TT_ >
396  boost::shared_ptr< dds::DataReader<TT_> > & reader)
397 {
398 
399  DDS::SampleLostStatus sampleLostStatus;
400  dds::ReturnCode_t status =reader->get_sample_lost_status(sampleLostStatus);
401  if (status !=DDS::RETCODE_OK)
402  {
403 #if CETDDS_DEBUG
404  std::cout << "DDSTopiReaderClass get_sample_lost_status returned error_code = " << status << std::endl;
405 #endif
406  return;
407  }
408  if (sampleLostStatus.total_count > 0)
409  std::cout << "DDSTopiReaderClass lost data samples total_count=" << sampleLostStatus.total_count
410  << ", total_count_change=" << sampleLostStatus.total_count_change << std::endl;
411 }
412 
413 template < class TT_ >
415  boost::shared_ptr< dds::DataReader<TT_> > &reader,
416  TT_ & topicdata,dds::ReturnCode_t & status)
417 {
418 #if CETDDS_DEBUG
419  std::cout << "receiveMessage\n";
420 #endif
421  statusConditionHandler(reader);
422 
423  const unsigned int seqSize=1;
424 
425  typename dds::topic_data_seq<TT_>::type topicSeq(seqSize);
426  dds::SampleInfoSeq infoSeq(seqSize);
427 
428  status = reader->take( topicSeq, infoSeq,1,
429  DDS::ANY_SAMPLE_STATE,DDS::ANY_VIEW_STATE,DDS::ANY_INSTANCE_STATE );
430 
431  checkStatus( status, "take" );
432 
433  if (status==DDS::RETCODE_NO_DATA)
434  return;
435 
436 #if CETDDS_EXTRA_DEBUG
437  dumpReceivedSamples( infoSeq, topicSeq.length(), status );
438 #endif
439 
440  if ( infoSeq[0].valid_data ) {
441  topicdata = topicSeq[0];
442  }
443  else {
444 #if CETDDS_DEBUG
445  printf( "handle invalid data\n" );
446 #endif
447  status = DDS::RETCODE_NO_DATA;
448  }
449 }
450 
451 // - - - - - - - - - - - - - - - - - - - - - - - - -
452 template < class TT_ >
454 {
455  // When DDS applications are communicating over the network, we need
456  // to allow time for the daemons to tell each other about the existence
457  // of this new writer. It seems like the
458  // NetworkService/Channels/Channel/Resolution configuration parameter
459  // is what sets the time between the updates, and this parameter has a
460  // default value of 10 msec. We use a default delay of 20 msec here
461  // so that we have a safety factor of 2.0.
462 
463  double maxDelay = novadaq::EnvVarCache::getInstance().
464  getEnvVarAsDouble( "RMS_WRITER_STARTUP_DELAY", 0.020 );
465 
466  struct timeval now;
467  gettimeofday( &now, NULL );
468  double currentTime = ( double ) now.tv_sec +
469  ((( double ) now.tv_usec ) / 1000000.0 );
470  double neededDelay = maxDelay - ( currentTime - _startTime );
471 
472 #if CETDDS_DEBUG
473  std::cout << "DDSTopicWriterClass startup delay = " << neededDelay << std::endl;
474 #endif
475 
476  if ( neededDelay > 0 ) {
477  usleep(( int )( 1000000 * neededDelay ) );
478  }
479 
480  _startupDone = true;
481 }
482 
483 template < class TT_ >
484 int DDSTopicWriterClass< TT_ >::write( TT_ const& topicdata )
485 try
486 {
487 #if CETDDS_DEBUG
488  std::cout << "write\n";
489 #endif
490 
491  if (_hasBeenClosed)
492  {
493  GENERATE_RMS_NOTCONNECTED_EXCEPTION("DDSTopicWriterClass not connected.");
494  }
495  else if(this->hasBeenNotified())
496  {
497  GENERATE_RMS_EXITINGPROCESS_EXCEPTION("Exiting process.");
498  }
499 
500  if ( ! _startupDone )
501  waitForNetworkServices();
502 
503  SignalInhibitor sig;
504  dds::ReturnCode_t status = writer->write( topicdata );
505 
506  if(this->hasBeenNotified())
507  {
508  GENERATE_RMS_EXITINGPROCESS_EXCEPTION("Exiting process.");
509  }
510 
511  checkStatus( status, "write" );
512 
513  return ( 0 );
514 }
516 {
517  close();
518  throw;
519 }
520 
521 
522 template < class TT_ >
523 int DDSTopicReaderClass< TT_ >::take_timed_wait( TT_ & topicdata, dds::Duration_t const& duration )
524 try
525 {
526 #if CETDDS_DEBUG
527  std::cout << "take\n";
528 #endif
529 
530  if (_hasBeenClosed)
531  {
532  GENERATE_RMS_NOTCONNECTED_EXCEPTION("DDSTopicReaderClass not connected.");
533  }
534  else if(this->hasBeenNotified())
535  {
536  GENERATE_RMS_EXITINGPROCESS_EXCEPTION("Exiting process.");
537  }
538 
539  // NOTE that this method returns DDS::RETCODE_TIMEOUT when the
540  // timeout is reached and no data has been received and
541  // DDS::RETCODE_NO_DATA when invalid data is received before
542  // the timeout expires. An alternative model would be to only
543  // return early if valid data has been received.
544 
545  dds::ReturnCode_t status=DDS::RETCODE_NO_DATA;
546  dds::ReturnCode_t wait_status=DDS::RETCODE_ERROR;
547 
548  try
549  {
550  SignalInhibitor sig;
551 
552  while ( wait_status != DDS::RETCODE_TIMEOUT && status == DDS::RETCODE_NO_DATA && !_hasBeenClosed)
553  {
554  wait_status = wait_set->dispatch(duration);
555 
556  if (wait_status==DDS::RETCODE_OK)
557  receiveMessage(reader, topicdata, status);
558 
559  if(this->hasBeenNotified())
560  {
561  GENERATE_RMS_EXITINGPROCESS_EXCEPTION("Exiting process.");
562  }
563  }
564  }
565  catch (dds::InterruptedException& ex)
566  {
567 #if CETDDS_DEBUG1
568  std::cerr << "Caught InterruptedException while calling take_timed_wait() in DDSTopicReaderClass; message="
569  << ex.what() << std::endl;
570 #endif
571  close();
572  }
573 
574  if ( wait_status == DDS::RETCODE_TIMEOUT )
575  status = DDS::RETCODE_TIMEOUT;
576  else if (wait_status==DDS::RETCODE_OK && status!=DDS::RETCODE_OK)
577  status = DDS::RETCODE_NO_DATA;
578 
579  return (( int )status );
580 }
582 {
583  close();
584  throw;
585 }
586 
587 
588 template < class TT_ >
589 int DDSTopicReaderClass< TT_ >::take_timed_wait( TT_ & topicdata, unsigned int usec )
590 {
591  dds::Duration_t timeout={ usec / 1000000, ( usec - ( usec / 1000000 ) * 1000000 ) * 1000};
592  return take_timed_wait( topicdata,timeout );
593 }
594 
595 template < class TT_ >
597 {
598  dds::Duration_t timeout=DDS::DURATION_INFINITE;
599  return take_timed_wait( topicdata,timeout );
600 }
601 
602 template < class TT_ >
604 {
605  dds::Duration_t timeout=DDS::DURATION_ZERO;
606  return take_timed_wait( topicdata,timeout );
607 }
608 
609 // - - - - - - - - - - - - - - - - - - - - - - - - -
610 
611 template < class TT_ >
613 {
614  _hasBeenClosed = true;
615  SignalInhibitor sig;
616  writer.reset();
617 #if CETDDS_DEBUG1
618  std::cout << "Closed DDSTopicWriter connection." << std::endl;
619 #endif
620 }
621 
622 
623 template < class TT_ >
625 {
626  _hasBeenClosed = true;
627  SignalInhibitor sig;
628  wait_set.reset();
629  reader.reset();
630 #if CETDDS_DEBUG1
631  std::cout << "Closed DDSTopicReader connection." << std::endl;
632 #endif
633 }
634 
635 template < class TT_ >
637 {
638  return _hasBeenClosed;
639 }
640 
641 template < class TT_ >
643 {
644  return _hasBeenClosed;
645 }
646 
647 } // end of namespace provider
648 
649 } // end of namespace rms
650 
651 } // end of namespace cd
652 
653 } // end of namespace fnal
654 
655 } // end of namespace gov
656 
657 
658 /*
659  * With "tab-width: 4" tabs and spaces could get mixed (especially in
660  * environments where c-backspace-function is backward-delete-char-untabify)
661  * which could make things a mess in other "tab-width" environments. (Always
662  * tabifying would work, but require a lot of discipline.)
663  * Local variables:
664  * mode: c++
665  * tab-width: 8
666  * c-tab-always-indent: nil
667  * c-basic-offset: 4
668  * c-file-offsets: ((substatement-open . 0)
669  (statement . c-lineup-runin-statements)
670  (label . -1000)
671  (arglist-intro . c-lineup-arglist-intro-after-paren)
672  (arglist-cont . c-lineup-arglist-intro-after-paren)
673  (arglist-cont-nonempty . c-lineup-arglist-intro-after-paren)
674  (arglist-close . c-lineup-arglist-intro-after-paren)
675  )
676  * End:
677  */
678 
679 #endif
680 // kate: indent-mode cstyle; space-indent on; indent-width 0;
const XML_Char * name
Definition: expat.h:151
int status
Definition: fabricate.py:1613
boost::interprocess::unique_ptr< dds::WaitSet, Deleter< dds::WaitSet > > wait_set
Definition: CETDDS.h:129
boost::shared_ptr< dds::DataWriter< TT_ > > writer
Definition: CETDDS.h:96
static DPSingleton & Instance()
Definition: CETDDS.h:142
const char * p
Definition: xmltok.h:285
static EnvVarCache & getInstance()
Definition: EnvVarCache.cpp:12
OStream cerr
Definition: OStream.cxx:7
dds_topic_filter_t & create_topic_filter_for(dds_topic_filter_t &filter, std::string const &type_name, std::string const &topic_name)
Definition: CETDDS.cpp:39
std::pair< std::string, std::vector< std::string > > dds_topic_filter_t
Definition: CETDDS.h:63
Module that kips a configurable number of events between each that it allows through. Note that this module really skips (N-1) events, it uses a simple modular division as its critera. This module will cut down the data sample to 1/N of its original size.
write
Run ND cosmics.
::xsd::cxx::tree::duration< char, simple_type > duration
Definition: Database.h:188
std::string unique_topic_name_for(std::string const &extended_topic_name)
Definition: CETDDS.cpp:53
std::shared_ptr< T > shared_ptr
Definition: memory.h:15
length
Definition: demo0.py:21
boost::interprocess::unique_ptr< dds::DomainParticipant, Deleter< dds::DomainParticipant > > dp
Definition: CETDDS.h:164
printf("%d Experimental points found\n", nlines)
std::string create_extended_topic_name_for(std::string const &type_name, std::string const &topic_name)
Definition: CETDDS.cpp:24
Definition: fnal.py:1
OStream cout
Definition: OStream.cxx:6
static constexpr Double_t mm
Definition: Munits.h:136
boost::interprocess::unique_ptr< ProcessSignalHandler, ProcessSignalHandlerDeleter > ProcessSignalHandler_t
::xsd::cxx::tree::string< char, simple_type > string
Definition: Database.h:154
bool string2bool(std::string const &bool_string)
Definition: CETDDS.cpp:61
void dumpReceivedSamples(dds::SampleInfoSeq const &infoSeq, const unsigned int length, const int status)
Definition: CETDDS.cpp:68
std::string create_content_filtered_topic_name_for(std::string const &type_name, std::string const &topic_name)
Definition: CETDDS.cpp:33
boost::shared_ptr< dds::DataReader< TT_ > > reader
Definition: CETDDS.h:128
#define GENERATE_RMS_NOTCONNECTED_EXCEPTION(msg)
assert(nhit_max >=nhit_nbins)
#define GENERATE_RMS_EXITINGPROCESS_EXCEPTION(msg)
void checkStatus(DDS::ReturnCode_t status, const char *info)
Definition: CheckStatus.cpp:64
ProcessSignalHandler_t signalHandler
Definition: CETDDS.h:176
c cd(1)
procfile close()