Class EncryptionMigrationProgress
- Namespace
- Excalibur.Dispatch.Serialization
- Assembly
- Excalibur.Dispatch.dll
Represents the progress of a serializer migration operation.
public record EncryptionMigrationProgress : IEquatable<EncryptionMigrationProgress>
- Inheritance
-
EncryptionMigrationProgress
- Implements
- Inherited Members
- Extension Methods
Remarks
This record is used with IProgress<T> to report migration progress during batch processing operations in SerializerMigrationService.
Progress is reported after each batch is processed, allowing consumers to:
- Track migration completion percentage
- Monitor failure rates
- Estimate remaining time
- Log progress for observability
See the migration strategy documentation.
Constructors
EncryptionMigrationProgress(int, int, int, int, int?)
Represents the progress of a serializer migration operation.
public EncryptionMigrationProgress(int TotalMigrated, int TotalFailed, int TotalSkipped, int CurrentBatchSize, int? EstimatedRemaining = null)
Parameters
TotalMigratedintThe total number of records successfully migrated so far.
TotalFailedintThe total number of records that failed migration so far.
TotalSkippedintThe total number of records skipped (already in target format).
CurrentBatchSizeintThe size of the most recently processed batch.
EstimatedRemainingint?The estimated number of records remaining to process, or null if unknown.
Remarks
This record is used with IProgress<T> to report migration progress during batch processing operations in SerializerMigrationService.
Progress is reported after each batch is processed, allowing consumers to:
- Track migration completion percentage
- Monitor failure rates
- Estimate remaining time
- Log progress for observability
See the migration strategy documentation.
Properties
CompletionPercentage
Gets the estimated completion percentage, if EstimatedRemaining is known.
public double? CompletionPercentage { get; }
Property Value
CurrentBatchSize
The size of the most recently processed batch.
public int CurrentBatchSize { get; init; }
Property Value
EstimatedRemaining
The estimated number of records remaining to process, or null if unknown.
public int? EstimatedRemaining { get; init; }
Property Value
- int?
FailureRate
Gets the failure rate as a percentage (0-100).
public double FailureRate { get; }
Property Value
Initial
Creates an initial progress instance with zero counts.
public static EncryptionMigrationProgress Initial { get; }
Property Value
SuccessRate
Gets the success rate as a percentage (0-100).
public double SuccessRate { get; }
Property Value
Remarks
Returns 100 if no records have been processed yet (to avoid division by zero). Skipped records are not counted as failures.
TotalFailed
The total number of records that failed migration so far.
public int TotalFailed { get; init; }
Property Value
TotalMigrated
The total number of records successfully migrated so far.
public int TotalMigrated { get; init; }
Property Value
TotalProcessed
Gets the total number of records processed (migrated + failed + skipped).
public int TotalProcessed { get; }
Property Value
TotalSkipped
The total number of records skipped (already in target format).
public int TotalSkipped { get; init; }
Property Value
Methods
ToString()
Returns a string representation suitable for logging.
public override string ToString()