Skip to content
This repository has been archived by the owner on May 15, 2018. It is now read-only.

Compatibility with tokio crate (not tokio-core) #31

Closed
Kixunil opened this issue Mar 12, 2018 · 6 comments
Closed

Compatibility with tokio crate (not tokio-core) #31

Kixunil opened this issue Mar 12, 2018 · 6 comments

Comments

@Kixunil
Copy link
Contributor

Kixunil commented Mar 12, 2018

This crate still requires handle for UnixStream, UnixStream and UnixDatagram constructors (connect, bind, pair...)

It should be changed to support tokio crate and the new style of writing Tokio-based services.

@maufl
Copy link

maufl commented Mar 23, 2018

Is there a workaround until tokio-uds is updated? Or is it not possible to use it with the tokio crate right now?

@carllerche
Copy link
Member

There is an open PR to update: #29

@maufl You can always use tokio-uds w/ tokio-core as tokio-core uses tokio + Runtime under the hood. That said, it would be better to get tokio-uds updated now 👍

@maufl
Copy link

maufl commented Mar 23, 2018

@carllerche Agree, but I'm not only asking because of tokio-uds but all the other tokio crates too. This is probably the wrong place, but if I want to start using tokio::run and tokio::spawn, is there a way to get a Handle to the reactor of the runtime so that I can continue using existing tokio crates? Or is this not possible without creating a reactor using tokio-core?

@carllerche
Copy link
Member

It is not possible to go from tokio::run -> tokio_core::Handle. Only the other way around.

@maufl
Copy link

maufl commented Mar 23, 2018

Thanks, that answers my question.

@carllerche
Copy link
Member

This issue should be resolved by the misc PRs that landed. There will be a release shortly. Thanks all.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants