swagger-api / swagger-api/swagger-codegen
swagger-codegen-cli-3.0.8 generation with 3 separated yaml
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Description
Unable to have a correct Java generation with 3 separated yaml files
Swagger-codegen version
swagger-codegen-cli-3.0.8.jar
Swagger declaration file content or url
First Yaml:
https://1drv.ms/u/s!ApK-i4jlhHB-qmpjQUB6GHoRqHyO?e=Q5TO2i
Second Yaml
https://1drv.ms/u/s!ApK-i4jlhHB-qmk_7jRkPQzsiKCg?e=iTuQgr
Last Yaml:
https://1drv.ms/u/s!ApK-i4jlhHB-qmtFRbziMmQkTYMr?e=07QeT3
Command line used for generation
java -jar ../../../python/External/swagger-codegen-cli-3.0.8.jar generate -i ../../../python/Development/APIDefinition/OAS_v3/Blue.yaml -l java -o Blue
java -jar ../../../python/External/swagger-codegen-cli-3.0.8.jar generate -i ../../../python/Development/APIDefinition/OAS_v3/EntityModels.yaml -l java -o Blue
java -jar ../../../python/External/swagger-codegen-cli-3.0.8.jar generate -i ../../../python/Development/APIDefinition/OAS_v3/Models.yaml -l java -o Blue
When I generate 3 projects java, I saw that for example in my First yaml "Blue.yaml" I use Entity, but I didn't have the really declaration of the Entity object that I described in the second YAML.
My question is, how I can refer on the first yaml the type describe in the second yaml "EntityModels.yaml" and generate only one project Java with all type plz ?
Because for example in the "Blue" java generated project the "Entity" java class of the BulkOperation object haven't the attributes/properties declared in the second YAML.
Thank a lot and best regards,
Adrien
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 three named inputs, Blue.yaml, EntityModels.yaml, and Models.yaml, and the swagger-codegen-cli-3.0.8 generate commands. Check how the generator handles references or definitions across separate OpenAPI files and whether one invocation can produce the requested Java project. Done means the generated Blue project contains Entity with the properties declared in EntityModels.yaml.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, openapi
- Domain
- backend-api-design
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100