Support » Plugin: Redis Object Cache » Old Transients & flush question

  • Resolved bighippo998

    (@bighippo998)


    I don’t particularly think this is a bug, or necessarily a Redis Cache plugin issue, but just in case anyone else encounters similar.

    The problem:
    We use WooCommerce and some time ago renamed a global attribute from ‘Available From’ to ‘Suppliers’. This has worked fine, until we disabled the redis cache (not the whole plugin). As soon as it’s disabled the old attribute is back and the new one disappears. We’ve only recently noticed this as we have a plugin that’s reliant on ‘Suppliers’ attribute and throws a warning if it doesn’t exists. It’s as if there’s a second old cache. After some digging it appears that deleting the transients when Redis Cache is disabled clears the problem and gives us back ‘Suppliers’.

    It’s not very often we’d run with Redis Cache disabled, just during a bulk import or upgrade. but it does raise the question, is there more than just this attribute that has an old transient that’s been used while the cache is off that we don’t know about?
    I’m fairly sure that transients should expire, so not sure why one being a few months old would be valid but seems to be.

    As I said at the start, it’s not really a Redis Cache issue, but does present when you disable it. Not sure if the transients could/should be cleared if the cache is flushed/disabled?

    Question:
    Whenever we disable the redis cache for imports or upgrades, we always flush the cache then disable and when reactivating it we activate and flush the cache again just to make sure nothing old is in there. Does either disabling or enabling the cache automatically flush?

    ps thanks for a great plugin.

Viewing 1 replies (of 1 total)
  • Plugin Author Till Krüss

    (@tillkruess)

    Whenever we disable the redis cache for imports or upgrades, we always flush the cache then disable and when reactivating it we activate and flush the cache again just to make sure nothing old is in there. Does either disabling or enabling the cache automatically flush?

    No, neither flushes the cache automatically, just in case there is data in Redis the user wants to keep.

    I’ve seen this issue once or twice before, I believe it’s a WC issue.

    Your approach of flushing the cache before and after disabling/enabling the object cache dropin is a good solution.

    Does that answer your questions?

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.