jgarzik / python-bitcoinrpc

Python interface to bitcoin's JSON-RPC API
GNU Lesser General Public License v2.1
644 stars 304 forks source link

Reuse TCP connection #20

Closed AmesCornish closed 11 years ago

AmesCornish commented 11 years ago

bitcoinrpc was opening thousands of connections on my machine, one for each proxy call. These changes fixed it so only one connection is used.

pstratem commented 11 years ago

ACK

tested and working

Bobalot commented 11 years ago

I think this patch might be causing bitcoind to stop responding to rpc calls after a certain amount of connections. I've just updated to this version of bitcoinrpc and starting having problems and end up having to restart bitcoind when this happens.

Will investigate further.

pstratem commented 11 years ago

bitcoind seems to lockup with rpcthreads - 1 concurrent calls.

if you have rpcthreads set to 8 dont make more than 7 concurrent requests

it's likely something to do with boost but i dont have the time nor the will to figure out what

Bobalot commented 11 years ago

Ignore my last, it seems you might be right @pstratem. Thanks, I'll look into this myself.