Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
acquia_contenthub.entity_config
is not respected by \Drupal\acquia_contenthub\EntityManager::getAllowedEntityTypes()
.
In fact, the only thing that respects acquia_contenthub.entity_config
is \Drupal\acquia_contenthub\EntityManager::isEligibleEntity()
. But that expects an actual Entity
object to be passed.
So how is ResourceRoutes
supposed to respect the configuration, if the internal API does not support this?
Also: why "allowed" vs "eligible"?
Comments
Comment #2
abarrios CreditAttribution: abarrios commentedI see what you mean and you are right, there is a bug right there. Currently we do not have a method to get the list of configured entities from "
acquia_contenthub.entity_config
". The only one method that obtains the list from the configuration isisEligibleEntity()
.The way how
ResourceRoutes
is obtaining the list of "configured" entities is actually wrong.The list of configured entities should be obtained from the configuration, not from
\Drupal\acquia_contenthub\EntityManager::getAllowedEntityTypes()
.Also:
Allowed: List of entity types that are allowed to be configurable in the interface (excludes some types which cannot be enabled in the configuration).
Eligible: An entity type that has been selected to be exported to content hub.
Comment #3
Wim Leersi.e. this configuration is not being respected:
… but also, that configuration has some significant flaws:
This should be converted to use config entities, for similar reasons as REST (see #2308745: Remove rest.settings.yml, use rest_resource config entities)
Comment #4
Wim Leers#2: okay, great to see that confirmed!
(I wrote/posted #3 yesterday, but d.o went offline just as I tried posting it.)
Comment #5
Wim LeersFor #3, see #2822285: Per-entity type configuration should not be stored in simple config, but in config entities.