Problem/Motivation

I've got many features and over 375 enabled modules, so fairly large site. features_module_info cached item in the default cache bin is causing me issues with memcache (can't have items > 1MB in size)

[warning]
WD memcache: Spent 32.96 ms splitting 1.03 MB object into 2 pieces, cid = em_-cache-features_module_info

Proposed resolution

Move features cached items to their own bin so that I can exclude them from memcache.

Remaining tasks

User interface changes

API changes

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

joelpittet’s picture

Status: Active » Needs review
FileSize
1.75 KB

Status: Needs review » Needs work

The last submitted patch, 1: cache_features-2421127-1.patch, failed testing.

joelpittet’s picture

Status: Needs work » Needs review
FileSize
2.2 KB

Add an update hook to install the new cache table bin.

Status: Needs review » Needs work

The last submitted patch, 3: cache_features-2421127-3.patch, failed testing.

joelpittet’s picture

Status: Needs work » Needs review
FileSize
2.56 KB

And of course a schema would help.

joelpittet’s picture

Status: Needs review » Needs work

The last submitted patch, 5: cache_features-2421127-5.patch, failed testing.

joelpittet’s picture

Status: Needs work » Needs review
FileSize
2.55 KB

Man I keep missing things.

hefox’s picture

Status: Needs review » Needs work

the return in hook_flush_caches looks misplaced

joelpittet’s picture

@hefox it's not I don't think... it's inside the condition:

  if (variable_get('features_rebuild_on_flush', TRUE)) {

But maybe it is ok flush that cache with all flushes always?

hefox’s picture

features_rebuild is where it goes and checks every features and sees if it the features has been changed. cache talble should not be inside that -- it may be disabled and then the cache will never be cleared.

joelpittet’s picture

Status: Needs work » Needs review
FileSize
2.51 KB
517 bytes

Fair point, here's a fix.

joelpittet’s picture

This has been working well for me, need someone to give this a test:)

mpotter’s picture

Status: Needs review » Needs work

Also, see this: https://api.drupal.org/api/drupal/modules%21system%21system.api.php/func...

I think the update hook number needs to be 7100 rather than 7000.

joelpittet’s picture

Status: Needs work » Needs review
FileSize
2.51 KB

Actually 7200 because it's on the 2.x branch no?

Here's a patch.

mpotter’s picture

Status: Needs review » Reviewed & tested by the community

Think this is good now.

joelpittet’s picture

Thanks @mpotter. Do you usually let another maintainer commit your RTBC'd patches as a policy or will you end up committing it? Just curious as I just started maintaining a few projects.

mpotter’s picture

Usually it's me or hefox committing patches these days. As you can probably tell from the activity in the issue queue I'm getting ready for a release soon at which point any RTBC patch is usually committed.

mpotter’s picture

Status: Reviewed & tested by the community » Fixed

Committed to 25b6385.

  • mpotter committed 25b6385 on 7.x-2.x authored by joelpittet
    Issue #2421127 by joelpittet: Features should have it's own cache bin...

Status: Fixed » Closed (fixed)

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