datacater icon indicating copy to clipboard operation
datacater copied to clipboard

Enhance the payload validation for user facing apis

Open ChrisRousey opened this issue 3 years ago • 1 comments

As of now, when a user sends an api request containing a payload for the given reosurce (stream, dpeloyment, config, pipeline), we have some validating in place for fields like stream->partitions, replication factor, but for others we have very little validation like deployment->partitions.

We sould increase the robustness of the api by adding validations for resource fields.

This issue entails:

  • Analyzing resources as to possible payload fields
  • writing validaiton requirements for these fields and implementing them
  • Returning errors to the user when a validation is not met

ChrisRousey avatar Mar 03 '23 14:03 ChrisRousey

Thanks for the issue!

Do you think better validation of input via Jackson Annotations https://github.com/FasterXML/jackson-annotations could help?

Or are we lacking semantic validation?

Do you have examples?

hknlof avatar Mar 06 '23 14:03 hknlof