Open drewda opened 8 years ago
I'm trying to integrate static feeds, realtime feeds and routing APIs from several public transportation operators/providers in Europe, so I have similar goals.
I need these stable IDs to have at least two properties:
As with any "one standard to obsolete all other existing ones", this ID scheme won't be perfect. There will likely be revised (but incompatible) 2nd version in the future, and therefore >=2 IDs for an entity.
I think the only reasonable way towards a globally stable, globally agreed-upon ID scheme is to store both the current best-effort of a stable ID (in order to gain experience with edge cases) as well as multiple local IDs (in order to keep compatibility with existing systems).
This is only remotely related, but the IPFS community has a lot how, on a meta-level, make addresses & address schemes future-proof (i.e. self-describing, upgradable):
We could use e.g. the multiaddr markup to encode multiple IDs of a operator/station/trip into one "package".
We've heard from at least two different users of Transitland that it would be helpful to provide stable identifiers for trips (or at least identifiers that are more stable than those included in many GTFS feeds'
trips.txt
file):@barbeau wrote in January:
Here’s the link on the need for trip hashing in OneBusAway:
and more recently we heard from a transit agency (https://hellomapzen.zendesk.com/agent/tickets/808):
At present, we just include trip IDs as strings on
RouteStopPattern
s and onScheduleStopPair
s.Ideas to consider for the future:
RouteStopPattern
with a final component that represents the start time of the trip. This one make the overall Onestop ID unique by route + stop sequence + geometry + start time.RouteStopPattern
s,Stop
s, etc.One major question to answer would be how long we persist IDs and records for trips. Erase them whenever we erase an old
FeedVersion
'sScheduleStopPair
s? Or keep the trips, along withRouteStopPattern
s to summarize past configurations of the transit network (even if service is no longer scheduled for some of those combinations)?Timeframe: Not urgent.