refactor: update partition handling to use Range struct for better clarity and consistency

This commit is contained in:
2026-04-13 22:36:07 -05:00
parent ed889b740a
commit 1ce3d9e153
6 changed files with 30 additions and 23 deletions

View File

@@ -228,13 +228,15 @@ ORDER BY batch_id`,
for rows.Next() {
partition := models.Partition{
Id: uuid.New(),
ShouldUseRange: true,
RetryCounter: 0,
IsLowerLimitInclusive: true,
Id: uuid.New(),
HasRange: true,
RetryCounter: 0,
Range: models.PartitionRange{
IsMinInclusive: true,
},
}
if err := rows.Scan(&partition.LowerLimit, &partition.UpperLimit); err != nil {
if err := rows.Scan(&partition.Range.Min, &partition.Range.Max); err != nil {
return nil, err
}