swagger-api / swagger-api/swagger-codegen-generators
[java jaxrs-jersey] Entities missing JAXB annotations
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 299
- Forks
- 439
- PR merge metrics
- No merged PRs in 30d
Description
I'm using OAS 3.0.0, and I've generated a server stub for jaxrs-jersey. The JSON works great out of the box, but there are no JAXB annotations on the model entities, so the media type application/xml does not work out of the box. I've added them manually and got it to work, so I am certain that that is all that needs to happen to fix it.
There are also several unused imports in the template including other model entities in the same package, and there is a lot of extra whitespace in the templates. While not strictly necessary, it probably wouldn't hurt to clean that up a bit, too.
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 by locating the jaxrs-jersey templates that generate Java model entities and compare the generated output with the JAXB annotations needed for application/xml. Review the unused imports and extra whitespace mentioned in the templates as well. Done means generated entities support XML media types without manual edits and the template output is cleaned up.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100