It looks like you may have already corrected this in the dev branch, but since this appears to be a bug in the official release, I'm noting in case anyone else runs across it.

I experienced an issue where my feed items were always updated, even if the hash had not changed. This was especially critical for me since one field mapped to a file. On every update, a new copy of the file was downloaded and placed in my files directory until eventually, my server ran out of disk space. For people with thousands of feed items, this bug could also cause unnecessary stress on their server depending on the cron configuration.

In digging into the getHash() method in FeedsSelfNodeProcessor.inc,the $hash variable is set to the DB object, not the actual hash string. When that variable is compared (on line 37) to the hash from the incoming feed item, the comparison always fails, thus triggering an update.

Adjusting the db_query call a bit solves the issue.

It looks like you removed this module's version of the getHash method in the dev release. Would be nice to get that change into the official release if possible as the bug has the potential to crash a server.

Comments

sjancich’s picture

Status: Active » Needs review
StatusFileSize
new766 bytes

Adding patch.

sjancich’s picture

Status: Needs review » Closed (cannot reproduce)

Apologies...I forgot I had applied the patch in from https://www.drupal.org/node/1965524. This bug is introduced with that patch, so I'll move the discussion on this issue over there.