Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop Time Events in the past should be kept #502

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kylerchin
Copy link

Maybe this should be recommended? This is extremely useful because it's helpful to have updates on when the train entered or left the station. Maybe we should state that past events should be the actual time in which the vehicle entered or left the stop.

Copy link

google-cla bot commented Sep 21, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@kylerchin kylerchin changed the title CHange to recommended to keep past events. Stop Time Events in the past should be kept Sep 21, 2024
@kylerchin
Copy link
Author

CLA issue should be fixed now! : 👍

@skinkie
Copy link
Contributor

skinkie commented Sep 21, 2024

-1 OpenGeo
It uses the wrong wording for what you want. Your intention is to receive information, thats fine. Your implementation an client is to fetch GTFS-RT at a regular interval. It may be that your update interval does not match the producers interval. What you want to describe is some sort of time to live for StopTimeEvents. Recommending to keep all historic StopTimeEvents bloats the GTFS tripUpdates distribution for no good reason, therefore it should not be recommended in the way you do.

@kylerchin
Copy link
Author

@skinkie There is good reason IMO to keep previous times, such as if a consumer server cold starts, or if a fault causes a significant loss in the cache data.

@skinkie
Copy link
Contributor

skinkie commented Sep 22, 2024

That is not a price to pay for the producer or all other consumers.

All these kinds of things could be fixed by a final implementation for Incrementality=DIFFERENTIAL, that would allow the majority of information be provided in tiny parts and your use case in the FULL_DATASET. Personally I think a HISTORY would be more appropriate.

@eliasmbd eliasmbd added Change: Clarification Revisions of the current specification to improve understanding. GTFS Realtime Issues and Pull Requests that focus on GTFS Realtime Status: Discussion Issues and Pull Requests that are currently being discussed and reviewed by the community. Support: Needs Feedback labels Sep 23, 2024
@miklcct
Copy link

miklcct commented Oct 8, 2024

I would say that past events should be kept as long as the trip hasn't been completed yet, otherwise consumers may have trouble working on delay propagation.

@gcamp
Copy link
Contributor

gcamp commented Oct 8, 2024

Can you explain how delay propagation is hard to do without the full trip?

@miklcct
Copy link

miklcct commented Oct 8, 2024

If a bus is running early, well ahead of its scheduled time, lacking previous information may well cause the system into impossible state like time running backwards.

For example, OpenTripPlanner allows you to configure an option when such things do happen.

@gcamp
Copy link
Contributor

gcamp commented Oct 8, 2024

That's already in the spec :

Producers should not drop a past StopTimeUpdate if it refers to a stop with a scheduled arrival time in the future for the given trip (i.e. the vehicle has passed the stop ahead of schedule), as otherwise it will be concluded that there is no update for this stop.

What is proposed here is that producers should keep all past items regardless of if they are running early or late.

@evansiroky
Copy link
Contributor

I agree that GTFS-RT should be reserved for realtime events only and not need to include historical data. A better way to communicate historical data would be via another standard, such as TIDES.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Change: Clarification Revisions of the current specification to improve understanding. GTFS Realtime Issues and Pull Requests that focus on GTFS Realtime Status: Discussion Issues and Pull Requests that are currently being discussed and reviewed by the community. Support: Needs Feedback
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants