Skip to content

fudong1127/thrift-connection-pool

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Description

This library wraps the actual Thrift generated client and uses internally a pool of connections to call remote methods

Usage

#actual thrift client module
import tutorial.Calculator

from thriftpool import client

cl=client.Client(iface_cls=tutorial.Calculator.Client, host='localhost', port=9090, pool_size=3, retries=3)
for i in range(5):
	cl.ping()

#close connection pool
cl.close()

To Do

Keep only a configurable number of connections alive and drop unused ones.

About

python library for reusable client connections

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%