Page MenuHomePhabricator

Provide a generic transaction-oriented bulk job worker
ClosedPublic

Authored by epriestley on Jan 10 2018, 9:06 PM.
Tags
None
Referenced Files
F13090978: D18862.diff
Thu, Apr 25, 2:40 AM
Unknown Object (File)
Fri, Apr 19, 2:44 AM
Unknown Object (File)
Thu, Apr 18, 11:23 AM
Unknown Object (File)
Wed, Apr 17, 3:13 PM
Unknown Object (File)
Wed, Apr 17, 3:00 PM
Unknown Object (File)
Sun, Apr 14, 8:45 PM
Unknown Object (File)
Fri, Apr 12, 2:44 AM
Unknown Object (File)
Wed, Apr 10, 4:38 AM
Subscribers
None

Details

Summary

Depends on D18806. Ref T13025. See PHI173. Currently, Maniphest bulk edits are processed by a Maniphest-specific worker. I want to replace this with a generic worker which can apply transactional edits to any object.

This implements a generic worker, although it has no callers yet. Future changes give it callers, and later remove the Maniphest-specific worker.

Test Plan

See next changes.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

amckinley added inline comments.
src/applications/transactions/bulk/PhabricatorEditEngineBulkJobType.php
33–35

It feels a little heavy-handed to make new a new BulkTask for every PHID. On the other hand, I have a hard time imagining bulk jobs with like 1m+ PHIDs, or otherwise scaling to the point where this would start to get painful.

This revision is now accepted and ready to land.Jan 11 2018, 12:26 AM

I think each actual edit normally writes at least 5 rows when it actually applies (offhand: transaction, feed story, mail message, notification row, Herald transcript) so the overhead of the bulk job should always be fairly low compared to the overhead of actually performing an edit, even though it's high relative to, say, holding a string in memory.

  • Pull the minor changes from D18863 to here (value vs old) to improve conceptual purity.
This revision was automatically updated to reflect the committed changes.