Skip to content

Upgrade to netex2-java-model 3.0.0 (NeTEx 2.0) - #328

Merged
vpaturet merged 6 commits into
masterfrom
5.x
Oct 16, 2026
Merged

vpaturet merged 6 commits into
masterfrom
5.x

Conversation

@vpaturet

@vpaturet vpaturet commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Upgrade the parser to the NeTEx 2.0 model published by entur/netex-java-model#270 as the new artifact org.entur:netex2-java-model 3.0.0. The parser version becomes 5.0.0.

Changes

  • Depend on org.entur:netex2-java-model 3.0.0 (released on Maven Central) instead of netex-java-model 2.x.
  • Move all imports from org.rutebanken.netex.model to org.entur.netex2.model.
  • Java baseline raised to 21, matching the model.
  • Adapt parsers to the NeTEx 2.0 model API: the substitution-group collection accessors lose their trailing underscore (getDayType_() → getDayType(), getLine_() → getLine(), ...), StopPlace and Parking list element types, new MultilingualString mixed-content API (see MultilingualStringHelper).
  • DatedServiceJourneys are indexed by service journey only when their JourneyRef is a ServiceJourneyRef; a missing journey ref no longer throws.
  • OperatingDay.calendarDate is now a LocalDate (xs:date mapping in the model).
  • CI: build with Java 21; remove the unused Artifactory credentials from the push workflow.

Verification

  • mvn package -PprettierCheck against netex2-java-model 3.0.0 from Maven Central: all 35 tests pass.
  • The POM passes the strict Maven Central PomChecker, so the jreleaser pomchecker / applyMavenCentralRules overrides are reverted to master's settings.

Not changed

  • renovate.json is left as on master. Its rule disabling model bumps on 3.x still refers to the old artifact, which is correct for that branch.

- Bump project version to 5.0.0-SNAPSHOT
- Update netex-java-model dependency to 3.0.0-SNAPSHOT
- Add Maven Central snapshot repository for SNAPSHOT resolution
- Adapt parsers for renamed methods (e.g. getXxx_() -> getXxx_Dummy())
- Handle StopPlace list type change (JAXBElement -> direct StopPlace)
- Handle Parking list type change (direct Parking -> JAXBElement)
- Handle DatedServiceJourney.getJourneyRef() change from List to single
- Add MultilingualStringHelper for new MultilingualString content API
- Configure CI for 5.x branch with snapshot publishing
- Remove unused Artifactory credentials from push workflow
…lock

Maven Central publishing fails because PomChecker rejects the
<repositories> block in the POM. Disable strict pomchecker validation
and applyMavenCentralRules on the nexus2 snapshot deployer.
netex-java-model 3.0.0-SNAPSHOT is compiled with Java 21 (class version
65.0), so the project and CI must use Java 21 as well.
- Depend on org.entur:netex2-java-model 3.0.0-SNAPSHOT instead of netex-java-model
- Move imports from org.rutebanken.netex.model to org.entur.netex2.model
- OperatingDay.calendarDate is now a LocalDate (xs:date mapping)
- Add missing ServiceJourneyRefStructure import in TimeTableFrameParser
- Document the new artifact and the Java 21 baseline in CLAUDE.md
@codecov-commenter

codecov-commenter commented Oct 13, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 68.96552% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.38%. Comparing base (e56f382) to head (0029e67).
⚠️ Report is 62 commits behind head on master.

Files with missing lines Patch % Lines
.../entur/netex/support/MultilingualStringHelper.java 45.45% 2 Missing and 4 partials ⚠️
...ntur/netex/loader/parser/TimeTableFrameParser.java 60.00% 0 Missing and 2 partials ⚠️
...org/entur/netex/loader/parser/SiteFrameParser.java 83.33% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master     #328      +/-   ##
============================================
- Coverage     89.28%   88.38%   -0.90%     
- Complexity      241      243       +2     
============================================
  Files            16       17       +1     
  Lines           821      835      +14     
  Branches         63       70       +7     
============================================
+ Hits            733      738       +5     
- Misses           63       65       +2     
- Partials         25       32       +7     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

…odel

netex-java-model PR #270 now hides the _Dummy suffix that xjc generated
for the NeTEx 2.0 substitution-group heads, so getDayType_Dummy(),
getRoute_Dummy(), getLine_Dummy(), ... are now getDayType(), getRoute(),
getLine(), ... Verified against the 3.0.0-20261014.093720-1 snapshot.
- Update netex2-java-model from 3.0.0-SNAPSHOT to 3.0.0
- Remove the Maven Central snapshot repository from the POM
- Restore strict jreleaser PomChecker and Maven Central rules, which
  were only relaxed to allow the snapshot repository
- Remove the 5.x-specific CI branch triggers and snapshot publishing
- Refer to netex2-java-model in the MultilingualStringHelper Javadoc
@vpaturet
vpaturet marked this pull request as ready for review October 16, 2026 09:37
@vpaturet
vpaturet merged commit 5195b04 into master Oct 16, 2026
1 check passed
@vpaturet
vpaturet deleted the 5.x branch October 16, 2026 09:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants