X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=SHUTTLE%2FAliShuttle.cxx;h=3673410d503697fd173b34538489fcaf05ca273a;hb=25cf73e9cbb76a7d4c160c61ed6179d7915dd39d;hp=6541261958b97efa750a6f536053a5b23d1d15c6;hpb=6e25f8281cd2855ffa9fc32c51088d50545b3f6d;p=u%2Fmrichter%2FAliRoot.git diff --git a/SHUTTLE/AliShuttle.cxx b/SHUTTLE/AliShuttle.cxx index 6541261958b..3673410d503 100644 --- a/SHUTTLE/AliShuttle.cxx +++ b/SHUTTLE/AliShuttle.cxx @@ -28,6 +28,7 @@ // For detSpec is used the alias name. // +#include #include "AliShuttle.h" #include "AliCDBManager.h" @@ -67,6 +68,7 @@ #include #include +using namespace std; ClassImp(AliShuttle) @@ -357,6 +359,7 @@ Int_t AliShuttle::StoreOCDB(const TString& gridURI) Form("StoreOCDB - cannot activate main %s storage", type)); return -2; } + gridSto->SetMirrorSEs(fgkMirrorSEs.Data()); gridIds = gridSto->GetQueryCDBList(); @@ -950,8 +953,12 @@ AliShuttleStatus* AliShuttle::ReadShuttleStatus() } Int_t path1 = GetCurrentRun()/10000; - fStatusEntry = AliCDBManager::Instance()->GetStorage(GetLocalCDB()) - ->Get(Form("/SHUTTLE/%s/%d", fCurrentDetector.Data(), path1), GetCurrentRun()); + try{ + fStatusEntry = AliCDBManager::Instance()->GetStorage(GetLocalCDB()) + ->Get(Form("/SHUTTLE/%s/%d", fCurrentDetector.Data(), path1), GetCurrentRun()); + } catch(std::exception& x) { + AliInfo(TString::Format("%s",x.what())); + } if (!fStatusEntry) return 0; fStatusEntry->SetOwner(1); @@ -1083,19 +1090,8 @@ Bool_t AliShuttle::ContinueProcessing() dynamic_cast (fPreprocessorMap.GetValue(fCurrentDetector)); if (!aPreprocessor) { - Log("SHUTTLE", Form("ContinueProcessing - %s: no preprocessor registered", fCurrentDetector.Data())); - if(fCurrentDetector==TString("HLT")){ - Log("SHUTTLE", "ContinueProcessing: Fake processing HLT, to avoid pending runs! => temporary, till an HLT preprocessor is made available."); - UpdateShuttleLogbook("HLT","DONE"); - Log(fCurrentDetector, "ContinueProcessing - skipping HLT preprocessor."); - - AliShuttleStatus* status = ReadShuttleStatus(); - if (!status) { - status = new AliShuttleStatus(AliShuttleStatus::kDone); - WriteShuttleStatus(status); - } - } - return kFALSE; + Log("SHUTTLE", Form("ContinueProcessing - %s: no preprocessor registered", fCurrentDetector.Data())); + return kFALSE; } AliShuttleLogbookEntry::Status entryStatus = @@ -1443,7 +1439,10 @@ Bool_t AliShuttle::Process(AliShuttleLogbookEntry* entry) { Long_t expiredTime = time(0) - begin; - if (expiredTime > fConfig->GetPPTimeOut()) + // the run-dependent timeout is the timeout from the configuration plus a twentieth of + // the run duration, e.g. 3 additional minutes for 1h run or 1/2h for a 10h run + Int_t runDepTimeOut = fConfig->GetPPTimeOut() + (GetCurrentEndTime() - GetCurrentStartTime()) * 0.05; + if (expiredTime > runDepTimeOut) { TString logMsg; AliShuttleStatus *currentStatus = ReadShuttleStatus();