Page MenuHomePhabricator

Inject dependencies into WikiPage
Closed, DeclinedPublic

Description

While WikiPage is not @newable, it still has manually constructions in deployed code. Until those are replaced (T259948: Remove manual construction of WikiPage objects), the dependencies should be optional.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change 619047 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/core@master] Inject dependencies to WikiPage

https://gerrit.wikimedia.org/r/619047

This goes countrary to the Service/ValueObject approach. WikiPage itself should probably become a value object and all the functionality in it should be extracted into separate services.

Are there currently plans to convert WikiPage to a value object?

Are there currently plans to convert WikiPage to a value object?

WikiPage should be broken up and cease to exist. Its function as an entity should be taken over by PageRecord.

Are there currently plans to convert WikiPage to a value object?

WikiPage should be broken up and cease to exist. Its function as an entity should be taken over by PageRecord.

Until that happens, since we now have a WikiPageFactory, can we inject the dependencies needed?

In light of migration to PageIdentity/PageReference, etc.

Change 619047 abandoned by DannyS712:

[mediawiki/core@master] Inject dependencies to WikiPage, part 1

Reason:

https://gerrit.wikimedia.org/r/619047