CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes
smproxy::EventRetriever< RegInfo, QueueCollectionPtr > Class Template Reference

#include <EventRetriever.h>

Public Types

typedef boost::shared_ptr
< RegInfo > 
RegInfoPtr
 

Public Member Functions

void addConsumer (const RegInfoPtr)
 
 EventRetriever (StateMachine *, const RegInfoPtr)
 
size_t getConnectedSMCount () const
 
const stor::QueueIDsgetQueueIDs () const
 
void stop ()
 
 ~EventRetriever ()
 

Private Types

typedef std::vector< ConnectionIDConnectionIDs
 
typedef stor::EventServerProxy
< RegInfo > 
EventServer
 
typedef boost::shared_ptr
< EventServer
EventServerPtr
 
typedef std::map< ConnectionID,
EventServerPtr
EventServers
 

Private Member Functions

void activity (const edm::ParameterSet &)
 
bool adjustMinEventRequestInterval (const stor::utils::Duration_t &)
 
bool anyActiveConsumers (QueueCollectionPtr) const
 
bool connect (const edm::ParameterSet &)
 
void connectToSM (const std::string &sourceURL, const edm::ParameterSet &)
 
void disconnectFromCurrentSM ()
 
void do_stop ()
 
void doIt (const edm::ParameterSet &)
 
 EventRetriever (EventRetriever const &)
 
void getInitMsg ()
 
bool getNextEvent (stor::CurlInterface::Content &)
 
bool openConnection (const ConnectionID &, const RegInfoPtr)
 
EventRetrieveroperator= (EventRetriever const &)
 
void processCompletedTopLevelFolders ()
 
bool tryToReconnect ()
 
void updateConsumersSetting (const stor::utils::Duration_t &)
 

Private Attributes

ConnectionIDs connectionIDs_
 
boost::mutex connectionIDsLock_
 
DataRetrieverMonitorCollectiondataRetrieverMonitorCollection_
 
const DataRetrieverParams dataRetrieverParams_
 
stor::DQMEventStore
< DQMEventMsg, EventRetriever
< RegInfo, QueueCollectionPtr >
, StateMachine
dqmEventStore_
 
EventServers eventServers_
 
size_t instance_
 
stor::utils::Duration_t minEventRequestInterval_
 
stor::utils::TimePoint_t nextReconnectTry_
 
stor::utils::TimePoint_t nextRequestTime_
 
EventServers::iterator nextSMtoUse_
 
stor::QueueIDs queueIDs_
 
boost::mutex queueIDsLock_
 
StateMachinestateMachine_
 
boost::scoped_ptr< boost::thread > thread_
 

Static Private Attributes

static size_t retrieverCount_
 

Detailed Description

template<class RegInfo, class QueueCollectionPtr>
class smproxy::EventRetriever< RegInfo, QueueCollectionPtr >

Retrieve events from the event server

Author:
mommsen
Revision:
1.2
Date:
2011/03/07 15:41:54

Definition at line 42 of file EventRetriever.h.

Member Typedef Documentation

template<class RegInfo , class QueueCollectionPtr >
typedef std::vector<ConnectionID> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::ConnectionIDs
private

Definition at line 117 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
typedef stor::EventServerProxy<RegInfo> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::EventServer
private

Definition at line 111 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
typedef boost::shared_ptr<EventServer> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::EventServerPtr
private

Definition at line 112 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
typedef std::map<ConnectionID, EventServerPtr> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::EventServers
private

Definition at line 113 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
typedef boost::shared_ptr<RegInfo> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::RegInfoPtr

Definition at line 46 of file EventRetriever.h.

Constructor & Destructor Documentation

template<class RegInfo , class QueueCollectionPtr >
smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::EventRetriever ( StateMachine ,
const RegInfoPtr   
)
template<class RegInfo , class QueueCollectionPtr >
smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::~EventRetriever ( )
template<class RegInfo , class QueueCollectionPtr >
smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::EventRetriever ( EventRetriever< RegInfo, QueueCollectionPtr > const &  )
private

Member Function Documentation

template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::activity ( const edm::ParameterSet )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::addConsumer ( const RegInfoPtr  )

Add a consumer

template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::adjustMinEventRequestInterval ( const stor::utils::Duration_t )
private
template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::anyActiveConsumers ( QueueCollectionPtr  ) const
private
template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::connect ( const edm::ParameterSet )
private

Referenced by Vispa.Gui.ZoomableScrollArea.ZoomableScrollArea::__init__(), Vispa.Views.PropertyView.BooleanProperty::__init__(), Vispa.Gui.FindDialog.FindDialog::_addScript(), Vispa.Gui.FindDialog.FindDialog::_addStringProperty(), Vispa.Main.Application.Application::_connectSignals(), Vispa.Plugins.ConfigEditor.CodeTableView.CodeTableView::_createItem(), Vispa.Gui.BoxContentDialog.BoxContentDialog::addButton(), Vispa.Gui.ToolBoxContainer.ToolBoxContainer::addWidget(), Vispa.Views.PropertyView.PropertyView::append(), Vispa.Views.PropertyView.PropertyView::appendAddRow(), Vispa.Main.Application.Application::createAction(), Vispa.Views.PropertyView.TextEditWithButtonProperty::createButton(), Vispa.Views.LineDecayView.LineDecayView::createLineDecayContainer(), Vispa.Views.PropertyView.TextEditWithButtonProperty::createLineEdit(), Vispa.Views.LineDecayView.LineDecayContainer::createObject(), Vispa.Views.PropertyView.TextEditWithButtonProperty::createTextEdit(), Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::filterDialog(), Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::find(), Vispa.Gui.PortWidget.PortWidget::mouseMoveEvent(), Vispa.Views.PropertyView.BooleanProperty::setChecked(), Vispa.Main.SplitterTab.SplitterTab::setController(), Vispa.Plugins.Browser.BrowserTab.BrowserTab::setController(), Vispa.Views.PropertyView.BooleanProperty::setReadOnly(), Vispa.Views.PropertyView.DropDownProperty::setReadOnly(), Vispa.Views.PropertyView.TextEditWithButtonProperty::setReadOnly(), Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::setTab(), Vispa.Views.PropertyView.IntegerProperty::setValue(), Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::switchCenterView(), Vispa.Plugins.EdmBrowser.EdmBrowserTabController.EdmBrowserTabController::updateViewMenu(), and Vispa.Plugins.ConfigEditor.ConfigEditorTabController.ConfigEditorTabController::updateViewMenu().

template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::connectToSM ( const std::string &  sourceURL,
const edm::ParameterSet  
)
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::disconnectFromCurrentSM ( )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::do_stop ( )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::doIt ( const edm::ParameterSet )
private
template<class RegInfo , class QueueCollectionPtr >
size_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::getConnectedSMCount ( ) const
inline

Return the number of active connections to SMs

Definition at line 75 of file EventRetriever.h.

References smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::eventServers_.

76  { return eventServers_.size(); }
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::getInitMsg ( )
private
template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::getNextEvent ( stor::CurlInterface::Content )
private
template<class RegInfo , class QueueCollectionPtr >
const stor::QueueIDs& smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::getQueueIDs ( ) const
inline

Return the list of QueueIDs attached to the EventRetriever

Definition at line 69 of file EventRetriever.h.

References smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::queueIDs_.

70  { return queueIDs_; }
stor::QueueIDs queueIDs_
template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::openConnection ( const ConnectionID ,
const RegInfoPtr   
)
private
template<class RegInfo , class QueueCollectionPtr >
EventRetriever& smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::operator= ( EventRetriever< RegInfo, QueueCollectionPtr > const &  )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::processCompletedTopLevelFolders ( )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::stop ( )

Stop retrieving events

template<class RegInfo , class QueueCollectionPtr >
bool smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::tryToReconnect ( )
private
template<class RegInfo , class QueueCollectionPtr >
void smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::updateConsumersSetting ( const stor::utils::Duration_t )
private

Member Data Documentation

template<class RegInfo , class QueueCollectionPtr >
ConnectionIDs smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::connectionIDs_
private

Definition at line 118 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
boost::mutex smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::connectionIDsLock_
mutableprivate

Definition at line 119 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
DataRetrieverMonitorCollection& smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::dataRetrieverMonitorCollection_
private

Definition at line 102 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
const DataRetrieverParams smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::dataRetrieverParams_
private

Definition at line 101 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
stor::DQMEventStore<DQMEventMsg, EventRetriever<RegInfo,QueueCollectionPtr>, StateMachine > smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::dqmEventStore_
private

Definition at line 129 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
EventServers smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::eventServers_
private
template<class RegInfo , class QueueCollectionPtr >
size_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::instance_
private

Definition at line 109 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
stor::utils::Duration_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::minEventRequestInterval_
private

Definition at line 105 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
stor::utils::TimePoint_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::nextReconnectTry_
private

Definition at line 121 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
stor::utils::TimePoint_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::nextRequestTime_
private

Definition at line 104 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
EventServers::iterator smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::nextSMtoUse_
private

Definition at line 115 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
stor::QueueIDs smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::queueIDs_
private
template<class RegInfo , class QueueCollectionPtr >
boost::mutex smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::queueIDsLock_
mutableprivate

Definition at line 124 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
size_t smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::retrieverCount_
staticprivate

Definition at line 108 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
StateMachine* smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::stateMachine_
private

Definition at line 100 of file EventRetriever.h.

template<class RegInfo , class QueueCollectionPtr >
boost::scoped_ptr<boost::thread> smproxy::EventRetriever< RegInfo, QueueCollectionPtr >::thread_
private

Definition at line 107 of file EventRetriever.h.