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 REQ] Fluent Strongly Typed Context #17252

Closed
MhAllan opened this issue Dec 1, 2020 · 1 comment
Closed

[FEATURE REQ] Fluent Strongly Typed Context #17252

MhAllan opened this issue Dec 1, 2020 · 1 comment
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that

Comments

@MhAllan
Copy link

MhAllan commented Dec 1, 2020

We have two problems with C# sdk
1- It is not strongly typed
2- It is unreadable, long methods and too much attributes

Suggestion suppose people to put Activities in interface or class. the the IDurableOrchestrationContext should be able to produce proxy for strongly typed methods

let's instead of

class ActivityClass
{
    [FunctionName(nameof(MethodName))]
    public Task<string> MethodName(int x)
}
//orchestrator
context.CallActivityWithRetryAsync<T>(nameof(ActivityClass.MethodName), retryOptions, input);

We should be able to do:

class ActivityClass
{
    public Task<string> MethodName(int x)
}
//orchestrator
context.ClientOf<AcitivyClass>().WithRetry(retryOptions).MethodName(x: 10);

Will be great

@ghost ghost added needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Dec 1, 2020
@MhAllan
Copy link
Author

MhAllan commented Dec 1, 2020

Meant to be for Azure Functions .Net SDK : Azure/azure-functions-dotnet-extensions#56

@MhAllan MhAllan closed this as completed Dec 1, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Mar 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Projects
None yet
Development

No branches or pull requests

1 participant