Repository navigation
Conversation
Extend the existing formatter and CI check to Maven POM files so contributors share one formatting baseline instead of IDE-specific output. Normalize the reactor POMs and document the formatting policy without changing dependencies or enabling dependency and plugin list sorting. Fixes apolloconfig#5701 Assisted-by: Claude Opus 5 (1M context)
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
Record the SortPom formatting change with its upstream PR URL. Assisted-by: Claude Opus 5 (1M context)
What's the purpose of this PR
Extend Apollo's existing Spotless formatting and CI check to Maven POM files, providing a shared baseline instead of IDE-specific indentation, wrapping, and element ordering.
Which issue(s) this PR fixes:
Fixes #5701
Brief changelog
<pom>formatter using SortPom to the root Spotless plugin configuration; each reactor module formats its ownpom.xmlthrough inheritance.recommended_2008_06element order, UTF-8, two-space indentation, and self-closing empty elements (expandEmptyElements=false).CONTRIBUTING.md. The existingmvn spotless:checkCI command now checks POMs as well; no separate workflow is needed.CHANGES.mdentry linking to this PR.The relevant formatting choices are compatible with the Google XML Style Guide, which permits two-space indentation and both empty-element forms and does not mandate a universal POM element order or fixed line width. IDE XML setting changes are out of scope; Spotless is the authoritative POM formatting baseline.
Test plan
Validated locally with JDK 17:
./mvnw -B spotless:apply spotless:check— all 14 reactor projects passed; no Java source changes../mvnw -B clean test— all reactor projects passed; 1,404 tests, 0 failures, 0 errors, 1 skipped.spotless:apply spotless:checkafter the clean build — passed and changed none of the 1,599 tracked files (SHA-256 comparison).master— configuration values and repeated-element order preserved; only the intended formatter block was added, with whitespace/comment formatting and structural POM element ordering changes.git diff --check— passed.Follow this checklist to help us incorporate your contribution quickly and easily:
mvn clean testto make sure this pull request doesn't break anything.mvn spotless:applyto format your code.CHANGESlog — added in a follow-up commit using this PR URL.🤖 Generated with Claude Code
Assisted-by: Claude Opus 5 (1M context)
Summary by CodeRabbit