Skip to content

Commit 637683c

Browse files
committed
TripModifications final
1 parent c244ec0 commit 637683c

File tree

3 files changed

+6
-21
lines changed

3 files changed

+6
-21
lines changed

gtfs-realtime/proto/gtfs-realtime.proto

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,6 @@ message FeedEntity {
108108
optional TripUpdate trip_update = 3;
109109
optional VehiclePosition vehicle = 4;
110110
optional Alert alert = 5;
111-
112-
// NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future.
113111
optional Shape shape = 6;
114112
optional Stop stop = 7;
115113
optional TripModifications trip_modifications = 8;
@@ -1144,7 +1142,6 @@ message Stop {
11441142
extensions 9000 to 9999;
11451143
}
11461144

1147-
// NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future.
11481145
message TripModifications {
11491146
// A `Modification` message replaces a span of n stop times from each affected trip starting at `start_stop_selector`.
11501147
message Modification {
@@ -1167,6 +1164,7 @@ message TripModifications {
11671164
repeated ReplacementStop replacement_stops = 4;
11681165

11691166
// An `id` value from the `FeedEntity` message that contains the `Alert` describing this Modification for user-facing communication.
1167+
// NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future.
11701168
optional string service_alert_id = 5;
11711169

11721170
// This timestamp identifies the moment when the modification has last been changed.
@@ -1222,7 +1220,6 @@ message TripModifications {
12221220
extensions 9000 to 9999;
12231221
}
12241222

1225-
// NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future.
12261223
// Select a stop by stop sequence or by stop_id. At least one of the two values must be provided.
12271224
message StopSelector {
12281225
// Must be the same as in stop_times.txt in the corresponding GTFS feed.
@@ -1239,7 +1236,6 @@ message StopSelector {
12391236
extensions 9000 to 9999;
12401237
}
12411238

1242-
// NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future.
12431239
message ReplacementStop {
12441240
// The difference in seconds between the arrival time at this stop and the arrival time at the reference stop. The reference stop is the stop prior to start_stop_selector. If the modification begins at the first stop of the trip, then the first stop of the trip is the reference stop.
12451241
// This value MUST be monotonically increasing and may only be a negative number if the first stop of the original trip is the reference stop.

gtfs-realtime/spec/en/reference.md

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -135,9 +135,9 @@ A definition (or update) of an entity in the transit feed. If the entity is not
135135
| **trip_update** | [TripUpdate](#message-tripupdate) | Conditionally required | One | Data about the realtime departure delays of a trip. At least one of the fields trip_update, vehicle, alert, or shape must be provided - all these fields cannot be empty. |
136136
| **vehicle** | [VehiclePosition](#message-vehicleposition) | Conditionally required | One | Data about the realtime position of a vehicle. At least one of the fields trip_update, vehicle, alert, or shape must be provided - all these fields cannot be empty. |
137137
| **alert** | [Alert](#message-alert) | Conditionally required | One | Data about the realtime alert. At least one of the fields trip_update, vehicle, alert, or shape must be provided - all these fields cannot be empty. |
138-
| **shape** | [Shape](#message-shape) | Conditionally required | One | Data about the realtime added shapes, such as for a detour. At least one of the fields trip_update, vehicle, alert, or shape must be provided - all these fields cannot be empty. <br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future. |
139-
| **stop** | [Stop](#message-stop) | Conditionally required | One | A new stop added to the feed dynamically. <br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future. |
140-
| **trip_modifications** | [TripModifications)(#message-tripmodifications) | Conditionally required | One | List of trips affected by a particular modifications, such as a detour. <br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future. |
138+
| **shape** | [Shape](#message-shape) | Conditionally required | One | Data about the realtime added shapes, such as for a detour. At least one of the fields trip_update, vehicle, alert, or shape must be provided - all these fields cannot be empty. |
139+
| **stop** | [Stop](#message-stop) | Conditionally required | One | A new stop added to the feed dynamically. |
140+
| **trip_modifications** | [TripModifications](#message-tripmodifications) | Conditionally required | One | List of trips affected by a particular modifications, such as a detour. |
141141

142142

143143
## _message_ TripUpdate
@@ -655,8 +655,6 @@ Represents a new Stop added to the feed dynamically. All fields are as described
655655
## _message_ TripModifications
656656

657657
A `TripModifications` message identifies a list of similar trips which are all affected by particular modifications, such as a detour.
658-
659-
<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
660658

661659
[More about Trip Modifications...](trip-modifications.md)
662660

@@ -673,8 +671,6 @@ A `TripModifications` message identifies a list of similar trips which are all a
673671

674672
A `Modification` message describes changes to each affected trip starting at `start_stop_selector`.
675673

676-
<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
677-
678674
![](images/trip_modification.png)
679675
_An example showing the effect of a modification on a particular trip. This modification may also be applied to several other trips._
680676

@@ -690,15 +686,14 @@ _Propagated detour delays affect all stops following the end of a modification.
690686
| **end_stop_selector** | [StopSelector](#message-stopselector) | Conditionally required | One | The stop selector of the last stop of the original trip that is to be affected by this modification. The selection is inclusive, so if only one stop_time is replaced by that modification, `start_stop_selector` and `end_stop_selector` must be equivalent. If no stop_time is replaced, `end_stop_selector` must not be provided. It's otherwise required. |
691687
| **propagated_modification_delay** | [int32](https://protobuf.dev/programming-guides/proto2/#scalar) | Optional | One | The number of seconds of delay to add to all departure and arrival times subsequent to the last stop inserted by a modification. If a modification affects only the shape (i.e. neither `end_stop_selector` nor `replacement_stops` are provided), then the delay propagation begins at the subsequent stop after `start_stop_selector`. Can be a positive or negative number. If multiple modifications apply to the same trip, the delays accumulate as the trip advances. <br/><br/>If the value is not supplied, consumers MAY interpolate or infer the `propagated_modification_delay` based on other data. |
692688
| **replacement_stops** | [ReplacementStop](#message-replacementstop) | Optional | Many | A list of replacement stops, replacing those of the original trip. The length of the new stop times may be less, the same, or greater than the number of replaced stop times. |
693-
| **service_alert_id** | [string](https://protobuf.dev/programming-guides/proto2/#scalar) | Optional | One | An `id` value from the `FeedEntity` message that contains the `Alert` describing this Modification for user-facing communication. |
689+
| **service_alert_id** | [string](https://protobuf.dev/programming-guides/proto2/#scalar) | Optional | One | An `id` value from the `FeedEntity` message that contains the `Alert` describing this Modification for user-facing communication.<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
690+
|
694691
| **last_modified_time** | [uint64](https://protobuf.dev/programming-guides/proto2/#scalar) | Optional | One | This timestamp identifies the moment when the modification has last been changed. In POSIX time (i.e., number of seconds since January 1st 1970 00:00:00 UTC). |
695692

696693
## _message_ StopSelector
697694

698695
Selector for a stop. Either by `stop_id` or `stop_sequence`. At least one of the two values must be provided.
699696

700-
<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
701-
702697
**Fields**
703698

704699
| _**Field Name**_ | _**Type**_ | _**Required**_ | _**Cardinality**_ | _**Description**_ |
@@ -710,8 +705,6 @@ Selector for a stop. Either by `stop_id` or `stop_sequence`. At least one of the
710705

711706
List of selected trips with an associated shape.
712707

713-
<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
714-
715708
**Fields**
716709

717710
| _**Field Name**_ | _**Type**_ | _**Required**_ | _**Cardinality**_ | _**Description**_ |
@@ -723,8 +716,6 @@ List of selected trips with an associated shape.
723716

724717
Each `ReplacementStop` message defines a stop that will now be visited by the trip, and optionally specifies the estimated travel time to the stop.
725718

726-
<br><br>**Caution:** this field is still **experimental**, and subject to change. It may be formally adopted in the future.
727-
728719
![](images/first_stop_reference.png)
729720
_If a modification affects the first stop of the trip, that stop also serves as the reference stop of the modification._
730721

gtfs-realtime/spec/en/trip-modifications.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22

33
A `TripModifications` message identifies a list of similar `trip_ids` from the (CSV) GTFS which are all affected by particular modifications, such as a detour.
44

5-
<br><br>**Caution:** this entity is still **experimental**, and subject to change. It may be formally adopted in the future.
6-
75
## SLO: Service-level objective
86

97
The frequency of data updates is expected to be approximately hourly (~24 times/day). Ingestion time may depend on the total number of affected trips. Consumers are expected to ingest a single TripModification within 5 minutes, and a feed with hundreds of detours within 20 minutes.

0 commit comments

Comments
 (0)