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

Improve API browser for several resources #6955

Merged
merged 1 commit into from Dec 10, 2019
Merged

Conversation

@mpfz0r
Copy link
Member

mpfz0r commented Dec 9, 2019

Most event resources were either missing @ApiParam annotations
or their models were not annotated with @JsonAutoDetect.

Both are needed to show meaningful model data in swagger.

Also add the word legacy to the old alarm callback resources, so API users are less confused.

Most event resources were either missing `@ApiParam` annotations
or their models were not annotated with `@JsonAutoDetect`.

Both are needed to show meaningful model data in swagger.
@mpfz0r mpfz0r requested review from bernd and edmundoa Dec 9, 2019
@bernd

This comment has been minimized.

Copy link
Member

bernd commented Dec 9, 2019

Most event resources were either missing @ApiParam annotations
or their models were not annotated with @JsonAutoDetect.

@mpfz0r We have to check every resource (and also database collection DTO) that didn't have the @JsonAutoDetect annotation before for changes. This might result in added fields in the JSON response for fields/methods that haven't been annotated with @JsonProperty before. (and add @JsonIgnore annotations for those)

@mpfz0r

This comment has been minimized.

Copy link
Member Author

mpfz0r commented Dec 9, 2019

Most event resources were either missing @ApiParam annotations
or their models were not annotated with @JsonAutoDetect.

@mpfz0r We have to check every resource (and also database collection DTO) that didn't have the @JsonAutoDetect annotation before for changes. This might result in added fields in the JSON response for fields/methods that haven't been annotated with @JsonProperty before. (and add @JsonIgnore annotations for those)

Thanks for the heads up. I'll check that.

@mpfz0r mpfz0r removed the ready-for-review label Dec 9, 2019
@mpfz0r

This comment has been minimized.

Copy link
Member Author

mpfz0r commented Dec 9, 2019

Most event resources were either missing @ApiParam annotations
or their models were not annotated with @JsonAutoDetect.

@mpfz0r We have to check every resource (and also database collection DTO) that didn't have the @JsonAutoDetect annotation before for changes. This might result in added fields in the JSON response for fields/methods that haven't been annotated with @JsonProperty before. (and add @JsonIgnore annotations for those)

Thanks for the heads up. I'll check that.

Checked all models, don't see a difference

@bernd
bernd approved these changes Dec 10, 2019
@bernd bernd self-assigned this Dec 10, 2019
@bernd bernd added this to the 3.2.0 milestone Dec 10, 2019
@bernd bernd merged commit 4fe82c2 into master Dec 10, 2019
4 checks passed
4 checks passed
ci-web-linter Jenkins build graylog-pr-linter-check 5414 has succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
graylog-project/pr Jenkins build graylog-project-pr-snapshot 7193 has succeeded
Details
license/cla Contributor License Agreement is signed.
Details
@bernd bernd deleted the add-missing-resource-annotations branch Dec 10, 2019
mpfz0r added a commit that referenced this pull request Jan 13, 2020
Most event resources were either missing `@ApiParam` annotations
or their models were not annotated with `@JsonAutoDetect`.

Both are needed to show meaningful model data in swagger.

Fixes #6742

(cherry picked from commit 4fe82c2)
bernd added a commit that referenced this pull request Jan 13, 2020
Most event resources were either missing `@ApiParam` annotations
or their models were not annotated with `@JsonAutoDetect`.

Both are needed to show meaningful model data in swagger.

Fixes #6742

(cherry picked from commit 4fe82c2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.