| Commit message (Collapse) | Author | Age | Files | Lines |
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
This enum is required to use `TorClient::reconfigure` correctly, and
as such ought to be re-exported.
|
| | |
|
| |
|
|
|
|
|
| |
This resolves a copy-and-paste error where we were putting
everything in our state directory.
Closes #297.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit addresses multiple problems highlighted by arti#182:
- `arti-client` had some types in its public API that weren't accessible
without importing another crate (`CfgPath`, `DataReader`,
`DataWriter`). This has been fixed.
- In addition, the doc comments for `DataReader` and `DataWriter` were
cleaned up to be of better quality, now that they're public.
- It was impossible to use `arti-client` without also importing
`tor-rtcompat`. This is now fixed by the addition of two convenience
methods: `TorClient::bootstrap_with_tokio` and
`TorClient::bootstrap_with_async_std`.
- Potentially controversially: `tor-rtcompat` now returns *concrete*
types from methods like `current_runtime`, instead of `impl Runtime`.
- This was needed in order to actually be able to name the `TorClient`
type that results from using these methods.
- This does mean we lose API flexibility, but on balance I think this
is a good thing, because the API we *do* have is actually usable...
|
| |
|
|
|
|
|
|
|
|
|
| |
Previously we kept this in an ambiguously named type,
`ClientTimeoutConfig`. But everything we do right now is client
related! So `StreamTimeoutConfig` is a better name.
Also, we'd previously neglected to expose the builder for this type
from `TorClientConfigBuilder`. Now we do.
Closes #281.
|
| |
|
|
|
| |
It no longer makes sense to say "most things can't change", now that
most things can.
|
| |
|
|
| |
This covers ClientAddrConfig and ClientTimeoutConfig.
|
| |
|
|
| |
We shouldn't have pub members in these config objects.
|
| |
|
|
|
|
|
| |
(There are other timeout rules, after all.)
Also, rename stream_timeout to connect_timeout, to make it more clear
when it applies.
|
| |\
| |
| |
| |
| | |
Usability: renaming and documentation in preemptive circuit config
See merge request tpo/core/arti!176
|
| | |
| |
| |
| |
| |
| | |
This obeys a few conventions:
* adjective before noun
* config objects end with "config"
|
| |\ \
| |/
|/|
| |
| |
| |
| | |
Make DNS fields in arti-client/src/client.rs configurable
Closes #252
See merge request tpo/core/arti!171
|
| | | |
|
| | | |
|
| | | |
|
| |/ |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
The sane_defaults() call is now the same as you get from a default
builder: by convention, we just call that method Default::default().
The with_directories() constructor makes more sense as a constructor
for the TorClientConfigBuilder than for TorClientConfig.
|
| |\ |
|
| | |
| |
| |
| | |
(Also fix a couple of typos)
|
| | |
| |
| |
| |
| | |
Make sure that we can change elements, and we can reconstruct builders
that give us the same thing.
|
| | | |
|
| | |
| |
| |
| |
| | |
When we deserialize a configuration, we should reject unknown variables
(except when we have an explicit reason to allow them).
|
| | |
| |
| |
| | |
These don't need to be exposed any longer.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
I'm still not 100% sure this is the right move: should we encourage
app developers to always pick their own directories? Or should we
make it easy for them to use, well, `sane_defaults`?
This patch takes the second approach.
|
| |/ |
|
| | |
|
| | |
|
| |
|
|
| |
Also fix some commonwealth spellings that had slipped in.
|
| |
|
|
|
| |
This should be ergonomic than having to construct every section of the
configuration separately.
|
| |
|
|
|
| |
Doing this is necessary for reconfiguration support, and will help a lot
with testing, too.
|
| |
|
|
|
|
|
|
|
|
| |
This patch makes sure that for every* config type we have, the defaults
you get from a Builder match those you get from Serde, and that both
match the value that you get from arti_defaults.toml. Later down the
line I'll be adding some tests to keep these in sync.
* StorageConfig still has no defaults of its own, since we aren't so
sure we want other applications to use Arti's directories by default.
|
| |
|
|
|
|
|
|
| |
Since these shell-variables are hardwired to use org.torproject.Arti as
the program name, it isn't appropriate to call them "app-specific".
If we someday reinstate APP_FOO, it should be based on a user-provided
application name.
|
| |
|
|
|
|
|
|
| |
In order to handle explicitly specified path buffers directly, we now
let CfgPath be either a string (that gets expanded) or a PathBuf
(that doesn't).
This simplifies TorClientConfig::with_directories()
|
| |
|
|
| |
This will make it more convenient to reconfigure things.
|
| | |
|
| |
|
|
|
|
|
|
| |
Now every section that the two configuration objects share has the
same type and name. This should help us in documenting our configuration
in a way that doesn't confuse people.
There is still lots of API work to go.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
To do this at all neatly, I had to split out `tor-config` from
`arti-config` again, and putting the lower level stuff (paths,
builder errors) into tor-config. I also changed our use of
derive_builder to always use a common error type, to avoid
error type proliferation.
|
| |
|
|
|
| |
I'm about to make tor-config a higher-level module, so it can't be a
dependency for tor-config.
|
| | |
|
|
|
Solves a name conflict with the existing tor_client create.
Closes #130.
|