refactor handle_messages
commitffa8cec3b55ecd884632c03efe318340e237fb4a
authorLucian Wischik <ljw@fb.com>
Thu, 23 Apr 2020 05:48:40 +0000 (22 22:48 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Thu, 23 Apr 2020 06:06:22 +0000 (22 23:06 -0700)
tree2c17aa1a270df19265042781831f28f2495ac334
parente07a0d0487bb5856489898ca45358be9df366670
refactor handle_messages

Summary:
The function `serve` had gotten way too big. I'm factoring out some methods here.

Also, the word "message" gets slung around a lot. I switched to calling it a "request" when it comes from the client and deserves a response. Hence, `handle_message` gets renamed to `handle_request`.

Minor other readability tweaks here and there.

Reviewed By: arxanas

Differential Revision: D21081303

fbshipit-source-id: 60701a2c773606f40434096e1b28ceff61fed259
hphp/hack/src/client/ide_service/clientIdeDaemon.ml