using Domain.Entities.Stocks; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Metadata.Builders; namespace Infrastructure.Persistence.Configurations.Stocks; public sealed class SeibroSweptDateConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { builder.ToTable(nameof(SeibroSweptDate), t => t.HasComment("SEIBro 날짜 스윕 조회 완료 마커 (0행 포함) — 리뷰 결함 #1: 조용한 날 재조회 제거용")); builder.HasKey(x => x.ID); builder.HasIndex(x => new { x.JobKey, x.Date, x.Discriminator }).IsUnique(); builder.Property(x => x.JobKey).HasMaxLength(40).IsRequired().HasComment("수집 job 식별자"); builder.Property(x => x.Date).IsRequired().HasComment("스윕 대상 날짜 (요청 파라미터 날짜)"); builder.Property(x => x.Discriminator).HasMaxLength(20).IsRequired().HasComment("스윕 축 구분 (tpcd/kacd/nation 등, 없으면 빈 문자열)"); builder.Property(x => x.SweptAt).IsRequired().HasComment("조회 완료 시각 (UTC, 0행 포함)"); } }