Page MenuHomePhabricator

Fix an unusual internal cursor in Conpherence
ClosedPublic

Authored by epriestley on Mar 24 2019, 8:58 PM.
Tags
None
Referenced Files
F15509834: D20318.diff
Wed, Apr 16, 4:25 PM
F15496181: D20318.id48473.diff
Sun, Apr 13, 6:15 AM
F15491223: D20318.id48479.diff
Sat, Apr 12, 12:26 AM
F15488266: D20318.id.diff
Thu, Apr 10, 8:50 PM
F15484294: D20318.diff
Wed, Apr 9, 5:28 PM
F15484245: D20318.id48479.diff
Wed, Apr 9, 5:14 PM
F15458546: D20318.id48473.diff
Mon, Mar 31, 4:35 AM
F15403710: D20318.diff
Mar 18 2025, 4:36 AM
Subscribers
None

Details

Summary

See https://discourse.phabricator-community.org/t/error-when-sending-a-message-chat-room/2548.

Conpherence calls setAfterID() and setBeforeID() directly on a subquery, but these methods no longer exist.

Use a pager instead. This code probably shouldn't exist (we should use some other approach to fetch this data in most cases) but that's a larger change.

Test Plan

Sent messages in a Conpherence thread. Before: fatal; after: success. Viewed the Conphrence menu, loaded threads, etc.

Diff Detail

Repository
rP Phabricator
Branch
thread1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 22343
Build 30571: Run Core Tests
Build 30570: arc lint + arc unit

Event Timeline

amckinley added inline comments.
src/applications/conpherence/query/ConpherenceThreadQuery.php
297

Que?

This revision is now accepted and ready to land.Mar 25 2019, 5:39 PM
src/applications/conpherence/query/ConpherenceThreadQuery.php
297

We must specify a page size to the Pager (it defaults to 100 otherwise) and Pagers don't understand "null/no limit".

No caller should be loading every transaction but I didn't actually trace everything down (since I'm pretty sure this code just needs to be removed in the future?) so 0xFFFF is just "a big number that probably won't break anything".

This revision was automatically updated to reflect the committed changes.