bosh-monitor-graphite: refactored tsdb connection/graphite connection, extracted common parts into separate tcp_connection class