skip to navigation
skip to content

Not Logged In

tclient 0.0.4

HTTP client for parallel http requests

tclient: HTTP client for parallel http requests

TClient is an http client for doing http requests in parallel. This is really just
a light wrapper around Tornado and uses Tornado's ioloop and httpclient.


  * Create multiple HTTP requests, have them run in parallel.
  * Convinient API for building requests with query params, forms, or JSON.
  * Integrates with BlueOx for logging and metrics.
  * Testing hooks


`tclient.Request` is based on `tornado.httpclient.HTTPRequest`, so you should checkout
it's [documentation](

In summary:

    req1 = tclient.Request('http://localhost:8888')
    req1.params['search'] = 'turtles in a half-shell'

    req2 = tclient.Request('http://localhost:8888')
    req2.method = "POST"
    req2.body = {'name': 'Raphael'}

    req3 = tclient.Request('http://localhost:8888', method="POST")
    req3.form['name'] = 'Raphael'
    req3.form.add_file("tmnt.jpg", picture_fp)

    resp1, resp2, resp3 = tclient.fetch_all([req1, req2, req3], timeout=30)
    for r in (resp1, resp2, resp3):

    print resp1.json['results']

### Dependencies

  * tornado
  * urllib3 (just for form encoding)
  * pycurl (recommended)
  * blueox (optional)
File Type Py Version Uploaded on Size
tclient-0.0.4.tar.gz (md5) Source 2013-12-20 6KB
  • Downloads (All Versions):
  • 5 downloads in the last day
  • 77 downloads in the last week
  • 354 downloads in the last month