Problem/Motivation

The cache_path cache bin is not cleaned up when the rest of the caches are. This causes the store for this cache (usually DB) to grow infinitely.

Proposed resolution

Commit patch to core which clears cache_path when the other caches are cleared. This is in the drupal_flush_all_caches() and system_cron() functions. Also, commit a cache flush test.

Remaining tasks

Patch #12 has been reviewed and tested and needs to be committed.

User interface changes

None.

API changes

None.

Original report by Akaoni

Originally reported by hijacking this issue:
http://drupal.org/node/902736#comment-4836630
Oops!!

Comments

Akaoni’s picture

StatusFileSize
new1.2 KB

Checking if old patch still works against 8.x-dev.

Akaoni’s picture

StatusFileSize
new1.23 KB

Rerolled and moved dereine's test patch.
This patch should fail.

Status: Needs review » Needs work

The last submitted patch, core-test_flush_all_caches-1259096-2.patch, failed testing.

Akaoni’s picture

Status: Needs work » Needs review
Akaoni’s picture

StatusFileSize
new2.43 KB

Fix and test combined patch.

Akaoni’s picture

Issue summary: View changes

Added patch #.

Akaoni’s picture

Issue summary: View changes

Added possible test path.

Akaoni’s picture

Issue summary: View changes

Updated possible test path.

karschsp’s picture

Issue summary: View changes

Updating test steps to include creating nodes with custom path aliases.

karschsp’s picture

Status: Needs review » Reviewed & tested by the community

Works as advertised.

karschsp’s picture

Status: Reviewed & tested by the community » Needs review

Setting back to Needs Review so we can get a couple more people to take a look.

Akaoni’s picture

@karschsp: Thanks for your help, mate!!! ; )

catch’s picture

drupal_flush_all_caches - this could do with being drupal_flush_all_caches().

crashtest_’s picture

I tested as stated above, and reviewed the patch code. The patch applied fine, and testing produced the result of the cache_path table being cleared on the "Clear all caches" button being clicked, where prior to applying the patch, the same action didn't clear that table.

Looks great to me!

Pat

Akaoni’s picture

@catch: Good pickup. Will make sure to update this in the comments once it's had another test or two.

@CrashTest_: You rock!! Thanks for testing!! ; )

Akaoni’s picture

StatusFileSize
new2.43 KB

New patch with catch's comment suggestion (functionally the same as #5).

catch’s picture

Component: cache system » base system
Status: Needs review » Reviewed & tested by the community

Looks good.

Akaoni’s picture

Thanks, catch!! ;)

Akaoni’s picture

Issue summary: View changes

Updated test path.

Status: Reviewed & tested by the community » Needs work
Issue tags: -Needs tests, -Needs backport to D7

The last submitted patch, core-cache_path_cleanup-1259096-12.patch, failed testing.

Akaoni’s picture

Status: Needs work » Needs review
Issue tags: +Needs tests, +Needs backport to D7

Must be some kind of testing oddity.
#12: core-cache_path_cleanup-1259096-12.patch queued for re-testing.

catch’s picture

Status: Needs review » Reviewed & tested by the community

The test failure looked completely unrelated (fatal error in form required values), back to RTBC.

dries’s picture

Status: Reviewed & tested by the community » Fixed

Good catch. Committed to 7.x and 8.x. Thanks.

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Updated remaining tasks.