Closed dignifiedquire closed 1 year ago
Hi, thank you for the PR. Removing the async-h1 and async-std dependency is the most important todo for this crate. However, I'm hesitant to move forward with the approach taken here for a few reasons:
I'm admittedly a bit slow at resolving #19, because it seems like that entails implementing a tiny futures based http client, that does not depend on either async-std or tokio. I'm working on it though... I'm open to suggestions or help on that front. I haven't found any popular ones that meet those criteria.
I realize that there is also the question of the underlying method that triggers wakers for timers and network connections. I tend to choose the async-io crate for that. That isn't a perfect solution, because some runtimes choose other crates or have their own implementation. But realistically it is a good lightweight solution and whether there are one or two threads running for that purpose doesn't seem like a big deal. I think this may be a "perfect is the enemy of good" situation for now. On that front I'm content waiting for ecosystem wide consolidation or a some high-level provider trait to emerge as quasi standard.
That's fair, unfortunately I waited for multiple years for any standardisation to happen and have somewhat given up on this. As I do need to get my dependency tree down, I have published a version that only supports tokio for now here: https://github.com/n0-computer/tokio-rustls-acme
I'm admittedly a bit slow at resolving #19, because it seems like that entails implementing a tiny futures based http client, that does not depend on either async-std or tokio. I'm working on it though... I'm open to suggestions or help on that front. I haven't found any popular ones that meet those criteria.
That is pretty painful, last time I tried. I worked on surf
for a while, which originally supported hyper/tokio and async-std/async-h1. Abstracting over these was quite complex and painful, which is why surf
now doesn't support hyper anymore.
Removes async-std/smol specific deps when using the tokio feature, and uses the tokio specific versions of the deps when the tokio features is enabeld.