Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I ran into the issue where theme functions in a newly installed module would not be picked up. The theme cache would clear fine, but (I think) the module_implements() cache didn't, causing the new modules theme hooks to be unregistered.
My suggestion is to add a hook_flush_caches() implementation with just apc_clear_cache()
as body. In this way, there is at least a method whereby the cache can be cleared. If this is undesirable, perhaps adding a separate Clear APC button somewhere is a better idea.
Comment | File | Size | Author |
---|---|---|---|
#7 | 1869134_apc_clear_cache_form_alter_2.patch | 1.32 KB | MrHaroldA |
#6 | 1869134_apc_clear_cache_form_alter.patch | 890 bytes | MrHaroldA |
Comments
Comment #1
MrHaroldA CreditAttribution: MrHaroldA commentedI'll try to incorporate this in #1565716: Make "drush cc" clear cache on the webnode itself!
Comment #2
R.Muilwijk CreditAttribution: R.Muilwijk commentedComment #3
MrHaroldA CreditAttribution: MrHaroldA commentedThat acually is a good idea ;) We maintain an externally hosted site which has
apc.stat=0
in it's APC config, so new/changed files aren't picked up unless the APC stat cache is flushed using the apc.php script.+1 for a "APC flush cache button" in the Drupal APC module!
Comment #4
Jorrit CreditAttribution: Jorrit commentedYes, so actually there is a need for two buttons: one for the code, one for the user cache.
Comment #5
R.Muilwijk CreditAttribution: R.Muilwijk commentedCould someone make a form_alter and add the button next to 'Clear all caches' button?
Comment #6
MrHaroldA CreditAttribution: MrHaroldA commentedLike this?
Comment #7
MrHaroldA CreditAttribution: MrHaroldA commentedOr like this? ;)
Comment #8
R.Muilwijk CreditAttribution: R.Muilwijk commentedCommitted to dev.