This seems a lot like what the scala libraries Zio or Kyo are doing for concurrency, just without the functional effect part.