Read translations from GTFS and Netex sources for stop names - #3808
Conversation
…on.TranslationServiceImpl
…Planner into stopNameTranslation
d461053 to
c31b3c8
Compare
| return getValue( | ||
| environment, | ||
| stop -> { | ||
| return stop.getName().toString(lang == null ? environment.getLocale() : new Locale(lang)); |
There was a problem hiding this comment.
I think there is quite a bit of duplication here and in the URL. Can you make this a little DRY?
There was a problem hiding this comment.
This uses LegacyGraphQLUtils.getLocale now
…TripPlanner into otp2_read_netex_translations
This should be fixed now |
Co-authored-by: Joel Lappalainen <lappalj8@gmail.com>
|
Fetching stop urls when they are not defined in data still causes NPE: |
optionsome
left a comment
There was a problem hiding this comment.
Thanks for doing these changes. Everything seems to work now and the code looks good. Just one question, do we need to update the serialization version due to the String -> I18NString type change in the stop model?
True. Done! |
|
I think the serialization version was also changed to 19 in dev-2.x, you have to update it again. We could discuss today in the developer meeting if it would be possible to automate the serialization version update similarly as we have done with the changelog (maybe based on some label of a merged pr?). |
Summary
Read translations for stop names from Netex feeds and expose them through the Transmodel API.
Issue
Built on top of #3781
Unit tests
None included
Code style
✅
Documentation
Transmodel API description added
Changelog
The changelog file
is generated from the pull-request title, make sure the title describe the feature or issue fixed.
To exclude the PR from the changelog add
[changelog skip]in the title.