Closed bartoszlenar closed 2 years ago
After a lot of offline discussions, I decided to postpone it a little bit. In the vast majority of cases, async/await support is not needed. There are only two justifications for that:
And Validot doesn't support this approach either now and in the foreseeable future. The validation logic should be quick and straightforward (or at least static) without calling external services or querying remote databases.
In this case, Validot follows a different path than FluentValidation.
This is a valid case, described in this issue's description. However, it's a low priority matter.
I'm closing this down. Validot will not be supporting awaitable predicates as rules.
Large collections are a separate issue and I've heard user voices encouraging me to address it... but I don't think that anything similar to WithAsyncStrategy
is the solution.
Most probably it will be handled with a separate, dedicated validator. Imagine something more like:
var collectionValidator = ValidatorFactory.CreateForCollections(specification);
var results = await collectionsValidator.Validate(largeCollection);
Feature description
Validate
method.Feature in action
Feature details
AsCollection
).