Closed GoogleCodeExporter closed 9 years ago
I have a note to fix this already, however:
That broken code is in the *old* section of the delete worker. Any modern
MogileFS install shouldn't be touching this code at all.
You should look for rows in file_to_delete or file_to_delete_later and ensure
new rows aren't entering there, and if there are rows, either delete them or
port them over to file_to_delete2.
Should probably add randomized warnings generated by that old delete code now,
as a few people have still been using it somehow.
Original comment by dorma...@rydia.net
on 27 Sep 2011 at 7:04
I am using the FilePaths plugin, that may be what is queueing up files in that
table
Original comment by daniel.frett
on 27 Sep 2011 at 7:05
just checked the code, it looks like the FilePaths plugin is directly
interacting with the tables
http://cpansearch.perl.org/src/HACHI/MogileFS-Plugin-FilePaths-0.02/lib/MogileFS
/Plugin/FilePaths.pm
around line 40-50:
$dbh->do("DELETE FROM file WHERE fid=?", undef, $oldfid);
$dbh->do("REPLACE INTO file_to_delete SET fid=?", undef, $oldfid);
Original comment by daniel.frett
on 27 Sep 2011 at 7:08
Neat. I'll leave this issue open until we can push a new FilePaths, but that is
pretty dead code.
You should be able to quickly patch it yourself by using the same code that
Query.pm uses to delete a file. $fid->delete or something :P
Original comment by dorma...@rydia.net
on 27 Sep 2011 at 7:10
I'll try and get some time at work to update the FilePaths plugin since we are
using it with a MogileFS FUSE mount for handling uploaded files to a
load-balanced wordpress install.
I'll fork my work off of https://github.com/hachi/MogileFS-Plugin-FilePaths
unless you have a better place to point me :)
Original comment by daniel.frett
on 27 Sep 2011 at 7:21
I just made a github pull request that updates FilePaths to utilize the
MogileFS::FID and MogileFS::Store framework for database interaction
https://github.com/hachi/MogileFS-Plugin-FilePaths/pull/2
Original comment by daniel.frett
on 29 Sep 2011 at 5:35
Tahnks! I've pulled your change into master (sorry for the long delay on that)
I'll ping hachi to check his pull requests for FilePaths.
Original comment by dorma...@rydia.net
on 29 Oct 2011 at 12:13
Original issue reported on code.google.com by
daniel.frett
on 27 Sep 2011 at 6:56