@golemio/pid 4.0.2-dev.1982507419 → 4.0.2-rc.1988899397
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/helpers/GtfsStopParser.d.ts +0 -2
- package/dist/helpers/GtfsStopParser.js +8 -11
- package/dist/helpers/GtfsStopParser.js.map +1 -1
- package/dist/input-gateway/jis/controllers/JISEventsController.js +2 -1
- package/dist/input-gateway/jis/controllers/JISEventsController.js.map +1 -1
- package/dist/input-gateway/jis/controllers/JISInfotextsController.js +2 -1
- package/dist/input-gateway/jis/controllers/JISInfotextsController.js.map +1 -1
- package/dist/input-gateway/vehicle-positions/VehiclePositionsController.js +1 -0
- package/dist/input-gateway/vehicle-positions/VehiclePositionsController.js.map +1 -1
- package/dist/integration-engine/jis/ioc/Di.js +0 -10
- package/dist/integration-engine/jis/ioc/Di.js.map +1 -1
- package/dist/integration-engine/jis/ioc/JISContainerToken.d.ts +0 -4
- package/dist/integration-engine/jis/ioc/JISContainerToken.js +0 -5
- package/dist/integration-engine/jis/ioc/JISContainerToken.js.map +1 -1
- package/dist/integration-engine/jis/repositories/JISInfotextsRepository.d.ts +1 -6
- package/dist/integration-engine/jis/repositories/JISInfotextsRepository.js +2 -50
- package/dist/integration-engine/jis/repositories/JISInfotextsRepository.js.map +1 -1
- package/dist/integration-engine/jis/workers/JISWorker.js +0 -1
- package/dist/integration-engine/jis/workers/JISWorker.js.map +1 -1
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsTask.d.ts +2 -1
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsTask.js +4 -5
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsTask.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/RopidGTFSStopsModel.d.ts +1 -5
- package/dist/integration-engine/ropid-gtfs/RopidGTFSStopsModel.js +0 -24
- package/dist/integration-engine/ropid-gtfs/RopidGTFSStopsModel.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/data-access/cache/DelayComputationRedisRepository.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/index.d.ts +0 -1
- package/dist/integration-engine/ropid-gtfs/index.js +0 -1
- package/dist/integration-engine/ropid-gtfs/index.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/ioc/Di.js +0 -8
- package/dist/integration-engine/ropid-gtfs/ioc/Di.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/ioc/RopidGtfsContainerToken.d.ts +0 -3
- package/dist/integration-engine/ropid-gtfs/ioc/RopidGtfsContainerToken.js +0 -3
- package/dist/integration-engine/ropid-gtfs/ioc/RopidGtfsContainerToken.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/transformations/RopidDeparturesPresetsTransformation.js +1 -1
- package/dist/integration-engine/ropid-gtfs/transformations/RopidDeparturesPresetsTransformation.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/workers/timetables/TimetableWorker.js +0 -1
- package/dist/integration-engine/ropid-gtfs/workers/timetables/TimetableWorker.js.map +1 -1
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/CheckSavedRowsAndReplaceTablesTask.js +5 -8
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/CheckSavedRowsAndReplaceTablesTask.js.map +1 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/data-access/TripsRepository.js +0 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/data-access/TripsRepository.js.map +1 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/data-access/interfaces/TripRepositoryInterfaces.d.ts +1 -2
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/tasks/PropagateTrainDelayTask.js.map +1 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/tasks/RefreshPublicStopTimeCacheTask.js +0 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/tasks/RefreshPublicStopTimeCacheTask.js.map +1 -1
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/transformations/PublicApiTripTransformation.js +0 -2
- package/dist/integration-engine/vehicle-positions/workers/vehicle-positions/transformations/PublicApiTripTransformation.js.map +1 -1
- package/dist/output-gateway/index.js +0 -1
- package/dist/output-gateway/index.js.map +1 -1
- package/dist/output-gateway/jis/ioc/Di.js +2 -2
- package/dist/output-gateway/jis/ioc/Di.js.map +1 -1
- package/dist/output-gateway/jis/ioc/OgJisToken.d.ts +0 -2
- package/dist/output-gateway/jis/ioc/OgJisToken.js +0 -2
- package/dist/output-gateway/jis/ioc/OgJisToken.js.map +1 -1
- package/dist/output-gateway/pid/controllers/v3/V3TransferBoardsController.js.map +1 -1
- package/dist/output-gateway/pid/domain/InfotextInterfaces.d.ts +0 -5
- package/dist/output-gateway/pid/helpers/JISInfotextStopSuppressionFilter.d.ts +1 -4
- package/dist/output-gateway/pid/helpers/JISInfotextStopSuppressionFilter.js +1 -7
- package/dist/output-gateway/pid/helpers/JISInfotextStopSuppressionFilter.js.map +1 -1
- package/dist/output-gateway/pid/index.d.ts +0 -50
- package/dist/output-gateway/pid/index.js.map +1 -1
- package/dist/output-gateway/pid/ioc/Di.js +6 -62
- package/dist/output-gateway/pid/ioc/Di.js.map +1 -1
- package/dist/output-gateway/pid/ioc/OgPidToken.d.ts +0 -11
- package/dist/output-gateway/pid/ioc/OgPidToken.js +0 -11
- package/dist/output-gateway/pid/ioc/OgPidToken.js.map +1 -1
- package/dist/output-gateway/pid/routers/index.d.ts +0 -1
- package/dist/output-gateway/pid/routers/index.js +1 -3
- package/dist/output-gateway/pid/routers/index.js.map +1 -1
- package/dist/output-gateway/pid/service/facade/InfotextFacade.d.ts +2 -7
- package/dist/output-gateway/pid/service/facade/InfotextFacade.js +4 -29
- package/dist/output-gateway/pid/service/facade/InfotextFacade.js.map +1 -1
- package/dist/output-gateway/pid/service/facade/StopFacade.d.ts +3 -12
- package/dist/output-gateway/pid/service/facade/StopFacade.js +7 -43
- package/dist/output-gateway/pid/service/facade/StopFacade.js.map +1 -1
- package/dist/output-gateway/pid/service/facade/TransferFacade.d.ts +9 -11
- package/dist/output-gateway/pid/service/facade/TransferFacade.js +14 -117
- package/dist/output-gateway/pid/service/facade/TransferFacade.js.map +1 -1
- package/dist/output-gateway/pid/service/helpers/PlatformCodeResolver.d.ts +1 -7
- package/dist/output-gateway/pid/service/helpers/PlatformCodeResolver.js +0 -12
- package/dist/output-gateway/pid/service/helpers/PlatformCodeResolver.js.map +1 -1
- package/dist/output-gateway/public/data-access/redis/PublicGtfsDepartureRepository.d.ts +1 -1
- package/dist/output-gateway/public/data-access/redis/PublicGtfsDepartureRepository.js +4 -4
- package/dist/output-gateway/public/data-access/redis/PublicGtfsDepartureRepository.js.map +1 -1
- package/dist/output-gateway/public/ioc/Di.js +1 -1
- package/dist/output-gateway/public/ioc/Di.js.map +1 -1
- package/dist/output-gateway/{shared → public}/service/VPSubscriber.d.ts +2 -4
- package/dist/output-gateway/{shared → public}/service/VPSubscriber.js +1 -1
- package/dist/output-gateway/public/service/VPSubscriber.js.map +1 -0
- package/dist/output-gateway/shared/constants/route-version.d.ts +1 -2
- package/dist/output-gateway/shared/constants/route-version.js +0 -1
- package/dist/output-gateway/shared/constants/route-version.js.map +1 -1
- package/dist/schema-definitions/jis/redis/const.d.ts +0 -1
- package/dist/schema-definitions/jis/redis/const.js +1 -2
- package/dist/schema-definitions/jis/redis/const.js.map +1 -1
- package/dist/schema-definitions/ropid-departures-presets/index.d.ts +0 -1
- package/dist/schema-definitions/ropid-departures-presets/index.js +0 -3
- package/dist/schema-definitions/ropid-departures-presets/index.js.map +1 -1
- package/dist/schema-definitions/ropid-gtfs/interfaces/IStopDto.d.ts +0 -1
- package/dist/schema-definitions/ropid-gtfs/redis/const.d.ts +0 -1
- package/dist/schema-definitions/ropid-gtfs/redis/const.js +1 -2
- package/dist/schema-definitions/ropid-gtfs/redis/const.js.map +1 -1
- package/dist/schema-definitions/vehicle-positions/models/views/PublicStopTimeModel.d.ts +2 -3
- package/dist/schema-definitions/vehicle-positions/models/views/PublicStopTimeModel.js +0 -4
- package/dist/schema-definitions/vehicle-positions/models/views/PublicStopTimeModel.js.map +1 -1
- package/dist/schema-definitions/vehicle-positions/models/views/interfaces/IPublicStopTimeDto.d.ts +0 -1
- package/dist/schema-definitions/vehicle-positions/redis/interfaces/IPublicApiCacheDto.d.ts +0 -2
- package/dist/schema-definitions/vehicle-positions/redis/interfaces/IPublicStopTimeCacheDto.d.ts +0 -1
- package/dist/schema-definitions/vehicle-positions/redis/schemas/PublicApiCacheDtoSchema.js +0 -8
- package/dist/schema-definitions/vehicle-positions/redis/schemas/PublicApiCacheDtoSchema.js.map +1 -1
- package/dist/schema-definitions/vehicle-positions/redis/schemas/PublicStopTimeCacheDtoSchema.js +1 -4
- package/dist/schema-definitions/vehicle-positions/redis/schemas/PublicStopTimeCacheDtoSchema.js.map +1 -1
- package/docs/asyncapi.yaml +0 -45
- package/docs/cache/types/redis.md +2 -82
- package/docs/jis/index.md +5 -15
- package/docs/openapi-input.yaml +2 -13
- package/docs/openapi-output.yaml +4 -326
- package/package.json +2 -2
- package/db/example/redis/gtfsStopsCacheMock.json +0 -8
- package/db/example/redis/jisCacheMock.json +0 -31
- package/db/migrations/postgresql/20250716143052-add-stop-name-to-combined-stop-times.js +0 -53
- package/db/migrations/postgresql/sqls/20250716143052-add-stop-name-to-combined-stop-times-down.sql +0 -47
- package/db/migrations/postgresql/sqls/20250716143052-add-stop-name-to-combined-stop-times-up.sql +0 -47
- package/dist/helpers/jis/JISInfotextSeverityLevelPriority.d.ts +0 -6
- package/dist/helpers/jis/JISInfotextSeverityLevelPriority.js +0 -11
- package/dist/helpers/jis/JISInfotextSeverityLevelPriority.js.map +0 -1
- package/dist/integration-engine/jis/repositories/JISInfotextsRedisRepository.d.ts +0 -9
- package/dist/integration-engine/jis/repositories/JISInfotextsRedisRepository.js +0 -86
- package/dist/integration-engine/jis/repositories/JISInfotextsRedisRepository.js.map +0 -1
- package/dist/integration-engine/jis/transformations/JISInfotextCacheTranformation.d.ts +0 -7
- package/dist/integration-engine/jis/transformations/JISInfotextCacheTranformation.js +0 -37
- package/dist/integration-engine/jis/transformations/JISInfotextCacheTranformation.js.map +0 -1
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsCacheTask.d.ts +0 -13
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsCacheTask.js +0 -47
- package/dist/integration-engine/jis/workers/tasks/RefreshJISInfotextsCacheTask.js.map +0 -1
- package/dist/integration-engine/ropid-gtfs/RopidGTFSCisStopsModel.d.ts +0 -18
- package/dist/integration-engine/ropid-gtfs/RopidGTFSCisStopsModel.js +0 -44
- package/dist/integration-engine/ropid-gtfs/RopidGTFSCisStopsModel.js.map +0 -1
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/RefreshGtfsStopsCacheTask.d.ts +0 -12
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/RefreshGtfsStopsCacheTask.js +0 -44
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/RefreshGtfsStopsCacheTask.js.map +0 -1
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/data-access/cache/GtfsStopsRedisRepository.d.ts +0 -12
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/data-access/cache/GtfsStopsRedisRepository.js +0 -87
- package/dist/integration-engine/ropid-gtfs/workers/timetables/tasks/data-access/cache/GtfsStopsRedisRepository.js.map +0 -1
- package/dist/output-gateway/jis/data-access/cache/JISInfotextsRedisRepository.d.ts +0 -17
- package/dist/output-gateway/jis/data-access/cache/JISInfotextsRedisRepository.js +0 -113
- package/dist/output-gateway/jis/data-access/cache/JISInfotextsRedisRepository.js.map +0 -1
- package/dist/output-gateway/pid/controllers/v4/V4TransferBoardsController.d.ts +0 -17
- package/dist/output-gateway/pid/controllers/v4/V4TransferBoardsController.js +0 -154
- package/dist/output-gateway/pid/controllers/v4/V4TransferBoardsController.js.map +0 -1
- package/dist/output-gateway/pid/controllers/v4/interfaces/ITransferBoardsParams.d.ts +0 -14
- package/dist/output-gateway/pid/controllers/v4/interfaces/ITransferBoardsParams.js +0 -3
- package/dist/output-gateway/pid/controllers/v4/interfaces/ITransferBoardsParams.js.map +0 -1
- package/dist/output-gateway/pid/helpers/TransferBoardFilter.d.ts +0 -5
- package/dist/output-gateway/pid/helpers/TransferBoardFilter.js +0 -33
- package/dist/output-gateway/pid/helpers/TransferBoardFilter.js.map +0 -1
- package/dist/output-gateway/pid/helpers/TransferBoardSorter.d.ts +0 -6
- package/dist/output-gateway/pid/helpers/TransferBoardSorter.js +0 -61
- package/dist/output-gateway/pid/helpers/TransferBoardSorter.js.map +0 -1
- package/dist/output-gateway/pid/routers/v4/V4PIDRouter.d.ts +0 -16
- package/dist/output-gateway/pid/routers/v4/V4PIDRouter.js +0 -67
- package/dist/output-gateway/pid/routers/v4/V4PIDRouter.js.map +0 -1
- package/dist/output-gateway/pid/service/transformations/JISInfotextCacheTransferTransformation.d.ts +0 -13
- package/dist/output-gateway/pid/service/transformations/JISInfotextCacheTransferTransformation.js +0 -31
- package/dist/output-gateway/pid/service/transformations/JISInfotextCacheTransferTransformation.js.map +0 -1
- package/dist/output-gateway/pid/service/transformations/TransferDepartureCacheTransformation.d.ts +0 -27
- package/dist/output-gateway/pid/service/transformations/TransferDepartureCacheTransformation.js +0 -78
- package/dist/output-gateway/pid/service/transformations/TransferDepartureCacheTransformation.js.map +0 -1
- package/dist/output-gateway/ropid-gtfs/data-access/redis/GtfsStopsRedisRepository.d.ts +0 -13
- package/dist/output-gateway/ropid-gtfs/data-access/redis/GtfsStopsRedisRepository.js +0 -83
- package/dist/output-gateway/ropid-gtfs/data-access/redis/GtfsStopsRedisRepository.js.map +0 -1
- package/dist/output-gateway/shared/service/VPSubscriber.js.map +0 -1
- package/dist/schema-definitions/jis/redis/interfaces/IJISInfotextDto.d.ts +0 -17
- package/dist/schema-definitions/jis/redis/interfaces/IJISInfotextDto.js +0 -3
- package/dist/schema-definitions/jis/redis/interfaces/IJISInfotextDto.js.map +0 -1
- package/dist/schema-definitions/jis/redis/schemas/JISInfotextDtoSchema.d.ts +0 -3
- package/dist/schema-definitions/jis/redis/schemas/JISInfotextDtoSchema.js +0 -59
- package/dist/schema-definitions/jis/redis/schemas/JISInfotextDtoSchema.js.map +0 -1
- package/dist/schema-definitions/ropid-gtfs/interfaces/IStopCisDto.d.ts +0 -16
- package/dist/schema-definitions/ropid-gtfs/interfaces/IStopCisDto.js +0 -3
- package/dist/schema-definitions/ropid-gtfs/interfaces/IStopCisDto.js.map +0 -1
- package/dist/schema-definitions/ropid-gtfs/models/StopCisDto.d.ts +0 -58
- package/dist/schema-definitions/ropid-gtfs/models/StopCisDto.js +0 -69
- package/dist/schema-definitions/ropid-gtfs/models/StopCisDto.js.map +0 -1
package/docs/asyncapi.yaml
CHANGED
|
@@ -48,39 +48,6 @@ channels:
|
|
|
48
48
|
messages:
|
|
49
49
|
empty:
|
|
50
50
|
$ref: "#/components/messages/JISInfotexts"
|
|
51
|
-
jis.refreshJISInfotextsCache:
|
|
52
|
-
address: vehicle-positions.jis.refreshJISInfotextsCache
|
|
53
|
-
description: Refresh JIS infotexts cache in Redis (Valkey)
|
|
54
|
-
bindings:
|
|
55
|
-
amqp:
|
|
56
|
-
is: queue
|
|
57
|
-
queue:
|
|
58
|
-
durable: true
|
|
59
|
-
messages:
|
|
60
|
-
empty:
|
|
61
|
-
$ref: "#/components/messages/emptyMessage"
|
|
62
|
-
ropidgtfs.refreshPublicGtfsDepartureCache:
|
|
63
|
-
address: vehicle-positions.ropidgtfs.refreshPublicGtfsDepartureCache
|
|
64
|
-
description: Refresh PublicGtfsDepartureCache
|
|
65
|
-
bindings:
|
|
66
|
-
amqp:
|
|
67
|
-
is: queue
|
|
68
|
-
queue:
|
|
69
|
-
durable: true
|
|
70
|
-
messages:
|
|
71
|
-
empty:
|
|
72
|
-
$ref: "#/components/messages/emptyMessage"
|
|
73
|
-
ropidgtfs.refreshGtfsStopsCache:
|
|
74
|
-
address: vehicle-positions.ropidgtfs.refreshGtfsStopsCache
|
|
75
|
-
description: Refresh GtfsStopsCache
|
|
76
|
-
bindings:
|
|
77
|
-
amqp:
|
|
78
|
-
is: queue
|
|
79
|
-
queue:
|
|
80
|
-
durable: true
|
|
81
|
-
messages:
|
|
82
|
-
empty:
|
|
83
|
-
$ref: "#/components/messages/emptyMessage"
|
|
84
51
|
updateGTFSTripId:
|
|
85
52
|
address: vehicle-positions.vehiclepositions.updateGTFSTripId
|
|
86
53
|
description: some description
|
|
@@ -327,18 +294,6 @@ operations:
|
|
|
327
294
|
action: "send"
|
|
328
295
|
channel:
|
|
329
296
|
$ref: "#/channels/jis.refreshJISInfotexts"
|
|
330
|
-
jis.refreshJISInfotextsCache:
|
|
331
|
-
action: "send"
|
|
332
|
-
channel:
|
|
333
|
-
$ref: "#/channels/jis.refreshJISInfotextsCache"
|
|
334
|
-
ropidgtfs.refreshPublicGtfsDepartureCache:
|
|
335
|
-
action: "send"
|
|
336
|
-
channel:
|
|
337
|
-
$ref: "#/channels/ropidgtfs.refreshPublicGtfsDepartureCache"
|
|
338
|
-
ropidgtfs.refreshGtfsStopsCache:
|
|
339
|
-
action: "send"
|
|
340
|
-
channel:
|
|
341
|
-
$ref: "#/channels/ropidgtfs.refreshGtfsStopsCache"
|
|
342
297
|
updateGTFSTripId:
|
|
343
298
|
action: "send"
|
|
344
299
|
channel:
|
|
@@ -62,7 +62,7 @@ flowchart TD;
|
|
|
62
62
|
- Pomocný timestamp se načte pomocí `GET` a vrátí se jako hodnota hlavičky `Last-Modified` převedená na ISO string. Pokud timestamp neexistuje, hodnota hlavičky bude unix timestamp 0 jako ISO string. Využívá se především pro monitoring a alerting
|
|
63
63
|
- Feedy se generují nejméně 3x za minutu (rabín 2x) pomocí queue-message
|
|
64
64
|
- Používají redis-mutex na zamykání, aby neběželo více shodných tasků v jeden okamžik
|
|
65
|
-
- Pokud generování stíhá běžet rychleji, task se snaží do ±7 vteřin svého běhu spustit nové generování souborů (opět přes queue-message).
|
|
65
|
+
- Pokud generování stíhá běžet rychleji, task se snaží do ±7 vteřin svého běhu spustit nové generování souborů (opět přes queue-message).
|
|
66
66
|
|
|
67
67
|
### Flowchart
|
|
68
68
|
|
|
@@ -152,7 +152,6 @@ flowchart TD;
|
|
|
152
152
|
- `cis_stop_platform_code` - nástupiště/kolej podle CIS u vlakových zastávek, jinde null
|
|
153
153
|
- `platform_code` - označení zastávky podle GTFS
|
|
154
154
|
- `stop_id` - GTFS id zastávky
|
|
155
|
-
- `stop_name` - název zastávky
|
|
156
155
|
- TTL 1 hodina a 5 minut
|
|
157
156
|
- Automatické promazání dat po úspěšném načtení GTFS jíždních řádů
|
|
158
157
|
- Cca jednou za 5 vteřin se přenačtou stop times pro všechny aktivní spoje. Generování může běžet pouze jednou, po dokončení tasku se spustí znovu (max čekání 4.8 vteřin)
|
|
@@ -314,83 +313,4 @@ flowchart TD;
|
|
|
314
313
|
rt_info["Obohacení o RT informace"];
|
|
315
314
|
get_departures--"Alespoň jedno vozidlo připadá nějakému spoji (aktivní, budoucí i zrušené) na odjezdu"-->rt_info;
|
|
316
315
|
rt_info--"RT informace o spoji"-->redis_repository<-->redis_public_cache;
|
|
317
|
-
```
|
|
318
|
-
|
|
319
|
-
## Cache pro API přestupních tabulí (transfer boards)
|
|
320
|
-
|
|
321
|
-
*(přestupní tabule využívají také cache pro Public API, která je již popsána výše)*
|
|
322
|
-
|
|
323
|
-
### gtfsStopsCache:*
|
|
324
|
-
|
|
325
|
-
- Jednotlivé komponenty cache jsou členěny do sad s `$setId`
|
|
326
|
-
- `$setId` je id vygenerované datové sady (4 náhodné bajty reprezentované hexadecimálně)
|
|
327
|
-
- Nová sada je vytvořena při každém přenačtení cache
|
|
328
|
-
- Id `$setId` nejnovější datové sady se propaguje přes PubSub channel `gtfsStopsCache` a je také uloženo v cache jako hodnota položky `gtfsStopsCache:activeSetName`
|
|
329
|
-
- Komponenty:
|
|
330
|
-
- `gtfsStopsCache:$setId:aswNodeToGtfsStops` - Hash mapa, mapující daný ASW node na seznam pod něj spadajících zastávek (GTFS ids zastávek, odděleny čárkami)
|
|
331
|
-
- `gtfsStopsCache:$setId:cisToAswNode` - Hash mapa, mapující dané CIS id zastávky na příslušný ASW node
|
|
332
|
-
- TTL žádné (mimo přenačtení cache, kdy je namísto okamžitého promazání původnímu setu nastaveno TTL 1 minuta)
|
|
333
|
-
- Cache je celá přenačtena vždy po přenačtení jízdních řádů (tedy 1-2x denně při stavu k červenci 2025)
|
|
334
|
-
|
|
335
|
-
### jisCache:*
|
|
336
|
-
|
|
337
|
-
- Jednotlivé komponenty cache jsou členěny do sad s `$setId`
|
|
338
|
-
- `$setId` je id vygenerované datové sady (4 náhodné bajty reprezentované hexadecimálně)
|
|
339
|
-
- Nová sada je vytvořena při každém přenačtení cache
|
|
340
|
-
- Id `$setId` nejnovější datové sady se propaguje přes PubSub channel `jisCache` a je také uloženo v cache jako hodnota položky `jisCache:activeSetName`
|
|
341
|
-
- Komponenty:
|
|
342
|
-
- `jisCache:$setId:infotexts` - Hash mapa, mapující dané id infotextu na informace o onom infotextu (JSON jako string)
|
|
343
|
-
- `jisCache:$setId:stops-infotexts` - Hash mapa, mapující dané GTFS id zástavky na seznam infotextů s ní asociovaných (ids infotextů, odděleny čárkami)
|
|
344
|
-
- TTL žádné (mimo přenačtení cache, kdy je namísto okamžitého promazání původnímu setu nastaveno TTL 1 minuta)
|
|
345
|
-
- Cache je celá přenačtena při každé aktualizaci infotextů (tento proces je více popsán v [Dokumentaci propisu VYMI (JIS) dat do datové platformy](../../jis/index.md))
|
|
346
|
-
|
|
347
|
-
### Flowchart (refresh gtfsStopsCache:*)
|
|
348
|
-
|
|
349
|
-
```mermaid
|
|
350
|
-
flowchart LR
|
|
351
|
-
finish_up_gtfs("`Dokončení zpracování GTFS JŘ`");
|
|
352
|
-
|
|
353
|
-
psql_ropidgtfs_cis_stops[("`PSQL ropidgtfs_cis_stops`")];
|
|
354
|
-
psql_ropidgtfs_stops[("`PSQL ropidgtfs_stops`")];
|
|
355
|
-
|
|
356
|
-
redis_gtfsStopsCache[("`Redis gtfsStopsCache:\*`")];
|
|
357
|
-
|
|
358
|
-
amqp_refreshGtfsStopsCache["`AMQP refreshGtfsStopsCache`"];
|
|
359
|
-
|
|
360
|
-
task_RefreshGtfsStopsCacheTask["`RefreshGtfsStopsCacheTask`"];
|
|
361
|
-
|
|
362
|
-
finish_up_gtfs --> amqp_refreshGtfsStopsCache;
|
|
363
|
-
amqp_refreshGtfsStopsCache --> task_RefreshGtfsStopsCacheTask;
|
|
364
|
-
task_RefreshGtfsStopsCacheTask <-- "`ASW ids a CIS ids zastávek`" --> psql_ropidgtfs_cis_stops;
|
|
365
|
-
task_RefreshGtfsStopsCacheTask <-- "`ASW nodes a GTFS ids zastávek`" --> psql_ropidgtfs_stops;
|
|
366
|
-
task_RefreshGtfsStopsCacheTask -- "`HSET gtfsStopsCache:$setId:aswNodeToGtfsStops a gtfsStopsCache:$setId:cisToAswNode, EXPIRE staré sady`" --> redis_gtfsStopsCache;
|
|
367
|
-
```
|
|
368
|
-
|
|
369
|
-
### Flowchart (refresh jisCache:*)
|
|
370
|
-
|
|
371
|
-
```mermaid
|
|
372
|
-
flowchart LR
|
|
373
|
-
refresh_infotexts("`Aktualizace infotextů`");
|
|
374
|
-
|
|
375
|
-
psql_jis_infotexts[("`PSQL jis_infotexts`")];
|
|
376
|
-
psql_jis_infotexts_ropidgtfs_stops[("`PSQL jis_infotexts_ropidgtfs_stops`")];
|
|
377
|
-
|
|
378
|
-
redis_jisCache[("`Redis jisCache:\*`")];
|
|
379
|
-
|
|
380
|
-
amqp_refreshJISInfotextsCache["`AMQP refreshJISInfotextsCache`"];
|
|
381
|
-
|
|
382
|
-
task_RefreshJISInfotextsTask["`RefreshJISInfotextsTask`"];
|
|
383
|
-
|
|
384
|
-
refresh_infotexts --> amqp_refreshJISInfotextsCache;
|
|
385
|
-
amqp_refreshJISInfotextsCache --> task_RefreshJISInfotextsTask;
|
|
386
|
-
task_RefreshJISInfotextsTask <-- "`Data infotextů`" --> psql_jis_infotexts;
|
|
387
|
-
task_RefreshJISInfotextsTask <-- "`GTFS ids zastávek a ids infotextů`" --> psql_jis_infotexts_ropidgtfs_stops;
|
|
388
|
-
task_RefreshJISInfotextsTask -- "`HSET jisCache:$setId:infotexts a jisCache:$setId:stops-infotexts, EXPIRE staré sady`" --> redis_jisCache;
|
|
389
|
-
```
|
|
390
|
-
|
|
391
|
-
### Flowchart (v4 transferboards API)
|
|
392
|
-
|
|
393
|
-
```mermaid
|
|
394
|
-
flowchart TD;
|
|
395
|
-
todo["TODO"];
|
|
396
|
-
```
|
|
316
|
+
```
|
package/docs/jis/index.md
CHANGED
|
@@ -123,11 +123,9 @@ flowchart TB
|
|
|
123
123
|
subgraph "Golemio VP Integration Engine"
|
|
124
124
|
golemio_refresh_events_task["`RefreshJISEventsTask`"];
|
|
125
125
|
golemio_refresh_infotexts_task["`RefreshJISInfotextsTask`"];
|
|
126
|
-
golemio_refresh_infotexts_cache_task["`RefreshJISInfotextsCacheTask`"];
|
|
127
126
|
end
|
|
128
127
|
|
|
129
128
|
vp_pg[("`VP PostgreSQL`")];
|
|
130
|
-
vp_redis[("`VP Redis (Valkey)`")];
|
|
131
129
|
end
|
|
132
130
|
|
|
133
131
|
vymi_events_controller_create --> vymi_get_events;
|
|
@@ -136,8 +134,8 @@ flowchart TB
|
|
|
136
134
|
vymi_infotexts_controller_create --> vymi_get_infotexts;
|
|
137
135
|
vymi_infotexts_controller_update --> vymi_get_infotexts;
|
|
138
136
|
|
|
139
|
-
vymi_get_events
|
|
140
|
-
vymi_get_infotexts
|
|
137
|
+
vymi_get_events -- "`SELECT aktuálních událostí z tabulek vehicle-positions.pid.jis_events a vehicle-positions.pid.jis_events_ropidgtfs_routes`" --> vymi_pg;
|
|
138
|
+
vymi_get_infotexts -- "`SELECT aktuálních infotextů z tabulek vehicle-positions.pid.jis_infotexts a vehicle-positions.pid.jis_infotexts_ropidgtfs_stops`" --> vymi_pg;
|
|
141
139
|
|
|
142
140
|
vymi_get_events --> golemio_api_post_events;
|
|
143
141
|
vymi_get_infotexts --> golemio_api_post_infotexts;
|
|
@@ -153,12 +151,9 @@ flowchart TB
|
|
|
153
151
|
|
|
154
152
|
golemio_refresh_events_task -- "`UPSERT do tabulek vehicle-positions.pid.jis_events a vehicle-positions.pid.jis_events_ropidgtfs_routes`" --> vp_pg;
|
|
155
153
|
golemio_refresh_infotexts_task -- "`UPSERT do tabulek vehicle-positions.pid.jis_infotexts a vehicle-positions.pid.jis_infotexts_ropidgtfs_stops`" --> vp_pg;
|
|
156
|
-
golemio_refresh_infotexts_task --> golemio_refresh_infotexts_cache_task;
|
|
157
|
-
|
|
158
|
-
golemio_refresh_infotexts_cache_task -- "`Aktualizace cache jisCache:infotexts:* a jisCache:stop-infotexts:*`" --> vp_redis;
|
|
159
154
|
```
|
|
160
155
|
|
|
161
|
-
Formát zasílaných dat je dále více popsán v implementační dokumentaci ([události](../implementation_documentation.md#jis-events-1), [infotexty](../implementation_documentation.md#jis-infotexts-1)), stejně tak jako odkazy na [Input Gateway OpenAPI](../implementation_documentation.md#input-api) a popis [uložení dat](../implementation_documentation.md#uložení-dat) včetně databázového schema a popisu retence.
|
|
156
|
+
Formát zasílaných dat je dále více popsán v implementační dokumentaci ([události](../implementation_documentation.md#jis-events-1), [infotexty](../implementation_documentation.md#jis-infotexts-1)), stejně tak jako odkazy na [Input Gateway OpenAPI](../implementation_documentation.md#input-api) a popis [uložení dat](../implementation_documentation.md#uložení-dat) včetně databázového schema a popisu retence.
|
|
162
157
|
|
|
163
158
|
## Pasivní načítání (pull) dat
|
|
164
159
|
|
|
@@ -205,7 +200,6 @@ flowchart TB
|
|
|
205
200
|
golemio_fetch_infotexts_task["`FetchJISInfotextsTask`"];
|
|
206
201
|
golemio_refresh_events_task["`RefreshJISEventsTask`"];
|
|
207
202
|
golemio_refresh_infotexts_task["`RefreshJISInfotextsTask`"];
|
|
208
|
-
golemio_refresh_infotexts_cache_task["`RefreshJISInfotextsCacheTask`"];
|
|
209
203
|
|
|
210
204
|
%% invisible unicode char due to https://github.com/orgs/community/discussions/106690
|
|
211
205
|
golemio_api_get_events["`HTTPS GET s API klíčem na https://api-vymi.golemio.cz/v1/exports/events/custom-format`"];
|
|
@@ -213,11 +207,10 @@ flowchart TB
|
|
|
213
207
|
end
|
|
214
208
|
|
|
215
209
|
vp_pg[("`VP PostgreSQL`")];
|
|
216
|
-
vp_redis[("`VP Redis (Valkey)`")];
|
|
217
210
|
end
|
|
218
211
|
|
|
219
|
-
vymi_get_events
|
|
220
|
-
vymi_get_infotexts
|
|
212
|
+
vymi_get_events -- "`SELECT aktuálních událostí z tabulek vehicle-positions.pid.jis_events a vehicle-positions.pid.jis_events_ropidgtfs_routes`" --> vymi_pg;
|
|
213
|
+
vymi_get_infotexts -- "`SELECT aktuálních infotextů z tabulek vehicle-positions.pid.jis_infotexts a vehicle-positions.pid.jis_infotexts_ropidgtfs_stops`" --> vymi_pg;
|
|
221
214
|
|
|
222
215
|
golemio_rabbit_fetch_events --> golemio_fetch_events_task;
|
|
223
216
|
golemio_rabbit_fetch_infotexts --> golemio_fetch_infotexts_task;
|
|
@@ -238,9 +231,6 @@ flowchart TB
|
|
|
238
231
|
|
|
239
232
|
golemio_refresh_events_task -- "`UPSERT do tabulek vehicle-positions.pid.jis_events a vehicle-positions.pid.jis_events_ropidgtfs_routes`" --> vp_pg;
|
|
240
233
|
golemio_refresh_infotexts_task -- "`UPSERT do tabulek vehicle-positions.pid.jis_infotexts a vehicle-positions.pid.jis_infotexts_ropidgtfs_stops`" --> vp_pg;
|
|
241
|
-
golemio_refresh_infotexts_task --> golemio_refresh_infotexts_cache_task;
|
|
242
|
-
|
|
243
|
-
golemio_refresh_infotexts_cache_task -- "`Aktualizace cache jisCache:infotexts:* a jisCache:stop-infotexts:*`" --> vp_redis;
|
|
244
234
|
```
|
|
245
235
|
|
|
246
236
|
Zdroj a formát dat pro aktivní stahování jsou dále více popsány v implementační dokumentaci ([události](../implementation_documentation.md#jis-events), [infotexty](../implementation_documentation.md#jis-infotexts)), stejně tak jako [worker a tasky](../implementation_documentation.md#jisworker) a popis [uložení dat](../implementation_documentation.md#uložení-dat) včetně databázového schema a popisu retence.
|
package/docs/openapi-input.yaml
CHANGED
|
@@ -453,12 +453,6 @@ components:
|
|
|
453
453
|
type: array
|
|
454
454
|
items:
|
|
455
455
|
type: object
|
|
456
|
-
required:
|
|
457
|
-
- routeName
|
|
458
|
-
- note
|
|
459
|
-
- apiVersion
|
|
460
|
-
- route
|
|
461
|
-
- query
|
|
462
456
|
properties:
|
|
463
457
|
routeName:
|
|
464
458
|
type: string
|
|
@@ -475,9 +469,6 @@ components:
|
|
|
475
469
|
query:
|
|
476
470
|
type: string
|
|
477
471
|
example: "?minutesAfter=300&limit=8&mode=departures&cisIds=40110"
|
|
478
|
-
isTesting:
|
|
479
|
-
type: boolean
|
|
480
|
-
example: true
|
|
481
472
|
JISEvents:
|
|
482
473
|
title: JIS events
|
|
483
474
|
type: array
|
|
@@ -840,16 +831,14 @@ components:
|
|
|
840
831
|
"note": "Tablo Zahradní město z centra (APEX)",
|
|
841
832
|
"apiVersion": 2,
|
|
842
833
|
"route": "/pid/departureboards",
|
|
843
|
-
"query": "?minutesAfter=40&limit=6&mode=departures&filter=routeHeadingOnceNoGapFill&order=real&aswIds=2781_2&aswIds=2781_52&skip=atStop&airCondition=true"
|
|
844
|
-
"isTesting": true
|
|
834
|
+
"query": "?minutesAfter=40&limit=6&mode=departures&filter=routeHeadingOnceNoGapFill&order=real&aswIds=2781_2&aswIds=2781_52&skip=atStop&airCondition=true"
|
|
845
835
|
},
|
|
846
836
|
{
|
|
847
837
|
"routeName": "apex-zahradnimesto-6048-kopie",
|
|
848
838
|
"note": "Tablo Zahradní město z centra (APEX)",
|
|
849
839
|
"apiVersion": 2,
|
|
850
840
|
"route": "/pid/departureboards",
|
|
851
|
-
"query": "?minutesAfter=40&limit=6&mode=departures&filter=routeHeadingOnceNoGapFill&order=real&aswIds=2781_2&aswIds=2781_52&skip=atStop&airCondition=true"
|
|
852
|
-
"isTesting": false
|
|
841
|
+
"query": "?minutesAfter=40&limit=6&mode=departures&filter=routeHeadingOnceNoGapFill&order=real&aswIds=2781_2&aswIds=2781_52&skip=atStop&airCondition=true"
|
|
853
842
|
}
|
|
854
843
|
]
|
|
855
844
|
JISEventsExample:
|
package/docs/openapi-output.yaml
CHANGED
|
@@ -36,9 +36,6 @@ tags:
|
|
|
36
36
|
- name: 🚏 PID Departure Boards (v3) - internal
|
|
37
37
|
description: Endpoints for internal use
|
|
38
38
|
|
|
39
|
-
- name: 🚏 PID Departure Boards (v4)
|
|
40
|
-
description: <img src="https://img.shields.io/badge/opendata-available-green" alt="golemioapi-opendata-badge" /> <img src="https://img.shields.io/badge/stability-experimental-orange" alt="golemioapi-stability-badge" />
|
|
41
|
-
|
|
42
39
|
- name: 🗓️ Public GTFS Static Lookup (v2)
|
|
43
40
|
description: <img src="https://img.shields.io/badge/opendata-available-green" alt="golemioapi-opendata-badge" />
|
|
44
41
|
|
|
@@ -1378,329 +1375,6 @@ paths:
|
|
|
1378
1375
|
type: string
|
|
1379
1376
|
example: ["U454Z301"]
|
|
1380
1377
|
|
|
1381
|
-
/v4/pid/transferboards:
|
|
1382
|
-
get:
|
|
1383
|
-
tags:
|
|
1384
|
-
- 🚏 PID Departure Boards (v4)
|
|
1385
|
-
summary: GET Transfer Boards
|
|
1386
|
-
parameters:
|
|
1387
|
-
- name: cisId
|
|
1388
|
-
in: query
|
|
1389
|
-
description: |
|
|
1390
|
-
CIS identifier of the stop or node. A list of CIS IDs can be found in [Prague Open data](https://opendata.praha.eu/datasets/https%3A%2F%2Fapi.opendata.praha.eu%2Flod%2Fcatalog%2F6ac8381f-ea19-4ea9-8949-92076809dc5a).
|
|
1391
|
-
Includes departures from all stops at the given CIS ID.
|
|
1392
|
-
Required if `aswId` is not provided. Only one of `cisId` or `aswId` can be used.
|
|
1393
|
-
required: false
|
|
1394
|
-
examples:
|
|
1395
|
-
cisId1:
|
|
1396
|
-
value: 58759
|
|
1397
|
-
summary: Anděl
|
|
1398
|
-
cisId2:
|
|
1399
|
-
value: 13035
|
|
1400
|
-
summary: Jesenice
|
|
1401
|
-
cisId3:
|
|
1402
|
-
value: 5454956
|
|
1403
|
-
summary: Praha-Uhříněves
|
|
1404
|
-
schema:
|
|
1405
|
-
type: number
|
|
1406
|
-
- name: aswId
|
|
1407
|
-
in: query
|
|
1408
|
-
description: |
|
|
1409
|
-
ASW identifier of the stop. The format is `nodeId/stopId` where stopId is not mandatory.
|
|
1410
|
-
You can use `_` instead of `/` or encode the slash sign with `%2F`,
|
|
1411
|
-
Includes departures from the given stop, plus from all stops at the given node (1330_1 -> 1330 -> 1330_1, 1330_2, ...),
|
|
1412
|
-
plus from all stops sharing the same name. Departures from associated metro and train stations are also included (Na Knížecí -> Anděl).
|
|
1413
|
-
Required if `cisId` is not provided. Only one of `cisId` or `aswId` can be used.
|
|
1414
|
-
required: false
|
|
1415
|
-
examples:
|
|
1416
|
-
aswId1:
|
|
1417
|
-
value: "1040_1"
|
|
1418
|
-
summary: "Anděl A (tram stop)"
|
|
1419
|
-
aswId2:
|
|
1420
|
-
value: "1040_14"
|
|
1421
|
-
summary: "Anděl G (bus stop)"
|
|
1422
|
-
aswId3:
|
|
1423
|
-
value: "1330_1"
|
|
1424
|
-
summary: "Jesenice A (bus stop - regional)"
|
|
1425
|
-
aswId4:
|
|
1426
|
-
value: "461_301"
|
|
1427
|
-
summary: "Praha-Uhříněves (train station)"
|
|
1428
|
-
schema:
|
|
1429
|
-
type: string
|
|
1430
|
-
maxLength: 20
|
|
1431
|
-
- name: tripNumber
|
|
1432
|
-
in: query
|
|
1433
|
-
description: |
|
|
1434
|
-
Trip number of the vehicle in which the transfer is planned.
|
|
1435
|
-
Use to filter out transfers for a specific trip.
|
|
1436
|
-
Represents the numeric part of the GTFS `trip_short_name` (`Os 2547` -> `2547`).
|
|
1437
|
-
Generally, `trip_short_name` is available only for train services.
|
|
1438
|
-
Required if `vehicleRegistrationNumber` is not provided. Only one of `tripNumber` or `vehicleRegistrationNumber` can be used.
|
|
1439
|
-
required: false
|
|
1440
|
-
examples:
|
|
1441
|
-
tripNumber1:
|
|
1442
|
-
value: 2547
|
|
1443
|
-
summary: Os 2547
|
|
1444
|
-
schema:
|
|
1445
|
-
type: number
|
|
1446
|
-
- name: vehicleRegistrationNumber
|
|
1447
|
-
in: query
|
|
1448
|
-
description: |
|
|
1449
|
-
Registration number of the vehicle in which the transfer is planned.
|
|
1450
|
-
Use to filter out transfers for a specific vehicle.
|
|
1451
|
-
Required if `tripNumber` is not provided. Only one of `tripNumber` or `vehicleRegistrationNumber` can be used.
|
|
1452
|
-
required: false
|
|
1453
|
-
examples:
|
|
1454
|
-
vehicleRegistrationNumber1:
|
|
1455
|
-
value: "1001"
|
|
1456
|
-
summary: "Vehicle registration number"
|
|
1457
|
-
schema:
|
|
1458
|
-
type: string
|
|
1459
|
-
maxLength: 20
|
|
1460
|
-
- name: routeType
|
|
1461
|
-
in: query
|
|
1462
|
-
description: |
|
|
1463
|
-
Transport type of the route in which the transfer is planned. This parameter is required to distinguish between different vehicle types, as trams and buses can share the same registration number. The value is represented by the following enum from GTFS:
|
|
1464
|
-
- 0: Tram
|
|
1465
|
-
- 1: Subway
|
|
1466
|
-
- 2: Train
|
|
1467
|
-
- 3: Bus
|
|
1468
|
-
- 4: Ferry
|
|
1469
|
-
- 7: Funicular
|
|
1470
|
-
- 11: Trolleybus
|
|
1471
|
-
For example, if you want to get a tram with registration number "1001", use routeType=0. For a bus with the same registration number, use routeType=3.
|
|
1472
|
-
required: true
|
|
1473
|
-
examples:
|
|
1474
|
-
routeType1:
|
|
1475
|
-
value: 2
|
|
1476
|
-
summary: "Train"
|
|
1477
|
-
routeType2:
|
|
1478
|
-
value: 3
|
|
1479
|
-
summary: "Bus"
|
|
1480
|
-
schema:
|
|
1481
|
-
type: number
|
|
1482
|
-
enum:
|
|
1483
|
-
- 0
|
|
1484
|
-
- 1
|
|
1485
|
-
- 2
|
|
1486
|
-
- 3
|
|
1487
|
-
- 4
|
|
1488
|
-
- 7
|
|
1489
|
-
- 11
|
|
1490
|
-
- name: timeFrom
|
|
1491
|
-
in: query
|
|
1492
|
-
description: |
|
|
1493
|
-
Set initial timestamp for time interval given by `minutesBefore` (hardcoded to 0) and `minutesAfter` (hardcoded to 60). Use to simulate query time different from now. Use ISO 8601 time format and URL encoded symbols - `%3A` for `:`, `%2B` for `.`, `%2F` for `+`. Time zone is set to `Europe/Prague`. Applicable range is -6 hours +2 days from now.
|
|
1494
|
-
required: false
|
|
1495
|
-
schema:
|
|
1496
|
-
type: string
|
|
1497
|
-
example: "2024-11-04T16:51:00"
|
|
1498
|
-
- name: limit
|
|
1499
|
-
in: query
|
|
1500
|
-
description: |
|
|
1501
|
-
Limit the number of rows of departures returned. The total number of departures is a union across individual types of departures. The default value is 8.
|
|
1502
|
-
required: false
|
|
1503
|
-
schema:
|
|
1504
|
-
type: number
|
|
1505
|
-
default: 8
|
|
1506
|
-
responses:
|
|
1507
|
-
"200":
|
|
1508
|
-
description: List of possible transfers at the provided stop/node (identified by cisId or aswId)
|
|
1509
|
-
headers:
|
|
1510
|
-
Cache-Control:
|
|
1511
|
-
description: Cache control directive for caching proxies
|
|
1512
|
-
schema:
|
|
1513
|
-
type: string
|
|
1514
|
-
example: public, s-maxage=5, stale-while-revalidate=5
|
|
1515
|
-
content:
|
|
1516
|
-
application/json:
|
|
1517
|
-
schema:
|
|
1518
|
-
type: object
|
|
1519
|
-
required:
|
|
1520
|
-
- platform_code
|
|
1521
|
-
- stop_name
|
|
1522
|
-
- departures
|
|
1523
|
-
- infotexts
|
|
1524
|
-
properties:
|
|
1525
|
-
platform_code:
|
|
1526
|
-
type: string
|
|
1527
|
-
example: "2/3"
|
|
1528
|
-
nullable: true
|
|
1529
|
-
stop_name:
|
|
1530
|
-
type: string
|
|
1531
|
-
example: "Anděl"
|
|
1532
|
-
nullable: true
|
|
1533
|
-
icons:
|
|
1534
|
-
type: array
|
|
1535
|
-
items:
|
|
1536
|
-
type: string
|
|
1537
|
-
nullable: true
|
|
1538
|
-
departures:
|
|
1539
|
-
type: array
|
|
1540
|
-
description: |
|
|
1541
|
-
List of departures from the stop.
|
|
1542
|
-
The list is sorted by:
|
|
1543
|
-
- route type - subway and then other
|
|
1544
|
-
- subway is sorted alphabetically, then by departure time, then by direction id
|
|
1545
|
-
- departure time
|
|
1546
|
-
items:
|
|
1547
|
-
type: object
|
|
1548
|
-
required:
|
|
1549
|
-
- departure_timestamp
|
|
1550
|
-
- route
|
|
1551
|
-
- trip
|
|
1552
|
-
properties:
|
|
1553
|
-
departure_timestamp:
|
|
1554
|
-
type: object
|
|
1555
|
-
required:
|
|
1556
|
-
- minutes
|
|
1557
|
-
properties:
|
|
1558
|
-
minutes:
|
|
1559
|
-
type: array
|
|
1560
|
-
items:
|
|
1561
|
-
type: string
|
|
1562
|
-
nullable: true
|
|
1563
|
-
example: ["<1", "8"]
|
|
1564
|
-
route:
|
|
1565
|
-
type: object
|
|
1566
|
-
required:
|
|
1567
|
-
- short_name
|
|
1568
|
-
- type
|
|
1569
|
-
properties:
|
|
1570
|
-
short_name:
|
|
1571
|
-
type: string
|
|
1572
|
-
example: "B"
|
|
1573
|
-
nullable: true
|
|
1574
|
-
type:
|
|
1575
|
-
type: number
|
|
1576
|
-
example: 1
|
|
1577
|
-
nullable: true
|
|
1578
|
-
stop:
|
|
1579
|
-
type: object
|
|
1580
|
-
required:
|
|
1581
|
-
- platform_code
|
|
1582
|
-
properties:
|
|
1583
|
-
platform_code:
|
|
1584
|
-
type: string
|
|
1585
|
-
example: "2/3"
|
|
1586
|
-
nullable: true
|
|
1587
|
-
trip:
|
|
1588
|
-
type: object
|
|
1589
|
-
required:
|
|
1590
|
-
- headsign
|
|
1591
|
-
- id
|
|
1592
|
-
- is_wheelchair_accessible
|
|
1593
|
-
properties:
|
|
1594
|
-
headsign:
|
|
1595
|
-
type: string
|
|
1596
|
-
example: "Zličín"
|
|
1597
|
-
nullable: false
|
|
1598
|
-
description: "If more then one trips are available, the first one is taken. Trips are grouped by direction_id."
|
|
1599
|
-
id:
|
|
1600
|
-
type: string
|
|
1601
|
-
example: "1309_2547_231210"
|
|
1602
|
-
nullable: false
|
|
1603
|
-
description: "If more then one trips are available, the first one is taken. Trips are grouped by direction_id."
|
|
1604
|
-
is_wheelchair_accessible:
|
|
1605
|
-
type: boolean
|
|
1606
|
-
description: True if the vehicle being used on this trip is wheelchair accessible. Metro trips are deemed accessible if the station is accessible.
|
|
1607
|
-
example: false
|
|
1608
|
-
icons:
|
|
1609
|
-
type: array
|
|
1610
|
-
items:
|
|
1611
|
-
type: string
|
|
1612
|
-
nullable: true
|
|
1613
|
-
substitution_text:
|
|
1614
|
-
type: object
|
|
1615
|
-
required:
|
|
1616
|
-
- cs
|
|
1617
|
-
properties:
|
|
1618
|
-
cs:
|
|
1619
|
-
type: string
|
|
1620
|
-
example: "Provoz metra přerušen."
|
|
1621
|
-
nullable: false
|
|
1622
|
-
en:
|
|
1623
|
-
type: string
|
|
1624
|
-
example: "Metro service interrupted."
|
|
1625
|
-
nullable: true
|
|
1626
|
-
infotexts:
|
|
1627
|
-
type: array
|
|
1628
|
-
items:
|
|
1629
|
-
type: object
|
|
1630
|
-
required:
|
|
1631
|
-
- text
|
|
1632
|
-
- display_type
|
|
1633
|
-
properties:
|
|
1634
|
-
text:
|
|
1635
|
-
type: object
|
|
1636
|
-
required:
|
|
1637
|
-
- cs
|
|
1638
|
-
properties:
|
|
1639
|
-
cs:
|
|
1640
|
-
type: string
|
|
1641
|
-
example: "Nehoda na trase, odklon linek mimo tuto stanici."
|
|
1642
|
-
nullable: false
|
|
1643
|
-
en:
|
|
1644
|
-
type: string
|
|
1645
|
-
example: "Trips are cancelled due to accident on route."
|
|
1646
|
-
nullable: true
|
|
1647
|
-
display_type:
|
|
1648
|
-
type: string
|
|
1649
|
-
example: "inline"
|
|
1650
|
-
enum:
|
|
1651
|
-
- "inline"
|
|
1652
|
-
- "general"
|
|
1653
|
-
nullable: false
|
|
1654
|
-
|
|
1655
|
-
"400":
|
|
1656
|
-
description: |
|
|
1657
|
-
Bad request - invalid query parameters, including:
|
|
1658
|
-
* `cisId` and `aswId` are missing or invalid
|
|
1659
|
-
* Both `cisId` and `aswId` are provided
|
|
1660
|
-
* `timeFrom` is invalid or out of range
|
|
1661
|
-
content:
|
|
1662
|
-
application/json:
|
|
1663
|
-
schema:
|
|
1664
|
-
type: object
|
|
1665
|
-
properties:
|
|
1666
|
-
error_message:
|
|
1667
|
-
type: string
|
|
1668
|
-
example: "Bad request"
|
|
1669
|
-
nullable: false
|
|
1670
|
-
error_status:
|
|
1671
|
-
type: integer
|
|
1672
|
-
example: 400
|
|
1673
|
-
nullable: false
|
|
1674
|
-
error_info:
|
|
1675
|
-
type: string
|
|
1676
|
-
example: "{...}"
|
|
1677
|
-
nullable: true
|
|
1678
|
-
required:
|
|
1679
|
-
- error_message
|
|
1680
|
-
- error_status
|
|
1681
|
-
"401":
|
|
1682
|
-
$ref: "#/components/responses/UnauthorizedError"
|
|
1683
|
-
"404":
|
|
1684
|
-
description: Not found - no valid GTFS stop found for the given CIS ID or ASW ID
|
|
1685
|
-
content:
|
|
1686
|
-
application/json:
|
|
1687
|
-
schema:
|
|
1688
|
-
type: object
|
|
1689
|
-
required:
|
|
1690
|
-
- departures
|
|
1691
|
-
- infotexts
|
|
1692
|
-
properties:
|
|
1693
|
-
departures:
|
|
1694
|
-
type: array
|
|
1695
|
-
example: []
|
|
1696
|
-
items:
|
|
1697
|
-
type: object
|
|
1698
|
-
infotexts:
|
|
1699
|
-
type: array
|
|
1700
|
-
example: []
|
|
1701
|
-
items:
|
|
1702
|
-
type: object
|
|
1703
|
-
|
|
1704
1378
|
/v2/public/gtfs/trips/{gtfsTripId}:
|
|
1705
1379
|
get:
|
|
1706
1380
|
tags:
|
|
@@ -2113,6 +1787,10 @@ paths:
|
|
|
2113
1787
|
$ref: "#/components/responses/BadRequestError"
|
|
2114
1788
|
401:
|
|
2115
1789
|
$ref: "#/components/responses/UnauthorizedError"
|
|
1790
|
+
|
|
1791
|
+
|
|
1792
|
+
|
|
1793
|
+
|
|
2116
1794
|
|
|
2117
1795
|
|
|
2118
1796
|
components:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@golemio/pid",
|
|
3
|
-
"version": "4.0.2-
|
|
3
|
+
"version": "4.0.2-rc.1988899397",
|
|
4
4
|
"description": "Golemio PID Module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
"@golemio/core": ">=1.16.0-rc.1551191551"
|
|
76
76
|
},
|
|
77
77
|
"dependencies": {
|
|
78
|
-
"@golemio/ovapi-gtfs-realtime-bindings": "1.2.
|
|
78
|
+
"@golemio/ovapi-gtfs-realtime-bindings": "1.2.3",
|
|
79
79
|
"@turf/turf": "^6.5.0",
|
|
80
80
|
"cheap-ruler": "^3.0.2",
|
|
81
81
|
"csv-parser": "^3.0.0",
|