Page MenuHomePhabricator

2021 Week 6 (Early February)
Updated 224 Days AgoPublic

Summary of changes from February 1, 2021 to February 6, 2021.

CodebaseRepositoryHEADActivity
PhabricatorrPrP00cf93548b11 commits
ArcanistrARCrARC32fe933f5 commits
Instances (SAAS)rSAASrSAASf7744660 commits
Services (SAAS)rSERVICESrSERVICES270d6f81 commit
Core (SAAS)rCORErCOREe5a9f4c3 commits
  • These changes were promoted to stable.

General

[] Phabricator now provides more tools for managing backlogs in the task queue. Most often, these situations arise when an install imports a large repository like the Linux kernel.

  • bin/worker ... --container R1234 will now select all tasks related to a particular container object, like a repository;
  • bin/worker priority ... will adjust the priority of a set of tasks;
  • bin/worker delay ... will delay execution of a set of tasks until later.

For more guidance on these flags and their most common use cases, see Managing the Worker Queue.

Security

  • No notes in this period.

Migrations

MigrationRiskDurationNotes
20210122.queuecontainer.01.sql1,517 ms

"Duration" is the duration for this install, and may not be representative.

Upgrading / Compatibility

Storage Patch Phases: This is a complex technical change which only affects installs which:

  • run custom code; and
  • that custom code includes custom storage patches; and
  • those storage patches submit tasks to the worker queue, most often by queueing search engine index updates.

These conditions are rare and it is plausible that zero installs are affected. If you aren't sure, you're almost certainly not affected.

Storage patches now support "phases", to allow certain types of patches which write objects to guarantee they execute after patches which modify the schemata for those objects.

This was necessitated by the addition of containerPHID to the worker task tables. This change breaks older patches which insert tasks into the queue, if all patches are executed in sequence from an empty database (this normally happens only during unit tests, or if you are upgrading an install that is many years out of date).

Specifically, the patches that this change breaks will attempt to write a containerPHID, because the modern application definition of the object includes this field. This will fail if the schema change which adds this field has not yet been applied. Adding a "phase" annotation allows these patches to be scheduled after schema modifications.

If you have custom storage patches (this is rare) and some of those patches are patches which rebuild search engine indexes (this is very rare) or directly interact with the worker queue (this is exceptionally rare), and you want to be able to execute all patches in sequence against a blank database state, you must go thorugh your patches and annotate your indexing/worker patches with a @phase indicator, following D21529.

In most cases, the recommended approach is to avoid this problem entirely in storage patches by using raw SQL to interact with the schema as it will exist at the time of the patch. This approach is stable and usually very simple. In this case, that approach was not attractive because it would be fairly complex.

Infrastructure

  • If you miscapitalize a symbol (like "ExCePtiOn"), the libphutil linter will now correct the symbol for you instead of merely telling you that it is incorrect.
  • Added a lint check for "private final" methods, which are disallowed at runtime by PHP8.
  • Added a lint check for blocks which catch "Exception" but do not catch "Throwable". This is likely an error in this codebase, and will lead to behavioral differences between versions of PHP before and after PHP7.

Minor

  • Removed "final" from "private final" methods in the Phabricator codebase to improve PHP8 compatibility. See T13588.
  • Added an --ignore-locality flag to bin/repository pull. See T13600.
  • Fixed an issue where editing "AlmanacNamespace" objects wild fail.
  • Improved help text for bin/policy unlock to make it more clear that you can unlock an object by PHID.

The [] icon indicates a change backed by support mana.

Last Author
epriestley
Last Edited
Feb 7 2021, 6:35 PM