Skip to main content
added an explicit question
Source Link
avpaderno
  • 97.9k
  • 15
  • 164
  • 284

I am looking at the documentation for the expire field in the cache tables and the documentation in CacheBackendInterface.php says:

  * @param int $expire
   *   One of the following values:
   *   - CacheBackendInterface::CACHE_PERMANENT: Indicates that the item should
   *     not be removed unless it is deleted explicitly.
   *   - A Unix timestamp: Indicates that the item will be considered invalid
   *     after this time, i.e. it will not be returned by get() unless
   *     $allow_invalid has been set to TRUE. When the item has expired, it may
   *     be permanently deleted by the garbage collector at any time.
   * @param array $tags

@param int $expire
One of the following values:

  • CacheBackendInterface::CACHE_PERMANENT: Indicates that the item should not be removed unless it is deleted explicitly.
  • A Unix timestamp: Indicates that the item will be considered invalid after this time, i.e. it will not be returned by get() unless $allow_invalid has been set to TRUE. When the item has expired, it may be permanently deleted by the garbage collector at any time.

But whenWhen I look in a cache table, for example, cache_rendercache_render, I see that many of the entiresentries have NULL in the expireexpire column and I noticed it only get clear on a complete cache clear, such as after running drush cr.

What does a null value set for the expire column in a cache table mean?

I am looking at the documentation for the expire field in the cache tables and the documentation in CacheBackendInterface.php says:

  * @param int $expire
   *   One of the following values:
   *   - CacheBackendInterface::CACHE_PERMANENT: Indicates that the item should
   *     not be removed unless it is deleted explicitly.
   *   - A Unix timestamp: Indicates that the item will be considered invalid
   *     after this time, i.e. it will not be returned by get() unless
   *     $allow_invalid has been set to TRUE. When the item has expired, it may
   *     be permanently deleted by the garbage collector at any time.
   * @param array $tags

But when I look in a cache table, for example, cache_render I see many of the entires have NULL in the expire column and I noticed it only get clear on a complete cache clear drush cr

I am looking at the documentation for the expire field in the cache tables and the documentation in CacheBackendInterface.php says:

@param int $expire
One of the following values:

  • CacheBackendInterface::CACHE_PERMANENT: Indicates that the item should not be removed unless it is deleted explicitly.
  • A Unix timestamp: Indicates that the item will be considered invalid after this time, i.e. it will not be returned by get() unless $allow_invalid has been set to TRUE. When the item has expired, it may be permanently deleted by the garbage collector at any time.

When I look in a cache table, for example cache_render, I see that many entries have NULL in the expire column and I noticed it only get clear on a complete cache clear, such as after running drush cr.

What does a null value set for the expire column in a cache table mean?

Fix title
Link
awm
  • 2.5k
  • 1
  • 22
  • 42

What does it mean if expire is set to null in a cache table?

Tweeted twitter.com/StackDrupal/status/1106706791344295936
Source Link
awm
  • 2.5k
  • 1
  • 22
  • 42

What does it mean if expire is set to null a cache table?

I am looking at the documentation for the expire field in the cache tables and the documentation in CacheBackendInterface.php says:

  * @param int $expire
   *   One of the following values:
   *   - CacheBackendInterface::CACHE_PERMANENT: Indicates that the item should
   *     not be removed unless it is deleted explicitly.
   *   - A Unix timestamp: Indicates that the item will be considered invalid
   *     after this time, i.e. it will not be returned by get() unless
   *     $allow_invalid has been set to TRUE. When the item has expired, it may
   *     be permanently deleted by the garbage collector at any time.
   * @param array $tags

But when I look in a cache table, for example, cache_render I see many of the entires have NULL in the expire column and I noticed it only get clear on a complete cache clear drush cr