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

Proper data file deletion #371

Closed
eaquigley opened this issue Jul 9, 2014 · 7 comments
Closed

Proper data file deletion #371

eaquigley opened this issue Jul 9, 2014 · 7 comments
Assignees

Comments

@eaquigley
Copy link
Contributor


Author Name: Michael Bar-Sinai (@michbarsinai)
Original Redmine Issue: 3786, https://redmine.hmdc.harvard.edu/issues/3786
Original Date: 2014-03-27
Original Assignee: Kevin Condon


Hello Leonid,

Continuing our discussion etc, please delete additional data when files are deleted. I recommend adding the code to DeleteDataFileCommand.

We should make sure they are removed from the Solr index too.


Related issue(s): #372
Redmine related issue(s): 3787


@eaquigley
Copy link
Contributor Author


Original Redmine Comment
Author Name: Leonid Andreev (@landreev)
Original Date: 2014-04-11T21:09:29Z


Phil,
This is a ticket for datafile deletion that Michael gave me; I've added code to the file delete command to take care of all the files that may be cached on the filesystem for the datafile object that's being removed.

Please note the 2nd part of the ticket: "We should make sure they are removed from the Solr index too."

I'm assuming this will be taken care of next time the dataset gets reindexed. So my understanding is that it's not necessary to specifically remove the information associated with the file from the Solr index files; because when we index a dataset, we wipe its Solr record clean, then repopulate it by iterating through the files that still exist... But I'm giving it to you to confirm.

(I'm assuming we may want to force a reindex after we delete a datafile; but then we should be careful - this DeleteDataFileCommand can be called by the DeleteDatasetCommand, which calls it for every file in the dataset when it's being deleted... So it would be kinda silly to reindex after deleting every single file, when the entire dataset is being deleted...)

When you're done with this ticket, please give it to QA (there's not UI for this functionality yet, but they can test it, with curl for example).

@eaquigley
Copy link
Contributor Author


Original Redmine Comment
Author Name: Philip Durbin (@pdurbin)
Original Date: 2014-06-18T17:27:32Z


I just did some testing in #3787 and related tickets. I believe we're properly deleting items from Solr now. Passing this ticket to QA.

@eaquigley eaquigley added this to the Dataverse 4.0: In Review milestone Jul 9, 2014
@eaquigley eaquigley modified the milestones: Dataverse 4.0: Beta 3, Dataverse 4.0: In Review Jul 15, 2014
@kcondon
Copy link
Contributor

kcondon commented Jul 22, 2014

I deleted a text file from a draft only version but the file remained on the file system.
Discussed with Leonid and may need to discuss with Phil what the rules are.
Leonid and I think the rules should be:

  1. Draft only, delete file removes all references to it from db and file system.
  2. Published version exists, delete severs connection to newly created draft version, will not show up in search if newest version with deleted file is published, can only get to previous version from version tab. If deleted version remains draft, search will show up file in published version.
  3. Deaccessioned version: Same as for 2.

@kcondon kcondon assigned landreev and unassigned kcondon Jul 23, 2014
@landreev
Copy link
Contributor

Never had a chance to look into this. Will be working on it this week. Re-tagging beta 5.

@landreev
Copy link
Contributor

landreev commented Sep 7, 2014

Appears to be a duplicate of #652. I'll close this ticket when 652 is fixed.

@landreev landreev assigned kcondon and unassigned landreev Sep 8, 2014
@landreev
Copy link
Contributor

landreev commented Sep 8, 2014

Moved #652 into QA. (this is the same issue).

@kcondon
Copy link
Contributor

kcondon commented Sep 8, 2014

OK, tested and it works, there is a search issue that was opened in a separate ticket

Closing

@kcondon kcondon closed this as completed Sep 8, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants