- Issue created by @sokru
- Merge request !60Issue #3433222 by sokru: Deprecate events and hooks in 8.x-7.x → (Open) created by sokru
- 🇨🇦Canada mparker17 UTC-4
The changes to the code looks good to me thus far: all the hooks defined in
elasticsearch_connector.api.php
are deprecated, and the only module —elasticsearch_connector_views
— has been marked as deprecated too.From experience, sometimes when I've written custom modules for a client site, I have used public methods from services defined in a contrib module. To this end, perhaps we should add the `deprecated:` key → to the 4 services in
elasticsearch_connector.services.yml
?From experience, rarely when I've written custom modules for a client site, I have extended classes in a contrib module (usually base classes — but not always). To this end, perhaps we should consider adding a
@deprecated
annotation to the 58 classes that were deleted between 7.x and 8.x — you can get this list by runninggit diff --numstat --diff-filter=D 3433222-deprecations...8.0.x | grep .php
? I daresay this is optional, because this is a lot of work, and extending classes aren't a recommended way to customize things.I notice there are some TODOs in the change record... would it be helpful for me to update the change record?
- Status changed to Needs review
4 months ago 7:25am 29 August 2024 - 🇫🇮Finland sokru
@mparker17: I would greatly appreciate if you could update the change record.
I added the deprecations for services, I think we should not add deprecations to classes, since its lot of work and it makes extra work to reroll any potential patches for 8.x-7.x branch.
Wonder if there's any other deprecation we should (or could) add.
The title and issue summary should be also updated to reflect what we have done.
- 🇨🇦Canada mparker17 UTC-4
@sokru, I spent some time updating the Change Record; but I still have work to do (I need to temporarily switch to other, more-pressing tasks today)
I found the hook examples to be pretty long, so I split them into their own Change Records: https://www.drupal.org/node/3470987 → and https://www.drupal.org/node/3471005 → — but I think it is be worth keeping the original Change Record — https://www.drupal.org/node/3433223 → — as a "summary". I think that it is likely that I will need to split out some of the sections for the events and services into their own change records too.