OpenAPITools / OpenAPITools/openapi-generator
interfaceOnly and generateModelDocumentation configs are not working as expected
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
I'm using a openapi-generator-maven-plugin with jaxrs-cxf generator and the following configuration:
<groupId>org.openapitools</groupId>
<artifactId>openapi-generator-maven-plugin</artifactId>
<version>3.3.4</version>
<executions>
<execution>
<goals>
<goal>generate</goal>
</goals>
<configuration>
<inputSpec>${project.basedir}/src/main/resources/openapi.yaml</inputSpec>
<generatorName>jaxrs-cxf</generatorName>
<generateSupportingFiles>false</generateSupportingFiles>
<generateApiTests>false</generateApiTests>
<generateModelDocumentation>false</generateModelDocumentation>
<generateApiDocumentation>false</generateApiDocumentation>
<configOptions>
<sourceFolder>src/gen/java/main</sourceFolder>
<interfaceOnly>true</interfaceOnly>
</configOptions>
</configuration>
</execution>
</executions>
</plugin>
I do expect from configuration not to generate implementation classes as well as not to have annotation documentation in my models and apis, however they're still in place.
I've found other people having the same issue.
Is it a bug which hasn't been fixed or should I do smth different?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the Maven configuration using the referenced src/main/resources/openapi.yaml path, generatorName jaxrs-cxf, interfaceOnly, and documentation-generation settings. Inspect the generated API and model output to determine which options are ignored; done means implementation classes and annotation documentation are omitted as requested.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100