Open pfrenssen opened 7 years ago
Yeah, it probably related to the OG related field creation. Those should probably do the invalidations themself.
Marking this as a novice issue. In order to fix this, here is a procedure you could follow:
Og::invalidateCache()
that are clearing the entity type definition and field definition caches. They are marked with a @todo
that links to this issue.Og::invalidateCache()
is now missing an invalidation of the entity type definition or field definition cache. Add a line to invalidate the required cache following the call to Og::invalidateCache()
.
It is expected that calling
Og::invalidateCache()
only invalidates the static caches of OG itself. However at the moment this method also clears caches inEntityTypeManager
andEntityFieldManager
:This is probably intended to solve problems occurring after making changes to group audience fields, but this is way too drastic for most use cases and can have a negative performance impact. The entity type definitions and field definitions should only be cleared when strictly necessary.