Fork me on GitHub

reproducible-build:strip-jaxb

Full name:

io.github.zlika:reproducible-build-maven-plugin:0.16:strip-jaxb

Description:

Normalizes ObjectFactory java files generated by the JAXB xjc tool and removes timestamps from JAXB generated files.

Attributes:

  • Requires a Maven project to be executed.
  • The goal is thread-safe and supports parallel builds.
  • Binds by default to the lifecycle phase: process-sources.

Required Parameters

Name Type Since Description
<generatedDirectory> File - Directory where to find the source files generated by xjc.
Default value is: ${project.build.directory}/generated-sources.
User property is: reproducible.generatedDirectory.

Optional Parameters

Name Type Since Description
<encoding> String - The file encoding to use when reading the source files. If the property project.build.sourceEncoding is not set, the platform default encoding is used.
Default value is: ${project.build.sourceEncoding}.
<fixJaxbOrder> boolean - Fixes ObjectFactory java files generated by the JAXB xjc tool. xjc (before JAXB 2.2.11) generates ObjectFactory.java files where the methods are put in a non-predictable order (cf.https://java.net/jira/browse/JAXB-598). If true, the methods in ObjectFactory.java file will be sorted in a reproducible order.
Default value is: true.
User property is: reproducible.fixJaxbOrder.
<matchingCommentText> String - Text which allow to identify the files generated by the JAXB xjc tool. If provided, value is appended to the list of values defined in the known xjc generators.
User property is: reproducible.matchingCommentText.
<removeJaxbTimestamps> boolean - If true, the timestamps generated by JAXB will be removed.
Default value is: true.
User property is: reproducible.removeJaxbTimestamps.
<skip> boolean - If true, skips the execution of the goal.
Default value is: false.
User property is: reproducible.skip.

Parameter Details

<encoding>

The file encoding to use when reading the source files. If the property project.build.sourceEncoding is not set, the platform default encoding is used.
  • Type: java.lang.String
  • Required: No
  • Default: ${project.build.sourceEncoding}

<fixJaxbOrder>

Fixes ObjectFactory java files generated by the JAXB xjc tool. xjc (before JAXB 2.2.11) generates ObjectFactory.java files where the methods are put in a non-predictable order (cf.https://java.net/jira/browse/JAXB-598). If true, the methods in ObjectFactory.java file will be sorted in a reproducible order.
  • Type: boolean
  • Required: No
  • User Property: reproducible.fixJaxbOrder
  • Default: true

<generatedDirectory>

Directory where to find the source files generated by xjc.
  • Type: java.io.File
  • Required: Yes
  • User Property: reproducible.generatedDirectory
  • Default: ${project.build.directory}/generated-sources

<matchingCommentText>

Text which allow to identify the files generated by the JAXB xjc tool. If provided, value is appended to the list of values defined in the known xjc generators.
  • Type: java.lang.String
  • Required: No
  • User Property: reproducible.matchingCommentText

<removeJaxbTimestamps>

If true, the timestamps generated by JAXB will be removed.
  • Type: boolean
  • Required: No
  • User Property: reproducible.removeJaxbTimestamps
  • Default: true

<skip>

If true, skips the execution of the goal.
  • Type: boolean
  • Required: No
  • User Property: reproducible.skip
  • Default: false