Using file entity and media modules I have a link in the body of a node to /file/609. This is automatically rewritten to point to the direct file URL, I assume by the media filter. After replacing the file (via /file/609/edit) the links in the nodes are now stale until a cache flush. Specifically it seems cache_entity_node needs to be cleared for any nodes referencing this file.

The attached patch searches the file_usage table and clears relevant caches after updating a file. Perhaps this would be better suited to the File Entity or Media module, feel free to move it to another queue.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mstrelan created an issue. See original summary.

mstrelan’s picture

Status: Active » Needs review
thePanz’s picture

I could see this as a File Entity issue, as Entitycache is not responsible of Files.
WDYT?