61 Commits

Author SHA1 Message Date
sakridge
297f859631
Change '>=' back to '>' to fix recycling of blobs/packets (#1192)
Recycler will have a strong ref to the item so it will be at
least 1, >= will always prevent recycling.
2018-09-11 16:52:45 -07:00
anatoly yakovenko
c34d911eaf
Migrate Budget DSL to use the Account state (#979)
* Migrate Budget DSL to use the Account state instead of global bank data structures.

* Serialize Instruction into Transaction::userdata.
* Store the pending set in the Account::userdata
* Enforce the token balance rules on contract execution. This becomes the entry point for generic contracts.
* This pr will have a performance impact on the bank. The next set of changes will fix this by locking each account during multi threaded execution of all the contracts.
* With this change a contract transaction needs to store its state under an address. That address could be the destination of the tokens, or any random address. For the latter, an extra step would be needed to claim the tokens which isn't implemented by budget_dsl at the moment.
* test tracking issue 1157
2018-09-07 20:18:36 -07:00
Rob Walker
226d3b9471
Trace recycle() calls (#968)
* trace recycle() calls fixes #810
2018-09-05 05:07:02 +09:00
Greg Fitzgerald
8cc030ef84 Use Vec instead of VecDeque for SharedBlobs 2018-09-04 07:50:23 -10:00
Rob Walker
63e44dcc35 continue rendezvous refactor for gossip and repair
* remove trailing whitespace in ci/audit.sh

  * code review fixups
     * rename GOSSIP_PORT_RANGE => SOLANA_PORT_RANGE
     * remove out-of-date TODO in localnet-sanity.sh

  * remove features=test and code that was using it (localhost prohibitions in
      crdt) added TODO in crdt.rs, maybe we should boot localhost in production
      networks?

  * boot tvu_window from NodeInfo: instead, send repair requests from the repair
      socket (to gossip on peer) and answer repair requests via the sockaddr
      from the repair request

  * remove various unused pub functions

  * banish SocketAddr parse().unwrap() to a macro that can also accept simpler stuff
2018-08-31 23:21:07 +09:00
Greg Fitzgerald
90ae662e4d Fix packet header offset
And update transaction offsets to use the same approach as packet.rs.
Maybe this should be serialized_size(), but thanks to this
GenericArray update, those values are the same.
2018-08-26 14:27:19 -06:00
sakridge
cabe80b129
Increment counter by number of packets received (#1049)
So that we can see the total packets/s
2018-08-23 12:32:50 -07:00
Rob Walker
bc5f29150b fix erasure, remove Entry "pad"
* fixes #997
 * Entry pad is no longer required since erasure coding aligns data length
2018-08-18 02:22:52 -07:00
Rob Walker
46016b8c7e crashes generate_coding() 2018-08-18 02:22:52 -07:00
Rob Walker
5dbecd6b6b add logging, more conservative reset 2018-08-18 02:22:52 -07:00
Rob Walker
5f6cbe0cf8 fixups 2018-08-13 21:07:26 -07:00
Rob Walker
f167b0c2c5 fixups 2018-08-13 21:07:26 -07:00
Rob Walker
f784500fbb fixups
fixes #907
2018-08-13 21:07:26 -07:00
Rob Walker
83df47323a initialize recycled data 2018-08-13 21:07:26 -07:00
Greg Fitzgerald
ad331e6d56 Rename PublicKey type to Pubkey
Recognize pubkey as a noun meaning the public key of a keypair.
2018-08-09 13:41:37 -06:00
Stephen Akridge
38be61bd22 Check for log level before doing perf counter work
Perf counters, especially when running the dynamic test can cause
functions like crdt::apply_updates to be really slow (>500ms).
2018-08-08 00:16:53 -07:00
Stephen Akridge
a200cedb4b Lower UDP data size to 64k - 128 bytes
rust API gives errors for packets larger than ~65500 and
wikipedia says 65507 is the max size, lowering this avoids the errors.
2018-08-07 18:39:36 -07:00
Rob Walker
f2b1a04bca cargo fmt fixups 2018-08-03 11:59:25 -07:00
Rob Walker
dd819cec3d fix off by one in packet.rs 2018-07-26 09:24:44 -07:00
Stephen Akridge
212874e155 Use BlobError for get_size return 2018-07-25 15:54:04 -07:00
Rob Walker
9c7913ac9e trying to raise an error 2018-07-25 08:12:20 -07:00
Rob Walker
8b01e6ac0b implement Blob::get_size(), the counterpart of Blob::set_size() 2018-07-25 08:12:20 -07:00
Rob Walker
3d80926508 fixups 2018-07-24 13:04:34 -07:00
Michael Vines
5deb34e5bd Little more trace! logging 2018-07-18 12:54:50 -07:00
anatoly yakovenko
d8c9655128
Dynamic test assert (#643)
* log responder error to warn

* log responder error to warn

* fixup!

* fixed assert

* fixed bad ports issue

* comments

* test for dummy address in Crdt::new instaad of NodeInfo::new

* return error if ContactInfo supplied to Crdt::new cannot be used to connect to network

* comments
2018-07-16 19:31:52 -07:00
anatoly yakovenko
09f2d273c5
less intrusive counters (#655)
* less intrusive counters

* fixed arg

* tests

* comments
2018-07-16 18:33:50 -07:00
Greg Fitzgerald
73ae3c3301 Apply most of clippy's feedback 2018-07-12 09:40:40 -06:00
Stephen Akridge
bed5438831 Improved streamer debug messages
distinguish between threads
2018-07-11 18:26:16 +02:00
Anatoly Yakovenko
03a8a5ed55 only submit to influx when we log
test accumilated value logging

lots of counters

higher influx rate

fix counter name

replicate-transactions
2018-07-11 07:53:39 -06:00
Greg Fitzgerald
231040b93e Add tests 2018-06-28 12:28:43 -07:00
Greg Fitzgerald
7c74afc35a Relax recycler
Instead of asserting ref count is 1 before recycling, allow users
to recycle items early. If it turns out that was too early, and
allocate() wants to return it, then boot it and take a memory
allocation performance hit instead.
2018-06-28 12:28:43 -07:00
Greg Fitzgerald
4aedd3f1b6 Cleanup type aliases and imports 2018-06-27 15:06:18 -06:00
Greg Fitzgerald
1691060a22 Assert recycler is given last reference to data
This patch likely fixes the sporadic failures in the following tests:

```
test server::tests::validator_exit ... FAILED
test streamer::test::streamer_send_test ... FAILED
test thin_client::tests::test_bad_sig ... FAILED
test drone::tests::test_send_airdrop ... FAILED
test thin_client::tests::test_thin_client ... FAILED
```
2018-06-26 16:51:07 -06:00
OEM Configuration (temporary user)
b20efabfd2 added retransmission of repair messages 2018-06-19 12:36:02 -07:00
Greg Fitzgerald
9d84ec4bb3 Delete TODO
That comment predates the separation of RPU and TPU.
2018-06-16 08:59:30 -06:00
Stephen Akridge
5f1d8c95eb Fix blob data size 2018-06-15 11:54:01 -06:00
Stephen Akridge
1ee5c81267 Fix benchmarking banking_stage 2018-06-08 15:50:36 -07:00
Anatoly Yakovenko
c2a9395a4b perf counters 2018-06-07 14:59:21 -07:00
Stephen Akridge
a06535d7ed cargo fmt 2018-06-05 15:32:25 -06:00
Stephen Akridge
34834c5af9 Store another size in the data block so it is coded as well 2018-06-05 15:32:25 -06:00
Stephen Akridge
b845245614 Restore more of the blob window and add is_coding helper 2018-06-05 15:32:25 -06:00
Stephen Akridge
33f01efe69 Fixes for erasure coding 2018-06-05 15:32:25 -06:00
Anatoly Yakovenko
cef1c208a5 Crdt pipeline, coalesce window repair requests in the listener by examining all of them at once, and ublock those threads from doing io. 2018-05-30 14:04:48 -06:00
Anatoly Yakovenko
8d1f82c34d breaks 2018-05-29 16:53:26 -07:00
Anatoly Yakovenko
0cb2036e3a comment on bad blob usage 2018-05-29 16:53:26 -07:00
Greg Fitzgerald
bb53f69016 Fix typos 2018-05-26 00:36:50 -06:00
Greg Fitzgerald
dcaeacc507 request_stage::serialize_packets -> packet::to_blobs
Good stuff - no need to hide them.
2018-05-25 17:31:07 -06:00
Greg Fitzgerald
aaeb5ba52f tr -> tx 2018-05-25 16:47:21 -06:00
Greg Fitzgerald
4955c6f13a request::to_request_packets -> packet::to_packets 2018-05-16 16:11:53 -06:00
Anatoly Yakovenko
2d635386af rebased 2018-05-14 15:20:41 -07:00