Skip to content

Automatically execute middleware validations when configuration struct uses custom validation #264

@hariso

Description

@hariso

Feature description

It's basically this: ConduitIO/conduit-connector-postgres#247.

If a configuration structs has custom validation (i.e. implements the Validate(ctx) method), then the SDK does not call the Validate() methods in the middleware. Because of that, a custom Validate(ctx) always needs to call DefaultXYZMiddleware.Validate() explicitly. It's easy to forget, but the SDK should be able to do automatically. There doesn't seem to be a case where a developer would like to override or completely skip the middleware validation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew feature or request

    Type

    No type

    Projects

    Status

    No status

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions