using Furion; using Furion.DataEncryption; using Furion.EventBus; using Furion.Logging; using Furion.TaskScheduler; using ICSharpCode.SharpZipLib.Zip; using Myshipping.Core.Entity; using Myshipping.Core.Service; using SqlSugar; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Myshipping.Core.Job { /// /// 日志清理 /// public class LogZipClearWorker : ISpareTimeWorker { [SpareTime(60000, "LogZipClearWorker", Description = "日志压缩清理", DoOnce = false, StartNow = true, ExecuteType = SpareTimeExecuteTypes.Serial)] public void LogZipClear(SpareTimer timer, long count) { Log.Information($"日志清理 {DateTime.Now}"); var evtPub = App.GetService(); evtPub.PublishAsync(new ChannelEventSource("LogZipClear:DoWork")); } } }