| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This commit executes maint/add_warning with the just added change to
deny string slices except in tests.
I recommend auditing this by checking out the previous commit followed
by running the script yourself and then verifying that the diff is
identical to this commit.
This commit makes cargo clippy fail. We will add exceptions in the next
commit.
|
| | |
|
| |
|
|
|
|
|
| |
`test_utils` is not exposed outside of `tor-proto`, so the feature
gating here isn't needed (we typically use the `testing` feature for
exposing testing utilities outside the current crate, but that's not the
case here).
|
| | |
|
| |
|
|
| |
Run maint/add_warning
|
| |
|
|
| |
We need this to calculate the half-stream timeouts for #264.
|
| |
|
|
|
|
|
| |
We no longer need to clone `CongestionWindowParams` now that it
implements `Copy`.
Resolves a clippy warning.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. Run cargo fix --edition
2. Selectively revert the "if let"->"match" changes.
These changes are meant to protect us from the lifetime changes
for "if let" bindings in Rust 2024.
But we're not actually relying on the old lifetime rules
anywhere, and the match syntax here is quite ugly.
3. Automatically revert `$pat:expr_2021` to `$pat:expr`.
(We don't actually want to restrict the expression syntax
that our macros accept).
Done with
`git grep -l expr_2021 | xargs perl -i -pe 's/expr_2021/expr/g;'`
4. Run cargo fmt.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Conflux is only supported when prop324 congestion control is enabled, so
we need an accessor for the cc algorithm of a given circuit hop in order
for the conflux code to be able to check *which* cc algorithm is in use.
|
| |
|
|
|
|
| |
This doesn't really change anything, but removing the `.clone()` makes
it a bit more obvious that copying the `*Params` is a lightweight
operation.
|
| | |
|
| | |
|
| |
|
|
|
| |
We use this method to decide whether to allow receiving stream SENDMEs,
and also whether we should send stream SENDMEs.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This adds a new function to the CongestionControl object that returns
true or false on if stream level SENDMEs are allowed by the underlying
algorithm.
Congestion control Vegas doesn't allow them as in it retires them and so
we avoid sending them for that algorithm.
Part of #1817
Signed-off-by: David Goulet <[email protected]>
|
| | |
|
| |
|
|
|
|
| |
Allows us to remove the pub.
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
| |
Put code for test inside the test module instead of gated by a
cfg(test).
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
| |
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
| |
Don't put in the comments, let the top-level module comments do that
job.
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
|
| |
Instead of having the congestion.rs test module public, make a
test_utils.rs file that contains code for other unit tests within the
congestion module.
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
| |
The big one! This is the Vegas algorithm implementation that is hooked
to the CongestionControl object by implementing the algorithm trait.
Still, at this commit, nothing is being used by the circuit reactor yet.
Related #534
Signed-off-by: David Goulet <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add the top level CongestionControl object that will allow the circuit
reactor to use it in order to decide if a cell can be sent or not. In
order to be used, it is configured with an algorithm that implements the
CongestionControlAlgorithm trait.
The Fixed Window algorithm is also added which essentially implements
the SENDME logic as arti knows it today with a fixed window size.
The SENDME code has been refactor in two different logical steps in
order to accomodate the future Vegas algorithm for which the congestion
window logic and SENDME validity is seperated.
There is now a SENDME validator that takes care of tracking the tags
(authenticated SENDMEs) and validating them upon reception. Then, if
valid, the window management is passed down the congestion control
algorithm, at this commit, FixedWindow object.
Related #534
Signed-off-by: David Goulet <[email protected]>
|
|
|
This commit adds the congestion window object, a round trip estimator
(RTT) and a state enum. These 3 entities are used by congestion control
in a generic way that is they are passed and used by any algorithm.
At this commit, they are not used hence the allow deadcode attribute for
now in order to minimize the build warnings.
We also introduce the params.rs file containing the parameters, taken
from consensus, used to configure these objects. They will be exposed to
the tor-cirmgr crate to build the CircParameters. More will come.
This also introduces the congestion/ directory that will contain more
code in future commits.
Related #534
Signed-off-by: David Goulet <[email protected]>
|