Commit Graph

12485 Commits

Author SHA1 Message Date
Matt Corallo
a6eb4ba38b Report minimum ping time in getpeerinfo 2015-09-03 13:06:13 -07:00
Wladimir J. van der Laan
195942d58e
Merge pull request #6630
86270c8 Replace boost::reverse_lock with our own. (Casey Rodarmor)
2015-09-03 21:46:08 +02:00
Casey Rodarmor
86270c8164 Replace boost::reverse_lock with our own. 2015-09-03 15:13:40 -04:00
Ian T
e83df075f9 Update RPC generate help for numblocks to include required
The `generate` RPC has no default `numblocks` and a numeric value is required.
2015-09-03 13:29:10 -04:00
Tom Harding
9524c4d35c In (strCommand == "tx"), return if AlreadyHave()
The main effect is to exit processing for recently-rejected hashes,
in case they are pushed to us without prior advertisement.  This
behavior was seen in the wild.

An additional effect is to do early checks for mempool or mapOrphan
existence.  No logging or nDoS tracking is needed for failures of
these checks.
2015-09-03 10:16:59 -07:00
Wladimir J. van der Laan
69dc5b51a0
Merge pull request #6374
027de94 Use network group instead of CNetAddr in final pass to select node to disconnect (Patrick Strateman)
000c18a Fix comment (Patrick Strateman)
fed3094 Acquire cs_vNodes before changing refrence counts (Patrick Strateman)
69ee1aa CNodeRef copy constructor and assignment operator (Patrick Strateman)
dc81dd0 Return false early if vEvictionCandidates is empty (Patrick Strateman)
17f3533 Better support for nodes with non-standard nMaxConnections (Patrick Strateman)
1317cd1 RAII wrapper for CNode* (Patrick Strateman)
df23937 Add comments to AttemptToEvictConnection (Patrick Strateman)
a8f6e45 Remove redundant whiteconnections option (Patrick Strateman)
b105ba3 Prefer to disconnect peers in favor of whitelisted peers (Patrick Strateman)
2c70153 AttemptToEvictConnection (Patrick Strateman)
4bac601 Record nMinPingUsecTime (Patrick Strateman)
ae037b7 Refactor: Move failure conditions to the top of AcceptConnection (Patrick Strateman)
1ef4817 Refactor: Bail early in AcceptConnection (Patrick Strateman)
541a1dd Refactor: AcceptConnection (Patrick Strateman)
2015-09-03 18:27:24 +02:00
Wladimir J. van der Laan
5e1ec3b5be
Merge pull request #6611
5b85126 Update build-unix.md (Altoidnerd)
2015-09-03 17:19:50 +02:00
Wladimir J. van der Laan
0c02a75787
Merge pull request #6627
88f856a [doc] Clarify authors in assets-attribution.md (MarcoFalke)
2015-09-03 17:03:46 +02:00
MarcoFalke
88f856a9e7 [doc] Clarify authors in assets-attribution.md 2015-09-03 14:22:57 +02:00
Wladimir J. van der Laan
26c9b83677 Move windows socket init to utility function 2015-09-03 10:59:19 +02:00
Cory Fields
4be0b082b9 libevent: Windows reuseaddr workaround in depends
Make it possible to reuse sockets.
This is necessary to make the RPC tests work in WINE.
2015-09-03 10:59:19 +02:00
Wladimir J. van der Laan
3a174cd400 Fix race condition between starting HTTP server thread and setting EventBase()
Split StartHTTPServer into InitHTTPServer and StartHTTPServer to give
clients a window to register their handlers without race conditions.

Thanks @ajweiss for figuring this out.
2015-09-03 10:59:19 +02:00
Wladimir J. van der Laan
6d2bc22146 Document options for new HTTP/RPC server in --help 2015-09-03 10:59:19 +02:00
Wladimir J. van der Laan
be33f3f50b Implement RPCTimerHandler for Qt RPC console
Implement RPCTimerHandler for Qt RPC console, so that `walletpassphrase`
works with GUI and `-server=0`.

Also simplify HTTPEvent-related code by using boost::function directly.
2015-09-03 10:59:19 +02:00
Wladimir J. van der Laan
57d85d9bee doc: mention SSL support dropped for RPC in release notes 2015-09-03 10:59:19 +02:00
Wladimir J. van der Laan
40b556d374 evhttpd implementation
- *Replace usage of boost::asio with [libevent2](http://libevent.org/)*.
boost::asio is not part of C++11, so unlike other boost there is no
forwards-compatibility reason to stick with it. Together with #4738 (convert
json_spirit to UniValue), this rids Bitcoin Core of the worst offenders with
regard to compile-time slowness.

- *Replace spit-and-duct-tape http server with evhttp*. Front-end http handling
is handled by libevent, a work queue (with configurable depth and parallelism)
is used to handle application requests.

- *Wrap HTTP request in C++ class*; this makes the application code mostly
HTTP-server-neutral

- *Refactor RPC to move all http-specific code to a separate file*.
Theoreticaly this can allow building without HTTP server but with another RPC
backend, e.g. Qt's debug console (currently not implemented) or future RPC
mechanisms people may want to use.

- *HTTP dispatch mechanism*; services (e.g., RPC, REST) register which URL
paths they want to handle.

By using a proven, high-performance asynchronous networking library (also used
by Tor) and HTTP server, problems such as #5674, #5655, #344 should be avoided.

What works? bitcoind, bitcoin-cli, bitcoin-qt. Unit tests and RPC/REST tests
pass. The aim for now is everything but SSL support.

Configuration options:

- `-rpcthreads`: repurposed as "number of  work handler threads". Still
defaults to 4.

- `-rpcworkqueue`: maximum depth of work queue. When this is reached, new
requests will return a 500 Internal Error.

- `-rpctimeout`: inactivity time, in seconds, after which to disconnect a
client.

- `-debug=http`: low-level http activity logging
2015-09-03 10:59:18 +02:00
fanquake
f4b9132d0c Update gitian build guide for Debian 8.1
Signed-off-by: fanquake <fanquake@gmail.com>
2015-09-03 15:51:37 +08:00
evan82
e5e655a165 Merge pull request #596 from UdjinM6/translations20150902_
translations 20150902
2015-09-02 14:35:16 -07:00
UdjinM6
8d1609f0a5 translations 20150902 2015-09-03 00:32:34 +03:00
UdjinM6
2fc59109ae translations 20150902 2015-09-03 00:27:40 +03:00
Evan Duffield
386a39d00e fixed compile err 2015-09-02 09:53:53 -07:00
Kevin Cooper
d4aa54c5af added org.bitcoin.bitcoind.plist for launchd (OS X) 2015-09-02 09:48:40 -07:00
Wladimir J. van der Laan
ee2a42b447 tests: GET requests cannot have request body, use POST in rest.py
Sending a request body with GET request is not valid in HTTP spec, and
not compatible with evhttpd.
2015-09-02 18:38:42 +02:00
Cory Fields
6e996d39da tests: fix qt payment test
Now that boost no longer automatically initializes openssl, we have to
do it ourselves.
2015-09-02 18:38:41 +02:00
Wladimir J. van der Laan
3140ef9249 build: build-system changes for libevent 2015-09-02 18:38:41 +02:00
Cory Fields
a9af234c1f libevent: add depends 2015-09-02 18:38:41 +02:00
Wladimir J. van der Laan
6a21dd598c Remove rpc_boostasiotocnetaddr test
Dropping all use of boost::asio.
2015-09-02 18:38:41 +02:00
Wladimir J. van der Laan
8f9301cdaa qa: Remove -rpckeepalive tests from httpbasics
This option was a temporary workaround, and is no longer necessary
with the new web server.
2015-09-02 18:38:41 +02:00
Wladimir J. van der Laan
51fcfc022c doc: remove documentation for rpcssl 2015-09-02 18:38:41 +02:00
Wladimir J. van der Laan
3932ff50c5
Merge pull request #6620
10e469a travis: bump wine to 1.7 (Cory Fields)
2015-09-02 18:38:10 +02:00
fanquake
42cf08905f depends: bump ccache to 3.2.3 2015-09-03 00:05:35 +08:00
fanquake
888c595cff depends: bump miniupnpc to 1.9.20150730 2015-09-03 00:05:35 +08:00
Cory Fields
10e469ae37 travis: bump wine to 1.7 2015-09-02 11:42:27 -04:00
Wladimir J. van der Laan
b319f0828e
Merge pull request #6617
bfadae3 travis: for travis generating an extra build (Cory Fields)
2015-09-02 17:14:29 +02:00
Evan Duffield
0111107853 Merge branch 'v0.12.0.x' 2015-09-02 05:22:45 -07:00
Evan Duffield
eebb03eb13 reduce memory usage 2015-09-02 05:20:06 -07:00
Evan Duffield
25894972c1 reduce memory usage 2015-09-02 05:13:32 -07:00
Evan Duffield
aaeda811db Revert "fix - ds can leak info by number of inputs"
This reverts commit f98fe6a208.
2015-09-02 05:06:22 -07:00
Altoidnerd
5b85126863 Update build-unix.md
If a user hasn't ready run autogen.sh, configure doesn't yet exist.  Do the instructions seem to presume you have already built bitcoin?  I don't think they do.

Would stifle beginners.

Update build-unix.md
2015-09-02 05:13:04 -04:00
Evan Duffield
277ebbe83d v52 bump 2015-09-01 20:57:54 -07:00
Evan Duffield
2fd0cc306d Merge branch 'v0.12.1.x' into v0.12.0.x 2015-09-01 20:56:23 -07:00
evan82
7d8fb85c13 Merge pull request #564 from UdjinM6/v0.12.1.x_fix_ds_leak_inputs
V0.12.1.x DS can (potentially) leak info by number of inputs
2015-09-01 20:53:56 -07:00
evan82
b4d3de4e72 Merge pull request #573 from UdjinM6/v0.12.1.x_fix_sync
V0.12.1.x Fixes for sync:
2015-09-01 20:53:42 -07:00
evan82
982226a5b3 Merge pull request #584 from crowning-/patch-1
Added "Name" to 'mnbudget show' output for easier JSON-parsing
2015-09-01 20:53:28 -07:00
evan82
39c2e40b64 Merge pull request #589 from crowning-/v0.12.1.x
UI: button to toggle lock-state for all inputs in coin-control dialog
2015-09-01 20:53:09 -07:00
evan82
d0c1931c49 Merge pull request #590 from UdjinM6/fix_upnp_hotmn
Fix: local hot MN can't start if upnp is on
2015-09-01 20:52:51 -07:00
evan82
b3d0f8056e Merge pull request #594 from UdjinM6/fix_conflicted_dstx
Fix: dstx stuck sometimes
2015-09-01 20:52:23 -07:00
evan82
33f1d035cd Merge pull request #592 from UdjinM6/more_for_missing
Rpc changes for missing masternodes:
2015-09-01 20:52:11 -07:00
Cory Fields
bfadae3374 travis: for travis generating an extra build 2015-09-01 21:45:23 -04:00
Wladimir J. van der Laan
10c0e52b68
Merge pull request #6548
060058e Enable python tests for Native Windows (ptschip)
2015-09-01 11:37:13 +02:00