Skip to content
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

[dolt migrate]: migration failed with conflicts #4790

Closed
mango-lzp opened this issue Nov 15, 2022 · 11 comments
Closed

[dolt migrate]: migration failed with conflicts #4790

mango-lzp opened this issue Nov 15, 2022 · 11 comments
Labels
bug Something isn't working new format Issues related specifically to the __DOLT__ storage format

Comments

@mango-lzp
Copy link

O_1JG BGVLFUKCHYXD%LB K

I can't see any conflicts in this table, and it blocked migration.
I successed migrate in another database, but this one doesn't work.
Am I missed something ?
Thanks to help me!

@mango-lzp
Copy link
Author

mango-lzp commented Nov 15, 2022

I went to check the code, I found this err will be throwed when [HasConflicts] fn is called.
And I found conflict resolve can clear conflictSchemasKey to make [HasConflicts] return false.
I tried to use "dolt conflicts resolve --ours ." to clear conflictSchemasKey.

but it still show failed with conflicts (auth).

I am a frontend programmer, “go” language is hard to read for me.
I think I am close, Plz do me a favor.

@max-hoffman
Copy link
Contributor

max-hoffman commented Nov 15, 2022

Hey @druvv , @mango-lzp has been very patient working through system table performance improvements with me. Would you mind helping them migrate this repo? I think they will see a happy speed up in some of their join queries on __DOLT__. The work I am doing to index system table commit columns will only apply to the new format, also.

@timsehn timsehn added bug Something isn't working new format Issues related specifically to the __DOLT__ storage format labels Nov 15, 2022
@andy-wm-arthur
Copy link
Contributor

@mango-lzp currently there is no path to migrate conflicts in the history. Conflict storage works very differently in the old and new storage formats. Are you hoping to migrate the conflicts for this commit? Or would it be sufficient to drop them on migration?

@druvv
Copy link
Contributor

druvv commented Nov 16, 2022

Hi @mango-lzp, if you want the migration to work and you don't care about the conflicts themselves you can run this query:

dolt filter-branch --all "delete * from dolt_conflicts_auth;"

This will delete the conflicts from all branches and commits where you may have had conflicts.

After running the above, try dolt migrate again.

@mango-lzp
Copy link
Author

@mango-lzp currently there is no path to migrate conflicts in the history. Conflict storage works very differently in the old and new storage formats. Are you hoping to migrate the conflicts for this commit? Or would it be sufficient to drop them on migration?

Hi @andrew-wm-arthur , It suggests that there is a conflict, but I can't see any conflicts in dolt_conflicts table. It is so confusing.

@mango-lzp
Copy link
Author

Hi @mango-lzp, if you want the migration to work and you don't care about the conflicts themselves you can run this query:

dolt filter-branch --all "delete * from dolt_conflicts_auth;"

This will delete the conflicts from all branches and commits where you may have had conflicts.

After running the above, try dolt migrate again.

image

I tried to run [dolt filter-branch --all "delete from dolt_conflicts_auth;"], but it still failed.

@zachmu
Copy link
Member

zachmu commented Nov 17, 2022

Hey @mango-lzp,

Sorry for the frustration. We're going to add a --force option to the migrate tool that will drop conflicts since the other techniques aren't working for you. We'll update here when it's available in a release.

Thanks,

Zach

@mango-lzp
Copy link
Author

@zachmu Thank you very much! I will keep my eyes on it.

@andy-wm-arthur
Copy link
Contributor

@mango-lzp you can now use dolt migrate --drop-conflicts to ignore conflicts on migration. We'll get a release out today so you can use it

@max-hoffman
Copy link
Contributor

v0.51.4 has been released. Let us know if you still have issues with --drop-conflicts.

@mango-lzp
Copy link
Author

@andrew-wm-arthur @max-hoffman Thanks a lot, I am trying to write shell script to deal with conflicts left over from history. I use --drop-conflicts in another dolt, It did work!. I got a fast query time in log query about 2 sec! Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working new format Issues related specifically to the __DOLT__ storage format
Projects
None yet
Development

No branches or pull requests

6 participants