void OnDomainUnload(object sender, EventArgs e) { try { var buckets = filler.CheckoutBuckets(); repository.Save(buckets); } catch (Exception ex) { log.Error(ex); } }
public override void Execute() { var now = Utility.CurrentTime(); if (LastExecuted.HasValue) { if (LastExecuted.Value.GetSlot(MemoryFlushInterval) != now.GetSlot(MemoryFlushInterval)) { var buckets = filler.CheckoutBuckets(); repository.Save(buckets); } } if (!LastExecuted.HasValue || LastExecuted.Value.GetSlot(TransferInterval) != now.GetSlot(TransferInterval)) { repository.Transfer(now, StatisticsGranularity); } }