Part of #2886622: Deprecate all EntityManager methods with E_USER_DEPRECATED, this covers the methods that moved to EntityTypeBundleInfo: getAllBundleInfo(), getBundleInfo(), clearCachedBundles().
The largest chunk here is the ContentEntityStorageBase class including many of its children, specifically SqlContentEntityStorage + Schema class and unit tests for these, those are fully updated to remove the entity_manager dependency.
The other changes are standard replacements, there is one form class that has a new constructor and one that changes it from $entity_manager which was actually pretty bogus as the parent has $this->entityManager set already.
Comments
Comment #2
BerdirSo this is the gets ContentEntityStorageBase and subclasses, but actually expected much worse, not that many services actually used there, just order is a bit weird/tricky I think. And the Schema sub-handler.
DefaultSelection and subclasses are skipped, those are handled by #3023981: Add @trigger_error() to deprecated EntityManager->EntityRepository methods, lets see if I got everything else.
Comment #4
BerdirThis should fix a good amount of test fails, mostly down to deprecations from the selection handlers if I'm lucky.
Comment #6
Berdir#3023981: Add @trigger_error() to deprecated EntityManager->EntityRepository methods is in, that means this should have a *lot* less failures, triggered a re-test. Will finalize then and update the deprecation messages.
Comment #8
BerdirNeeded a reroll anyway and the other change was not actually pushed yet. I also saw that a rename went sideways and renamed $this->entityManager in a lot of forms, this should clean that up again.
Also added deprecation tests.
Comment #10
BerdirFixing a few of the obvious issues, this should be better.
Comment #11
Berdirclassname here is wrong, will fix on the next update.
Comment #12
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedIs
drupal:x.y.z
a new standard for deprecation messages?If it is, it's not applied consistently.. :) We should at least have "Drupal" before 8.0.0.
Minor: we could move the new trait use statement above the first one.
Everything else looks great to :)
Comment #13
BerdirStandardized the deprecation messages in EntityManager and EntityManagerTest.
Comment #14
amateescu CreditAttribution: amateescu for Pfizer, Inc. commentedGreat!
Comment #15
alexpottCommitted 81915a9 and pushed to 8.7.x. Thanks!