swagger-api / swagger-api/swagger-codegen
code generator compile error on generating camunda open api json
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
hi everyone
I'm using below configuration to generate camunda open api rest interfaces:
<plugin>
<groupId>io.swagger.codegen.v3</groupId>
<artifactId>swagger-codegen-maven-plugin</artifactId>
<version>3.0.30</version>
<executions>
<execution>
<goals>
<goal>generate</goal>
</goals>
<configuration>
<inputSpec>${project.basedir}/src/main/resources/openapi.json</inputSpec>
<output>${project.basedir}/src/main/java2</output>
<language>spring</language>
<library>spring-cloud</library>
<configOptions>
<generateForOpenFeign>true</generateForOpenFeign>
<interfaceOnly>true</interfaceOnly>
<dateLibrary>java8</dateLibrary>
</configOptions>
</configuration>
</execution>
</executions>
</plugin>
and I'm using camunda official open api json defined in below dependency. i put the json in my resources and generate the code.
<dependency>
<groupId>org.camunda.bpm</groupId>
<artifactId>camunda-engine-rest-openapi</artifactId>
<version>7.15.0</version>
</dependency>
but when it generates the code there is a compile error on ProcessInstaceApi class as below. seems like /n is not converted correctly.
(@Parameter(in = ParameterIn.DEFAULT, description = "Please note that if both processInstances and historicProcessInstanceQuery are provided,
then the resulting execution will be performed on the union of these sets.
**Unallowed property**: `processInstanceQuery`", schema=@Schema()) @Valid @RequestBody SetJobRetriesByProcessDto body) {
is there any problem with camunda open api json file? or the problem is in code generation?
thanks' in advance.
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
Start with the Maven swagger-codegen configuration, the copied openapi.json from camunda-engine-rest-openapi 7.15.0, and the generated ProcessInstaceApi class. Run the generation and compilation to isolate whether the multiline description is emitted incorrectly; done means the generated source compiles or the responsible input/output is clearly identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, spring
- Domain
- api, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100