Page MenuHomePhabricator

Add an "--as" flag to "bin/conduit call ..." to improve flexibility and ease of profiling
ClosedPublic

Authored by epriestley on Aug 8 2018, 4:10 PM.
Tags
None
Referenced Files
F18600028: D19566.id46776.diff
Sat, Sep 13, 8:51 AM
F18516296: D19566.id.diff
Fri, Sep 5, 12:26 PM
F18509727: D19566.id.diff
Fri, Sep 5, 3:34 AM
F18503093: D19566.diff
Thu, Sep 4, 10:51 PM
F18494160: D19566.diff
Thu, Sep 4, 7:28 AM
F18388809: D19566.id46776.diff
Fri, Aug 29, 5:06 AM
F18186634: D19566.id46776.diff
Aug 16 2025, 6:26 PM
F17948055: D19566.id46776.diff
Jul 31 2025, 7:56 PM
Subscribers
None

Details

Summary

Ref T13164. In PHI801, an install reported a particular slow Conduit method call.

Conduit calls aren't easily profilable with normal tools (for example, arc call-conduit --xprofile ... gives you a profile of the client). They can be profiled most easily with bin/conduit call ... --xprofile.

However, bin/conduit call currently doesn't let you pick a user to execute the command on behalf of, so it's not terribly useful for profiling *.edit-style methods which do a write: these need a real acting user.

Test Plan

Ran bin/conduit call --method user.whoami --as epriestley ... with valid, invalid, and no acting users.

$ echo '{}' | ./bin/conduit call --method user.whoami --as epriestley --input -
Reading input from stdin...
{
  "result": {
    "phid": "PHID-USER-icyixzkx3f4ttv67avbn",
    "userName": "epriestley",
    "realName": "Evan Priestley",
...

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable