Jason Rhinelander
846577a0aa
Add missing inbound traffic pump trigger
2021-11-15 13:38:10 -04:00
Jason Rhinelander
8cdde74020
Simplify
2021-11-15 13:38:08 -04:00
Jason Rhinelander
b3a8160c89
Pump hidden context sooner
...
This has to happen before pumping links because it is putting things on
links.
2021-11-15 13:38:05 -04:00
Jason Rhinelander
0924dd8862
Remove dead declaration
2021-11-15 13:38:02 -04:00
Jason Rhinelander
f9395cd5dd
Cleanup: avoid pointless copy of this
pointer
2021-11-15 13:38:00 -04:00
Jason Rhinelander
9844d358e6
Fix packet delay creep
...
- Make the main PumpLL also pump hidden services, rather than using
separate wakers in each TunEndpoint. It seems there is some
interactions that just one or the other is not enough.
- Eliminate TunEndpoint send queue -- it isn't needed as we can just
send directly.
2021-11-15 13:37:57 -04:00
Jason Rhinelander
99b12940ad
Cleanups
2021-11-15 13:37:54 -04:00
Jason Rhinelander
e47d3098ac
Increase plaintext queue size from 32 to 512
...
In testing we were sometimes hitting a full queue error, which makes
sense because the queue size seems really small.
Increase it to 512.
2021-11-15 13:37:49 -04:00
Jason Rhinelander
78cc466bf2
Rename PumpLL -> TriggerPump
...
And rename the actual pump implementation back to PumpLL.
2021-11-15 13:37:47 -04:00
Jason Rhinelander
031ea7aa37
Get rid of external event loop direct wakeups
...
If something needs to wake up the event loop it should be using an
async, as we are now with PumpLL(); but we had various code triggering a
wakeup, expecting that PumpLL gets called on every wakeup, which isn't
true anymore.
2021-11-15 13:36:44 -04:00
Jason Rhinelander
74215fc44c
Fix link layer delivery race condition (fix random ping delays)
...
We trigger a pump immediately, but this is racey because we add to our
plaintext data in a worker thread; if the worker thread runs after the
pump then it ends up leaving plaintext to be handled, but there's no
wakeup until the next one.
This was the cause of seeing a random +1s and bunching added to ping
responses sometimes: it wasn't until the *next* ping goes through the
network that the plaintext queue gets processed, at which point it
flushes the old one and often the new one together.
The fix here gets rid of the map of sessions needing wakeups and instead
adds an atomic flag to all of them to let us figure out which ones
need to be flushed.
2021-11-15 13:36:28 -04:00
Jason Rhinelander
aa1dc83459
Simplify
2021-11-15 13:36:13 -04:00
Jason Rhinelander
362fda5a56
Combine empty + pop into single call
2021-11-15 13:36:09 -04:00
Jason Rhinelander
b03f3c2d79
Remove another unwanted unconditional PumpLL
2021-11-15 13:36:03 -04:00
Jason Rhinelander
9113a6b36b
Triggered pumping
...
This redoes how/when we pump so that we should only be calling the
idempotent PumpLL() when we actually have (or may have) something to
pump.
2021-11-15 13:35:57 -04:00
Jason Rhinelander
bfc6d35b33
Simplifications & C++17
...
- Modernize some iterator loops
- Simplify a couple places by using `if (init; ...)`
- Replace various std::binds with lambdas
2021-11-14 10:11:00 -04:00
Jason Rhinelander
41807f1763
transit hop: drop instead of flushing when full
...
If full happens we are going to trigger a bunch of flushes which
probably isn't very useful, so drop instead.
2021-11-14 10:10:58 -04:00
Jason Rhinelander
cf5c4e7284
outbound_message_handler: skip instead of aborting on removed paths
2021-11-14 10:10:19 -04:00
Jason Rhinelander
633431be66
Make outbound message queue PumpLL again if it doesn't send all
2021-11-14 10:10:19 -04:00
Jason Rhinelander
faf95cbd0a
Allow a nullptr callback for event loop PumpLL
2021-11-14 10:07:31 -04:00
Jeff Becker
8a9025e234
only pump path context in idempotent pumpll
2021-11-14 10:07:31 -04:00
Jeff Becker
bb86996acf
make event loop pump function non idempotent
2021-11-14 10:07:31 -04:00
Jeff Becker
8744c93944
prevent 100% cpu usage on service nodes
...
call_soon wakes up the mainloop and is often reentrant, we dont want to
ever way up the event loop but we also want to always defer the call so
we always use the workers
2021-11-14 10:07:11 -04:00
Jeff Becker
22d4b88edc
make PumpLL idempotent to reduce cpu use a bit
2021-11-09 11:59:57 -05:00
Jason Rhinelander
1ddfb7420a
Merge pull request #1791 from majestrate/exclude-failing-from-queue-2021-10-29
...
exclude fully failed nodes from service node testing list
2021-10-29 14:44:16 -03:00
Jason Rhinelander
0ec50e6624
Fix comment typo
2021-10-29 11:52:54 -03:00
Jeff Becker
fcba709fcb
do not requeue nodes for testing from failing queue if we do not have them marked as failing anymore
2021-10-29 10:46:50 -04:00
Jeff
60c1b69ea3
Merge pull request #1784 from jagerman/deb-docker-images
...
Generate CI images with much DRY-er Python dockerfile generating script
2021-10-28 14:01:04 -04:00
Jason Rhinelander
e6622c1d46
Install g++-8 on bionic
2021-10-28 13:49:37 -03:00
Jason Rhinelander
cd49031bd2
Fix race condition in interactive output
2021-10-28 13:49:20 -03:00
Jason Rhinelander
fd81ee76af
Merge pull request #1778 from majestrate/net-range-detection-bug-2021-10-22
...
check for intersecting ip ranges correctly, add unit test
2021-10-27 21:29:23 -03:00
Jason Rhinelander
52f8273dc1
Merge pull request #1781 from majestrate/bump-static-deps-2021-10-25
...
bump libunbound static dep hashpin
2021-10-27 16:44:39 -03:00
Jason Rhinelander
0b4c56dff5
Add hacks; add --distro to rebuild just one
...
Bionic is broken and needs a hack to create some dumb pgm include
directory.
Add --distro cli argument so that you can rebuild just one distro.
2021-10-26 17:38:17 -03:00
Jason Rhinelander
0572713533
Fix i386 builds
2021-10-26 15:10:54 -03:00
Jason Rhinelander
09e97eef77
Make it snazzy
...
Shows statuses that "fill in" when run interactively.
2021-10-26 14:57:58 -03:00
Jason Rhinelander
2064ca049d
Parallelize builds
2021-10-26 14:05:35 -03:00
Jason Rhinelander
9b7ec7dd50
Add --no-cache option; fix manifest generation
2021-10-26 10:59:24 -03:00
Jason Rhinelander
1c4332ad6a
Replace dockerfiles with a Python script
2021-10-26 03:28:49 -03:00
Jason Rhinelander
cbbee59774
Add a bunch of base CI images for building debs
...
Installs just the base tools (which are quite substantial), but not the
deps (which get installed as part of the build).
2021-10-26 03:25:26 -03:00
Jeff Becker
b5f5d07f03
bump libunbound static dep hashpin
2021-10-25 11:35:50 -04:00
Jason Rhinelander
808c2df6cc
Merge pull request #1779 from jagerman/ci-python-deps
...
Add python packages to ci images
2021-10-22 20:12:00 -03:00
Jason Rhinelander
f3bac4ae72
Pass DOCKER_BUILD_OPTS env var to docker build
2021-10-22 19:15:46 -03:00
Jason Rhinelander
c7410660c8
Make sure we apt-get update in the build
...
The base image can get out of date.
2021-10-22 19:15:46 -03:00
Jason Rhinelander
78e829a03f
Add python build deps to ci images
2021-10-22 19:15:46 -03:00
Jeff Becker
6c70022dcc
check for intersecting ip ranges correctly, add unit test
2021-10-22 15:53:19 -04:00
Jeff Becker
1a360c1a36
version bump to 0.9.7
2021-10-19 15:17:42 -04:00
Jason Rhinelander
410e98f4eb
Merge pull request #1775 from jagerman/parallel-submodules
...
Fetch CI submodules in parallel
2021-10-18 22:26:53 -03:00
Jason Rhinelander
45249422b1
Fetch CI submodules in parallel
2021-10-18 13:50:43 -03:00
Jeff
dce6c1e3b6
Merge pull request #1774 from jagerman/clang-13
...
Docker + clang updates
2021-10-18 07:13:21 -04:00
Jason Rhinelander
7bc86ff983
Reorder pipelines to put static builds together
2021-10-17 23:44:03 -03:00