Fix and improve the code for displaying cache statistics.

Review Request #1186 — Created April 25, 2018 and updated — Latest diff uploaded

Review Board
The memcached statistics code is pretty old, and has a lot of warts. One
of those warts is that hostnames without ports would lead to crashes,
and another is that "STAT" lines containing a name but not a value would
as well. A third is that we had to use the Django memcached backend to
get memcached stats.

This change fixes those three issues, and updates some of the syntax and
docs for the file.

The stats code is still very limited (other backends can't provide
stats, and we're assuming a lot about the data), but this will be
addressed separately.

Testing Done:
Tested all the failure conditions I previously hit (lack of port causing
a crash, lack of value in a "STAT" line, and lack of stats for a custom
memcached backend).

Unit tests were _not_ added, due to a planned redesign, which the tests
would not survive.

Reviewed at