Commit Graph

84 Commits

Author SHA1 Message Date
JoelKatz
bc30aeaa04 Reduce logging. 2013-05-14 11:05:39 -07:00
JoelKatz
a5acb4e69a Fix bug that can cause crash. 2013-05-04 13:15:24 -07:00
JoelKatz
407a43aea9 Change shared_polymorphic_downcast to dynamic_pointer_cast. 2013-05-01 22:22:51 -07:00
JoelKatz
7f4d76808b Fixes and simplifications. 2013-04-26 00:11:44 -07:00
JoelKatz
380ab0d3fd Fix two small bugs. 2013-04-25 13:49:41 -07:00
JoelKatz
c785bb3673 More fetch fixes. 2013-04-25 13:28:55 -07:00
JoelKatz
cc9268ac79 Reduce logging. 2013-04-25 11:11:27 -07:00
JoelKatz
494202fbcf Ledger acquire improvements and I/O reductions. 2013-04-25 11:09:57 -07:00
JoelKatz
84087e62cb Smarter peer selection for acquires. 2013-04-23 06:48:42 -07:00
JoelKatz
d5535dbdfd More fetch pack work. 2013-04-22 12:45:37 -07:00
JoelKatz
aeccecb578 ech pack stuff. 2013-04-22 11:09:07 -07:00
JoelKatz
94838b0db7 Fetch pack bugfixes. 2013-04-22 10:29:54 -07:00
JoelKatz
8a368204c1 Last part of the fetch pack code. 2013-04-22 06:56:11 -07:00
JoelKatz
0c7066944e Fetch pack scheme. Phase two. 2013-04-21 20:37:46 -07:00
JoelKatz
bade087b4e Fix a deadlock reported by cn_smi between the PeerSet lock and the master lock. 2013-04-17 13:06:41 -07:00
JoelKatz
a56d284e4d Some cleanups. 2013-04-04 20:32:11 -07:00
JoelKatz
159ba3f848 Improve log message. 2013-03-29 16:16:14 -07:00
JoelKatz
3b40a7787d Small tweaks. 2013-03-29 10:17:17 -07:00
JoelKatz
34005874ba Don't request so many hashes. 2013-03-29 08:41:55 -07:00
JoelKatz
567b17efe6 Tiny bugfix. 2013-03-29 08:33:35 -07:00
JoelKatz
85afb49058 Time fetches better. 2013-03-29 08:22:52 -07:00
JoelKatz
00913f838f Fix the 'getAccountHash() == mAccountStateMap->getHash()' bug.
'getNeededHashes' can do the wrong thing (report no needed hashes when we
need them all) if we have a ledger's root node but not the root node of the
tree we're querying.
2013-03-17 22:04:34 -07:00
JoelKatz
9edfd51430 Reduce some log severities. 2013-03-17 21:24:56 -07:00
JoelKatz
6bc474c461 tryLocal should only check the hash database. 2013-03-17 17:30:35 -07:00
JoelKatz
74bf47c73d Defer acquire timeouts if ledger data is backing up. 2013-03-16 18:30:26 -07:00
JoelKatz
a12c72f422 Be more careful not to tamper with an acquired ledger/map after
it has completed.
2013-03-16 18:22:35 -07:00
JoelKatz
b9456c8fd7 Except when interacting with boost, use std::function and std::bind
when C++11 is available. See: http://stackoverflow.com/questions/14617835
2013-03-16 03:27:43 -07:00
JoelKatz
f222544048 Do the same thing for timer entry. 2013-03-15 22:50:26 -07:00
JoelKatz
e392366c63 Get ledger acquire work off the main thread and out of the master lock.
Prioritize ledger acquire work appripriately. This should help prevent the
server from becoming overly sluggish while acquiring ledgers. Still todo:
Finish all pending receive operations before sending out any data requests.
2013-03-15 22:34:55 -07:00
JoelKatz
a8552ec4f6 Fix a ledger acquire race that caused a crash. 2013-03-15 01:19:49 -07:00
JoelKatz
2248d92a33 Wrap all peer socket accesses in a strand. This is needed to prevent a fatal
race condition in composed intermediary functions.

A few ledger acquire cleanups.
2013-03-12 16:53:30 -07:00
JoelKatz
b9433d4780 Correct chatty log. 2013-03-12 00:53:02 -07:00
JoelKatz
8874dd3f01 Remove chatty debug. 2013-03-11 23:33:09 -07:00
JoelKatz
cd8721fbdc Add an assert to catch a mismatch in id/hash size tables. 2013-03-09 11:13:18 -08:00
JoelKatz
eccb6eb936 Cleanups and a small fix. 2013-03-05 21:54:04 -08:00
JoelKatz
5b383d43b0 Fix a bug that could cause crashes. 2013-02-21 19:29:25 -08:00
JoelKatz
52c378411d If we start seeing acquire timeouts, don't start new acquires.
The link could be overloaded.
2013-02-20 13:30:57 -08:00
JoelKatz
e674bcea36 A collection of small bugfixes. 2013-02-08 16:22:27 -08:00
JoelKatz
1808454983 Use the new uptime code. Replace slow, non-monotonic 'time(NULL)' calls
with fast, almost-always-monotonic 'upTime()' calls.
2013-02-05 22:31:26 -08:00
JoelKatz
9781c10736 Fix some cases where ledger flags are incorrectly set. 2013-02-01 16:11:32 -08:00
JoelKatz
0cb1a1d84b Cleanups and timing adjustments. 2013-01-28 02:32:57 -08:00
JoelKatz
56571602b0 Reduce a debug message to debug level. 2013-01-15 19:46:58 -08:00
JoelKatz
90010b8870 Cleanups. Remove some unneeded filters. 2013-01-15 10:20:41 -08:00
jed
f3a28d65b7 windows 2013-01-14 12:57:37 -08:00
JoelKatz
8afbc33706 Some LedgerAcquire improvements. 2013-01-14 02:12:30 -08:00
JoelKatz
fc78cb38ed Don't favor (for acquire) peers that come earlier in the peer vector. 2013-01-13 21:40:46 -08:00
JoelKatz
6f33155308 Makr ledgers we acquired to accept as closed. 2013-01-13 00:22:46 -08:00
JoelKatz
a0bfd57937 Fix an endless loop. 2013-01-12 23:47:06 -08:00
JoelKatz
e5c1b3e6f2 Remove a bogus assert. 2013-01-12 21:48:15 -08:00
JoelKatz
cbeb6a50e8 LedgerAcquire::filterNodes wasn't following the right logic. 2013-01-12 08:34:36 -08:00