Ignore:
Timestamp:
26/09/2008 23:18:35 (4 years ago)
Author:
chris
Message:

Add file logging support (LogFile and LogFileLevel config options).

Ensure that backup-finish is always called, and add a new event,
backup-ok, which is called just before backup-finish when the backup
run was successful.

Keep track of the last backup status notification sent (excluding
backup-start and backup-finish) and send a notification whenever it
changes.

Add a new boolean option, NotifyAlways?, to override that check and
always send notifications to the NotifyScript after every backup run,
for notify scripts which do their own state tracking or otherwise
require notification on every event.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • box/trunk/bin/bbackupd/BackupClientDirectoryRecord.h

    r2245 r2302  
    3737        public: 
    3838        virtual ~SysadminNotifier() { } 
    39         virtual void NotifySysadmin(int Event) = 0; 
     39 
     40        typedef enum 
     41        { 
     42                StoreFull = 0, 
     43                ReadError, 
     44                BackupError, 
     45                BackupStart, 
     46                BackupFinish, 
     47                BackupOK, 
     48                MAX 
     49                // When adding notifications, remember to add 
     50                // strings to NotifySysadmin() 
     51        } 
     52        EventCode; 
     53 
     54        virtual void NotifySysadmin(EventCode Event) = 0; 
    4055}; 
    4156 
     
    195210         
    196211                bool StopRun() { return mrRunStatusProvider.StopRun(); } 
    197                 void NotifySysadmin(int Event)  
     212                void NotifySysadmin(SysadminNotifier::EventCode Event)  
    198213                {  
    199214                        mrSysadminNotifier.NotifySysadmin(Event);  
Note: See TracChangeset for help on using the changeset viewer.