Skip to content

HTTPX AsyncClient slower than aiohttp? #838

@imbolc

Description

@imbolc

I just found async-client to be significantly slower comparing to aiohttp, escecially for single request:

aiohttp httpx aiohttp/httpx
single, rps 1062 141 7.5
session, rps 1862 1197 1.5
session/single 1.8 8.5

I tried both release and master, results are pretty the same. The code of the benchmark is here: https://gist.github.com/imbolc/15cab07811c32e7d50cc12f380f7f62f

Metadata

Metadata

Assignees

No one assigned

    Labels

    discussionperfIssues relating to performance

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy