ow
This commit is contained in:
1 parent
7c8af2fb08
commit
c10f8347e2
31 files changed
+358
-292
No files matched your search
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -34,8 +34,6 @@ public partial class Program
|
||||
string taskName = null;
|
||||
Dictionary<string, string> bodyDict = new Dictionary<string, string>();
|
||||
|
||||
File.AppendAllText("log.txt", "Main:" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "\r\n");
|
||||
|
||||
if (args != null && args.Length > 0)
|
||||
{
|
||||
var services = new ServiceCollection();
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<!-- https://go.microsoft.com/fwlink/?LinkID=208121. -->
|
||||
<Project>
|
||||
<PropertyGroup>
|
||||
<History>True|2026-09-21T07:29:51.3588778Z||;True|2026-09-21T15:18:10.5399306+08:00||;True|2026-09-21T14:59:51.6908938+08:00||;True|2026-09-21T14:49:11.2390264+08:00||;True|2026-09-21T14:17:57.4013084+08:00||;True|2026-09-21T14:00:14.9207890+08:00||;True|2026-09-21T11:59:35.1020536+08:00||;True|2026-09-21T11:50:47.8944224+08:00||;True|2026-09-21T11:30:52.9019631+08:00||;True|2026-09-21T10:47:01.8026331+08:00||;</History>
|
||||
<History>True|2026-09-21T13:16:57.9976233Z||;True|2026-09-21T19:43:49.4288081+08:00||;True|2026-09-21T18:49:13.4734866+08:00||;True|2026-09-21T18:10:56.1357602+08:00||;True|2026-09-21T17:47:00.1779419+08:00||;True|2026-09-21T15:29:51.3588778+08:00||;True|2026-09-21T15:18:10.5399306+08:00||;True|2026-09-21T14:59:51.6908938+08:00||;True|2026-09-21T14:49:11.2390264+08:00||;True|2026-09-21T14:17:57.4013084+08:00||;True|2026-09-21T14:00:14.9207890+08:00||;True|2026-09-21T11:59:35.1020536+08:00||;True|2026-09-21T11:50:47.8944224+08:00||;True|2026-09-21T11:30:52.9019631+08:00||;True|2026-09-21T10:47:01.8026331+08:00||;</History>
|
||||
<LastFailureDetails />
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -31,20 +31,24 @@ namespace CloudBuilder.Topshelf.Task
|
||||
IRepository<SecurityScheduleTaskQueueEntity> taskRepository = service.GetRepository<IRepository<SecurityScheduleTaskQueueEntity>>();
|
||||
|
||||
|
||||
SecurityScheduleTaskQueueEntity task = taskRepository.DetachedEntities.OrderBy(x => x.QueueId).FirstOrDefault();
|
||||
SecurityScheduleTaskQueueEntity[] tasks = taskRepository.DetachedEntities.OrderBy(x => x.QueueId).ToArray();
|
||||
|
||||
if (task == null) return;
|
||||
if (tasks == null || tasks.Length == 0) return;
|
||||
|
||||
foreach (var task in tasks)
|
||||
{
|
||||
IRepository<DmsFileEntity> repositoryDmsFile = service.GetRepository<IRepository<DmsFileEntity>>();
|
||||
DmsFileEntity dmsFile = repositoryDmsFile.DetachedEntities.Where(x => x.OrderKey == task.DocumentId).FirstOrDefault();
|
||||
|
||||
IRepository<DmsFileEntity> repositoryDmsFile = service.GetRepository<IRepository<DmsFileEntity>>();
|
||||
DmsFileEntity dmsFile = repositoryDmsFile.DetachedEntities.Where(x => x.OrderKey == task.DocumentId).FirstOrDefault();
|
||||
if (dmsFile == null) return;
|
||||
|
||||
if (dmsFile == null) return;
|
||||
RunMyProcess(task.TaskId, task.TaskParam);
|
||||
|
||||
RunMyProcess(task.TaskId, task.TaskParam);
|
||||
dmsFile.TranscodeIndc = YesNoPolicy.YES;
|
||||
repositoryDmsFile.UpdateNow(dmsFile);
|
||||
|
||||
dmsFile.TranscodeIndc = YesNoPolicy.YES;
|
||||
repositoryDmsFile.UpdateNow(dmsFile);
|
||||
taskRepository.DeleteNow(task);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
@@ -60,7 +64,11 @@ namespace CloudBuilder.Topshelf.Task
|
||||
{
|
||||
try
|
||||
{
|
||||
parameters = parameters.Replace("/app/data", "/vol1/1000/Docker/NET8/DEV/data");
|
||||
//Dockerfile中定义的volumes的映射地址
|
||||
var rf = service.Configuration["FileServiceSettings:RelativeFileDirectory"];
|
||||
var af = service.Configuration["FileServiceSettings:AbsoluteFileDirectory"];
|
||||
|
||||
parameters = parameters.Replace(rf, af);
|
||||
|
||||
log.WriteToFile(exePath + parameters);
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
"DbContexts": {
|
||||
"MasterDbContext": {
|
||||
"DbContextTypeName": "MasterDbContext",
|
||||
"ConnectionString": "server=nas.youjiala.com;port=3307;database=builder;uid=root;pwd=Root@1237890;CharSet=utf8mb4;",
|
||||
"ConnectionString": "server=nas.youjiala.com;port=3307;database=Furion;uid=root;pwd=Root@1237890;CharSet=utf8mb4;",
|
||||
"DatabaseType": "MySql",
|
||||
"LazyLoadingProxiesEnabled": true,
|
||||
"AuditEntityEnabled": true,
|
||||
@@ -26,6 +26,10 @@
|
||||
"UserMobile": "13560851330"
|
||||
}
|
||||
},
|
||||
"FileServiceSettings": {
|
||||
"AbsoluteFileDirectory": "/vol1/1000/Docker/NET8/publish/data",
|
||||
"RelativeFileDirectory": "/app/data" //Dockerfile - /vol1/1000/Docker/NET8/publish/data:/app/data
|
||||
},
|
||||
"IApplicationService": {
|
||||
"UserId": "000003" //通过Service是不需要用户权限而直接调用
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user