eclipse-ee4j / eclipse-ee4j/jaxb-ri

wsimport generates duplicate ObjectFactories for <xjcarg/> jars

Open
#930 4 comments 0 reactions 1 assignee View on GitHub

@glassfishrobot is already working on this.

Since Sep 21, 2018.

Component: xjc ObjectFactory Priority: Major Type: Improvement wsimport xjc
Dominant language
Java
Stars
222
Forks
131
Avg merge
2d 17h
Merged PRs (30d)
9

Description

When generating service artifacts with wsimport, any classes pre-generated using xjc still have ObjectFactories generated even though they're already in the xjc-generated jar. These ObjectFactories can be generated differently from each other, though they're referencing the same underlying type (i.e. nillable).

To work around this issue, the duplicates need to be deleted at build time, which isn't a maintainable approach long-term.

Ideally, wsimport should not generate any ObjectFactories or perhaps methods in the ObjectFactory which are already present in the xjc-built jar. Perhaps the episode file can be of some assitance here, since wsimport is smart enough not to create the .java files.

Environment

Windows 7 64-bit
JDK 1.6_30 (32-bit)
Core i5 670

Affected Versions

[2.1.7]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.