Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: AsyncRead/AsyncWrite support? #86

Open
1 task done
Schniz opened this issue Jun 12, 2023 · 1 comment
Open
1 task done

[Feature]: AsyncRead/AsyncWrite support? #86

Schniz opened this issue Jun 12, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@Schniz
Copy link

Schniz commented Jun 12, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Description

Right now, all the functions support Read and Write traits. When using async Rust, it would probably be better to support AsyncRead and AsyncWrite. I wonder if that's something you'll be willing to accept.

We can obviously feature flag this, and make it experimental at first. But I wanted to know what you think.

Acceptance Criteria

  • Supporting AsyncRead implementations in ciborium
  • Supporting AsyncRead in ciborium-ll, or even Stream?

Suggestions for a technical implementation

Having a future feature flag to not add burden of current apps that don't need async support.

@Schniz Schniz added the enhancement New feature or request label Jun 12, 2023
@ahmedcharles
Copy link
Contributor

Serde doesn't have a mechanism for restarting once an error has happened, so supporting async traits for the serde portion of the library doesn't make sense. For the low level library, I think it would be sufficient for it to work on &[u8], since the library doesn't block in any other way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: New
Development

No branches or pull requests

2 participants