Skip to content
Snippets Groups Projects

Draft: add config_target for batch_size, encryption_profile, make_entities_uncacheable

Open Patrick Kenny requested to merge issue/field_encrypt-3476949:config_target into 3.2.x
1 file
+ 3
0
Compare changes
  • Side-by-side
  • Inline
+ 3
0
@@ -76,6 +76,7 @@ class SettingsForm extends ConfigFormBase {
@@ -76,6 +76,7 @@ class SettingsForm extends ConfigFormBase {
$form['encryption_profile'] = [
$form['encryption_profile'] = [
'#type' => 'select',
'#type' => 'select',
'#title' => $this->t('Encryption profile'),
'#title' => $this->t('Encryption profile'),
 
'#config_target' => 'field_encrypt.settings:encryption_profile',
'#description' => $this->t(
'#description' => $this->t(
'Select the encryption profile to use for encrypting fields. New entities and revisions will always use this profile. Existing entities and revisions can be updated via <a href=":link">Encrypted fields entity type settings</a>',
'Select the encryption profile to use for encrypting fields. New entities and revisions will always use this profile. Existing entities and revisions can be updated via <a href=":link">Encrypted fields entity type settings</a>',
[':link' => Url::fromRoute('field_encrypt.settings.entity_type')->toString()]
[':link' => Url::fromRoute('field_encrypt.settings.entity_type')->toString()]
@@ -89,6 +90,7 @@ class SettingsForm extends ConfigFormBase {
@@ -89,6 +90,7 @@ class SettingsForm extends ConfigFormBase {
$form['make_entities_uncacheable'] = [
$form['make_entities_uncacheable'] = [
'#type' => 'checkbox',
'#type' => 'checkbox',
'#title' => $this->t('Exclude entities from persistent caches'),
'#title' => $this->t('Exclude entities from persistent caches'),
 
'#config_target' => 'field_encrypt.settings:make_entities_uncacheable',
'#description' => $this->t('This ensures unencrypted data is not exposed in the cache. However, it negatively impacts performance because it prevents caching of all entity types for which field encryption is enabled, even entity bundles that do not have any encrypted fields.'),
'#description' => $this->t('This ensures unencrypted data is not exposed in the cache. However, it negatively impacts performance because it prevents caching of all entity types for which field encryption is enabled, even entity bundles that do not have any encrypted fields.'),
'#default_value' => $config->get('make_entities_uncacheable'),
'#default_value' => $config->get('make_entities_uncacheable'),
];
];
@@ -140,6 +142,7 @@ class SettingsForm extends ConfigFormBase {
@@ -140,6 +142,7 @@ class SettingsForm extends ConfigFormBase {
$form['batch_update']['batch_size'] = [
$form['batch_update']['batch_size'] = [
'#type' => 'number',
'#type' => 'number',
'#title' => $this->t('Batch size'),
'#title' => $this->t('Batch size'),
 
'#config_target' => 'field_encrypt.settings:batch_size',
'#default_value' => $config->get('batch_size'),
'#default_value' => $config->get('batch_size'),
'#description' => $this->t('Specify the number of entities to process on each field update batch execution. It is recommended to keep this number low, to avoid timeouts.'),
'#description' => $this->t('Specify the number of entities to process on each field update batch execution. It is recommended to keep this number low, to avoid timeouts.'),
];
];
Loading