log ServerCommand.handle
commit3921eb32a95c3dfdaa835d5ec578cbb50d820c5d
authorLucian Wischik <ljw@fb.com>
Wed, 27 Nov 2019 16:47:48 +0000 (27 08:47 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Wed, 27 Nov 2019 16:53:20 +0000 (27 08:53 -0800)
tree1549510f904c1ad3d832017b362e45bc9893bdf9
parent48f82a6333d8a9d98b8ad56ba6c10070bf6c7a36
log ServerCommand.handle

Summary:
Something that's always bugged me is that our monitor log is full of per-command logs like this:
```
[2019-11-22 13:17:02.305] Got default request for typechecker. Prior request 2368.0 seconds ago
[2019-11-22 13:17:28.974] Got default request for typechecker. Prior request 26.0 seconds ago
```

But we never actually get to see what the command is! Well, the monitor isn't able to see what the command is (since the monitor hands-off before reading command off the fd).

But this diff puts the information into the server log. More precisely: for every non-persistent request, which already wrote one line into the monitor log, this diff will make it also write one line in the server log:
```
[2019-11-22 13:17:02.306] [master] Handled STATUS  [0.000006 s]
[2019-11-22 13:17:30.566] [master] Handled FIND_REFS function HackAstFindRefsTest_test [1.591067 s]
```

Therefore, this diff won't cause a huge extra log load. Only one extra line in the server log, in cases where there was already one line in the monitor log.

Reviewed By: arxanas

Differential Revision: D18718520

fbshipit-source-id: 1703343faa294cdf66613858df6b3dd028e37a2c
hphp/hack/src/server/serverCommand.ml