Small cleanups.
Experimenting with metrics and simple socket client.