@golemio/parkings 1.8.6 → 1.8.7-dev.1238114799
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/db/example/00_clear_test_data.sql +1 -0
- package/db/example/01_sql_dump.sql +1 -1
- package/db/example/07_opening_hours.sql +7 -0
- package/db/example/08_isphk_data.sql +32 -0
- package/dist/integration-engine/ParkingsWorker.js +3 -2
- package/dist/integration-engine/ParkingsWorker.js.map +1 -1
- package/dist/integration-engine/ParkomatsWorker.js +9 -8
- package/dist/integration-engine/ParkomatsWorker.js.map +1 -1
- package/dist/integration-engine/datasources/StaticParkingLotsGeoDataSourceFactory.js +3 -2
- package/dist/integration-engine/datasources/StaticParkingLotsGeoDataSourceFactory.js.map +1 -1
- package/dist/integration-engine/datasources/StaticTariffsDataSourceFactory.js +3 -2
- package/dist/integration-engine/datasources/StaticTariffsDataSourceFactory.js.map +1 -1
- package/dist/integration-engine/datasources/TskParkingDataSourceFactory.d.ts +1 -1
- package/dist/integration-engine/datasources/TskParkingDataSourceFactory.js +6 -5
- package/dist/integration-engine/datasources/TskParkingDataSourceFactory.js.map +1 -1
- package/dist/integration-engine/datasources/iptoict/IptOictDataSource.js +3 -4
- package/dist/integration-engine/datasources/iptoict/IptOictDataSource.js.map +1 -1
- package/dist/integration-engine/datasources/manual/ManualEntrancesDatasource.js +2 -1
- package/dist/integration-engine/datasources/manual/ManualEntrancesDatasource.js.map +1 -1
- package/dist/integration-engine/datasources/mr-parkit/MrParkitDataSourceProvider.js +3 -2
- package/dist/integration-engine/datasources/mr-parkit/MrParkitDataSourceProvider.js.map +1 -1
- package/dist/integration-engine/datasources/osm/OsmDataSource.js +3 -2
- package/dist/integration-engine/datasources/osm/OsmDataSource.js.map +1 -1
- package/dist/integration-engine/datasources/osm/OsmEntrancesDataSource.js +2 -1
- package/dist/integration-engine/datasources/osm/OsmEntrancesDataSource.js.map +1 -1
- package/dist/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.d.ts +1 -1
- package/dist/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.js +3 -2
- package/dist/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.js.map +1 -1
- package/dist/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.js +2 -1
- package/dist/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.js.map +1 -1
- package/dist/integration-engine/transformations/EntrancesManualTransformation.js +1 -1
- package/dist/integration-engine/transformations/EntrancesManualTransformation.js.map +1 -1
- package/dist/integration-engine/transformations/IptOictParkingTransformation.js +1 -1
- package/dist/integration-engine/transformations/IptOictParkingTransformation.js.map +1 -1
- package/dist/output-gateway/controllers/v3/V3ParkingController.js +2 -0
- package/dist/output-gateway/controllers/v3/V3ParkingController.js.map +1 -1
- package/dist/output-gateway/data-access/ParkingOpeningHoursRepository.d.ts +6 -0
- package/dist/output-gateway/data-access/ParkingOpeningHoursRepository.js +34 -0
- package/dist/output-gateway/data-access/ParkingOpeningHoursRepository.js.map +1 -0
- package/dist/output-gateway/data-access/ParkingRepository.d.ts +3 -1
- package/dist/output-gateway/data-access/ParkingRepository.js +47 -4
- package/dist/output-gateway/data-access/ParkingRepository.js.map +1 -1
- package/dist/output-gateway/helpers/params/IParkingParams.d.ts +2 -0
- package/dist/output-gateway/ioc/Di.js +2 -0
- package/dist/output-gateway/ioc/Di.js.map +1 -1
- package/dist/output-gateway/ioc/ModuleContainerToken.d.ts +1 -0
- package/dist/output-gateway/ioc/ModuleContainerToken.js +1 -0
- package/dist/output-gateway/ioc/ModuleContainerToken.js.map +1 -1
- package/dist/output-gateway/routers/v3/V3ParkingRouter.js +3 -0
- package/dist/output-gateway/routers/v3/V3ParkingRouter.js.map +1 -1
- package/dist/output-gateway/transformations/v3/ParkingDtoTransformation.d.ts +1 -0
- package/dist/output-gateway/transformations/v3/ParkingDtoTransformation.js +12 -0
- package/dist/output-gateway/transformations/v3/ParkingDtoTransformation.js.map +1 -1
- package/dist/schema-definitions/models/interfaces/IParking.d.ts +2 -0
- package/docs/implementation-documentation.md +3 -3
- package/docs/openapi-output.yaml +71 -0
- package/package.json +3 -3
|
@@ -4,6 +4,7 @@ DELETE FROM parkings_measurements_part;
|
|
|
4
4
|
DELETE FROM parkings_average_occupancy;
|
|
5
5
|
DELETE FROM parkings_location;
|
|
6
6
|
DELETE FROM parkings;
|
|
7
|
+
DELETE FROM parkings_opening_hours;
|
|
7
8
|
DELETE FROM common.citydistricts where district_name_slug = 'praha-10';
|
|
8
9
|
truncate table parkings_business_errors;
|
|
9
10
|
|
|
@@ -43,4 +43,4 @@ INSERT INTO parking_sources ("source", open_data, api_v3_allowed, payment_url, c
|
|
|
43
43
|
('korid', false, false, 'https://parking.liberec.cz/', '{"email": "pomoc@parking.liberec.cz", "phone": "+420604295403", "web_url": "https://parking.liberec.cz/", "term_of_use_url": "https://www.liberec.cz/cz/prakticke-informace/doprava-udrzba-komunikaci/parkovaci-mista/parkovaci-mista.html"}'::jsonb, true, NULL, NULL),
|
|
44
44
|
('ipr', false, false, NULL, NULL, true, NULL, NULL),
|
|
45
45
|
('mr_parkit', false, true, NULL, '{"email": "info@mrparkit.com", "phone": "+420 277 277 977", "web_url": "https://www.mrparkit.com/", "term_of_use_url": "https://www.mrparkit.com/cs/pravni-dokumenty"}', false, NULL, NULL),
|
|
46
|
-
('isphk', false, true, NULL,
|
|
46
|
+
('isphk', false, true, NULL, '{"email": "zadosti@isphk.cz","phone": "800 101 039","web_url": "https://www.isphk.cz/","term_of_use_url": null}', false, 'http://parking.cz', 'http://parking_locations.cz');
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
INSERT INTO parkings_opening_hours (parking_id,"source",valid_from,valid_to,periods_of_time,created_at,updated_at) VALUES
|
|
2
|
+
('isphk-hk_isp_002','isphk','2024-01-30 01:00:00+01','2024-05-30 01:00:00+01','[{"day_in_week":"Mo","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Tu","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"We","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Th","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Fr","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Sa","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Su","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null}]','2024-03-07 10:58:14.286+01','2024-03-19 09:01:00.18+01'),
|
|
3
|
+
('isphk-hk_isp_003','isphk','2024-02-26 01:00:00+01','2024-05-30 01:00:00+01','[{"day_in_week":"Mo","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Tu","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"We","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Th","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Fr","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Sa","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Su","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null}]','2024-03-07 10:58:14.286+01','2024-03-19 09:01:00.18+01'),
|
|
4
|
+
('isphk-hk_isp_005','isphk','2024-03-30 01:00:00+01','2024-06-20 01:00:00+01','[{"day_in_week":"Mo","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Tu","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"We","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Th","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Fr","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Sa","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Su","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null}]','2024-03-07 10:58:14.286+01','2024-03-19 09:01:00.18+01'),
|
|
5
|
+
('isphk-hk_isp_005','isphk','2024-04-30 01:00:00+01','2024-06-30 01:00:00+01','[{"day_in_week":"Mo","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Tu","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"We","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Th","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Fr","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Sa","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null},{"day_in_week":"Su","start":"00:00","end":"23:59","ph":"PH_off","maximum_duration":null,"disc_parking":null}]','2024-03-07 10:58:14.286+01','2024-03-19 09:01:00.18+01'),
|
|
6
|
+
('osm-w_22823347','osm','1970-01-01 01:00:00+01',NULL,'[{"day_in_week":"Mo","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Tu","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Mo","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Tu","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Tu","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"We","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Tu","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"We","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"We","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Th","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"We","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Th","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Th","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Fr","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Th","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Fr","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Fr","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Sa","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Fr","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Sa","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Sa","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Su","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Sa","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Su","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Su","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Mo","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Su","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Mo","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null}]','2024-03-06 14:33:20.361+01','2024-03-17 16:00:09.681+01'),
|
|
7
|
+
('osm-r_14470409','osm','1970-01-01 01:00:00+01',NULL,'[{"day_in_week":"Mo","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Tu","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Mo","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Tu","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Tu","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"We","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Tu","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"We","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"We","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Th","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"We","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Th","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Th","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Fr","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Th","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Fr","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Fr","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Sa","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Fr","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Sa","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Sa","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Su","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Sa","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Su","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null},{"day_in_week":"Su","start":"04:00","end":"23:59","ph":"ph_off","maximum_duration":null},{"day_in_week":"Mo","start":"00:00","end":"01:00","ph":"ph_off","maximum_duration":null},{"day_in_week":"Su","start":"04:00","end":"23:59","ph":"ph_only","maximum_duration":null},{"day_in_week":"Mo","start":"00:00","end":"01:00","ph":"ph_only","maximum_duration":null}]','2024-03-06 14:33:20.361+01','2024-03-17 16:00:09.681+01');
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
INSERT INTO parkings
|
|
2
|
+
(id, "source", source_id, data_provider, "name", category, date_modified, address, "location", area_served, web_app_payment_url, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, tariff_id, valid_from, valid_to, parking_type, zone_type, centroid, android_app_payment_url, ios_app_payment_url, "security", max_vehicle_dimensions, covered, contact, parking_policy)
|
|
3
|
+
VALUES('isphk-hk_isp_001', 'isphk', 'hk_isp_001', 'manual', 'Parkoviště - Areál Gayerova kasárna', NULL, '2024-03-19 12:35:38.035', NULL, 'SRID=4326;POLYGON ((15.8334023 50.2124219, 15.8332966 50.2126351, 15.8324748 50.2124681, 15.8325805 50.212255, 15.8334023 50.2124219))'::public.geometry, NULL, NULL, NULL, NULL, '2024-03-19 12:24:00.743', NULL, NULL, '2024-03-19 12:35:38.038', NULL, NULL, NULL, NULL, 'surface', NULL, 'SRID=4326;POINT (15.83293855 50.21244505)'::public.geometry, NULL, NULL, NULL, NULL, false, NULL, 'commercial');
|
|
4
|
+
INSERT INTO parkings
|
|
5
|
+
(id, "source", source_id, data_provider, "name", category, date_modified, address, "location", area_served, web_app_payment_url, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, tariff_id, valid_from, valid_to, parking_type, zone_type, centroid, android_app_payment_url, ios_app_payment_url, "security", max_vehicle_dimensions, covered, contact, parking_policy)
|
|
6
|
+
VALUES('isphk-hk_isp_002', 'isphk', 'hk_isp_002', 'manual', 'Parkovací dům Jana Gayera', NULL, '2024-03-19 12:35:38.035', NULL, 'SRID=4326;POLYGON ((15.8321452 50.2130086, 15.8322186 50.2128579, 15.8323087 50.2128759, 15.8323223 50.2128479, 15.8323356 50.2128204, 15.8323149 50.2128163, 15.8323881 50.2126659, 15.8331828 50.2128243, 15.8331099 50.2129743, 15.8330819 50.2129687, 15.8330694 50.2129944, 15.8330549 50.213024, 15.8331541 50.2130438, 15.8330805 50.213195, 15.8326895 50.2131171, 15.832548 50.2130889, 15.8321452 50.2130086))'::public.geometry, NULL, NULL, NULL, NULL, '2024-03-19 12:24:00.743', NULL, NULL, '2024-03-19 12:35:38.038', NULL, NULL, NULL, NULL, 'multi_storey', NULL, 'SRID=4326;POINT (15.832664 50.21293045)'::public.geometry, NULL, NULL, NULL, NULL, true, NULL, 'commercial');
|
|
7
|
+
INSERT INTO parkings
|
|
8
|
+
(id, "source", source_id, data_provider, "name", category, date_modified, address, "location", area_served, web_app_payment_url, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, tariff_id, valid_from, valid_to, parking_type, zone_type, centroid, android_app_payment_url, ios_app_payment_url, "security", max_vehicle_dimensions, covered, contact, parking_policy)
|
|
9
|
+
VALUES('isphk-hk_isp_003', 'isphk', 'hk_isp_003', 'manual', 'Parkovací dům RegioCentrum', NULL, '2024-03-19 12:35:38.035', NULL, 'SRID=4326;POLYGON ((15.8294385 50.207829, 15.8294834 50.2077227, 15.8294878 50.2077019, 15.82955 50.207706, 15.829675 50.2077134, 15.8298179 50.2082955, 15.8292389 50.2084276, 15.8293478 50.2086025, 15.8291261 50.2086672, 15.8289545 50.2083726, 15.8292259 50.2083024, 15.8289966 50.2079245, 15.8294385 50.207829))'::public.geometry, NULL, NULL, NULL, NULL, '2024-03-19 12:24:00.743', NULL, NULL, '2024-03-19 12:35:38.038', NULL, NULL, NULL, NULL, 'underground', NULL, 'SRID=4326;POINT (15.8293862 50.20818455)'::public.geometry, NULL, NULL, NULL, NULL, true, NULL, 'commercial');
|
|
10
|
+
INSERT INTO parkings
|
|
11
|
+
(id, "source", source_id, data_provider, "name", category, date_modified, address, "location", area_served, web_app_payment_url, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, tariff_id, valid_from, valid_to, parking_type, zone_type, centroid, android_app_payment_url, ios_app_payment_url, "security", max_vehicle_dimensions, covered, contact, parking_policy)
|
|
12
|
+
VALUES('isphk-hk_isp_004', 'isphk', 'hk_isp_004', 'manual', 'Parkoviště ‐ Zimní stadion', NULL, '2024-03-19 12:35:38.035', NULL, 'SRID=4326;POLYGON ((15.8302249 50.2073579, 15.8301801 50.2075294, 15.8293367 50.2074391, 15.8293816 50.2072675, 15.8302249 50.2073579))'::public.geometry, NULL, NULL, NULL, NULL, '2024-03-19 12:24:00.743', NULL, NULL, '2024-03-19 12:35:38.038', NULL, NULL, NULL, NULL, 'surface', NULL, 'SRID=4326;POINT (15.8297808 50.20739845)'::public.geometry, NULL, NULL, NULL, NULL, false, NULL, 'commercial');
|
|
13
|
+
INSERT INTO parkings
|
|
14
|
+
(id, "source", source_id, data_provider, "name", category, date_modified, address, "location", area_served, web_app_payment_url, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, tariff_id, valid_from, valid_to, parking_type, zone_type, centroid, android_app_payment_url, ios_app_payment_url, "security", max_vehicle_dimensions, covered, contact, parking_policy)
|
|
15
|
+
VALUES('isphk-hk_isp_005', 'isphk', 'hk_isp_005', 'manual', 'Parkovací dům Katschnerka', NULL, '2024-03-19 12:35:38.035', NULL, 'SRID=4326;POLYGON ((15.8215837 50.2146887, 15.8215852 50.2146855, 15.8215877 50.2146826, 15.8215911 50.21468, 15.8215952 50.214678, 15.8215999 50.2146765, 15.8216049 50.2146756, 15.8216101 50.2146755, 15.8216153 50.2146759, 15.8216202 50.2146771, 15.8216247 50.2146788, 15.8216285 50.2146811, 15.8216315 50.2146838, 15.8216336 50.2146869, 15.8216347 50.2146902, 15.8216347 50.2146935, 15.8216337 50.2146968, 15.8216317 50.2146999, 15.8216288 50.2147027, 15.8216251 50.214705, 15.8216207 50.2147068, 15.8216158 50.214708, 15.8216107 50.2147086, 15.8216055 50.2147085, 15.8216004 50.2147077, 15.8215957 50.2147062, 15.8215915 50.2147042, 15.821654 50.2148299, 15.821667 50.2148562, 15.8216957 50.2149139, 15.8208888 50.2150785, 15.8208576 50.2150069, 15.8207455 50.2147894, 15.8207476 50.214789, 15.8207486 50.214791, 15.8208549 50.2147691, 15.820854 50.2147672, 15.8215516 50.2146246, 15.8215837 50.2146887))'::public.geometry, NULL, NULL, NULL, NULL, '2024-03-19 12:24:00.743', NULL, NULL, '2024-03-19 12:35:38.038', NULL, NULL, NULL, NULL, 'multi_storey', NULL, 'SRID=4326;POINT (15.8212206 50.21485155)'::public.geometry, NULL, NULL, NULL, NULL, true, NULL, 'commercial');
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
INSERT INTO parkings_location
|
|
19
|
+
(id, "source", source_id, data_provider, "location", centroid, address, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, special_access)
|
|
20
|
+
VALUES('hk_isp_001_001', 'isphk', 'hk_isp_001', 'manual', 'SRID=4326;POLYGON ((15.8334023 50.2124219, 15.8332966 50.2126351, 15.8324748 50.2124681, 15.8325805 50.212255, 15.8334023 50.2124219))'::public.geometry, 'SRID=4326;POINT (15.83293855 50.21244505)'::public.geometry, NULL, 60, NULL, '2024-03-19 12:35:38.248', NULL, NULL, '2024-03-19 12:35:38.248', NULL, '{}');
|
|
21
|
+
INSERT INTO parkings_location
|
|
22
|
+
(id, "source", source_id, data_provider, "location", centroid, address, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, special_access)
|
|
23
|
+
VALUES('hk_isp_002_001', 'isphk', 'hk_isp_002', 'manual', 'SRID=4326;POLYGON ((15.8321452 50.2130086, 15.8322186 50.2128579, 15.8323087 50.2128759, 15.8323223 50.2128479, 15.8323356 50.2128204, 15.8323149 50.2128163, 15.8323881 50.2126659, 15.8331828 50.2128243, 15.8331099 50.2129743, 15.8330819 50.2129687, 15.8330694 50.2129944, 15.8330549 50.213024, 15.8331541 50.2130438, 15.8330805 50.213195, 15.8326895 50.2131171, 15.832548 50.2130889, 15.8321452 50.2130086))'::public.geometry, 'SRID=4326;POINT (15.832664 50.21293045)'::public.geometry, NULL, 284, NULL, '2024-03-19 12:35:38.248', NULL, NULL, '2024-03-19 12:35:38.248', NULL, NULL);
|
|
24
|
+
INSERT INTO parkings_location
|
|
25
|
+
(id, "source", source_id, data_provider, "location", centroid, address, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, special_access)
|
|
26
|
+
VALUES('hk_isp_003_001', 'isphk', 'hk_isp_003', 'manual', 'SRID=4326;POLYGON ((15.8294385 50.207829, 15.8294834 50.2077227, 15.8294878 50.2077019, 15.82955 50.207706, 15.829675 50.2077134, 15.8298179 50.2082955, 15.8292389 50.2084276, 15.8293478 50.2086025, 15.8291261 50.2086672, 15.8289545 50.2083726, 15.8292259 50.2083024, 15.8289966 50.2079245, 15.8294385 50.207829))'::public.geometry, 'SRID=4326;POINT (15.8293862 50.20818455)'::public.geometry, NULL, 425, NULL, '2024-03-19 12:35:38.248', NULL, NULL, '2024-03-19 12:35:38.248', NULL, NULL);
|
|
27
|
+
INSERT INTO parkings_location
|
|
28
|
+
(id, "source", source_id, data_provider, "location", centroid, address, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, special_access)
|
|
29
|
+
VALUES('hk_isp_004_001', 'isphk', 'hk_isp_004', 'manual', 'SRID=4326;POLYGON ((15.8302249 50.2073579, 15.8301801 50.2075294, 15.8293367 50.2074391, 15.8293816 50.2072675, 15.8302249 50.2073579))'::public.geometry, 'SRID=4326;POINT (15.8297808 50.20739845)'::public.geometry, NULL, 50, NULL, '2024-03-19 12:35:38.248', NULL, NULL, '2024-03-19 12:35:38.248', NULL, '{}');
|
|
30
|
+
INSERT INTO parkings_location
|
|
31
|
+
(id, "source", source_id, data_provider, "location", centroid, address, total_spot_number, create_batch_id, created_at, created_by, update_batch_id, updated_at, updated_by, special_access)
|
|
32
|
+
VALUES('hk_isp_005_001', 'isphk', 'hk_isp_005', 'manual', 'SRID=4326;POLYGON ((15.8215837 50.2146887, 15.8215852 50.2146855, 15.8215877 50.2146826, 15.8215911 50.21468, 15.8215952 50.214678, 15.8215999 50.2146765, 15.8216049 50.2146756, 15.8216101 50.2146755, 15.8216153 50.2146759, 15.8216202 50.2146771, 15.8216247 50.2146788, 15.8216285 50.2146811, 15.8216315 50.2146838, 15.8216336 50.2146869, 15.8216347 50.2146902, 15.8216347 50.2146935, 15.8216337 50.2146968, 15.8216317 50.2146999, 15.8216288 50.2147027, 15.8216251 50.214705, 15.8216207 50.2147068, 15.8216158 50.214708, 15.8216107 50.2147086, 15.8216055 50.2147085, 15.8216004 50.2147077, 15.8215957 50.2147062, 15.8215915 50.2147042, 15.821654 50.2148299, 15.821667 50.2148562, 15.8216957 50.2149139, 15.8208888 50.2150785, 15.8208576 50.2150069, 15.8207455 50.2147894, 15.8207476 50.214789, 15.8207486 50.214791, 15.8208549 50.2147691, 15.820854 50.2147672, 15.8215516 50.2146246, 15.8215837 50.2146887))'::public.geometry, 'SRID=4326;POINT (15.8212206 50.21485155)'::public.geometry, NULL, 497, NULL, '2024-03-19 12:35:38.248', NULL, NULL, '2024-03-19 12:35:38.248', NULL, NULL);
|
|
@@ -10,6 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.ParkingsWorker = void 0;
|
|
13
|
+
const ParkingsLocationRepository_1 = require("./repositories/ParkingsLocationRepository");
|
|
13
14
|
const ParkingLotsTransformation_1 = require("./transformations/ParkingLotsTransformation");
|
|
14
15
|
const UpdateAddressWorker_1 = require("./workers/UpdateAddressWorker");
|
|
15
16
|
const InputParkingLotsSchema_1 = require("../schema-definitions/datasources/InputParkingLotsSchema");
|
|
@@ -17,6 +18,7 @@ const ParkingMeasurementsDtoSchema_1 = require("../schema-definitions/datasource
|
|
|
17
18
|
const index_1 = require("../schema-definitions/index");
|
|
18
19
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
19
20
|
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
21
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
20
22
|
const ContainerToken_1 = require("@golemio/core/dist/integration-engine/ioc/ContainerToken");
|
|
21
23
|
const models_1 = require("@golemio/core/dist/integration-engine/models");
|
|
22
24
|
const workers_1 = require("@golemio/core/dist/integration-engine/workers");
|
|
@@ -28,7 +30,6 @@ const ModuleContainerToken_1 = require("./ioc/ModuleContainerToken");
|
|
|
28
30
|
const TskAverageOccupancyRepository_1 = require("./repositories/TskAverageOccupancyRepository");
|
|
29
31
|
const KoridParkingConfigTransformation_1 = require("./transformations/KoridParkingConfigTransformation");
|
|
30
32
|
const KoridParkingDataTransformation_1 = require("./transformations/KoridParkingDataTransformation");
|
|
31
|
-
const ParkingsLocationRepository_1 = require("./repositories/ParkingsLocationRepository");
|
|
32
33
|
class ParkingsWorker extends workers_1.BaseWorker {
|
|
33
34
|
constructor() {
|
|
34
35
|
super();
|
|
@@ -108,7 +109,7 @@ class ParkingsWorker extends workers_1.BaseWorker {
|
|
|
108
109
|
const dataTypeStrategy = new datasources_1.JSONDataTypeStrategy({ resultsPath: "results" });
|
|
109
110
|
// filter items with lastUpdated lower than two days
|
|
110
111
|
dataTypeStrategy.setFilter((item) => item.lastUpdated > new Date().getTime() - 2 * 24 * 60 * 60 * 1000);
|
|
111
|
-
this.dataSource = new datasources_1.DataSource(index_1.Parkings.name + "DataSource", new
|
|
112
|
+
this.dataSource = new datasources_1.DataSource(index_1.Parkings.name + "DataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
112
113
|
headers: {},
|
|
113
114
|
method: "GET",
|
|
114
115
|
url: this.config.datasources.TSKParkings,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ParkingsWorker.js","sourceRoot":"","sources":["../../src/integration-engine/ParkingsWorker.ts"],"names":[],"mappings":";;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"ParkingsWorker.js","sourceRoot":"","sources":["../../src/integration-engine/ParkingsWorker.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,0FAAyF;AAEzF,2FAA0F;AAC1F,uEAAsE;AACtE,qGAAiF;AACjF,iHAA6F;AAE7F,uDAAsC;AAEtC,8EAAqE;AAErE,mFAAqG;AACrG,6IAA0I;AAC1I,6FAA0F;AAC1F,yEAAyF;AACzF,2EAA2E;AAC3E,6EAAwE;AACxE,mFAAkF;AAClF,+GAA4G;AAC5G,iCAA6C;AAC7C,qEAAkE;AAClE,gGAA6F;AAC7F,yGAAsG;AACtG,qGAAkG;AAElG,MAAa,cAAe,SAAQ,oBAAU;IAe1C;QACI,KAAK,EAAE,CAAC;QAqDZ;;;WAGG;QACI,0BAAqB,GAAG,GAAwB,EAAE;YACrD,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC;YAC5C,IAAI,aAAyD,CAAC;YAC9D,IAAI;gBACA,+CAA+C;gBAC/C,8DAA8D;gBAC9D,aAAa,GAAG,CACZ,MAAM,6EAAqC,CAAC,aAAa,CACrD,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,6BAA6B,CACxD,CAAC,MAAM,EAAE,CACb,CAAC,QAAQ,CAAC;aACd;YAAC,OAAO,GAAG,EAAE;gBACV,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,gDAAgD,GAAG,CAAC,OAAO,EAAE,CAAC,CAAC;aACpF;Y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YAC9C,UAAU,EAAE,gBAAgB;SAC/B,EACD,IAAI,uCAAmB,CAAC,gBAAQ,CAAC,YAAY,CAAC,IAAI,GAAG,kBAAkB,EAAE,2DAA4B,CAAC,CACzG,CAAC;QAEF,IAAI,CAAC,+BAA+B,GAAG,IAAI,sBAAa,CACpD,gBAAQ,CAAC,kBAAkB,CAAC,IAAI,GAAG,OAAO,EAC1C;YACI,yBAAyB,EAAE,gBAAQ,CAAC,kBAAkB,CAAC,yBAAyB;YAChF,QAAQ,EAAE,gBAAQ,CAAC,QAAQ;YAC3B,WAAW,EAAE,gBAAQ,CAAC,kBAAkB,CAAC,WAAW;YACpD,UAAU,EAAE,gBAAgB;SAC/B,EACD,IAAI,uCAAmB,CAAC,gBAAQ,CAAC,kBAAkB,CAAC,IAAI,GAAG,kBAAkB,EAAE,2DAA4B,CAAC,CAC/G,CAAC;QAEF,IAAI,CAAC,6BAA6B,GAAG,IAAI,6DAA6B,EAAE,CAAC;QAEzE,IAAI,CAAC,UAAU,GAAG,sBAAiB,CAAC,OAAO,CAAa,2CAAoB,CAAC,UAAU,CAAC,CAAC;QACzF,IAAI,CAAC,aAAa,GAAG,sBAAiB,CAAC,OAAO,CAAqB,2CAAoB,CAAC,kBAAkB,CAAC,CAAC;QAC5G,IAAI,CAAC,oBAAoB,GAAG,sBAAiB,CAAC,OAAO,CACjD,2CAAoB,CAAC,wBAAwB,CAChD,CAAC;QACF,IAAI,CAAC,0BAA0B,GAAG,IAAI,uDAA0B,EAAE,CAAC;IACvE,CAAC;CA+FJ;AAlKD,wCAkKC"}
|
|
@@ -13,14 +13,15 @@ exports.ParkomatsWorker = void 0;
|
|
|
13
13
|
const _sch_1 = require("../schema-definitions");
|
|
14
14
|
const ParkomatInputSchema_1 = require("../schema-definitions/parkomats/datasources/ParkomatInputSchema");
|
|
15
15
|
const ParkomatDto_1 = require("../schema-definitions/parkomats/models/ParkomatDto");
|
|
16
|
+
const helpers_1 = require("@golemio/core/dist/helpers");
|
|
16
17
|
const config_1 = require("@golemio/core/dist/integration-engine/config");
|
|
17
18
|
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
18
|
-
const
|
|
19
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
20
|
+
const helpers_2 = require("@golemio/core/dist/integration-engine/helpers");
|
|
19
21
|
const models_1 = require("@golemio/core/dist/integration-engine/models");
|
|
20
22
|
const workers_1 = require("@golemio/core/dist/integration-engine/workers");
|
|
21
23
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
22
24
|
const ParkomatsTransformation_1 = require("./transformations/ParkomatsTransformation");
|
|
23
|
-
const helpers_2 = require("@golemio/core/dist/helpers");
|
|
24
25
|
class ParkomatsWorker extends workers_1.BaseWorker {
|
|
25
26
|
constructor() {
|
|
26
27
|
super();
|
|
@@ -32,9 +33,9 @@ class ParkomatsWorker extends workers_1.BaseWorker {
|
|
|
32
33
|
// setting custom interval from message data
|
|
33
34
|
const customInterval = JSON.parse(msg.content.toString());
|
|
34
35
|
if (customInterval.from && customInterval.to) {
|
|
35
|
-
from = (0,
|
|
36
|
-
to = (0,
|
|
37
|
-
|
|
36
|
+
from = (0, helpers_1.dateTime)(new Date(customInterval.from), { timeZone: "Europe/Prague" });
|
|
37
|
+
to = (0, helpers_1.dateTime)(new Date(customInterval.to), { timeZone: "Europe/Prague" });
|
|
38
|
+
helpers_2.log.debug(`Interval from: ${from} to ${to} was used.`);
|
|
38
39
|
}
|
|
39
40
|
else {
|
|
40
41
|
throw new Error("Interval must contain from and to properties.");
|
|
@@ -42,13 +43,13 @@ class ParkomatsWorker extends workers_1.BaseWorker {
|
|
|
42
43
|
}
|
|
43
44
|
catch (err) {
|
|
44
45
|
// setting default interval (normal situation)
|
|
45
|
-
to = (0,
|
|
46
|
+
to = (0, helpers_1.dateTime)(new Date()).setTimeZone("Europe/Prague");
|
|
46
47
|
from = to.clone();
|
|
47
48
|
from.subtract(12, "minutes");
|
|
48
49
|
}
|
|
49
50
|
this.dataSourceHTTPSettings.url =
|
|
50
51
|
this.dataSourceUrl + from.format("yyyy-LL-dd'T'HH:mm:ss") + `&to=${to.format("yyyy-LL-dd'T'HH:mm:ss")}`;
|
|
51
|
-
this.dataSource.setProtocolStrategy(new
|
|
52
|
+
this.dataSource.setProtocolStrategy(new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy(this.dataSourceHTTPSettings));
|
|
52
53
|
const data = yield this.dataSource.getAll();
|
|
53
54
|
const transformedData = yield this.transformation.transform(data);
|
|
54
55
|
yield this.model.save(transformedData);
|
|
@@ -62,7 +63,7 @@ class ParkomatsWorker extends workers_1.BaseWorker {
|
|
|
62
63
|
// if `to` omitted, API returns empty array!
|
|
63
64
|
url: this.dataSourceUrl,
|
|
64
65
|
};
|
|
65
|
-
this.dataSource = new datasources_1.DataSource(_sch_1.Parkomats.name + "DataSource", new
|
|
66
|
+
this.dataSource = new datasources_1.DataSource(_sch_1.Parkomats.name + "DataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy(this.dataSourceHTTPSettings), new datasources_1.JSONDataTypeStrategy({ resultsPath: "" }), new golemio_validator_1.JSONSchemaValidator(_sch_1.Parkomats.name + "DataSource", ParkomatInputSchema_1.ParkomatInputSchema));
|
|
66
67
|
this.model = new models_1.PostgresModel(_sch_1.Parkomats.name + "Model", {
|
|
67
68
|
outputSequelizeAttributes: ParkomatDto_1.ParkomatDto.attributeModel,
|
|
68
69
|
pgSchema: _sch_1.Parkomats.pgSchema,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ParkomatsWorker.js","sourceRoot":"","sources":["../../src/integration-engine/ParkomatsWorker.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,gDAAiC;AACjC,yGAAqF;AACrF,oFAAgE;AAChE,yEAAsE;AACtE,
|
|
1
|
+
{"version":3,"file":"ParkomatsWorker.js","sourceRoot":"","sources":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B,EAAE,yBAAW,CAAC,cAAc;YACrD,QAAQ,EAAE,gBAAS,CAAC,QAAQ;YAC5B,WAAW,EAAE,gBAAS,CAAC,WAAW;YAClC,UAAU,EAAE,gBAAgB;SAC/B,EACD,IAAI,uCAAmB,CAAC,gBAAS,CAAC,IAAI,GAAG,gBAAgB,EAAE,yBAAW,CAAC,UAAU,CAAC,CACrF,CAAC;QACF,IAAI,CAAC,cAAc,GAAG,IAAI,iDAAuB,EAAE,CAAC;IACxD,CAAC;CA+BJ;AArED,0CAqEC"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.StaticParkingLotsGeoDataSourceFactory = void 0;
|
|
4
|
+
const StaticParkingLotsGeoJsonSchema_1 = require("../../schema-definitions/datasources/StaticParkingLotsGeoJsonSchema");
|
|
4
5
|
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
6
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
5
7
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
6
|
-
const StaticParkingLotsGeoJsonSchema_1 = require("../../schema-definitions/datasources/StaticParkingLotsGeoJsonSchema");
|
|
7
8
|
class StaticParkingLotsGeoDataSourceFactory {
|
|
8
9
|
static getDataSource(sourceUrl) {
|
|
9
|
-
return new datasources_1.DataSource("StaticParkingLotsGeoDataSource", new
|
|
10
|
+
return new datasources_1.DataSource("StaticParkingLotsGeoDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
10
11
|
headers: {},
|
|
11
12
|
method: "GET",
|
|
12
13
|
url: sourceUrl,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StaticParkingLotsGeoDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/StaticParkingLotsGeoDataSourceFactory.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"StaticParkingLotsGeoDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/StaticParkingLotsGeoDataSourceFactory.ts"],"names":[],"mappings":";;;AAAA,wHAAiG;AACjG,mFAAqG;AACrG,6IAA0I;AAC1I,mFAAkF;AAElF,MAAa,qCAAqC;IACvC,MAAM,CAAC,aAAa,CAAC,SAAiB;QACzC,OAAO,IAAI,wBAAU,CACjB,gCAAgC,EAChC,IAAI,qDAAyB,CAAC;YAC1B,OAAO,EAAE,EAAE;YACX,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,SAAS;SACjB,CAAC,EACF,IAAI,kCAAoB,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,EAC7C,IAAI,uCAAmB,CAAC,+DAA8B,CAAC,IAAI,EAAE,+DAA8B,CAAC,UAAU,CAAC,CAC1G,CAAC;IACN,CAAC;CACJ;AAbD,sFAaC"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.StaticTariffsDataSourceFactory = void 0;
|
|
4
|
+
const StaticTariffsJsonSchema_1 = require("../../schema-definitions/datasources/StaticTariffsJsonSchema");
|
|
4
5
|
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
6
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
5
7
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
6
|
-
const StaticTariffsJsonSchema_1 = require("../../schema-definitions/datasources/StaticTariffsJsonSchema");
|
|
7
8
|
class StaticTariffsDataSourceFactory {
|
|
8
9
|
static getDataSource(sourceUrl) {
|
|
9
|
-
return new datasources_1.DataSource("StaticTariffsDataSource", new
|
|
10
|
+
return new datasources_1.DataSource("StaticTariffsDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
10
11
|
headers: {},
|
|
11
12
|
method: "GET",
|
|
12
13
|
url: sourceUrl,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StaticTariffsDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/StaticTariffsDataSourceFactory.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"StaticTariffsDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/StaticTariffsDataSourceFactory.ts"],"names":[],"mappings":";;;AAAA,0GAAmF;AACnF,mFAAqG;AACrG,6IAA0I;AAC1I,mFAAkF;AAElF,MAAa,8BAA8B;IAChC,MAAM,CAAC,aAAa,CAAC,SAAiB;QACzC,OAAO,IAAI,wBAAU,CACjB,yBAAyB,EACzB,IAAI,qDAAyB,CAAC;YAC1B,OAAO,EAAE,EAAE;YACX,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,SAAS;SACjB,CAAC,EACF,IAAI,kCAAoB,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,EAC7C,IAAI,uCAAmB,CAAC,iDAAuB,CAAC,IAAI,EAAE,iDAAuB,CAAC,UAAU,CAAC,CAC5F,CAAC;IACN,CAAC;CACJ;AAbD,wEAaC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DataSource } from "@golemio/core/dist/integration-engine/datasources";
|
|
2
1
|
import { IConfiguration } from "@golemio/core/dist/integration-engine/config";
|
|
2
|
+
import { DataSource } from "@golemio/core/dist/integration-engine/datasources";
|
|
3
3
|
export declare class TskParkingDataSourceFactory {
|
|
4
4
|
private config;
|
|
5
5
|
private schemas;
|
|
@@ -13,14 +13,15 @@ var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.TskParkingDataSourceFactory = void 0;
|
|
16
|
-
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
17
|
-
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
18
16
|
const TskParkingMachinesSchema_1 = require("../../schema-definitions/datasources/TskParkingMachinesSchema");
|
|
19
17
|
const TskParkingSectionLevelSchema_1 = require("../../schema-definitions/datasources/TskParkingSectionLevelSchema");
|
|
20
|
-
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
21
|
-
const ioc_1 = require("@golemio/core/dist/integration-engine/ioc");
|
|
22
18
|
const TskParkingSectionSchema_1 = require("../../schema-definitions/datasources/TskParkingSectionSchema");
|
|
23
19
|
const TskParkingZoneTariffSchema_1 = require("../../schema-definitions/datasources/TskParkingZoneTariffSchema");
|
|
20
|
+
const datasources_1 = require("@golemio/core/dist/integration-engine/datasources");
|
|
21
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
22
|
+
const ioc_1 = require("@golemio/core/dist/integration-engine/ioc");
|
|
23
|
+
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
24
|
+
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
24
25
|
let TskParkingDataSourceFactory = exports.TskParkingDataSourceFactory = class TskParkingDataSourceFactory {
|
|
25
26
|
constructor(config) {
|
|
26
27
|
this.config = config;
|
|
@@ -34,7 +35,7 @@ let TskParkingDataSourceFactory = exports.TskParkingDataSourceFactory = class Ts
|
|
|
34
35
|
}
|
|
35
36
|
getDataSource(endpoint) {
|
|
36
37
|
const authToken = Buffer.from(this.config.datasources.parking.TskApiCredentials.user + ":" + this.config.datasources.parking.TskApiCredentials.pass).toString("base64");
|
|
37
|
-
return new datasources_1.DataSource(this.schemas[endpoint].name + "DataSource", new
|
|
38
|
+
return new datasources_1.DataSource(this.schemas[endpoint].name + "DataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
38
39
|
headers: {
|
|
39
40
|
Authorization: `Basic ${authToken}`,
|
|
40
41
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TskParkingDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/TskParkingDataSourceFactory.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"TskParkingDataSourceFactory.js","sourceRoot":"","sources":["../../../src/integration-engine/datasources/TskParkingDataSourceFactory.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,4GAAqF;AACrF,oHAA6F;AAC7F,0GAAmF;AACnF,gHAAyF;AAEzF,mFAAqG;AACrG,6IAA0I;AAC1I,mEAA2E;AAC3E,mFAAkF;AAClF,iEAAwE;AAUjE,IAAM,2BAA2B,yCAAjC,MAAM,2BAA2B;IASpC,YAA2C,MAA8B;QAAtB,WAAM,GAAN,MAAM,CAAgB;QARjE,YAAO,GAAsB;YACjC,eAAe,EAAE,iDAAuB;YACxC,sBAAsB,EAAE,2DAA4B;YACpD,sBAAsB,EAAE,2DAA4B;YACpD,eAAe,EAAE,mDAAwB;YACzC,cAAc,EAAE,uDAA0B;SAC7C,CAAC;IAE0E,CAAC;IAEtE,aAAa,CAAC,QAAgB;QACjC,MAAM,SAAS,GAAG,MAAM,CAAC,IAAI,CACzB,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,GAAG,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,iBAAiB,CAAC,IAAI,CACxH,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAErB,OAAO,IAAI,wBAAU,CACjB,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,GAAG,YAAY,EAC1C,IAAI,qDAAyB,CAAC;YAC1B,OAAO,EAAE;gBACL,aAAa,EAAE,SAAS,SAAS,EAAE;aACtC;YACD,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,eAAe,CAAC,QAAQ,CAAC;SACjH,CAAC,EACF,IAAI,kCAAoB,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,EAC7C,IAAI,uCAAmB,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,UAAU,CAAC,CAC1F,CAAC;IACN,CAAC;CACJ,CAAA;sCA7BY,2BAA2B;IADvC,IAAA,qBAAU,GAAE;IAUI,WAAA,IAAA,iBAAM,EAAC,oBAAc,CAAC,MAAM,CAAC,CAAA;;GATjC,2BAA2B,CA6BvC"}
|
|
@@ -9,24 +9,23 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
9
9
|
exports.IptOictDataSource = void 0;
|
|
10
10
|
const IptOictFeatureCollectionSchemaGenerator_1 = require("../../../schema-definitions/datasources/iptoict/IptOictFeatureCollectionSchemaGenerator");
|
|
11
11
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
12
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
12
13
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
13
14
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
14
15
|
let IptOictDataSource = exports.IptOictDataSource = class IptOictDataSource {
|
|
15
16
|
getParkingData(sourceUrl) {
|
|
16
|
-
return new integration_engine_1.DataSource("IptOictParkingDataSource", new
|
|
17
|
+
return new integration_engine_1.DataSource("IptOictParkingDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
17
18
|
method: "GET",
|
|
18
19
|
url: sourceUrl,
|
|
19
|
-
encoding: "utf8",
|
|
20
20
|
headers: {
|
|
21
21
|
"Content-Type": "application/json; charset=utf-8",
|
|
22
22
|
},
|
|
23
23
|
}), new integration_engine_1.JSONDataTypeStrategy({ resultsPath: "features" }), new golemio_validator_1.JSONSchemaValidator("IptOictParkingDataSourceValidator", IptOictFeatureCollectionSchemaGenerator_1.IptOictFeatureCollectionSchemaGenerator.getParkingSchema().properties.features)).getAll();
|
|
24
24
|
}
|
|
25
25
|
getParkingLocationData(sourceUrl) {
|
|
26
|
-
return new integration_engine_1.DataSource("IptOictParkingDataSource", new
|
|
26
|
+
return new integration_engine_1.DataSource("IptOictParkingDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
27
27
|
method: "GET",
|
|
28
28
|
url: sourceUrl,
|
|
29
|
-
encoding: "utf8",
|
|
30
29
|
headers: {
|
|
31
30
|
"Content-Type": "application/json; charset=utf-8",
|
|
32
31
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IptOictDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/iptoict/IptOictDataSource.ts"],"names":[],"mappings":";;;;;;;;;AAAA,qJAA2H;AAC3H,
|
|
1
|
+
{"version":3,"file":"IptOictDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/iptoict/IptOictDataSource.ts"],"names":[],"mappings":";;;;;;;;;AAAA,qJAA2H;AAC3H,8EAAyF;AACzF,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAgE;AAGzD,IAAM,iBAAiB,+BAAvB,MAAM,iBAAiB;IACnB,cAAc,CAAC,SAAiB;QACnC,OAAO,IAAI,+BAAU,CACjB,0BAA0B,EAC1B,IAAI,qDAAyB,CAAC;YAC1B,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,SAAS;YACd,OAAO,EAAE;gBACL,cAAc,EAAE,iCAAiC;aACpD;SACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CACnB,mCAAmC,EACnC,iFAAuC,CAAC,gBAAgB,EAAE,CAAC,UAAU,CAAC,QAAQ,CACjF,CACJ,CAAC,MAAM,EAAE,CAAC;IACf,CAAC;IAEM,sBAAsB,CAAC,SAAiB;QAC3C,OAAO,IAAI,+BAAU,CACjB,0BAA0B,EAC1B,IAAI,qDAAyB,CAAC;YAC1B,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,SAAS;YACd,OAAO,EAAE;gBACL,cAAc,EAAE,iCAAiC;aACpD;SACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CACnB,yCAAyC,EACzC,iFAAuC,CAAC,sBAAsB,EAAE,CAAC,UAAU,CAAC,QAAQ,CACvF,CACJ,CAAC,MAAM,EAAE,CAAC;IACf,CAAC;CACJ,CAAA;4BApCY,iBAAiB;IAD7B,IAAA,qBAAU,GAAE;GACA,iBAAiB,CAoC7B"}
|
|
@@ -25,6 +25,7 @@ exports.ManualEntrancesDatasource = void 0;
|
|
|
25
25
|
const IptOictFeatureCollectionSchemaGenerator_1 = require("../../../schema-definitions/datasources/iptoict/IptOictFeatureCollectionSchemaGenerator");
|
|
26
26
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
27
27
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
28
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
28
29
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
29
30
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
30
31
|
let ManualEntrancesDatasource = exports.ManualEntrancesDatasource = class ManualEntrancesDatasource {
|
|
@@ -34,7 +35,7 @@ let ManualEntrancesDatasource = exports.ManualEntrancesDatasource = class Manual
|
|
|
34
35
|
}
|
|
35
36
|
getManualEntrances() {
|
|
36
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
37
|
-
return new integration_engine_1.DataSource("ParkingOsmDataSource", new
|
|
38
|
+
return new integration_engine_1.DataSource("ParkingOsmDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
38
39
|
method: "GET",
|
|
39
40
|
url: this.url,
|
|
40
41
|
headers: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ManualEntrancesDatasource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/manual/ManualEntrancesDatasource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,qJAA2H;AAG3H,wEAAqE;AACrE,
|
|
1
|
+
{"version":3,"file":"ManualEntrancesDatasource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/manual/ManualEntrancesDatasource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,qJAA2H;AAG3H,wEAAqE;AACrE,8EAAyF;AACzF,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AAIjE,IAAM,yBAAyB,uCAA/B,MAAM,yBAAyB;IAGlC,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;QACrE,IAAI,CAAC,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,sDAAsD,CAAC,CAAC;IACpG,CAAC;IAEY,kBAAkB;;YAC3B,OAAO,IAAI,+BAAU,CACjB,sBAAsB,EACtB,IAAI,qDAAyB,CAAC;gBAC1B,MAAM,EAAE,KAAK;gBACb,GAAG,EAAE,IAAI,CAAC,GAAG;gBACb,OAAO,EAAE;oBACL,cAAc,EAAE,kBAAkB;iBACrC;aACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CACnB,kCAAkC,EAClC,iFAAuC,CAAC,yBAAyB,EAAE,CAAC,UAAU,CAAC,QAAQ,CAC1F,CACJ,CAAC,MAAM,EAAE,CAAC;QACf,CAAC;KAAA;CACJ,CAAA;oCAxBY,yBAAyB;IADrC,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAHlC,yBAAyB,CAwBrC"}
|
|
@@ -17,6 +17,7 @@ exports.MrParkitDataSourceProvider = void 0;
|
|
|
17
17
|
const MrParkitJsonSchema_1 = require("../../../schema-definitions/datasources/MrParkitJsonSchema");
|
|
18
18
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
19
19
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
20
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
20
21
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
21
22
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
22
23
|
let MrParkitDataSourceProvider = exports.MrParkitDataSourceProvider = MrParkitDataSourceProvider_1 = class MrParkitDataSourceProvider {
|
|
@@ -30,7 +31,7 @@ let MrParkitDataSourceProvider = exports.MrParkitDataSourceProvider = MrParkitDa
|
|
|
30
31
|
return new integration_engine_1.DataSource(MrParkitDataSourceProvider_1.DATASOURCE_NAME, this.getProtocolStrategy(url, apiVersion, apiKey), new integration_engine_1.JSONDataTypeStrategy({ resultsPath: "garages" }), new golemio_validator_1.JSONSchemaValidator(MrParkitDataSourceProvider_1.DATASOURCE_NAME, MrParkitJsonSchema_1.mrParkitJsonSchema));
|
|
31
32
|
}
|
|
32
33
|
getProtocolStrategy(url, apiVersion, apiKey) {
|
|
33
|
-
return new
|
|
34
|
+
return new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
34
35
|
method: "GET",
|
|
35
36
|
url: url,
|
|
36
37
|
headers: {
|
|
@@ -38,7 +39,7 @@ let MrParkitDataSourceProvider = exports.MrParkitDataSourceProvider = MrParkitDa
|
|
|
38
39
|
"x-api-version": apiVersion,
|
|
39
40
|
"x-api-key": apiKey,
|
|
40
41
|
},
|
|
41
|
-
|
|
42
|
+
timeoutInSeconds: 20,
|
|
42
43
|
});
|
|
43
44
|
}
|
|
44
45
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MrParkitDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/mr-parkit/MrParkitDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mGAAyE;AAGzE,wEAAqE;AACrE,
|
|
1
|
+
{"version":3,"file":"MrParkitDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/mr-parkit/MrParkitDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mGAAyE;AAGzE,wEAAqE;AACrE,8EAAsG;AACtG,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AAMjE,IAAM,0BAA0B,uEAAhC,MAAM,0BAA0B;IAGnC,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;IAAG,CAAC;IAEtE,aAAa;QAChB,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,iDAAiD,CAAC,CAAC;QAC5F,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,wDAAwD,CAAC,CAAC;QAC1G,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,oDAAoD,CAAC,CAAC;QAElG,OAAO,IAAI,+BAAU,CACjB,4BAA0B,CAAC,eAAe,EAC1C,IAAI,CAAC,mBAAmB,CAAC,GAAG,EAAE,UAAU,EAAE,MAAM,CAAC,EACjD,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,SAAS,EAAE,CAAC,EACpD,IAAI,uCAAmB,CAAC,4BAA0B,CAAC,eAAe,EAAE,uCAAkB,CAAC,CAC1F,CAAC;IACN,CAAC;IAEO,mBAAmB,CAAC,GAAW,EAAE,UAAkB,EAAE,MAAc;QACvE,OAAO,IAAI,qDAAyB,CAAC;YACjC,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,GAAG;YACR,OAAO,EAAE;gBACL,cAAc,EAAE,kBAAkB;gBAClC,eAAe,EAAE,UAAU;gBAC3B,WAAW,EAAE,MAAM;aACtB;YACD,gBAAgB,EAAE,EAAE;SACvB,CAAC,CAAC;IACP,CAAC;;AA5Bc,0CAAe,GAAG,oBAAoB,AAAvB,CAAwB;qCAD7C,0BAA0B;IADtC,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAHlC,0BAA0B,CA8BtC"}
|
|
@@ -25,6 +25,7 @@ exports.OsmDataSource = void 0;
|
|
|
25
25
|
const FeatureCollectionSchemaGenerator_1 = require("../../../schema-definitions/datasources/osm/FeatureCollectionSchemaGenerator");
|
|
26
26
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
27
27
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
28
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
28
29
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
29
30
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
30
31
|
let OsmDataSource = exports.OsmDataSource = class OsmDataSource {
|
|
@@ -35,7 +36,7 @@ let OsmDataSource = exports.OsmDataSource = class OsmDataSource {
|
|
|
35
36
|
}
|
|
36
37
|
getParkingsData() {
|
|
37
38
|
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
-
return new integration_engine_1.DataSource("ParkingOsmDataSource", new
|
|
39
|
+
return new integration_engine_1.DataSource("ParkingOsmDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
39
40
|
method: "GET",
|
|
40
41
|
url: this.parkingsUrl,
|
|
41
42
|
headers: {
|
|
@@ -46,7 +47,7 @@ let OsmDataSource = exports.OsmDataSource = class OsmDataSource {
|
|
|
46
47
|
}
|
|
47
48
|
getParkingsLocationData() {
|
|
48
49
|
return __awaiter(this, void 0, void 0, function* () {
|
|
49
|
-
return new integration_engine_1.DataSource("ParkingSpacesOsmDataSource", new
|
|
50
|
+
return new integration_engine_1.DataSource("ParkingSpacesOsmDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
50
51
|
method: "GET",
|
|
51
52
|
url: this.parkingsLocation,
|
|
52
53
|
headers: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OsmDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/osm/OsmDataSource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mIAA2F;AAI3F,wEAAqE;AACrE,
|
|
1
|
+
{"version":3,"file":"OsmDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/osm/OsmDataSource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mIAA2F;AAI3F,wEAAqE;AACrE,8EAAyF;AACzF,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AAIjE,IAAM,aAAa,2BAAnB,MAAM,aAAa;IAItB,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;QACrE,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,mDAAmD,CAAC,CAAC;QACrG,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,2DAA2D,CAAC,CAAC;IACtH,CAAC;IAEY,eAAe;;YACxB,OAAO,IAAI,+BAAU,CACjB,sBAAsB,EACtB,IAAI,qDAAyB,CAAC;gBAC1B,MAAM,EAAE,KAAK;gBACb,GAAG,EAAE,IAAI,CAAC,WAAW;gBACrB,OAAO,EAAE;oBACL,cAAc,EAAE,kBAAkB;iBACrC;aACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CAAC,+BAA+B,EAAE,qDAAkB,CAAC,gBAAgB,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CACtH,CAAC,MAAM,EAAE,CAAC;QACf,CAAC;KAAA;IAEY,uBAAuB;;YAChC,OAAO,IAAI,+BAAU,CACjB,4BAA4B,EAC5B,IAAI,qDAAyB,CAAC;gBAC1B,MAAM,EAAE,KAAK;gBACb,GAAG,EAAE,IAAI,CAAC,gBAAgB;gBAC1B,OAAO,EAAE;oBACL,cAAc,EAAE,kBAAkB;iBACrC;aACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CACnB,+BAA+B,EAC/B,qDAAkB,CAAC,sBAAsB,EAAE,CAAC,UAAU,CAAC,QAAQ,CAClE,CACJ,CAAC,MAAM,EAAE,CAAC;QACf,CAAC;KAAA;CACJ,CAAA;wBAzCY,aAAa;IADzB,IAAA,qBAAU,GAAE;IAKI,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAJlC,aAAa,CAyCzB"}
|
|
@@ -25,6 +25,7 @@ exports.OsmEntrancesDataSource = void 0;
|
|
|
25
25
|
const FeatureCollectionSchemaGenerator_1 = require("../../../schema-definitions/datasources/osm/FeatureCollectionSchemaGenerator");
|
|
26
26
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
27
27
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
28
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
28
29
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
29
30
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
30
31
|
let OsmEntrancesDataSource = exports.OsmEntrancesDataSource = class OsmEntrancesDataSource {
|
|
@@ -34,7 +35,7 @@ let OsmEntrancesDataSource = exports.OsmEntrancesDataSource = class OsmEntrances
|
|
|
34
35
|
}
|
|
35
36
|
getOsmEntrances() {
|
|
36
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
37
|
-
return new integration_engine_1.DataSource("OsmEntrancesDataSource", new
|
|
38
|
+
return new integration_engine_1.DataSource("OsmEntrancesDataSource", new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
38
39
|
method: "GET",
|
|
39
40
|
url: this.url,
|
|
40
41
|
headers: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OsmEntrancesDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/osm/OsmEntrancesDataSource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mIAA2F;AAG3F,wEAAqE;AACrE,
|
|
1
|
+
{"version":3,"file":"OsmEntrancesDataSource.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/osm/OsmEntrancesDataSource.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mIAA2F;AAG3F,wEAAqE;AACrE,8EAAyF;AACzF,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AAIjE,IAAM,sBAAsB,oCAA5B,MAAM,sBAAsB;IAG/B,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;QACrE,IAAI,CAAC,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,qDAAqD,CAAC,CAAC;IACnG,CAAC;IAEY,eAAe;;YACxB,OAAO,IAAI,+BAAU,CACjB,wBAAwB,EACxB,IAAI,qDAAyB,CAAC;gBAC1B,MAAM,EAAE,KAAK;gBACb,GAAG,EAAE,IAAI,CAAC,GAAG;gBACb,OAAO,EAAE;oBACL,cAAc,EAAE,kBAAkB;iBACrC;aACJ,CAAC,EACF,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC,EACrD,IAAI,uCAAmB,CAAC,iCAAiC,EAAE,qDAAkB,CAAC,iBAAiB,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CACzH,CAAC,MAAM,EAAE,CAAC;QACf,CAAC;KAAA;CACJ,CAAA;iCArBY,sBAAsB;IADlC,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAHlC,sBAAsB,CAqBlC"}
|
package/dist/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { ISmart4CityList } from "../../../schema-definitions/datasources/interfaces/ISmart4CityList";
|
|
1
2
|
import { ISimpleConfig } from "@golemio/core/dist/helpers/configuration/ISimpleConfig";
|
|
2
3
|
import { IDataSource } from "@golemio/core/dist/integration-engine";
|
|
3
4
|
import { IDataSourceProvider } from "../interfaces/IDataSourceProvider";
|
|
4
|
-
import { ISmart4CityList } from "../../../schema-definitions/datasources/interfaces/ISmart4CityList";
|
|
5
5
|
export declare class Smart4CityListDataSourceProvider implements IDataSourceProvider<ISmart4CityList[]> {
|
|
6
6
|
private config;
|
|
7
7
|
private static DATASOURCE_NAME;
|
|
@@ -14,11 +14,12 @@ var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
|
14
14
|
var Smart4CityListDataSourceProvider_1;
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.Smart4CityListDataSourceProvider = void 0;
|
|
17
|
+
const Smart4CityListJsonSchema_1 = require("../../../schema-definitions/datasources/Smart4CityListJsonSchema");
|
|
17
18
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
18
19
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
20
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
19
21
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
20
22
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
21
|
-
const Smart4CityListJsonSchema_1 = require("../../../schema-definitions/datasources/Smart4CityListJsonSchema");
|
|
22
23
|
let Smart4CityListDataSourceProvider = exports.Smart4CityListDataSourceProvider = Smart4CityListDataSourceProvider_1 = class Smart4CityListDataSourceProvider {
|
|
23
24
|
constructor(config) {
|
|
24
25
|
this.config = config;
|
|
@@ -28,7 +29,7 @@ let Smart4CityListDataSourceProvider = exports.Smart4CityListDataSourceProvider
|
|
|
28
29
|
}
|
|
29
30
|
getProtocolStrategy() {
|
|
30
31
|
const url = new URL(this.config.getValue("old.datasources.parking.Smart4City.ApiBaseUrl"));
|
|
31
|
-
return new
|
|
32
|
+
return new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
32
33
|
method: "GET",
|
|
33
34
|
url: url.toString(),
|
|
34
35
|
headers: { "Content-Type": "application/json" },
|
package/dist/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smart4CityListDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"Smart4CityListDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/smart4city/Smart4CityListDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+GAAqF;AAGrF,wEAAqE;AACrE,8EAAsG;AACtG,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AAIjE,IAAM,gCAAgC,mFAAtC,MAAM,gCAAgC;IAGzC,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;IAAG,CAAC;IAEtE,aAAa;QAChB,OAAO,IAAI,+BAAU,CACjB,kCAAgC,CAAC,eAAe,EAChD,IAAI,CAAC,mBAAmB,EAAE,EAC1B,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC,EACnD,IAAI,uCAAmB,CAAC,kCAAgC,CAAC,eAAe,EAAE,mDAAwB,CAAC,CACtG,CAAC;IACN,CAAC;IAEO,mBAAmB;QACvB,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,+CAA+C,CAAC,CAAC,CAAC;QAEnG,OAAO,IAAI,qDAAyB,CAAC;YACjC,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,GAAG,CAAC,QAAQ,EAAE;YACnB,OAAO,EAAE,EAAE,cAAc,EAAE,kBAAkB,EAAE;SAClD,CAAC,CAAC;IACP,CAAC;;AArBc,gDAAe,GAAG,0BAA0B,AAA7B,CAA8B;2CADnD,gCAAgC;IAD5C,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAHlC,gCAAgC,CAuB5C"}
|
package/dist/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.js
CHANGED
|
@@ -20,6 +20,7 @@ exports.Smart4CityLocationDataSourceProvider = void 0;
|
|
|
20
20
|
const Smart4CityLocationJsonSchema_1 = require("../../../schema-definitions/datasources/Smart4CityLocationJsonSchema");
|
|
21
21
|
const CoreToken_1 = require("@golemio/core/dist/helpers/ioc/CoreToken");
|
|
22
22
|
const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
23
|
+
const HTTPFetchProtocolStrategy_1 = require("@golemio/core/dist/integration-engine/datasources/protocol-strategy/HTTPFetchProtocolStrategy");
|
|
23
24
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
24
25
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
25
26
|
const path_1 = __importDefault(require("path"));
|
|
@@ -33,7 +34,7 @@ let Smart4CityLocationDataSourceProvider = exports.Smart4CityLocationDataSourceP
|
|
|
33
34
|
getProtocolStrategy(cityCode) {
|
|
34
35
|
const url = new URL(this.config.getValue("old.datasources.parking.Smart4City.ApiBaseUrl"));
|
|
35
36
|
url.pathname = path_1.default.join(url.pathname, cityCode, "/parkinglocations");
|
|
36
|
-
return new
|
|
37
|
+
return new HTTPFetchProtocolStrategy_1.HTTPFetchProtocolStrategy({
|
|
37
38
|
method: "GET",
|
|
38
39
|
url: url.toString(),
|
|
39
40
|
headers: { "Content-Type": "application/json" },
|
package/dist/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Smart4CityLocationDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"Smart4CityLocationDataSourceProvider.js","sourceRoot":"","sources":["../../../../src/integration-engine/datasources/smart4city/Smart4CityLocationDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,uHAA6F;AAG7F,wEAAqE;AACrE,8EAAsG;AACtG,6IAA0I;AAC1I,mFAAkF;AAClF,iEAAwE;AACxE,gDAAwB;AAIjB,IAAM,oCAAoC,2FAA1C,MAAM,oCAAoC;IAG7C,YAAoD,MAAqB;QAArB,WAAM,GAAN,MAAM,CAAe;IAAG,CAAC;IAEtE,aAAa,CAAC,QAAgB;QACjC,OAAO,IAAI,+BAAU,CACjB,sCAAoC,CAAC,eAAe,EACpD,IAAI,CAAC,mBAAmB,CAAC,QAAQ,CAAC,EAClC,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,kBAAkB,EAAE,CAAC,EAC7D,IAAI,uCAAmB,CAAC,sCAAoC,CAAC,eAAe,EAAE,2DAA4B,CAAC,CAC9G,CAAC;IACN,CAAC;IAEO,mBAAmB,CAAC,QAAgB;QACxC,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAS,+CAA+C,CAAC,CAAC,CAAC;QACnG,GAAG,CAAC,QAAQ,GAAG,cAAI,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,EAAE,QAAQ,EAAE,mBAAmB,CAAC,CAAC;QAEtE,OAAO,IAAI,qDAAyB,CAAC;YACjC,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,GAAG,CAAC,QAAQ,EAAE;YACnB,OAAO,EAAE,EAAE,cAAc,EAAE,kBAAkB,EAAE;SAClD,CAAC,CAAC;IACP,CAAC;;AAtBc,oDAAe,GAAG,8BAA8B,AAAjC,CAAkC;+CADvD,oCAAoC;IADhD,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,qBAAS,CAAC,YAAY,CAAC,CAAA;;GAHlC,oCAAoC,CAwBhD"}
|