d8-contrib-modules / tfa

DEPRECATED - D8 TFA port now on drupal.org
https://www.drupal.org/project/tfa
5 stars 11 forks source link

Clearing plugin definition cache #33

Closed therealssj closed 8 years ago

therealssj commented 8 years ago

Motivation We are shifting validation libraries from tfa basic to tfa. The plugin definiton will be updated and hence if someone updates the plugin he will face fatal errors as the plugin definitons are still the outdated cached ones.

Resolution TBD

therealssj commented 8 years ago

Some help I got on IRC From dawehner

[11:30pm] dawehner:
therealssj: do you know the cache tag of your plugins?
[11:31pm] dawehner:
therealssj: you could clear just that Cache::invalidateCacheTags or similar
[11:31pm] dawehner:
therealssj: there is also a reset() method on plugin mangers to deal with thtat

From timplunkett

[12:04am] timplunkett:
therealssj: if you want to clear all plugin caches, \Drupal::service('plugin.cache_clearer')->clearCachedDefinitions();
[12:05am] timplunkett:
or just that method on the specific plugin manager