-
-
Notifications
You must be signed in to change notification settings - Fork 176
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
[14.0][ADD] dms_version: DMS Version Control #265
Conversation
There's something weird in the commit history |
da42c73
to
80f1a25
Compare
Here is my description of the design to explain what we wanted to achieve: Configuration
DMS Files
Versioning
Restoring
|
I will test as soon as @yweng8111 fixed the commit history and the other PR errors. |
@agent-z28 FYI |
2170603
to
8eeb0ca
Compare
@pedrobaeza I've already solved that problem in commit history. But there are still some errors in pre-commit, that I don't get locally. Did I do something wrong? |
8eeb0ca
to
16225e1
Compare
You need to execute the copier update to get a newest template fixing the pre-commit problem. Please do it in a separate PR, and once merged, you can rebase here. |
Thanks for the Tip.
|
The copier template already exists. You just need to update it ( |
af1f457
to
3e587aa
Compare
@marylla @agent-z28 Please Review |
@yweng8111 I don't remember if we talked about this before, but... the "has versioning" is not automatically set in directories if the storage type is "attachment". And even if I change it manually, the newly created subdirectories and their files won't get the "has versioning" setting. Did we forget this or was there a reason why we didn't implement it? |
No we don't forget this. I have commented it in the estimation. I will send you the Link later. |
Okay, for all people interested in dms_version module... it is only implemented for storage type "database" and "filestore"... but we're happy if someone has an idea how we can develop this... @victoralmau maybe you want to intervene here? |
3e587aa
to
1099458
Compare
In the initial approach I thought in #177 it was only thought for storage type database or filestore and I think it is the most reasonable. Considering the use case of attachments would be out of the initial scope (in my opinion) since you would have to archive attachments (something that probably has a lot of side effects). PS: It is very difficult for me to know the changes that have been done since #177 because they have not kept the initial commits and added an extra one with the corresponding changes. |
If you really wanted to implement versioning on attachments, it would be possible to have a record "dms.file.history" and move the attachments to it, but that would require some work and also require more configuration with the attachment storages. If think it's fine to skip versioning on attachment. It should just be written upfront in the module documentation, README, etc. I've tested the module in v16 in conjunction with #275 The main issue I had debugging this is that the stack of write is insanely long, due to the various hacks that both Assuming create_revision works correctly, 8b6999b skip the check so that archiving the current revision is taken care of in There was a small bug in that you could not unarchive a file that had no revision, fixed in dfdfbbc. Last I changed the create to work in batch in 0eb2226. Sorry for the wall of text, check https://github.com/lambdao-dev/dms/commits/14.0-add-dms_version-len/ for the code :-) |
@yweng8111 Can you please have a look at what @len-foss and @victoralmau wrote.
I am not very familiar with the technical background of what @len-foss described regarding the "stack of write is insanely long". Can you please check this and get it somehow integrated in your code changes? He mentioned a patch that maybe does the trick. |
1099458
to
579eb60
Compare
579eb60
to
1b68eb0
Compare
I just follow your design and we need it also for the one2many field "all_revision_ids"
I don't understand what you mean. Can you show me later? @marylla
I have integrated some code from @len-foss, Thanks for the tips. |
There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. |
Superseed: #177
DMS Version Control
I have made some changes from an old PR, that are designed by @marylla