DCS error mails are only sent once per subdet and run
authorjgrosseo <jgrosseo@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sat, 8 Mar 2008 17:59:14 +0000 (17:59 +0000)
committerjgrosseo <jgrosseo@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sat, 8 Mar 2008 17:59:14 +0000 (17:59 +0000)
updated LDIF files

SHUTTLE/AliShuttle.cxx
SHUTTLE/AliShuttle.h
SHUTTLE/schema_prod/ACO.ldif
SHUTTLE/schema_prod/SDD.ldif
SHUTTLE/schema_prod/TPC.ldif

index 94fa409..185640e 100644 (file)
@@ -77,6 +77,7 @@ fTimeout(timeout), fRetries(retries),
 fPreprocessorMap(),
 fLogbookEntry(0),
 fCurrentDetector(),
+fFirstProcessing(0),
 fStatusEntry(0),
 fMonitoringMutex(0),
 fLastActionTime(0),
@@ -999,7 +1000,8 @@ Bool_t AliShuttle::ContinueProcessing()
        // checks if the processing should be continued
        // if yes it returns kTRUE and updates the AliShuttleStatus with nextStatus
 
-       if (!fConfig->HostProcessDetector(fCurrentDetector)) return kFALSE;
+       if (!fConfig->HostProcessDetector(fCurrentDetector))
+               return kFALSE;
 
        AliPreprocessor* aPreprocessor =
                dynamic_cast<AliPreprocessor*> (fPreprocessorMap.GetValue(fCurrentDetector));
@@ -1040,12 +1042,16 @@ Bool_t AliShuttle::ContinueProcessing()
                }
        }
 
+       // Is the subdetector processed first time for this run?
+       fFirstProcessing = kFALSE;
+
        AliShuttleStatus* status = ReadShuttleStatus();
        if (!status) {
                // first time
                Log("SHUTTLE", Form("ContinueProcessing - %s: Processing first time",
                                fCurrentDetector.Data()));
                status = new AliShuttleStatus(AliShuttleStatus::kStarted);
+               fFirstProcessing = kTRUE;
                return WriteShuttleStatus(status);
        }
 
@@ -1103,10 +1109,10 @@ Bool_t AliShuttle::ContinueProcessing()
                
                // Send mail to detector expert!
                Log("SHUTTLE", Form("ContinueProcessing - Sending mail to %s expert...", 
-                                       fCurrentDetector.Data()));
+                                   fCurrentDetector.Data()));
                if (!SendMail())
                        Log("SHUTTLE", Form("ContinueProcessing - Could not send mail to %s expert",
-                                       fCurrentDetector.Data()));
+                                           fCurrentDetector.Data()));
 
        } else {
                Log("SHUTTLE", Form("ContinueProcessing - %s: restarting. "
@@ -2102,10 +2108,10 @@ const char* AliShuttle::GetFile(Int_t system, const char* detector,
                 if (fileSize.Length()>0)
                 {
                         // compare filesize of local file with the one stored in the FXS DB
-                       Long_t id,size,flags,mtime;
-                       Int_t sizeComp = gSystem->GetPathInfo(localFileName.Data(),&id,&size,&flags,&mtime);
+                       Long_t size = -1;
+                       Int_t sizeComp = gSystem->GetPathInfo(localFileName.Data(), 0, &size, 0, 0);
 
-                       if ( sizeComp != 0 || size != fileSize.Atoi())
+                       if (sizeComp != 0 || size != fileSize.Atoi())
                        {
                                Log(detector, Form("GetFileName - size of file %s does not match with local copy!",
                                                        filePath.Data()));
@@ -2992,7 +2998,8 @@ Bool_t AliShuttle::SendMail()
        if (fTestMode != kNone)
                return kTRUE;
                
-       if (!fConfig->SendMail()) return kTRUE;
+       if (!fConfig->SendMail()) 
+               return kTRUE;
 
        TString to="";
        TIter iterExperts(fConfig->GetResponsibles(fCurrentDetector));
@@ -3124,7 +3131,11 @@ Bool_t AliShuttle::SendMailToDCS()
        if (fTestMode != kNone)
                return kTRUE;
 
-       if (!fConfig->SendMail()) return kTRUE;
+       if (!fConfig->SendMail()) 
+               return kTRUE;
+
+       if (!fFirstProcessing)
+               return kTRUE;
 
        void* dir = gSystem->OpenDirectory(GetShuttleLogDir());
        if (dir == NULL)
index a258e2d..404a050 100644 (file)
@@ -140,6 +140,7 @@ private:
 
        AliShuttleLogbookEntry* fLogbookEntry;   //! current Shuttle logbook entry
        TString fCurrentDetector; // current detector
+       Bool_t fFirstProcessing;  // processing this detector the first time in this run
 
        TSQLServer *fServer[4];         // pointer to the three FXS + Run & Shuttle logbook servers
        Bool_t fFXSCalled[3];           // FXS call status
index 8769124..22e3b27 100644 (file)
@@ -11,4 +11,4 @@ objectClass: dcsConfig
 dcsHost: alidcsamanda.cern.ch
 dcsPort: 1337
 multiSplit: 4000
-dcsAlias: ACO_HV_MODULE[00..59]
+dcsAlias: ACO_HV_MODULE[00..59]_VMON
index 6af8b69..094ff8b 100644 (file)
@@ -1,4 +1,3 @@
-# SDD config
 dn: det=SDD,o=shuttle_prod,dc=cern,dc=ch
 objectClass: top
 objectClass: detectorConfig
@@ -12,3 +11,18 @@ objectClass: dcsConfig
 dcsHost: alidcsamanda.cern.ch
 dcsPort: 1337
 multiSplit: 4000
+dcsAlias: SDD_LAYER3_LADDER[00..05]_MODULE[0..5]_HV
+dcsAlias: SDD_LAYER4_LADDER[00..11]_MODULE[0..7]_HV
+dcsAlias: SDD_LAYER3_LADDER[00..05]_MODULE[0..5]_MV
+dcsAlias: SDD_LAYER4_LADDER[00..11]_MODULE[0..7]_MV
+dcsAlias: SDD_LAYER3_LADDER[00..13]_MODULE[0..5]_TEMP_L
+dcsAlias: SDD_LAYER3_LADDER[00..13]_MODULE[0..5]_TEMP_R
+dcsAlias: SDD_LAYER4_LADDER[00..21]_MODULE[0..7]_TEMP_L
+dcsAlias: SDD_LAYER4_LADDER[00..21]_MODULE[0..7]_TEMP_R
+dcsAlias: SDD_LAYER3_LADDER[00..13]_MODULE[0..5]_OK
+dcsAlias: SDD_LAYER4_LADDER[00..21]_MODULE[0..7]_OK
+dcsAlias: SDD_LAYER3_LADDER[00..13]_MODULE[0..5]_TEMP_L_STATE
+dcsAlias: SDD_LAYER3_LADDER[00..13]_MODULE[0..5]_TEMP_R_STATE
+dcsAlias: SDD_LAYER4_LADDER[00..21]_MODULE[0..7]_TEMP_L_STATE
+dcsAlias: SDD_LAYER4_LADDER[00..21]_MODULE[0..7]_TEMP_R_STATE
+
index b1b1afb..b85d36a 100644 (file)
@@ -1,3 +1,9 @@
+dn: det=TPC,o=shuttle_prod,dc=cern,dc=ch
+objectClass: detectorConfig
+det: TPC
+strictRunOrder: 0
+responsible: Haavard.Helstrup@cern.ch
+
 dn: dcsHost=alidcsamanda.cern.ch,det=TPC,o=shuttle_prod,dc=cern,dc=ch
 objectClass: dcsConfig
 dcsHost: alidcsamanda.cern.ch