C#C
C#14mo ago
deprecatio

✅ doubts about migrations

what's bothering me: every time we do a migration on our main service we have 8K+ lines more to commit in the project
(which btw means that for example in the vs search i have to exclude migrations path - thing that took ages because it didn't work - or it's useless)

it's not a big deal di per se, but i find it kinda silly that project is what, ~150K loc, and we have 1+ M loc of migrations (around 100 tables (i'm working on isolating some parts, but i don't know if/when that'll happen) and almost 400 migrations) because every migration (ef core) does a new snapshot
so is this how it's supposed to be? is it not? would i be better off moving migrations to another solution? is there a way to save some code?
i've seen somewhere that maybe you can squash some migrations together, but a) atm i don't know how to do that b) im not sure i want, maybe some i could but with the first ones i don't think i would save that much
Was this page helpful?