• tatterdemalion@programming.dev
    link
    fedilink
    arrow-up
    1
    ·
    4 months ago

    I’m not sure what tokio (or axum) can do to avoid the trait bounds. Would it makes sense to provide a “share nothing” runtime implementation that can be injected at startup? I wonder how the intermediate layers (e.g. axum) would indicate that futures are usable by a more generic runtime which may or may not need Send + 'static.

    • Giooschi@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      4 months ago

      Would it makes sense to provide a “share nothing” runtime implementation that can be injected at startup?

      Isn’t this tokio::task::spawn_local?