| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Stop referring to TCP streams in its documentation;
update other documentation to refer to NetStreamProvider
rather than TcpProvider.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
(And similarly rename TcpListener to NetStreamListener,
along with their TcpStream/TcpListener associated types.)
These types are about to become generic over addresses,
and therefore shouldn't be named after TCP.
Renaming was done mostly with Rust Analyzer,
except for some macros that needed to be hand-edited.
(I'll revise the comments in the next commit;
this one is all about renaming.)
|
| |
|
|
|
|
|
| |
With this extension trait, we no longer need to construct
`CompoundRuntime` directly outside of tor-rtcompat. This in turn
will make it a little less painful when we have to add more generics
to CompoundRuntime.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Add a function to get the keying material as detailed by RFC 5705.
Because native-tls doesn't have such support, there is a place holder
panic!() for now.
This means that for the forseable future, relay would only work with
rustls until we figure out a solution for native-tls.
Closes #1432
Signed-off-by: David Goulet <[email protected]>
|
| | |
|
| |
|
|
|
|
| |
In all the uses in-crate, this is just a RealCoarseTimeProvider.
Now all the compound runtimes impl CoarseTimeProvider.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
In particular, when the (unstable) tokio tracing feature is enabled,
every tracing line includes the name of where the current task was
created. Without this change, that ends up being the name of
intermediate trait methods like TokioRuntimeHandle::block_on, which is
not very helpful.
Adding the `track_caller` attribute causes the name of the caller of
these methods to be used instead, which is typically more helpful.
IIUC this change is not breaking in terms of semver
https://rustc-dev-guide.rust-lang.org/backend/implicit-caller-location.html.
|
| |
|
|
| |
We're doing this deliberately, I believe.
|
| |
|
|
|
|
|
|
| |
This will make it much more convenient for code that only wants one of
these traits (or a subset of them). This is a good thing to support
because it will allow us to use a ZST in places that do not need an
actual async runtime handle (typically, the runtime handle is needed
only for spawn).
|
| |
|
|
|
|
| |
Previously, CompoundRuntime would use the default implementations of
SleepProvider::now() and ::wallclock(), instead of using its wrapped
SleepProvider. This mildly embarrassing omission has been rectified.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
Now all of the runtime types we provide all
impl<S> TlsProvider<S> where S: ...
rather than merely TlsProvider<Self::TcpStream>.
And we document and intent to perhaps require this in the future.
|
| |
|
|
|
| |
This avoids a future confusion with the new `SpawnBlocking` trait in
async_executors v0.5, and better describes what the trait provides.
|
| |
|
|
|
| |
If we implement our own clone on CompoundRuntime, we no longer need
Clone implementations on our TlsProvider implementations.
|
|
|
This type can solve two problems at once.
First, it lets users replace parts of an existing runtime
implementation without replacing the whole thing. For example, you
can use it to override your TcpProvider implementation to solve
problems like #235.
Second, we can use it internally to tor-rtcompat to define Runtimes
piece-by-piece. Mostly we'll use this to separate our Tls
implementations from our implementations of the rest of the Runtime.
|