Added test for OCDB objects in DoInit and updated documentation (Gaute)
authorrichterm <richterm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 12 Feb 2010 10:36:55 +0000 (10:36 +0000)
committerrichterm <richterm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 12 Feb 2010 10:36:55 +0000 (10:36 +0000)
HLT/ITS/AliHLTITSClusterFinderComponent.cxx
HLT/ITS/AliHLTITSClusterFinderComponent.h

index 94de7e7..22dc90a 100644 (file)
@@ -29,7 +29,7 @@ using namespace std;
 
 #include "AliCDBEntry.h"
 #include "AliCDBManager.h"
-#include "AliHLTDataTypes.h"
+#include "AliCDBStorage.h"
 #include "AliITSgeomTGeo.h"
 #include "AliITSRecPoint.h"
 #include "AliHLTITSSpacePointData.h"
@@ -164,6 +164,71 @@ Int_t AliHLTITSClusterFinderComponent::DoInit( int argc, const char** argv ) {
   fStatTimeAllC = 0;
   fStatNEv = 0;
   */
+  
+  Int_t runNo = GetRunNo();
+  AliCDBStorage* store = AliCDBManager::Instance()->GetDefaultStorage();
+  if (!store) {
+    return NULL;
+  }
+
+  bool cdbOK = true;
+  //OCDB for SPD
+  if(store->GetLatestVersion("ITS/Calib/SPDNoisy", runNo)<0){
+    HLTError("SPDNoisy is not found in SPD/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/SPDDead", runNo)<0){
+    HLTError("SPDDead is not found in SPD/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("TRIGGER/SPD/PITConditions", runNo)<0){
+    HLTError("PITConditions is not found in TRIGGER/SPD");
+    cdbOK = false;
+  }
+  
+  //OCDB for SDD
+  if(store->GetLatestVersion("ITS/Calib/CalibSDD", runNo)<0){
+    HLTError("CalibSDD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/RespSDD", runNo)<0){
+    HLTError("RespSDD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/DriftSpeedSDD", runNo)<0){
+    HLTError("DriftSpeedSDD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/DDLMapSDD", runNo)<0){
+    HLTError("DDLMapSDD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/MapsTimeSDD", runNo)<0){
+    HLTError("MapsTimeSDD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+
+  //OCDB for SSD
+  if(store->GetLatestVersion("ITS/Calib/NoiseSSD", runNo)<0){
+    HLTError("NoiseSSD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/GainSSD", runNo)<0){
+    HLTError("GainSSD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  if(store->GetLatestVersion("ITS/Calib/BadChannelsSSD", runNo)<0){
+    HLTError("BadChannelsSSD is not found in ITS/Calib");
+    cdbOK = false;
+  }
+  
+  //General reconstruction
+  if(store->GetLatestVersion("GRP/CTP/Scalers", runNo)<0){
+    HLTError("Scalers is not found in GRP/CTP/");
+    cdbOK = false;
+  }
+  if(!cdbOK){return NULL;}
+
   if(fModeSwitch==kClusterFinderSPD) {
     HLTDebug("using ClusterFinder for SPD");
     //fNModules=AliITSgeomTGeo::GetNDetectors(1)*AliITSgeomTGeo::GetNLadders(1) + AliITSgeomTGeo::GetNDetectors(2)*AliITSgeomTGeo::GetNLadders(2);
index de879b9..cd13c59 100644 (file)
@@ -54,7 +54,18 @@ class AliHLTITSClusterFinderSSD;
  *      a configuration argument without parameters
  *
  * <h2>Default CDB entries:</h2>
- * TODO
+ * ITS/Calib/SPDNoisy
+ * ITS/Calib/SPDDead
+ * TRIGGER/SPD/PITConditions
+ * ITS/Calib/CalibSDD
+ * ITS/Calib/RespSDD
+ * ITS/Calib/DriftSpeedSDD
+ * ITS/Calib/DDLMapSDD
+ * ITS/Calib/MapsTimeSDD
+ * ITS/Calib/NoiseSSD
+ * ITS/Calib/GainSSD
+ * ITS/Calib/BadChannelsSSD
+ * GRP/CTP/Scalers
  *
  * <h2>Performance:</h2>
  * TODO