Skip to main content

Weekly Off Storage

Summary

WeeklyOffs stores one recurring day-name row per tenant entry, without employee or effective-date scope.

Audience

Backend developers, QA, architects, Attendance owners, and support engineers.

Reference Content

The object has an integer primary key, tenant identifier, required bounded day string, tenant query filter, and a non-unique tenant/day index. The database does not enforce valid day names or uniqueness, although replacement logic trims values and removes case-insensitive duplicates before insertion.

The current mutation replaces the tenant collection by deleting existing visible rows and adding the new list in one DbContext save. There is no individual update/delete lifecycle, employee assignment, recurrence expression beyond the day string, effective date, or roster relationship. LeaveDayCalculator uses the day-name collection when the active policy enables weekly-off exclusion.

Attendance also owns weekly-off behavior, and gateway ownership can route compatibility traffic across service boundaries. This overlap is Transitional; no shared-table relationship is present.

ConcernConfirmed behaviorSource
IndexNon-unique tenant/daymicroservices/src/leave-service/Infrastructure/LeaveDbContext.cs
ReplaceRemove visible tenant rows then add normalized distinct stringsmicroservices/src/leave-service/Infrastructure/Persistence.cs
CalculationOptional day exclusion by policymicroservices/src/leave-service/Domain/Leave/LeaveDayCalculator.cs

Source References

  • microservices/src/leave-service/Domain/Leave/CalendarEntities.cs
  • microservices/src/leave-service/Domain/Leave/LeaveDayCalculator.cs
  • microservices/src/leave-service/Infrastructure/LeaveDbContext.cs
  • microservices/src/leave-service/Infrastructure/Persistence.cs

See Also

Keywords

  • WeeklyOff
  • Recurring day
  • Attendance ownership

Revision Information

  • Status: Draft
  • Last reviewed: 2026-07-15
  • Review cycle: Quarterly