Skip to content

Conversation

@jakejscott
Copy link
Contributor

Fixes DI for the asp.net sample

  1. Closes Fix aspnet DI sample #47

  2. How was this tested:
    Manually by running the web and worker and hitting http://localhost:5000

  3. Any docs updates needed?
    N/A

@cretz
Copy link
Member

cretz commented Dec 13, 2023

This was already using DI. Based on https://stackoverflow.com/questions/43240405/async-provider-in-net-core-di and others I've seen, they suggest that async be deferred until needed hence why I put the task in the container (though in retrospect maybe it should have been a lazy task).

I wonder if TemporalClientAdapter or TemporalClientProvider or whatever is something we should add to Temporalio.Extensions.Hosting. But it'd just be a lazy wrapper.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix aspnet DI sample

2 participants