Пример #1
0
 internal Channel(string name, int maxLogsPerBatch, TimeSpan batchTimeInterval, int maxParallelBatches,
                  string appSecret, IIngestion ingestion, IStorage storage)
 {
     _mutex = new StatefulMutex(_stateKeeper);
     Name   = name;
     _maxParallelBatches = maxParallelBatches;
     _maxLogsPerBatch    = maxLogsPerBatch;
     _appSecret          = appSecret;
     _ingestion          = ingestion;
     _storage            = storage;
     _batchTimeInterval  = batchTimeInterval;
     _batchScheduled     = false;
     _enabled            = true;
     DeviceInformationHelper.InformationInvalidated += (sender, e) => InvalidateDeviceCache();
     Task.Run(CountFromDiskAsync);
 }
Пример #2
0
 public Push()
 {
     _mutex = new StatefulMutex(_stateKeeper);
     LogSerializer.AddLogType(PushInstallationLog.JsonIdentifier, typeof(PushInstallationLog));
 }