CMS 3D CMS Logo

Public Member Functions | Private Attributes

popcon::DQMSummarySourceHandler Class Reference

#include <DQMSummarySourceHandler.h>

Inheritance diagram for popcon::DQMSummarySourceHandler:
popcon::PopConSourceHandler< DQMSummary >

List of all members.

Public Member Functions

 DQMSummarySourceHandler (const edm::ParameterSet &pset)
void getNewObjects ()
std::string id () const
 ~DQMSummarySourceHandler ()

Private Attributes

std::string m_connectionString
std::string m_name
std::string m_pass
unsigned long long m_since
std::string m_user

Detailed Description

Definition at line 11 of file DQMSummarySourceHandler.h.


Constructor & Destructor Documentation

popcon::DQMSummarySourceHandler::DQMSummarySourceHandler ( const edm::ParameterSet pset)

Definition at line 11 of file DQMSummarySourceHandler.cc.

References m_connectionString.

                                                                              :
    m_name(pset.getUntrackedParameter<std::string>("name","DQMSummarySourceHandler")),
    m_since(pset.getUntrackedParameter<unsigned long long>("firstSince",1)), 
    m_user(pset.getUntrackedParameter<std::string>("OnlineDBUser","CMS_DQM_SUMMARY")), 
    m_pass(pset.getUntrackedParameter<std::string>("OnlineDBPass","****")) {
    m_connectionString = "oracle://cms_omds_lb/CMS_DQM_SUMMARY";
  }
popcon::DQMSummarySourceHandler::~DQMSummarySourceHandler ( )

Definition at line 19 of file DQMSummarySourceHandler.cc.

{}

Member Function Documentation

void popcon::DQMSummarySourceHandler::getNewObjects ( ) [virtual]

Implements popcon::PopConSourceHandler< DQMSummary >.

Definition at line 21 of file DQMSummarySourceHandler.cc.

References gather_cfg::cout, cond::LogDBEntry::destinationDB, cond::TagInfo::lastInterval, popcon::PopConSourceHandler< DQMSummary >::lastPayload(), cond::TagInfo::lastPayloadToken, popcon::PopConSourceHandler< DQMSummary >::logDBEntry(), m_connectionString, m_name, m_pass, m_since, popcon::PopConSourceHandler< DQMSummary >::m_to_transfer, m_user, cond::TagInfo::name, DQMSummaryReader::readData(), findQualityFiles::size, cond::TagInfo::size, popcon::PopConSourceHandler< DQMSummary >::tagInfo(), and cond::LogDBEntry::usertext.

                                              {
    //check what is already inside of the database
    edm::LogInfo("DQMSummarySourceHandler") << "------- " << m_name << " -> getNewObjects\n" 
                                            << "got offlineInfo " << tagInfo().name 
                                            << ", size " << tagInfo().size 
                                            << ", last object valid since " 
                                            << tagInfo().lastInterval.first << " token "   
                                            << tagInfo().lastPayloadToken << std::endl;
    edm::LogInfo("DQMSummarySourceHandler") << " ------ last entry info regarding the payload (if existing): " 
                                            << logDBEntry().usertext
                                            << "; last record with the correct tag (if existing) has been written in the db: " 
                                            << logDBEntry().destinationDB << std::endl; 
    if (tagInfo().size > 0) {
      Ref payload = lastPayload();
      edm::LogInfo("DQMSummarySourceHandler") << "size of last payload  "
                                              << payload->m_summary.size() << std::endl;
    }
    std::cout << "runnumber/first since = " << m_since << std::endl;
    DQMSummary * dqmSummary = new DQMSummary;
    DQMSummaryReader dqmSummaryReader(m_connectionString, m_user, m_pass);
    *dqmSummary = dqmSummaryReader.readData("SUMMARYCONTENT", m_since);
    m_to_transfer.push_back(std::make_pair((DQMSummary*)dqmSummary,m_since));
    edm::LogInfo("DQMSummarySourceHandler") << "------- " 
                                            << m_name << " - > getNewObjects" 
                                            << std::endl;
  }
std::string popcon::DQMSummarySourceHandler::id ( void  ) const [virtual]

Implements popcon::PopConSourceHandler< DQMSummary >.

Definition at line 48 of file DQMSummarySourceHandler.cc.

References m_name.

{return m_name;}

Member Data Documentation

Definition at line 22 of file DQMSummarySourceHandler.h.

Referenced by DQMSummarySourceHandler(), and getNewObjects().

Definition at line 18 of file DQMSummarySourceHandler.h.

Referenced by getNewObjects(), and id().

Definition at line 24 of file DQMSummarySourceHandler.h.

Referenced by getNewObjects().

unsigned long long popcon::DQMSummarySourceHandler::m_since [private]

Definition at line 20 of file DQMSummarySourceHandler.h.

Referenced by getNewObjects().

Definition at line 23 of file DQMSummarySourceHandler.h.

Referenced by getNewObjects().