Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing data Notification Rule name is not mandatory #653

Closed
johnaohara opened this issue Sep 18, 2023 · 3 comments
Closed

Missing data Notification Rule name is not mandatory #653

johnaohara opened this issue Sep 18, 2023 · 3 comments
Assignees
Labels
branch/master The master branch type/bug Something isn't working

Comments

@johnaohara
Copy link
Member

The rule "Name" field for Missing data notifications is not mandatory

image

This is inconsistent with other forms

@johnaohara johnaohara added type/bug Something isn't working branch/master The master branch labels Sep 18, 2023
@stalep
Copy link
Member

stalep commented Sep 18, 2023

Hm, so NotificationSettings.name is annoted with @JsonProperty( required = true )
According to this: https://stackoverflow.com/questions/45867473/should-you-use-notnull-and-jsonpropertyrequired-in-the-same-object
It will not do any validation. So we either need to continue to use Bean Validation with @NotNull or Swagger with @ApiModelProperty

@stalep
Copy link
Member

stalep commented Sep 18, 2023

I assume there are more fields like this we do not validate any longer...

@johnaohara
Copy link
Member Author

Hm, so NotificationSettings.name is annoted with @JsonProperty( required = true ) According to this: https://stackoverflow.com/questions/45867473/should-you-use-notnull-and-jsonpropertyrequired-in-the-same-object It will not do any validation. So we either need to continue to use Bean Validation with @NotNull or Swagger with @ApiModelProperty

@JsonProperty( required = true ) just means it should be in the json object when it is deserialized/serialized, nothing about its value

@stalep stalep self-assigned this Sep 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
branch/master The master branch type/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants