cache_form is never cleared on some sites

Created on 28 March 2012, over 13 years ago
Updated 12 April 2024, over 1 year ago

As per title, the form retrieved in cache_get would never invoke db_query("DELETE FROM {cache_form} WHERE expire != CACHE_PERMANENT and EXPIRE < time()", ) because cache_flush_cache_form will always be 0, manually setting this to a value would only invoke the cache cleaning once.
I propose adding variable_set("cache_flush_cache_form") to form_cache_get, expiry is already set to a long TTL, so this should be safe to clear the cache, instead of using a cron to regularly truncate the table

🐛 Bug report
Status

Needs work

Version

7.0 ⚰️

Component
Cache 

Last updated 12 days ago

Created by

🇲🇾Malaysia martianunlimited

Live updates comments and jobs are added and updated live.
  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024