async fn handle_connection(
    connection: Connection,
    packet_sender: AsyncSender<PacketAccumulator>,
    remote_addr: SocketAddr,
    remote_pubkey: Option<Pubkey>,
    last_update: Arc<AtomicU64>,
    connection_table: Arc<Mutex<ConnectionTable>>,
    stream_exit: Arc<AtomicBool>,
    stats: Arc<StreamStats>,
    peer_type: ConnectionPeerType,
    wait_for_chunk_timeout: Duration
)