Adding Java EE 7 Batch Addon to JBoss Forge ? – Part 6 (Tech Tip #40)
This is the sixth part (part 1, part 2, part 3, part 4, part 5) of a multi-part video series where Lincoln Baxter (@lincolnthree) and I are interactively building a Forge addon to add Java EE 7 Batch functionality.
Part 1 showed how to get started with creating an addon, add relevant POM dependencies, build and install the addon using Forge shell, add a new command
batch-new-jobxml, and add
--writer parameters to the newly added command.
Part 2 showed how to identify classes for each CLI parameter that already honor the contract required by the Batch specification.
Part 3 showed how parameters can be made required, created templates for reader, processor, and writer, validated the specified parameters.
Part 4 added a new test for the command and showed how Forge can be used in debug mode.
Part 5 fixed a bug reported by a community member and started work to make processor validation optional.
This part shows:
- Upgrade from Forge 2.6.0 to 2.7.1
- Fix the failing test
- Reader, processor, and writer files are now templates instead of source files
- Reader, processor, and writer are injected appropriately in test's temp project
As always, the evolving source code is available at github.com/javaee-samples/forge-addons. The debugging will continue in the next episode.