Introducing new Status - OCDBError in case the OCDB is not
authorzampolli <zampolli@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 10 Nov 2009 16:32:43 +0000 (16:32 +0000)
committerzampolli <zampolli@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 10 Nov 2009 16:32:43 +0000 (16:32 +0000)
accessible.

SHUTTLE/AliShuttle.cxx
SHUTTLE/AliShuttleStatus.cxx
SHUTTLE/AliShuttleStatus.h

index 354ff8a..a804d77 100644 (file)
@@ -1215,7 +1215,8 @@ Bool_t AliShuttle::ContinueProcessing()
                Bool_t increaseCount = kTRUE;
                if (status->GetStatus() == AliShuttleStatus::kDCSError || 
                    status->GetStatus() == AliShuttleStatus::kDCSStarted ||
-                   status->GetStatus() == AliShuttleStatus::kFXSError)
+                   status->GetStatus() == AliShuttleStatus::kFXSError ||
+                   status->GetStatus() == AliShuttleStatus::kOCDBError)
                                increaseCount = kFALSE;
                                
                UpdateShuttleStatus(AliShuttleStatus::kStarted, increaseCount);
@@ -1607,7 +1608,7 @@ Bool_t AliShuttle::Process(AliShuttleLogbookEntry* entry)
                        else if (success == 0)
                        {
                                Log("SHUTTLE", 
-                                       Form("\t\t\t****** run %d - %s: PP ERROR ******",
+                                       Form("\t\t\t****** run %d - %s: ERROR ******",
                                                GetCurrentRun(), aDetector->GetName()));
                        }
 
@@ -1705,6 +1706,15 @@ Int_t AliShuttle::ProcessCurrentDetector()
                return 2;
        }
        
+       // checking if OCDB is reachable
+       AliCDBEntry* testEntry = GetFromOCDB("SHUTTLE","GRP/CTP/DummyConfig");
+       if (!testEntry){
+               // OCDB is not accessible, going in OCDBError for current detector
+               AliError("OCDB Test entry not accessible");
+               UpdateShuttleStatus(AliShuttleStatus::kOCDBError);
+               return 0;
+       }
+
        TMap* dcsMap = new TMap();
        
        aPreprocessor->Initialize(GetCurrentRun(), GetCurrentStartTime(), GetCurrentEndTime());
index e9af0dd..979735f 100644 (file)
@@ -139,6 +139,7 @@ const char* AliShuttleStatus::GetStatusName(Status status)
     case kStoreDelayed: return "StoreDelayed";
     case kFXSError: return "FXSError";
     case kSkipped: return "Skipped";
+    case kOCDBError: return "OCDBError";
   }
 
   return 0;
index 31f33c8..0c8f643 100644 (file)
@@ -31,7 +31,8 @@ public:
     kFailed,  // final
     kStoreDelayed,
     kFXSError,
-    kSkipped // final
+    kSkipped, // final
+    kOCDBError
   };
 
   AliShuttleStatus();