Hello all,
I’m close to implement the workaround to speed up migrations here: https://github.com/prisma/prisma/issues/7933
before I do so, maybe there’s something I’m missing and there’s already a way to have them run fast..
Let me know I’m highly interested into that matter..
n
Nurul
06/06/2022, 6:59 AM
Hey Stephane 👋
What improvements are you suggesting?
If you could create a PR then our migrate team can have a look and should be able to provide you with feedback.
s
Stephane Le Dorze
06/06/2022, 9:20 PM
like said in the Issue; the official way of migrating is slow.
And the given script is fast.
I don’t know if there’s some good reasons that lead to this performance difference..
t
tom
06/10/2022, 7:30 AM
The main reason is that there are more roundtrips in the actual migrate, because we manage the migrations table. That adds two extra roundtrips per migration. We could get that down to one roundtrip, but then when a migration fails, we wouldn't be always able to tell which one from looking at the migrations table.
s
Stephane Le Dorze
08/08/2022, 2:16 PM
got it still if I remember well (2 months old!) it may be due to the need to call the cli - instead of a SDK call that makes it slower than necessary..