Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Sendless futures#1372

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
hamiltop wants to merge2 commits intoasync-graphql:master
base:master
Choose a base branch
Loading
fromhamiltop:sendless_futures

Conversation

hamiltop
Copy link

Per#723 it may be useful to have an environment without Send and Sync.

This was a bit of slog, but it wasn't actually that bad. The main things that were needed:

  1. useasync_trait::async_trait(?Send)
  2. removeSend andSync bounds almost everywhere.
  3. useLocalBoxFuture instead ofBoxFuture
  4. use.boxed_local() instead of.boxed()
  5. usetokio::task::spawn_local() instead oftokio::spawn(). Also add sometokio::task::TaskSets where needed.
  6. Get rid of a pesky lazy staticTEST_HARNESS.

Overall it was mostly straightforward. Everything compiles and all tests pass.

If someone can confirm this is actually useful I'm happy to take a second pass and try and make it configurable via a feature flag.

This is mostly a PoC. We'll want to get this all behind a feature flagso multi-threaded environments can still require Send.
If this is usefull, I'll go back and try to make this configurable by a feature-flag
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

1 participant
@hamiltop

[8]ページ先頭

©2009-2025 Movatter.jp