failsafe load dlls

add user config queue offsets
throttle improvements
This commit is contained in:
Alex Bezdieniezhnykh
2025-04-17 01:19:48 +03:00
parent 0237e279a5
commit 0c66607ed7
32 changed files with 320 additions and 188 deletions
@@ -0,0 +1,7 @@
namespace Azaion.CommonSecurity.DTO;
internal class BusinessExceptionDto
{
public int ErrorCode { get; set; }
public string Message { get; set; } = string.Empty;
}
@@ -0,0 +1,15 @@
namespace Azaion.CommonSecurity.DTO;
public class DirectoriesConfig
{
public string ApiResourcesDirectory { get; set; } = null!;
public string VideosDirectory { get; set; } = null!;
public string LabelsDirectory { get; set; } = null!;
public string ImagesDirectory { get; set; } = null!;
public string ResultsDirectory { get; set; } = null!;
public string ThumbnailsDirectory { get; set; } = null!;
public string GpsSatDirectory { get; set; } = null!;
public string GpsRouteDirectory { get; set; } = null!;
}
@@ -8,10 +8,7 @@ public abstract class ExternalClientConfig
public int RetryCount {get;set;}
}
public class InferenceClientConfig : ExternalClientConfig
{
public string ResourcesFolder { get; set; } = "";
}
public class InferenceClientConfig : ExternalClientConfig;
public class GpsDeniedClientConfig : ExternalClientConfig
{
@@ -6,6 +6,4 @@ public class HardwareInfo
public string GPU { get; set; } = null!;
public string MacAddress { get; set; } = null!;
public string Memory { get; set; } = null!;
public string Hash { get; set; } = null!;
}
@@ -4,4 +4,5 @@ public class SecureAppConfig
{
public InferenceClientConfig InferenceClientConfig { get; set; } = null!;
public GpsDeniedClientConfig GpsDeniedClientConfig { get; set; } = null!;
public DirectoriesConfig DirectoriesConfig { get; set; } = null!;
}
+16 -6
View File
@@ -1,11 +1,21 @@
using MessagePack;
namespace Azaion.CommonSecurity.DTO;
[MessagePackObject]
public class User
{
[Key("i")] public string Id { get; set; } = "";
[Key("e")] public string Email { get; set; } = "";
[Key("r")]public RoleEnum Role { get; set; }
public string Id { get; set; } = "";
public string Email { get; set; } = "";
public RoleEnum Role { get; set; }
public UserConfig? UserConfig { get; set; } = null!;
}
public class UserConfig
{
public UserQueueOffsets? QueueConfig { get; set; } = new();
}
public class UserQueueOffsets
{
public int AnnotationsOffset { get; set; }
public int AnnotationsConfirmOffset { get; set; }
public int AnnotationsCommandsOffset { get; set; }
}