Skip to content

Parameter validation for Async methods #180

Open
@bgrainger

Description

@bgrainger

There are two general approaches for parameter validation (e.g., ArgumentNullException) with *Async methods:

  1. "Eagerly" throw the exception before the Task is created; this requires a non-async method that calls the async helper.
  2. Return a faulted Task holding the ArgumentException; this happens by default if parameter checking happens in an async method.

Test if ADO.NET providers differ in how they implement this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions