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.
This was some kind of replacement for a locking mechanism at one point I think, either way that code is long since gone but the cache bin never went with it.
We should remove it from schema in D7 too, not 100% sure about having an update just in case some contrib module is doing something with this (can't think why though).
Comment | File | Size | Author |
---|---|---|---|
#25 | 1275684-image_cache-bin-25.patch | 1.91 KB | pillarsdotnet |
#23 | 1275684-image_cache-bin-23.patch | 1.91 KB | pillarsdotnet |
#20 | remove-image_cache-bin-1275684-20.patch | 1.91 KB | pillarsdotnet |
#18 | remove-image_cache-bin-1275684-18.patch | 1.91 KB | pillarsdotnet |
#14 | image_D7.patch | 1.38 KB | catch |
Comments
Comment #1
catch.
Comment #3
neclimdulum... is head broken or something cause most of those tests have nothing to do with images....
Just for reference as to how this happened git-bisect blames #851878: serve image derivatives from the same url they are generated from 7c57f94315b7
Comment #4
catchimage_whoops.patch queued for re-testing.
Comment #6
neclimdulre: the update, i'd say we remove it at least in d8. if we aren't providing the cache_flush, then we don't own the table anymore and we shouldn't leave random tables laying around. I don't know how we'd review if contrib is using it in d7. I guess that would be the litmus for backporting?
Comment #7
catchThought about this a bit today and removing it in D7 seems good to me. Grepping contrib is a bit harder than it used to be but I can't think of a reason any module would use this (and if they did it's an easy fix).
Comment #8
sunLooks good to me, obviously for D8, but I also think that D7 should be safe. That is, with a probability of 99%.
Comment #9
Dries CreditAttribution: Dries commentedWeird. The patch does not seem to apply.
Comment #10
catchCache API changed which affected the bin name in hook_flush_caches(). Re-rolled.
Comment #11
neclimdulI just realized, shouldn't we actually remove the table?
Comment #12
suneuhm, indeed. ;)
Comment #13
catchHmm I was going to put that in the D7 patch, I can do it now though.
Comment #14
catchHere it is.
Comment #15
sunThanks!
Comment #16
neclimdulAwesome, just wanted to make sure we didn't leave a table lying around for people upgrading :)
double plus rtbc now.
Comment #17
Dries CreditAttribution: Dries commentedCommitted to 8.x and moving to 7.x. for webchick. I didn't want to commit the d7 patch yet because the test bot hasn't run yet.
Comment #18
pillarsdotnet CreditAttribution: pillarsdotnet commentedRe-uploading for 7.x testbot.
Comment #20
pillarsdotnet CreditAttribution: pillarsdotnet commentedThe additional
image_update_7000()
function needed to be renamed toimage_update_7002()
.Comment #21
Berdir#20: remove-image_cache-bin-1275684-20.patch queued for re-testing.
Comment #23
pillarsdotnet CreditAttribution: pillarsdotnet commentedRe-rolled.
Comment #25
pillarsdotnet CreditAttribution: pillarsdotnet commentedBumping update function to 7005.
Comment #26
sunHm. Is it safe to do that for D7?
What if a contributed or custom module (re-)uses this cache bin?
Comment #27
pillarsdotnet CreditAttribution: pillarsdotnet commentedTrying to find a way to search through all contrib and custom modules to answer your question, @sun.
So I visited the project/issues page and scraped a list of the node ids for all projects, and now I'm visiting each node page and scraping the project name. Once that's done I'll use drush to dl the 7.x version of each and grep through the whole dirtree for 'cache_image' and let you know.
Should be done in another couple of hours.
Of course, that only tests for contrib modules published through drupal.org, but anything else they can just deal with it, as far as I'm concerned. People who write unpublished code that depends on undocumented unintentional cruft get what they deserve.
Comment #28
pillarsdotnet CreditAttribution: pillarsdotnet commentedDownloading stalled.
Maybe d.o is blocking me?Restarted...Comment #29
pillarsdotnet CreditAttribution: pillarsdotnet commentedOkay, here are all the places that reference
cache_image
:backup_migrate_destination_db::backup_settings_default()
Return the default tables whose data can be ignored. These tables mostly contain info which can be easily reproducted (such as cache or search index) but also tables which can become quite bloated but are not necessarily extremely important to back up or migrate during development (such ass access log and watchdog)
_backup_migrate_default_structure_only_tables()
Return the default tables whose data can be ignored. These tables mostly contain info which can be easily reproducted (such as cache or search index) but also tables which can become quite bloated but are not necessarily extremely important to back up or migrate during development (such ass access log and watchdog)
SimpleTestCloneTestCase::$excludeTables
Tables listed in this array will not have data copied, only table structure.
SimpleTestCloneTestCase::cloneTable()
simpletest_fixture_generate()
...
...
...
DrupalCloneTestCase::$excludeTables
Tables to exlude during data cloning, only their structure will be cloned.
DrupalCloneTestCase::cloneTable
tests/drupal-7.og.update_7001.database.php
Filled installation of Drupal 7, for test purposes.
tests/og-7.x-1.x.database.php
Filled installation of Drupal 7.0, for test purposes.
Comment #30
mgifford@sun, did @pillarsdotnet's response answer your question?
Any way to search if a contributed module (re-)uses this cache bin? Must be an easy way to search for that.
As far as custom modules, that could be announced in the release notes.
Comment #31
sunI do not think we can remove (any) database tables in D7, since doing so falls under the API change + backwards-compatibility umbrella. We may be able to scan contrib, but we cannot scan custom code.
Comment #32
mgiffordOk, in that case, it looks like we can't fix this for D7.
Comment #33
Andrew Answer CreditAttribution: Andrew Answer as a volunteer commented