90 lines
2.1 KiB
C#
90 lines
2.1 KiB
C#
namespace OrpaonVision.Core.Training.Contracts.Commands;
|
||
|
||
/// <summary>
|
||
/// 创建运行时部署快照命令。
|
||
/// </summary>
|
||
public sealed class CreateRuntimeDeploymentSnapshotCommand
|
||
{
|
||
/// <summary>
|
||
/// 快照名称。
|
||
/// </summary>
|
||
public string Name { get; init; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 快照描述。
|
||
/// </summary>
|
||
public string Description { get; init; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 机种ID。
|
||
/// </summary>
|
||
public Guid ProductTypeId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 规则版本ID。
|
||
/// </summary>
|
||
public Guid RuleVersionId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 模型包版本ID。
|
||
/// </summary>
|
||
public Guid ModelPackageVersionId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 运行时参数版本ID。
|
||
/// </summary>
|
||
public Guid RuntimeParameterVersionId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 创建者。
|
||
/// </summary>
|
||
public string CreatedBy { get; init; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 快照元数据(JSON格式)。
|
||
/// </summary>
|
||
public string MetadataJson { get; init; } = string.Empty;
|
||
}
|
||
|
||
/// <summary>
|
||
/// 激活运行时部署快照命令。
|
||
/// </summary>
|
||
public sealed class ActivateRuntimeDeploymentSnapshotCommand
|
||
{
|
||
/// <summary>
|
||
/// 快照ID。
|
||
/// </summary>
|
||
public Guid SnapshotId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 激活者。
|
||
/// </summary>
|
||
public string ActivatedBy { get; init; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 激活原因。
|
||
/// </summary>
|
||
public string Reason { get; init; } = string.Empty;
|
||
}
|
||
|
||
/// <summary>
|
||
/// 回滚到运行时部署快照命令。
|
||
/// </summary>
|
||
public sealed class RollbackToRuntimeDeploymentSnapshotCommand
|
||
{
|
||
/// <summary>
|
||
/// 目标快照ID。
|
||
/// </summary>
|
||
public Guid TargetSnapshotId { get; init; }
|
||
|
||
/// <summary>
|
||
/// 回滚者。
|
||
/// </summary>
|
||
public string RolledBackBy { get; init; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 回滚原因。
|
||
/// </summary>
|
||
public string Reason { get; init; } = string.Empty;
|
||
}
|