-
-
Notifications
You must be signed in to change notification settings - Fork 528
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SequelizeMeta is attemping to sync on each migration run #85
Comments
That is because of https://github.com/sequelize/umzug/blob/master/lib/storages/sequelize.js#L84 Why would you consider that a bottleneck? |
I can see that this is far from ideal. But tbh it has for me ultra high priority. |
Because you don't need to initialize it and check on each migration run, but i think you already know that. :) By the way, thanks for changing the table schema, it solved some problems we were getting when merging PRs with different timings. 👍 |
Unfortunately this link is dead :-(
This seems terribly inefficient. For each migration file (which we have over a hundred), the following 5 extra SQL statements are made (that I believe are unnecessary):
Surely nobody is running two migrators against the same DB at the same time. And if they are, I don't see how this would help. |
Updated link: Seems that now it is defined and re-used. |
I'm on Umzug 1.11.0 (is that the latest?). I still see all of the SQL I mentioned above. I worked around this mayhem by creating a mysql dump that I use to initialize new user's DBs. When a new user signs up, I'm reading in the MySQL dump and executing the queries one by one rather than executing the umzug migrations. A few comparisons:
I should also note that I (have to) turn off foreign key checks in the mysql dump (although there's no data there). But I suspect that makes the table creation a little faster. I'd be surprised if that made it twice as fast though. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
It seems that
SequelizeMeta
syncs between each migration run, is this expected?IMHO, if there isn't a propose, this is a bottleneck.
logging:
The text was updated successfully, but these errors were encountered: