Commit Graph

299 Commits

Author SHA1 Message Date
Stephen Shelton
595288e046
Add PeerDb::handleGossipedRC 2020-07-02 10:13:22 -06:00
Stephen Shelton
43ffe23f66
Remove obnoxious log statement 2020-06-04 13:21:05 -06:00
Jeff Becker
3a776b3ed1
bounds checks and such 2020-05-23 16:07:20 -04:00
Jason Rhinelander
ebd2142114 Don't use std::optional::value() because f u macos
This replaces all use of std::optional's `opt.value()` with `*opt`
because macOS is great and the ghost of Steve Jobs says that actually
supporting std::optional's value() method is not for chumps before macOS
10.14.  So don't use it because Apple is great.

Pretty much all of our use of it actually is done better with operator*
anyway (since operator* doesn't do a check that the optional has a
value).

Also replaced *most* of the `has_value()` calls with direct bool
context, except for one in the config section which looked really
confusing at a glance without a has_value().
2020-05-20 19:18:28 -03:00
Jason Rhinelander
26ecf23ad8 Silence various warnings 2020-05-17 21:28:17 -03:00
Jason Rhinelander
dccc663f31 Miss Match demands her name be removed from the code
(i.e. fix speeling mistack: missmatch -> mismatch)
2020-05-13 22:35:15 -03:00
Jason Rhinelander
1697bf90fe C++17
Compiles with C++17, replaces ghc::filesystem with std::filesystem,
nonstd::optional with std::optional, and llarp::string_view with
std::string_view.
2020-05-01 17:43:27 -03:00
Jeff
5b1941222b
unscrew travis-ci (#1223)
* update travis ci clang-format to clang-format-9 because we use that now
add python3-dev package becuase something inside ci thinks it has python but really does not

* try using python3.6

* try working around hot garbage that is travis-ci

* add deadsnakes repo for python3.8

* prevent nullptr deference when running in unit tests

* move python3.8 to main dependancy matrix and add python3.8 to homebrew deps

* add deadsnake apt repo

* add deadsnakes and python3.8 back to previous matrix

* dev package for python

* toggle hive build in ci

* dont add pybind11 if not bulding hive

* revert setting pyenv shim for travis ci

* make native builds on by default except for windows ci

* only apply native build being off for windows release target becuase that broke macos
2020-04-18 16:58:41 -03:00
Jason Rhinelander
3c6aa002b8 Fix errors and warnings compiling on mac 2020-04-10 14:26:50 -03:00
Stephen Shelton
273270916e
The Great Wall of Blame
This commit reflects changes to clang-format rules. Unfortunately,
these rule changes create a massive change to the codebase, which
causes an apparent rewrite of git history.

Git blame's --ignore-rev flag can be used to ignore this commit when
attempting to `git blame` some code.
2020-04-07 12:38:56 -06:00
Stephen Shelton
ea835405c5
Refactor NotifyRouterEvent() to forward args, event code cleanup
This template-ifies Router::NotifyRouterEvent() up so that it accepts
the arguments to instantiate the specified event type, forwarding them
to std::make_unique. This would allow (in the future) the function to
no-op the call and avoid memory allocation. It also slightly reduces
the amount of code required to fire an event.

This commit also simplifies some of the RouterEvent code to reduce
redundancy.
2020-03-12 11:50:46 -06:00
Stephen Shelton
6664202868
Add FindRouterSentEvent and FindRouterReceivedEvent to RouterHive 2020-03-10 12:12:11 -06:00
Thomas Winget
84a1d7dbcc clang format....... 2020-03-06 20:20:11 -05:00
Thomas Winget
a58a8c9a61 hive.py now defaults to 1000 relays because f your box.
also check for error on uv_async_init...

may want to `ulimit -Sn $(ulimit -Hn)`...
2020-03-03 19:57:09 -05:00
Thomas Winget
c8c66f0a5f some refactoring of tooling code, added RCGossipReceivedEvent 2020-03-03 19:57:09 -05:00
Stephen Shelton
4741d81051 Add GotIntro event to RouterHive 2020-03-03 19:57:09 -05:00
Jeff Becker
e7689b40a7 dht pub intro message router event thiny doo 2020-03-03 19:57:09 -05:00
Stephen Shelton
321314b456
Remove re-propagation of introsets when we are wrong candidate 2020-03-02 15:24:41 -07:00
Stephen Shelton
9be8050854
Make format 2020-03-02 09:57:37 -07:00
Stephen Shelton
886a981997
Consolidate introset publishing constants 2020-03-02 09:57:37 -07:00
Jeff Becker
d3f222ddcc
revert relay side dedup parameter 2020-03-02 11:42:26 -05:00
Stephen Shelton
bbee45118e
Remove redundant lookup logic from relays 2020-03-02 09:27:07 -07:00
Jeff Becker
8f4362f092
fix up introset lookups 2020-03-02 11:12:29 -05:00
Jason Rhinelander
806d43c34e
Merge pull request #1147 from notlesh/diagnose-pubintro-round2-2020-02-28
Diagnose pubintro round2
2020-03-01 20:26:41 -04:00
Jeff Becker
45fa9bebbc
wrong txid 2020-03-01 12:33:54 -05:00
Jeff Becker
e3b5fb4dd9
add local publish intro message to send reply down path 2020-03-01 12:30:05 -05:00
Jeff Becker
5b075259e6
revert 2020-03-01 11:21:48 -05:00
Jeff Becker
b4a59a0b1a
make format 2020-03-01 11:20:11 -05:00
Jeff Becker
dd21cba1fe
dedup via txid not keyspace location 2020-03-01 11:17:39 -05:00
Jason Rhinelander
27b8743107 Add warns for introset publish failures 2020-03-01 11:48:43 -04:00
jeff
f76b9f3042 make format 2020-02-29 17:43:51 -05:00
jeff
49e69d7087 remove uneeded code 2020-02-29 15:48:51 -05:00
Stephen Shelton
2ebd9bbd95
Implement PublishServiceJob::SendReply() 2020-02-28 20:59:24 -07:00
Stephen Shelton
638ea2e0fd
Make format 2020-02-28 17:07:35 -07:00
Stephen Shelton
d09fd13dd6
Calculate 'candidateNumber' when we should store Introset 2020-02-28 17:00:49 -07:00
Stephen Shelton
37ca564005
Log when DHTSendTo fails @ Router::SendToOrQueue 2020-02-28 16:56:35 -07:00
Stephen Shelton
62014de91c
Handle PubIntro relayOrder logic on client-side 2020-02-28 16:45:04 -07:00
Stephen Shelton
a8623f09e9
Properly deserialize PubIntroMessages' relayed var 2020-02-28 16:30:10 -07:00
Stephen Shelton
c0fbe06c0f
Require 'From' and 'relayed' in PublishIntroMessage ctor 2020-02-28 16:28:57 -07:00
Stephen Shelton
f61cd1a7da
Add some notes/comments about DHT message handling 2020-02-28 16:26:52 -07:00
Stephen Shelton
6b906de00d
Judicious removal of dead code 2020-02-28 16:26:45 -07:00
Jeff Becker
dea78d2326
change function signature for dht context to exclude time parameter 2020-02-27 11:37:23 -05:00
Jeff Becker
7a84bbe459
remove dht explore timer 2020-02-27 11:28:01 -05:00
Jeff Becker
bf0416cab8
remove Time_t, add operator overload for printing llarp_time_t and add to_json function for serializing llarp_time_t to json 2020-02-25 12:05:13 -05:00
Jeff Becker
d2d109e92c
llarp_time_t is now using std::chrono 2020-02-24 15:25:03 -05:00
Jeff Becker
f4520ac920
make decaying hashset use llarp::Time_t and move unit tests to use catch2 2020-02-24 15:22:49 -05:00
Jason Rhinelander
089056ca5b Remove all ABSL_ATTRIBUTE_UNUSED uses 2020-02-24 14:27:44 -04:00
Jason Rhinelander
f84ce61d66 Removed empty cpp files
These aren't needed: CMake already knows how to follow #includes and
rebuild when headers change as long as the headers are included
*somewhere*.  The extra .cpp files here just require building a bunch of
.cpp files with just header content that we just end up throw away
during linking (since the same things will also be compiled in whatever
other compilation units include the same headers).
2020-02-21 23:39:11 -04:00
Jeff
7c5a721457
Merge pull request #1114 from notlesh/redundant-introset-lookup-improvements-2020-02-20
Redundant introset lookup improvements
2020-02-20 15:25:09 -05:00
Stephen Shelton
63c3106db2
Make format 2020-02-20 13:14:20 -07:00