Add support for NeTex DatedServiceJourneys - #3889
Conversation
t2gran
left a comment
There was a problem hiding this comment.
We should probably test this, with a dataset with DSJ.
dcef10b to
0a08dbd
Compare
e2c84c8 to
988b82f
Compare
I tried reproducing this after @t2gran's PR and that seems to have fixed the issue. If it's still a problem let me know. |
I did fix it, an operating-day (any entity) must be in the same file (group file) or one of its parents, shared group file or shared file. |
e83c2e1 to
72abcfb
Compare
|
@JonathanBrynhagen For next time, I would prefer if you did not "force push" after we have gone fare into the review process😀. I makes it harder to review. |
* Mapping DatedServiceJourney from NeTEx to a TripOnServiceDate object * Created GraphQL endpoint for fetching DatedServiceJourney * Added DatedServiceJourney field to leg in the GraphQL plan response * Added fields containing TripOnServiceDate in TimetableSnapshot when updating with SIRI-realtime
72abcfb to
8a7ebd9
Compare

Summary
Created a new object
TripOnServiceDateto represent a DatedServiceJourney and adds these to the graph index by creating two new maps.One is indexed using datedServiceJourneyId and the other using a tuple of tripId and serviceDate. Both return a single TripOnServiceDate.
TripOnServiceDates are also indexed in TimetableSnapshots for when there are realtime updates.
A new GraphQL endpoint is added called datedServiceJourney with which you can retrieve a datedServiceJourney from the graph index (or TimetableSnapshot if there are realtime updates) using a datedServiceJourneyId.
Additionally a field is added to the LegType where you can now retrieve the datedServiceJourney used in that leg aswell following the same logic as above.
Unit tests
A new unit test was added asserting that TripOnServiceDate objects are correctly created during NeTEx mapping.
Code style
Followed the code style included in the repo
Related issue #3150