New Normalizer: REMOVE_FILTER #22228
Conversation
Improve exception handling and tests.
…ed-normalizer # Conflicts: # modules/openapi-generator/src/main/java/org/openapitools/codegen/OpenAPINormalizer.java # modules/openapi-generator/src/test/java/org/openapitools/codegen/OpenAPINormalizerTest.java
Add handling of x- filter
|
thanks for the PR the first thing that comes to my mind is whether we can leverage the existing FILTER by updating that to support removing schema instead? that way we can avoid maintaining 2 filters that have very similar functionalities. e.g. |
|
@wing328 Thanks for your comment. The main goal of this PR is to remove undesired part of the specification. I think we agree that it is a valuable feature. FILTER is similar to redocly Using An option is to rename The challenge is to find a syntax that is clear and simple enough to be put on the command line. |
if that's the case, why not simply use redocly to pre-process the spec first? |
|
Redocly is a bit heavy to run under Maven. I prefer adding a few config to thé openapi-génératif -maven -plugin. I wanted to say that filter(~in) is different than this filterîng out |
Implement #22227
PR checklist
Commit all changed files.
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*.IMPORTANT: Do NOT purge/delete any folders/files (e.g. tests) when regenerating the samples as manually written tests may be removed.
master(upcoming7.x.0minor release - breaking changes with fallbacks),8.0.x(breaking changes without fallbacks)"fixes #123"present in the PR description)