HomePhabricator

Kick off indexing for File objects on creation

Description

Kick off indexing for File objects on creation

Summary: Ensures that newly-made File objects get indexed into the new ngrams index. Fixes T8788.

Test Plan:

  • uploaded a file with daemons stopped; confirmed no new rows in ngrams table
  • started daemons; confirmed indexing of previously-uploaded files happened
  • uploaded a new file with daemons running; confirmed it got added to the index

Not sure how to test the changes to PhabricatorFileUploadSource->writeChunkedFile() and PhabricatorChunkedFileStorageEngine->allocateChunks(). I spent a few minutes trying to find their callers, but the first looks like it requires a Diffusion repo and the 2nd is only accessible via Conduit. I can test that stuff if necessary, but it's such a small change that I'm not worried about it.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin

Maniphest Tasks: T8788

Differential Revision: https://secure.phabricator.com/D17718

Details

Provenance
amckinleyAuthored on Apr 18 2017, 3:13 PM
amckinleyPushed on Apr 18 2017, 3:38 PM
Reviewer
epriestley
Differential Revision
D17718: Kick off indexing for File objects on creation
Parents
rP7fd98a5e8659: Every so often, ask the Aphict server how things are going
Branches
Unknown
Tags
Unknown
Tasks
T8788: Allow querying for files by name
Build Status
Buildable 16548
Build 22050: Run Core Tests