]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
- corrected the CDB manager initialization depending on the source of the CDB URI
authorkkanaki <kkanaki@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 8 Apr 2011 12:28:36 +0000 (12:28 +0000)
committerkkanaki <kkanaki@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 8 Apr 2011 12:28:36 +0000 (12:28 +0000)
- removed the specific storage setting, the default storage takes care of what's necessary for the data unpacking

HLT/exa/extract-ESD.C

index 1be3dd70286f62cf913e1a5e6dbb99bc08677e03..63cbe6298bb010f17c2c4cb9719bc4bd603ae45b 100644 (file)
@@ -29,23 +29,24 @@ void extract_ESD(const char* input, const char *cdbURI, int nofEvents=-1){
   // Set the CDB storage location
   AliCDBManager *man = AliCDBManager::Instance();
   man->SetDefaultStorage(cdbURI);
-  man->SetRun(0);
-  if (struri.BeginsWith("local://")) man->SetSpecificStorage("HLT/Calib/StreamerInfo", "local://$ALICE_ROOT/OCDB");
+  //man->SetRun(146018);
+
   AliRawReader* pRawReader=AliRawReader::Create(input);
   if (!pRawReader){
     cout << "cannot open RawReader for file " << input << endl;
     return;
   }
-
+  
   if (!pRawReader->NextEvent()){
     cerr << "no events available" << endl;
     return;
   }
+  
+  if(struri.Contains("local") || strfile.Contains("alien")) man->SetRun(pRawReader->GetRunNumber());
 
   // setup of the HLT system
   AliHLTSystem *pHLT = AliHLTPluginBase::GetInstance();
-  if(!pHLT) cerr << "fatal error: can not get HLT instance" << endl;
+  if(!pHLT) cerr << "fatal error: cannot get HLT instance" << endl;
 
   TString arg;
   arg.Form("-typeid ALIESDV0");