Problem/Motivation

The "Exclude entities from persistent caches" option is misleading. The description in the UI: "This will ensure unencrypted data will not be exposed in the cache, but will have a negative impact on performance."

What this option actually does is exclude ALL entities of an entity type that has field encryption enabled, regardless of whether or not they actually have a field that is encrypted.

For example, if you have 10 content types, like Article, Page, Landing Page, Blog Post, and so on, and only one has a field with field encryption enabled, then using the "Excluding entities from persistent caches" will remove all nodes of all content types from the cache.

Proposed resolution

For now, make the description clearer in the UI. But long term, it would be great if only entity bundles that had a field with field encryption enabled would be excluded from caching.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

ptmkenny created an issue. See original summary.

ptmkenny’s picture

Status: Active » Needs review

This MR describes the extent of the performance penalty. As I said, I think the best solution is to refactor the code so that entities which are not subject to field encryption will not be excluded from the cache, but for now, warning the admin about the situation is a good stopgap.

ptmkenny’s picture

alexpott’s picture

Version: 3.0.x-dev » 3.1.x-dev
Status: Needs review » Fixed

I agree with #3. Let's improve the text.

  • alexpott committed d271f7fd on 3.1.x authored by ptmkenny
    Issue #3312772 by ptmkenny: "Exclude entities from persistent caches"...

Status: Fixed » Closed (fixed)

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