-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Validation.Integration.WCF naturally does not support async methods decorated with [OperationContract].
This blog post describes the path to add support for async Begin/End pattern.
https://philippetruche.wordpress.com/2008/07/14/using-the-enterprise-library-validation-block-with-wcf-asynchronous-operations/
Adding support async methods returning Task or Task<T> is similar.
In addition to checking on operation.SyncMethod it should also check operation.TaskMethod.
I've been using that check for ~2 years now with net472 projects, but we want to migrate to .netstandard projects and possibly avoid maintaining my own fork of Validation.Integration.WCF.
E.g.
ValidationBehavior.HasValidationAssertions(OperationDescription operation)
{
MethodInfo methodInfo = operation.SyncMethod ?? operation.Task;
...
}
public ValidationParameterInspector(OperationDescription operation, string ruleSet)
{
MethodInfo method = operation.SyncMethod ?? operation.Task;
...
}icnocop and kronic
Metadata
Metadata
Assignees
Labels
No labels