summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrii Kalinich (GitHub) <AKalinich@luxoft.com>2018-06-05 20:08:44 +0300
committerGitHub <noreply@github.com>2018-06-05 20:08:44 +0300
commita7ba8634cc5de72d0a5bd8249ecbe38083d8c934 (patch)
tree416ca3931570624da7fb7464041d3ede6e4f19a8
parent112c685ae48d7cf939e3d2147453de1719862ec6 (diff)
parent31ed739ba05c6702600f76645132b40d8392587b (diff)
downloadsdl_core-a7ba8634cc5de72d0a5bd8249ecbe38083d8c934.tar.gz
Merge branch 'develop' into feature/get_system_time
-rw-r--r--.gitignore1
-rw-r--r--CHANGELOG.md153
-rw-r--r--CMakeLists.txt63
-rw-r--r--Doxyfile2
-rw-r--r--docs/SDL.SDD.Template.dox (renamed from docs/FORD.OpenSDL.SDD.TPL.dox)38
-rw-r--r--docs/mainpage.dox4
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/examples/cpp/console.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetdecoder.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetencoder.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/inputstreamreader.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/locationinfo.cpp6
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/loggingevent.cpp6
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/objectoutputstream.cpp10
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/serversocket.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/sockethubappender.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/socketoutputstream.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/threadcxx.cpp2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/logger.h2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/location/locationinfo.h2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/loggingevent.h2
-rw-r--r--src/3rd_party/apache-log4cxx-0.10.0/src/test/cpp/xml/domtestcase.cpp10
-rw-r--r--src/appMain/CMakeLists.txt4
-rwxr-xr-xsrc/appMain/hmi_capabilities.json13
-rw-r--r--src/appMain/sdl_preloaded_pt.json12
-rw-r--r--src/components/application_manager/include/application_manager/application.h9
-rw-r--r--src/components/application_manager/include/application_manager/application_data_impl.h10
-rw-r--r--src/components/application_manager/include/application_manager/request_controller.h7
-rw-r--r--src/components/application_manager/include/application_manager/smart_object_keys.h14
-rw-r--r--src/components/application_manager/src/application_data_impl.cc49
-rw-r--r--src/components/application_manager/src/application_manager_impl.cc7
-rw-r--r--src/components/application_manager/src/commands/mobile/put_file_request.cc46
-rw-r--r--src/components/application_manager/src/commands/mobile/register_app_interface_request.cc30
-rw-r--r--src/components/application_manager/src/commands/mobile/set_app_icon_request.cc12
-rw-r--r--src/components/application_manager/src/commands/mobile/set_display_layout_request.cc55
-rw-r--r--src/components/application_manager/src/hmi_capabilities_impl.cc3
-rw-r--r--src/components/application_manager/src/message_helper/message_helper.cc16
-rw-r--r--src/components/application_manager/src/policies/policy_handler.cc3
-rw-r--r--src/components/application_manager/src/request_controller.cc35
-rw-r--r--src/components/application_manager/src/smart_object_keys.cc14
-rw-r--r--src/components/application_manager/test/application_manager_impl_test.cc48
-rw-r--r--src/components/application_manager/test/commands/mobile/put_file_test.cc59
-rw-r--r--src/components/application_manager/test/commands/mobile/set_app_icon_test.cc23
-rw-r--r--src/components/application_manager/test/commands/mobile/set_display_layout_test.cc2
-rw-r--r--src/components/application_manager/test/commands/mobile/slider_test.cc5
-rw-r--r--src/components/application_manager/test/hmi_capabilities.json10
-rw-r--r--src/components/application_manager/test/include/application_manager/mock_application.h8
-rw-r--r--src/components/application_manager/test/policy_handler_test.cc1
-rw-r--r--src/components/application_manager/test/request_controller/request_controller_test.cc36
-rw-r--r--src/components/application_manager/test/resumption/resumption_data_db_test.cc4
-rw-r--r--src/components/application_manager/test/resumption/resumption_data_test.cc1
-rw-r--r--src/components/application_manager/test/resumption_sql_queries_test.cc213
-rw-r--r--src/components/application_manager/test/sdl_preloaded_pt.json10
-rw-r--r--src/components/application_manager/test/sdl_pt_update.json12
-rw-r--r--src/components/hmi_message_handler/include/hmi_message_handler/mb_controller.h30
-rw-r--r--src/components/hmi_message_handler/include/hmi_message_handler/websocket_session.h30
-rw-r--r--src/components/hmi_message_handler/src/mb_controller.cc29
-rw-r--r--src/components/hmi_message_handler/src/websocket_session.cc30
-rw-r--r--src/components/interfaces/HMI_API.xml139
-rw-r--r--src/components/interfaces/MOBILE_API.xml156
-rw-r--r--src/components/policy/policy_external/include/policy/policy_table/enums.h2
-rw-r--r--src/components/policy/policy_external/include/policy/policy_table_interface_ext.xml2
-rw-r--r--src/components/policy/policy_external/src/policy_manager_impl.cc24
-rw-r--r--src/components/policy/policy_external/src/policy_table/enums.cc14
-rw-r--r--src/components/policy/policy_external/src/sql_pt_representation.cc8
-rw-r--r--src/components/policy/policy_external/test/json/PTU.json10
-rw-r--r--src/components/policy/policy_external/test/json/PTU2.json10
-rw-r--r--src/components/policy/policy_external/test/json/PTU3.json10
-rw-r--r--src/components/policy/policy_external/test/json/PTU_default_app.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_default_app_app_invalid_values_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_default_app_empty_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_default_app_omitted_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_default_app_one_invalid_value_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_pre_data_consent_app.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_empty_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_invalid_values_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_omitted_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_one_invalid_value_RequestType_array.json4
-rw-r--r--src/components/policy/policy_external/test/json/PTU_with_empty_requestType_array.json12
-rw-r--r--src/components/policy/policy_external/test/json/PTU_with_invalid_requestType_between_correct.json12
-rw-r--r--src/components/policy/policy_external/test/json/PTU_with_one_invalid_requestType.json12
-rw-r--r--src/components/policy/policy_external/test/json/PTU_without_requestType_field.json12
-rw-r--r--src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_reqestType_between_valid.json10
-rw-r--r--src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_requestType.json10
-rw-r--r--src/components/policy/policy_external/test/json/preloadedPT_with_several_invalid_default_requestTypes.json10
-rw-r--r--src/components/policy/policy_external/test/json/ptu2_requestType.json14
-rw-r--r--src/components/policy/policy_external/test/json/ptu_requestType.json14
-rw-r--r--src/components/policy/policy_external/test/json/sdl_preloaded_pt.json10
-rw-r--r--src/components/policy/policy_external/test/json/sdl_preloaded_pt1.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_preloaded_pt_send_location.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_pt_first_update.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_pt_second_update.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_pt_update.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_have_params.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1_omitted_in2.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_send_location.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_send_location_all_params.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_send_location_no_params.json12
-rw-r--r--src/components/policy/policy_external/test/json/sdl_update_pt_send_location_some_params.json12
-rw-r--r--src/components/policy/policy_external/test/json/valid_sdl_pt_update.json12
-rw-r--r--src/components/policy/policy_external/test/policy_manager_impl_ptu_test.cc3
-rw-r--r--src/components/policy/policy_external/test/policy_manager_impl_test_base.cc6
-rw-r--r--src/components/policy/policy_regular/include/policy/policy_table/enums.h2
-rw-r--r--src/components/policy/policy_regular/policy_table_interface_ext.xml3
-rw-r--r--src/components/policy/policy_regular/src/policy_manager_impl.cc10
-rw-r--r--src/components/policy/policy_regular/src/policy_table/enums.cc14
-rw-r--r--src/components/policy/policy_regular/test/PTU.json10
-rw-r--r--src/components/policy/policy_regular/test/PTU2.json10
-rw-r--r--src/components/policy/policy_regular/test/PTU3.json10
-rw-r--r--src/components/policy/policy_regular/test/PTU4.json10
-rw-r--r--src/components/policy/policy_regular/test/policy_manager_impl_test.cc2
-rw-r--r--src/components/policy/policy_regular/test/ptu2_requestType.json14
-rw-r--r--src/components/policy/policy_regular/test/ptu_requestType.json14
-rw-r--r--src/components/policy/policy_regular/test/sdl_preloaded_pt.json10
-rw-r--r--src/components/policy/policy_regular/test/sdl_pt_first_update.json12
-rw-r--r--src/components/policy/policy_regular/test/sdl_pt_second_update.json12
-rw-r--r--src/components/policy/policy_regular/test/sdl_pt_update.json12
-rw-r--r--src/components/policy/policy_regular/test/valid_sdl_pt_update.json12
-rw-r--r--src/components/remote_control/test/include/mock_application.h8
-rw-r--r--src/components/security_manager/docs/SDL.SDD.Security.dox (renamed from src/components/security_manager/docs/FORD.OpenSDL.SDD.Security.dox)28
-rw-r--r--src/components/security_manager/docs/assets/sm_class_diagram.png (renamed from src/components/security_manager/docs/assets/sm_class_digram.png)bin368935 -> 368935 bytes
-rw-r--r--src/components/security_manager/docs/assets/sm_sequence_diagram_decryption.png (renamed from src/components/security_manager/docs/assets/sm_sequence_digram_decryption.png)bin28014 -> 28014 bytes
-rw-r--r--src/components/security_manager/docs/assets/sm_sequence_diagram_encryption.png (renamed from src/components/security_manager/docs/assets/sm_sequence_digram_encryption.png)bin22326 -> 22326 bytes
-rw-r--r--src/components/security_manager/docs/assets/sm_sequence_diagram_init.png (renamed from src/components/security_manager/docs/assets/sm_sequence_digram_init.png)bin119018 -> 119018 bytes
-rw-r--r--src/components/security_manager/docs/assets/sm_sequence_diagram_verify.png (renamed from src/components/security_manager/docs/assets/sm_sequence_digram_verify.png)bin39820 -> 39820 bytes
-rw-r--r--src/components/security_manager/src/crypto_manager_impl.cc5
-rw-r--r--src/components/security_manager/src/ssl_context_impl.cc2
-rw-r--r--src/components/security_manager/test/ssl_context_test.cc59
-rw-r--r--src/components/smart_objects/include/smart_objects/number_schema_item.h16
-rw-r--r--src/components/smart_objects/src/number_schema_item.cc2
-rw-r--r--src/components/utils/src/file_system.cc25
-rw-r--r--src/components/utils/test/policy.sql2
133 files changed, 1822 insertions, 385 deletions
diff --git a/.gitignore b/.gitignore
index c552e22d6c..ec291473fe 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,3 +5,4 @@ CMakeCache.txt
CMakeFiles/
*.pyc
.idea
+src/appMain/build_config.txt
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7b97dd0471..481f63a805 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,92 +1,61 @@
-# 4.3.0 Release Candidate
-
-## New Features
-
-### EXTENDED_POLICY modes:
-- The `EXTENDED_POLICY` CMake variable (previously `ENABLE_EXTENDED_POLICY`) now has three possible configurations
- - `HTTP` (previously `ENABLE_EXTENDED_POLICY: OFF`) - #941
- - `PROPRIETARY` (previously `ENABLE_EXTENDED_POLICY: ON`) - #940
- - `EXTERNAL_PROPRIETARY` (new, fully featured version of `PROPRIETARY` mode) - #942
-
-### EXTERNAL_PROPRIETARY mode:
-#### New policy table update sequence
-A new policy table update flow was created specifically for the `EXTERNAL_PROPRIETARY` policy mode
-
-- Requirements/Details - #933
-- Diagram - https://user-images.githubusercontent.com/10549248/26896053-9417c604-4b91-11e7-9e47-524c930eb542.png
-
-#### External Policy Manager
-As part of the `EXTERNAL_PROPRIETARY` policy mode, the concept of an "external policy manager" is necessary. This policy manager is a separate program which is in charge of encrypting/decrypting policy tables and attaching an HTTP header to the OnSystemRequest payload when performing a Policy Table Update.
-
-As part of this release, a sample application which performs this function was added to this repository for those who wish to implement this new policy mode, and this program can be started along with Core using an included bash script. This sample application does nothing with the policy table snapshot during the encryption and decryption phases, allowing for OEMs to implement their own encryption algorithms in their place.
-
-#### App permissions/User consent
-Users can now control what functional groups that they want apps to be able to access, as well as decide whether to enable SDL functionality at all on a device-by-device basis.
-
- - Logic was added to allow the user to control what devices are permitted to use SDL functionality - #934
- - Users are prompted when activating an app on a new device for the first time whether or not to allow the device to use SDL functionality (sequence shown in [this diagram](https://user-images.githubusercontent.com/10549248/26897493-ba378f2c-4b96-11e7-93b0-b24f01c7dc28.png))
- - Logic was added to the Policy Manager to allow the user to control what apps have access to specific functional groups - #939
- - Users are prompted when activating an app for the first time (or modifying permissions in settings) with information on what access a requested functional group requires. The user responds to determine whether or not to allow this functionality within the new app (sequence shown in [this diagram](https://user-images.githubusercontent.com/10549248/26902322-e6e02bf0-4ba6-11e7-98b3-c285396061a4.png))
-
-
-#### External user consent
-External user consent allows the HMI to define several groups of permissions within the policy table. This allows the user to enable/disable several functional groups at once.
-
- - The `externalConsentStatus` field is included as part of a GetListOfPermissions response from SDL Core to communicate which groups are activated - #1047
- - External consent groups can be used to enable sets of functional groups using the `disallowed_by_external_consent_entities_off` field in the Policy Table - #1049
- - If this external consent group is set to `ON`, all functional groupings with this parameter are allowed by the user - #1048
- - If this external consent group is set to `OFF`, all functional groupings with this parameter are disallowed by the user - #1050
- - External consent groups can be used to disable sets of functional groups using the `disallowed_by_external_consent_entities_on` field in the Policy Table
- - If this external consent group is set to `ON`, all functional groupings with this parameter are disallowed by the user
- - If this external consent group is set to `OFF`, all functional groupings with this parameter are allowed by the user
-
-#### Cache Manager Function Implementations
-Prior to this release, several functions included in cache_manager.cc were not fully implemented and would not query the local policy table for defined rules and policies. The newly implemented functions for the `EXTERNAL_PROPRIETARY` cache manager are listed below:
- - [CanAppKeepContext()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L310)
- - [CanAppStealFocus()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L363)
- - [GetDefaultHMI()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L374)
- - [ResetUserConsent()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L391)
- - [GetUserPermissionsForDevice()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L406)
- - [GetPreconsentedGroups()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L477)
- - [GetConsentedGroups()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L514)
- - [GetUnconsentedGroups()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L549)
- - [RemoveAppConsentForGroup()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L605)
- - [GetDeviceGroupsFromPolicies()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L799)
- - [SetDeviceData()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L975)
- - [SetUserPermissionsForDevice()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1008)
- - [ReactOnUserDevConsentForApp()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1043)
- - [SetUserPermissionsForApp()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1076)
- - [CountUnconsentedGroups()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1768)
- - [SetMetaInfo()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1868)
- - [IsMetaInfoPresent()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1884)
- - [SetSystemLanguage()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1893)
- - [CleanupUnpairedDevices()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L1919)
- - [SetVinValue()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L2175)
- - [ResetPT()](https://github.com/smartdevicelink/sdl_core/blob/release/4.3.0/src/components/policy/policy_external/src/cache_manager.cc#L2309)
-
-#### Security behavior
-Requirements/Details - #937
-
-### HMI_API additions:
-
-A new RPC was added as part of the implementation of `EXTERNAL_PROPRIETARY` policy mode
-
- - [DecryptCertificate](https://github.com/smartdevicelink/sdl_core/blob/6283aa26e262d2d16ed1393989d8e0e062dba88d/src/components/interfaces/HMI_API.xml#L2468-L2476) RPC
-
-Several API additions were made as part of the implementation of the external user consent feature
-
- - [EntityStatus](https://github.com/smartdevicelink/sdl_core/blob/6283aa26e262d2d16ed1393989d8e0e062dba88d/src/components/interfaces/HMI_API.xml#L1263-L1266) enum
- - [ExternalConsentStatus](https://github.com/smartdevicelink/sdl_core/blob/6283aa26e262d2d16ed1393989d8e0e062dba88d/src/components/interfaces/HMI_API.xml#L1268-L1278) struct
- - externalConsentStatus field added to [OnAppPermissionConsent](https://github.com/smartdevicelink/sdl_core/blob/6283aa26e262d2d16ed1393989d8e0e062dba88d/src/components/interfaces/HMI_API.xml#L4170-L4172) and [GetListOfPermissions](https://github.com/smartdevicelink/sdl_core/blob/6283aa26e262d2d16ed1393989d8e0e062dba88d/src/components/interfaces/HMI_API.xml#L4170-L4172)
-
-## Fixes
-- Includes fixes for all defects found by the Coverity scan tool that were introduced in this release - #1641
-- Includes fixes for several Coverity defects that were previously implemented in the `coverity` branch - #1637
-
-## Implemented proposals
-Two new evolution proposals were implemented in release 4.3.0:
-
-- Add API Patch Version [SDL-0050](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0050-add-api-patch-version.md)
- - A patch version was added to the MOBILE API version, HMI API interface versions, and SyncMsgVersion struct
-- External Policy Manager [SDL-0045](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0045-external-policy-manager.md)
- - Details for the implementation of this proposal can be found in the `External Policy Manager` section of these release notes
+# Release 4.5.0
+
+## Supported Specifications
+- SDL Mobile RPC Spec: [Version 4.5.0](https://github.com/smartdevicelink/rpc_spec/releases/tag/4.5.0)
+- SDL Protocol Spec: [Version 5.0.0](https://github.com/smartdevicelink/protocol_spec/releases/tag/5.0.0)
+
+## Implemented Proposals
+
+[Connectivity via iAP-BT and Transport Switch](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0053-Connectivity-via-iAP-BT-and-Transport-Switch.md) - Implementation of a mechanism to change a registered app connected over one transport to another seamlessly.
+
+[Mark public deprecated methods](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0092-Deprecated-interfaces-markup.md) - Implemented a DEPRECATED macro for marking deprecated methods in the project. Using methods marked with this macro will result in a warning being generated.
+
+[Remove QT HMI from SDL Core (Partially Complete)](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0110-remove-qt-hmi-from-sdl-core.md) - The `qt_hmi` component was removed from SDL Core, the QT_HMI_API interface and dbus adapter will be removed in the next major release, due to this aspect of the proposal requiring breaking changes.
+
+[Use Boost Library (Partially Complete)](https://github.com/smartdevicelink/sdl_evolution/blob/master/proposals/0044-use-Boost-library.md) - The `boost` library is now installed as a 3rd party library, this library is currently only used in the refactored message broker component.
+
+## Enhancements
+- `DBus` and `libusb` are now dynamically linked, instead of being installed as 3rd-party libraries during the SDL Core build - #2004
+
+## Bug Fixes
+- [Remove OEM Specific references in SDL policy table preload file](https://github.com/smartdevicelink/sdl_core/issues/1252)
+- ["resultCode" should be more descriptive than "INVALID_DATA"](https://github.com/smartdevicelink/sdl_core/issues/31)
+- [SDL doesn't apply sequence SUSPEND -> OnSDLAwake -> SUSPEND -> IGN_OFF for saving resumption data](https://github.com/smartdevicelink/sdl_core/issues/1395)
+- [SDL responds "resultCode: SUCCESS" while dataType:VEHICLEDATA_EXTERNTEMP is VEHICLE_DATA_NOT_AVAILABLE and not in subscribed list store](https://github.com/smartdevicelink/sdl_core/issues/982)
+- [Policies SDL should be case-insensetive to "AppID" against listed in policies manager](https://github.com/smartdevicelink/sdl_core/issues/992)
+- [App is disconnected due to PROTOCOL_VIOLATION when start audio streaming after rejected 2 times then accepted](https://github.com/smartdevicelink/sdl_core/issues/1004)
+- [SDL doesn't set unsuccessful "message" value to "info" param in case HMI responds via single UI.RPC when Interface.IsReady missing](https://github.com/smartdevicelink/sdl_core/issues/997)
+- [Navigation SDL does not respond info message in case GENERIC_ERROR watchdog timeout from HMI](https://github.com/smartdevicelink/sdl_core/issues/990)
+- [SDL does not respond info message in case GENERIC_ERROR watchdog timeout from HM](https://github.com/smartdevicelink/sdl_core/issues/1012)
+- [SDL doesn't send info parameter when result of ResetGlobalProperties is GENERIC_ERROR](https://github.com/smartdevicelink/sdl_core/issues/1016)
+- [SDL does not send StopAudioStream() if exit app while Video service and Audio service are starting.](https://github.com/smartdevicelink/sdl_core/issues/1002)
+- [APIs AlertManeuver: SDL responds GENERIC_ERROR instead of INVALID_DATA when soft button has Type is Image or Both and Text is whitespace or \t or \n or empty](https://github.com/smartdevicelink/sdl_core/issues/980)
+- [IVSU SDL doesn't reject SystemRequest with filenam=IVSU but w/o binary data.](https://github.com/smartdevicelink/sdl_core/issues/976)
+- [Memory leaks: SDL does not release memory after sending AddCommand limit exhausted](https://github.com/smartdevicelink/sdl_core/issues/1029)
+- [Negative result code send instead of IGNORED for UnsubscribedVehicleData when VehicleInfo IsReady Missing](https://github.com/smartdevicelink/sdl_core/issues/996)
+- [API SDL responds "UNSUPPORTED_RESOURCE", success= false in case only have "UNSUPPORTED_RESOURCE" to Navigation.AlertManeuver](https://github.com/smartdevicelink/sdl_core/issues/989)
+- [Default app policies are never updated after a PTU](https://github.com/smartdevicelink/sdl_core/issues/1772)
+- [Build fails with GCC6+](https://github.com/smartdevicelink/sdl_core/issues/1975)
+- [Remote Control test suite fails](https://github.com/smartdevicelink/sdl_core/issues/1993)
+- [PoliciesManager allows all requested params in case "parameters" field is empty](https://github.com/smartdevicelink/sdl_core/issues/1873)
+- [OnDriverDistraction SDL does not send notification to app right after this app changes level from NONE to any other](https://github.com/smartdevicelink/sdl_core/issues/1881)
+- [Protect access to Resumption data during LastState::SaveStateToFileSystem](https://github.com/smartdevicelink/sdl_core/issues/1953)
+- [Need to protect cache manager "pt_" from concurrent access](https://github.com/smartdevicelink/sdl_core/issues/1961)
+- [Prevent deadlock in EventDispatcherIimpl::raise_event](https://github.com/smartdevicelink/sdl_core/issues/1949)
+- [Bluetooth StartService fail after Core restarted](https://github.com/smartdevicelink/sdl_core/issues/1932)
+- [Silent error caused by implicit conversion of SmartPointer to integer](https://github.com/smartdevicelink/sdl_core/issues/1834)
+- [AOA USB transport buffer size too small](https://github.com/smartdevicelink/sdl_core/issues/1863)
+- [Lock screen icon URL should be updated](https://github.com/smartdevicelink/sdl_core/issues/1646)
+- [Broken link in README.md for Software Architecture Documentation](https://github.com/smartdevicelink/sdl_core/issues/2091)
+- [SDL doesn't send OnPermissionsChange in case of external user consent](https://github.com/smartdevicelink/sdl_core/issues/2072)
+- [Build fails when ENABLE_SECURITY=OFF](https://github.com/smartdevicelink/sdl_core/issues/2073)
+
+### Security Related Fixes
+- [SDL must start PTU for navi app right after app successfully registration](https://github.com/smartdevicelink/sdl_core/issues/1925)
+- [SDL must start PTU for any app except navi right after app successfully request to start first secure service](https://github.com/smartdevicelink/sdl_core/issues/1924)
+- [PolicyTableUpdate is failed by any reason and "ForceProtectedService"=ON at .ini file](https://github.com/smartdevicelink/sdl_core/issues/1923)
+- [PolicyTableUpdate has NO "certificate" and "ForceProtectedService"=ON at .ini file](https://github.com/smartdevicelink/sdl_core/issues/1922)
+- [SDL must respond NACK in case navigation app connected over protocol v2 sends StartService for audio service](https://github.com/smartdevicelink/sdl_core/issues/1912)
+- [PolicyTableUpdate has NO "certificate" and "ForceProtectedService"=OFF at .ini file](https://github.com/smartdevicelink/sdl_core/issues/1894)
+- [PolicyTableUpdate is failed by any reason and "ForceProtectedService"=OFF at .ini file](https://github.com/smartdevicelink/sdl_core/issues/1891)
+- [PolicyTableUpdate is valid and brings "certificate"](https://github.com/smartdevicelink/sdl_core/issues/1888)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 450a9192f3..49959597a9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -163,6 +163,65 @@ endif()
#Jenkins integration section end
+#Deliver Build Configuration
+
+set(build_config_path "src/appMain/build_config.txt")
+FILE(WRITE "${build_config_path}" "")
+
+get_property(cHelpString CACHE EXTENDED_POLICY PROPERTY HELPSTRING)
+get_property(cType CACHE EXTENDED_POLICY PROPERTY TYPE)
+get_property(cValue CACHE EXTENDED_POLICY PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "EXTENDED_POLICY:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE REMOTE_CONTROL PROPERTY HELPSTRING)
+get_property(cType CACHE REMOTE_CONTROL PROPERTY TYPE)
+get_property(cValue CACHE REMOTE_CONTROL PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "REMOTE_CONTROL:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE BUILD_BT_SUPPORT PROPERTY HELPSTRING)
+get_property(cType CACHE BUILD_BT_SUPPORT PROPERTY TYPE)
+get_property(cValue CACHE BUILD_BT_SUPPORT PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "BUILD_BT_SUPPORT:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE BUILD_USB_SUPPORT PROPERTY HELPSTRING)
+get_property(cType CACHE BUILD_USB_SUPPORT PROPERTY TYPE)
+get_property(cValue CACHE BUILD_USB_SUPPORT PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "BUILD_USB_SUPPORT:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE ENABLE_SECURITY PROPERTY HELPSTRING)
+get_property(cType CACHE ENABLE_SECURITY PROPERTY TYPE)
+get_property(cValue CACHE ENABLE_SECURITY PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "ENABLE_SECURITY:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE EXTENDED_MEDIA_MODE PROPERTY HELPSTRING)
+get_property(cType CACHE EXTENDED_MEDIA_MODE PROPERTY TYPE)
+get_property(cValue CACHE EXTENDED_MEDIA_MODE PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "EXTENDED_MEDIA_MODE:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE TELEMETRY_MONITOR PROPERTY HELPSTRING)
+get_property(cType CACHE TELEMETRY_MONITOR PROPERTY TYPE)
+get_property(cValue CACHE TELEMETRY_MONITOR PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "TELEMETRY_MONITOR:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE HMI PROPERTY HELPSTRING)
+get_property(cType CACHE HMI PROPERTY TYPE)
+get_property(cValue CACHE HMI PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "HMI:${cType}=${cValue}\n\n")
+
+get_property(cHelpString CACHE ENABLE_HMI_PTU_DECRYPTION PROPERTY HELPSTRING)
+get_property(cType CACHE ENABLE_HMI_PTU_DECRYPTION PROPERTY TYPE)
+get_property(cValue CACHE ENABLE_HMI_PTU_DECRYPTION PROPERTY VALUE)
+file(APPEND "${build_config_path}" "//${cHelpString}\n")
+file(APPEND "${build_config_path}" "ENABLE_HMI_PTU_DECRYPTION:${cType}=${cValue}\n")
+
add_custom_target(pasa-tarball
COMMAND ${CMAKE_SOURCE_DIR}/tools/Utils/export-customer-specific.sh ${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR} pasa
COMMAND tar -cz -C /tmp/PASA -f ${CMAKE_BINARY_DIR}/pasa.tar.gz .
@@ -180,7 +239,6 @@ add_custom_target(genivi-tarball
COMMAND tar -cz -C /tmp/GENIVI -f ${CMAKE_BINARY_DIR}/genivi.tar.gz .
)
-
project (${PROJECT})
#ADD_DEPENDENCIES(${PROJECT} Policy)
@@ -445,5 +503,4 @@ find_package(Doxygen)
message(STATUS "sudo apt-get install doxygen graphviz")
message(STATUS "To enable processing of MscGen comments please install mscgen")
message(STATUS "sudo apt-get install mscgen")
-endif()
-
+endif() \ No newline at end of file
diff --git a/Doxyfile b/Doxyfile
index 0b46c939b6..36155e37a7 100644
--- a/Doxyfile
+++ b/Doxyfile
@@ -838,7 +838,7 @@ RECURSIVE = YES
# run.
EXCLUDE = **/CMakeLists.txt \
- docs/FORD.OpenSDL.SDD.TPL.dox
+ docs/SDL.SDD.Template.dox
src/components/test_main.cc
src/thirdPartyLibs \
tools/FlexeLint \
diff --git a/docs/FORD.OpenSDL.SDD.TPL.dox b/docs/SDL.SDD.Template.dox
index c0106df5d4..435da665db 100644
--- a/docs/FORD.OpenSDL.SDD.TPL.dox
+++ b/docs/SDL.SDD.Template.dox
@@ -9,19 +9,19 @@ https://adc.luxoft.com/confluence/display/PORTAL/Software+Detailed+Design+Templa
For adding new component documentation please follow this steps:
1. Copy this document to the 'doc' subdirectory in the Component working directory with a new name
- Example:
- + src/components/transport_manager/docs/FORD.OpenSDL.SDD.TM.dox
- + src/components/utils/docs/FORD.OpenSDL.SDD.Utils.dox
+ + src/components/transport_manager/docs/SDL.SDD.TM.dox
+ + src/components/utils/docs/SDL.SDD.Utils.dox
- https://adc.luxoft.com/confluence/display/PORTAL/Documentation+Control+Guideline#DocumentationControlGuideline-DocumentNaming
2. Replace <!Component Name> with a correct naming according to SAD naming
- Name examples:
Application Manager, Connection Handler
- Replace examples:
- ~ sed -i 's/<!Component Name>/Utils/g' FORD.OpenSDL.SDD.Utils.dox
+ ~ sed -i 's/<!Component Name>/Utils/g' SDL.SDD.Utils.dox
3. Replace <!Component_Id> with a shot unique name
- Something like app_manage, connection_handler, policy
- It shall be one word without spaces and special symbols except '_'
- Replace examples:
- ~ sed -i 's/<!Component_Id>/connection_handler/g' FORD.OpenSDL.SDD.Utils.dox
+ ~ sed -i 's/<!Component_Id>/connection_handler/g' SDL.SDD.Utils.dox
Note: After that step all Doxygen tags becomes working well and IDE could be used
4. Add reference in mainpage.dox Table of Content using <!Component_Id> used in p.3
5. Replace blocks marked as following with a content according to instructions in these blocks
@@ -101,7 +101,7 @@ Example:
Here need to be added a reason and short description of the components functionality
Example:
Security Manager component extracted as a separate module for
- Ford channel data protection.
+ SDL channel data protection.
This components is used to :
- Provide security communications
- Protect income and outcome business layer data from interception
@@ -152,27 +152,27 @@ Example:
\anchor <!Component_Id>_class_structure
### 2.2 Class Structure
-The following UML class digram shows the component classes structure.
+The following UML class diagram shows the component classes structure.
<!!!!!!!!!!!BEGIN_INSTRUCTION!!!!!!!!!!!!!>
Here need to be added class diagram
Example:
- ![Security Manager class diagram](sm_class_digram.png)
+ ![Security Manager class diagram](sm_class_diagram.png)
For adding images in MD format follow https://www.stack.nl/~dimitri/doxygen/manual/markdown.html#md_images
-As a tool for image preparing could be used Gliffy digram
+As a tool for image preparing could be used Gliffy diagram
https://adc.luxoft.com/confluence/pages/createpage.action?showGliffyMacro=true&fromCreateDialog=true&spaceKey=APPLINK
OR plantuml diagram
http://plantuml.com/classes.html
Note: Source files of diagram and output images need to be also committed to git.
<!!!!!!!!!!!END_INSTRUCTION!!!!!!!!!!!!!>
-For more information about class digram follow:
+For more information about class diagram follow:
- http://www.uml-diagrams.org/class-diagrams-overview.html
- https://sourcemaking.com/uml/modeling-it-systems/structural-view/class-diagram
\anchor <!Component_Id>_sequence_diagram
### 2.3 Sequence diagram
-The following UML sequence digram shows how objects operate with one another and in what order.
+The following UML sequence diagram shows how objects operate with one another and in what order.
<!!!!!!!!!!!BEGIN_INSTRUCTION!!!!!!!!!!!!!>
Here need to be added sequence diagram
@@ -182,34 +182,34 @@ Example:
![job](job.png)
![disconnection](disconnection.png)
For adding images in MD format follow https://www.stack.nl/~dimitri/doxygen/manual/markdown.html#md_images
-As a tool for image preparing could be used Gliffy digram
+As a tool for image preparing could be used Gliffy diagram
https://adc.luxoft.com/confluence/pages/createpage.action?showGliffyMacro=true&fromCreateDialog=true&spaceKey=APPLINK
OR plantuml diagram
http://plantuml.com/sequence.html
Note: Source files of diagram and output images need to be also committed to git.
<!!!!!!!!!!!END_INSTRUCTION!!!!!!!!!!!!!>
-For more information about sequence digram follow:
+For more information about sequence diagram follow:
- http://www.uml-diagrams.org/sequence-diagrams.html
- https://sourcemaking.com/uml/modeling-it-systems/external-view/use-case-sequence-diagram
\anchor <!Component_Id>_state_chart
### 2.4 State chart diagram
-The following UML state digram shows the component life cycle states.
+The following UML state diagram shows the component life cycle states.
<!!!!!!!!!!!BEGIN_INSTRUCTION!!!!!!!!!!!!!>
Here need to be added state diagram
Example:
![StateControllerImpl state](state_contoroller_states.png)
For adding images in MD format follow https://www.stack.nl/~dimitri/doxygen/manual/markdown.html#md_images
-As a tool for image preparing could be used Gliffy digram
+As a tool for image preparing could be used Gliffy diagram
https://adc.luxoft.com/confluence/pages/createpage.action?showGliffyMacro=true&fromCreateDialog=true&spaceKey=APPLINK
OR plantuml diagram
http://plantuml.com/state.html
Note: Source files of diagram and output images need to be also committed to git.
<!!!!!!!!!!!END_INSTRUCTION!!!!!!!!!!!!!>
-For more information about class digram follow:
+For more information about class diagram follow:
- http://www.uml-diagrams.org/state-machine-diagrams.html
*/
//-----------------------------------------------------------
@@ -285,7 +285,7 @@ The format of processing/saving/loading data is:
Here need to be added a list of formats
Example:
- Json data according to APPLINK-19421
- - Binary data array according to Ford Protocol Specification
+ - Binary data array according to SDL Protocol Specification
+ https://github.com/smartdevicelink/protocol_spec
- PEM certificates according to APPLINK-21512
All link will be auto-added by doxygen
@@ -314,7 +314,7 @@ Example:
\page <!Component_Id>_references_and_history 5. References and history
\anchor <!Component_Id>_references
### 5.1 References
-- [Software Architecture Document](https://smartdevicelink.com/en/guides/core/software-architecture-document/table-of-contents/)
+- [Software Architecture Document](https://smartdevicelink.com/en/docs/sdl-core/master/software-architecture-document/table-of-contents/)
<!!!!!!!!!!!BEGIN_INSTRUCTION!!!!!!!!!!!!!>
Here need to be added a list of all related to component functionality
@@ -349,7 +349,7 @@ Example:
For more precise document change history follow github history -
<!!!!!!!!!!!BEGIN_INSTRUCTION!!!!!!!!!!!!!>
Example for this template:
-- https://github.com/smartdevicelink/sdl_core/commits/master/docs/software_detailed_design_template.dox
-- https://github.com/smartdevicelink/sdl_core/commits/develop/docs/software_detailed_design_template.dox
+- https://github.com/smartdevicelink/sdl_core/commits/master/docs/SDL.SDD.Template.dox
+- https://github.com/smartdevicelink/sdl_core/commits/develop/docs/SDL.SDD.Template.dox
<!!!!!!!!!!!END_INSTRUCTION!!!!!!!!!!!!!>
*/ \ No newline at end of file
diff --git a/docs/mainpage.dox b/docs/mainpage.dox
index 91ee95fc26..08ef020594 100644
--- a/docs/mainpage.dox
+++ b/docs/mainpage.dox
@@ -1,9 +1,9 @@
/**
* \mainpage Software Detail Design Documentation
*
- * This documents contain SW detailed design information fro each [SmartDeviceLink component](https://smartdevicelink.com/en/guides/core/software-architecture-document/components-view/).
+ * This documents contain SW detailed design information fro each [SmartDeviceLink component](https://smartdevicelink.com/en/docs/sdl-core/master/software-architecture-document/components-view/).
*
- * For getting SmartDeviceLink overview, please, refer to [Software Architecture Document](https://smartdevicelink.com/en/docs/core/master/software-architecture-document/table-of-contents/)
+ * For getting SmartDeviceLink overview, please, refer to [Software Architecture Document](https://smartdevicelink.com/en/docs/sdl-core/master/software-architecture-document/table-of-contents/)
*
* ##Table of contents
* - \ref security_manager
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/examples/cpp/console.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/examples/cpp/console.cpp
index 9fda7c8eb4..157982e845 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/examples/cpp/console.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/examples/cpp/console.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <stdlib.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetdecoder.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetdecoder.cpp
index ea5a680a6c..0336b8dafa 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetdecoder.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetdecoder.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/logstring.h>
#include <log4cxx/helpers/charsetdecoder.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetencoder.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetencoder.cpp
index 6b1f564666..adb8f8526d 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetencoder.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/charsetencoder.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/logstring.h>
#include <log4cxx/helpers/charsetencoder.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/inputstreamreader.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/inputstreamreader.cpp
index 2963b45619..40e3b67bd0 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/inputstreamreader.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/inputstreamreader.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <string.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/locationinfo.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/locationinfo.cpp
index e74d015335..654f9b0eb8 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/locationinfo.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/locationinfo.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/spi/location/locationinfo.h>
@@ -148,7 +150,7 @@ void LocationInfo::write(ObjectOutputStream& os, Pool& p) const {
if (lineNumber == -1 && fileName == NA && methodName == NA_METHOD) {
os.writeNull(p);
} else {
- char prolog[] = {
+ unsigned char prolog[] = {
0x72, 0x00, 0x21, 0x6F, 0x72, 0x67, 0x2E,
0x61, 0x70, 0x61, 0x63, 0x68, 0x65, 0x2E, 0x6C,
0x6F, 0x67, 0x34, 0x6A, 0x2E, 0x73, 0x70, 0x69,
@@ -161,7 +163,7 @@ void LocationInfo::write(ObjectOutputStream& os, Pool& p) const {
0x61, 0x76, 0x61, 0x2F, 0x6C, 0x61, 0x6E, 0x67,
0x2F, 0x53, 0x74, 0x72, 0x69, 0x6E, 0x67, 0x3B,
0x78, 0x70 };
- os.writeProlog("org.apache.log4j.spi.LocationInfo", 2, prolog, sizeof(prolog), p);
+ os.writeProlog("org.apache.log4j.spi.LocationInfo", 2, reinterpret_cast<char *>(prolog), sizeof(prolog), p);
char* line = p.itoa(lineNumber);
//
// construct Java-like fullInfo (replace "::" with ".")
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp
index 203cb5c346..37b57180a2 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/logstring.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/loggingevent.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/loggingevent.cpp
index 1faae3f702..f9730792cf 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/loggingevent.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/loggingevent.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/spi/loggingevent.h>
@@ -254,7 +256,7 @@ void LoggingEvent::setProperty(const LogString& key, const LogString& value)
void LoggingEvent::writeProlog(ObjectOutputStream& os, Pool& p) {
- char classDesc[] = {
+ unsigned char classDesc[] = {
0x72, 0x00, 0x21,
0x6F, 0x72, 0x67, 0x2E, 0x61, 0x70, 0x61, 0x63,
0x68, 0x65, 0x2E, 0x6C, 0x6F, 0x67, 0x34, 0x6A,
@@ -310,7 +312,7 @@ void LoggingEvent::writeProlog(ObjectOutputStream& os, Pool& p) {
0x3B, 0x78, 0x70 };
os.writeProlog("org.apache.log4j.spi.LoggingEvent",
- 8, classDesc, sizeof(classDesc), p);
+ 8, reinterpret_cast<char *>(classDesc), sizeof(classDesc), p);
}
void LoggingEvent::write(helpers::ObjectOutputStream& os, Pool& p) const {
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/objectoutputstream.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/objectoutputstream.cpp
index 7cd696b842..29412c1a67 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/objectoutputstream.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/objectoutputstream.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#if defined(_MSC_VER)
#pragma warning ( disable: 4231 4251 4275 4786 )
@@ -36,8 +38,8 @@ ObjectOutputStream::ObjectOutputStream(OutputStreamPtr outputStream, Pool& p)
objectHandle(0x7E0000),
classDescriptions(new ClassDescriptionMap())
{
- char start[] = { 0xAC, 0xED, 0x00, 0x05 };
- ByteBuffer buf(start, sizeof(start));
+ unsigned char start[] = { 0xAC, 0xED, 0x00, 0x05 };
+ ByteBuffer buf(reinterpret_cast<char *>(start), sizeof(start));
os->write(buf, p);
}
@@ -81,7 +83,7 @@ void ObjectOutputStream::writeObject(const MDC::Map& val, Pool& p) {
//
// TC_OBJECT and the classDesc for java.util.Hashtable
//
- char prolog[] = {
+ unsigned char prolog[] = {
0x72, 0x00, 0x13, 0x6A, 0x61, 0x76, 0x61,
0x2E, 0x75, 0x74, 0x69, 0x6C, 0x2E, 0x48, 0x61,
0x73, 0x68, 0x74, 0x61, 0x62, 0x6C, 0x65, 0x13,
@@ -90,7 +92,7 @@ void ObjectOutputStream::writeObject(const MDC::Map& val, Pool& p) {
0x64, 0x46, 0x61, 0x63, 0x74, 0x6F, 0x72, 0x49,
0x00, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68,
0x6F, 0x6C, 0x64, 0x78, 0x70 };
- writeProlog("java.util.Hashtable", 1, prolog, sizeof(prolog), p);
+ writeProlog("java.util.Hashtable", 1, reinterpret_cast<char *>(prolog), sizeof(prolog), p);
//
// loadFactor = 0.75, threshold = 5, blockdata start, buckets.size = 7
char data[] = { 0x3F, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05,
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/serversocket.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/serversocket.cpp
index f2b5de61c7..e5c1b29be9 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/serversocket.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/serversocket.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/helpers/serversocket.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/sockethubappender.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/sockethubappender.cpp
index 09f5d8ce31..5ef4b1b794 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/sockethubappender.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/sockethubappender.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#if defined(_MSC_VER)
#pragma warning ( disable: 4231 4251 4275 4786 )
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/socketoutputstream.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/socketoutputstream.cpp
index d5166dc8ec..a0e30aa6aa 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/socketoutputstream.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/socketoutputstream.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <string.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/threadcxx.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/threadcxx.cpp
index fffb43a66a..a40df3be94 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/threadcxx.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/cpp/threadcxx.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#include <log4cxx/logstring.h>
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/logger.h b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/logger.h
index 5d82b36b39..8f5fac2341 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/logger.h
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/logger.h
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#ifndef _LOG4CXX_LOGGER_H
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/location/locationinfo.h b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/location/locationinfo.h
index fc98121dce..f07216afe2 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/location/locationinfo.h
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/location/locationinfo.h
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#ifndef _LOG4CXX_SPI_LOCATION_LOCATIONINFO_H
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/loggingevent.h b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/loggingevent.h
index 2c9c353f8b..58deb3694a 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/loggingevent.h
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/main/include/log4cxx/spi/loggingevent.h
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
#ifndef _LOG4CXX_SPI_LOGGING_EVENT_H
diff --git a/src/3rd_party/apache-log4cxx-0.10.0/src/test/cpp/xml/domtestcase.cpp b/src/3rd_party/apache-log4cxx-0.10.0/src/test/cpp/xml/domtestcase.cpp
index a500628180..903646048f 100644
--- a/src/3rd_party/apache-log4cxx-0.10.0/src/test/cpp/xml/domtestcase.cpp
+++ b/src/3rd_party/apache-log4cxx-0.10.0/src/test/cpp/xml/domtestcase.cpp
@@ -13,6 +13,8 @@
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
+ *
+ * Note: This file has been modified from its original form.
*/
@@ -190,9 +192,9 @@ public:
DOMConfigurator::configure(LOG4CXX_TEST_STR("input/xml/DOMTestCase3.xml"));
LOG4CXX_INFO(logger, "File name is expected to end with a superscript 3");
#if LOG4CXX_LOGCHAR_IS_UTF8
- const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, 0xC2, 0xB3, 0 };
+ const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, static_cast<logchar>(0xC2), static_cast<logchar>(0xB3), 0 };
#else
- const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, 0xB3, 0 };
+ const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, static_cast<logchar>(0xB3), 0 };
#endif
File file;
file.setPath(fname);
@@ -209,9 +211,9 @@ public:
DOMConfigurator::configure(LOG4CXX_TEST_STR("input/xml/DOMTestCase4.xml"));
LOG4CXX_INFO(logger, "File name is expected to end with an ideographic 4");
#if LOG4CXX_LOGCHAR_IS_UTF8
- const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, 0xE3, 0x86, 0x95, 0 };
+ const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, static_cast<logchar>(0xE3), static_cast<logchar>(0x86), static_cast<logchar>(0x95), 0 };
#else
- const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, 0x3195, 0 };
+ const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2F, 0x64, 0x6F, 0x6D, static_cast<logchar>(0x3195), 0 };
#endif
File file;
file.setPath(fname);
diff --git a/src/appMain/CMakeLists.txt b/src/appMain/CMakeLists.txt
index f59f21e5c3..06738713bd 100644
--- a/src/appMain/CMakeLists.txt
+++ b/src/appMain/CMakeLists.txt
@@ -156,7 +156,7 @@ endif()
target_link_libraries(${PROJECT} ${LIBRARIES})
add_dependencies(${PROJECT} Policy)
-
+file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/build_config.txt DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/log4cxx.properties DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/audio.8bit.wav DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/test.txt DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
@@ -214,7 +214,7 @@ endif ()
# Install rules
install(TARGETS ${PROJECT} DESTINATION bin)
install(
- FILES log4cxx.properties audio.8bit.wav test.txt smartDeviceLink.ini
+ FILES build_config.txt log4cxx.properties audio.8bit.wav test.txt smartDeviceLink.ini
hmi_capabilities.json sdl_preloaded_pt.json sample_policy_manager.py
${CMAKE_SOURCE_DIR}/mycert.pem ${CMAKE_SOURCE_DIR}/mykey.pem
DESTINATION bin
diff --git a/src/appMain/hmi_capabilities.json b/src/appMain/hmi_capabilities.json
index bef4d1e896..8b61df1b31 100755
--- a/src/appMain/hmi_capabilities.json
+++ b/src/appMain/hmi_capabilities.json
@@ -226,9 +226,15 @@
},
{
"name": "graphic",
- "imageTypeSupported": [
-
- ],
+ "imageTypeSupported": [],
+ "imageResolution": {
+ "resolutionWidth": 35,
+ "resolutionHeight": 35
+ }
+ },
+ {
+ "name": "secondaryGraphic",
+ "imageTypeSupported": [],
"imageResolution": {
"resolutionWidth": 35,
"resolutionHeight": 35
@@ -251,7 +257,6 @@
],
"graphicSupported": true,
"templatesAvailable": [
-
"DEFAULT", "MEDIA", "NON-MEDIA", "ONSCREEN_PRESETS", "NAV_FULLSCREEN_MAP", "NAV_KEYBOARD",
"GRAPHIC_WITH_TEXT", "TEXT_WITH_GRAPHIC", "TILES_ONLY", "TEXTBUTTONS_ONLY",
"GRAPHIC_WITH_TILES", "TILES_WITH_GRAPHIC", "GRAPHIC_WITH_TEXT_AND_SOFTBUTTONS",
diff --git a/src/appMain/sdl_preloaded_pt.json b/src/appMain/sdl_preloaded_pt.json
index 0965d7710d..1b3f2b0ff5 100644
--- a/src/appMain/sdl_preloaded_pt.json
+++ b/src/appMain/sdl_preloaded_pt.json
@@ -13,10 +13,10 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://localhost:3000/api/1/policies/proprietary"]
+ "default": ["http://x.x.x.x:3000/api/1/policies/proprietary"]
},
"0x04": {
- "default": ["http://localhost:3000/api/1/softwareUpdate"]
+ "default": ["http://x.x.x.x:3000/api/1/softwareUpdate"]
},
"queryAppsUrl": {
"default": ["http://sdl.shaid.server"]
@@ -397,12 +397,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -414,12 +416,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -431,12 +435,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -447,12 +453,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/application_manager/include/application_manager/application.h b/src/components/application_manager/include/application_manager/application.h
index 0c93f7447b..01e3bf6b56 100644
--- a/src/components/application_manager/include/application_manager/application.h
+++ b/src/components/application_manager/include/application_manager/application.h
@@ -189,6 +189,9 @@ class DynamicApplicationData {
virtual const smart_objects::SmartObject* keyboard_props() const = 0;
virtual const smart_objects::SmartObject* menu_title() const = 0;
virtual const smart_objects::SmartObject* menu_icon() const = 0;
+ virtual const smart_objects::SmartObject* day_color_scheme() const = 0;
+ virtual const smart_objects::SmartObject* night_color_scheme() const = 0;
+ virtual const std::string& display_layout() const = 0;
virtual void load_global_properties(const smart_objects::SmartObject& so) = 0;
virtual void set_help_prompt(
@@ -220,6 +223,12 @@ class DynamicApplicationData {
virtual void set_video_stream_retry_number(
const uint32_t& video_stream_retry_number) = 0;
+ virtual void set_day_color_scheme(
+ const smart_objects::SmartObject& color_scheme) = 0;
+ virtual void set_night_color_scheme(
+ const smart_objects::SmartObject& color_scheme) = 0;
+
+ virtual void set_display_layout(const std::string& layout) = 0;
/**
* @brief Checks if application is media, voice communication or navigation
* @return true if application is media, voice communication or navigation,
diff --git a/src/components/application_manager/include/application_manager/application_data_impl.h b/src/components/application_manager/include/application_manager/application_data_impl.h
index 64b5f8780b..dc9be4e1d8 100644
--- a/src/components/application_manager/include/application_manager/application_data_impl.h
+++ b/src/components/application_manager/include/application_manager/application_data_impl.h
@@ -55,6 +55,7 @@ class InitialApplicationDataImpl : public virtual Application {
const smart_objects::SmartObject* ngn_media_screen_name() const;
const mobile_api::Language::eType& language() const;
const mobile_api::Language::eType& ui_language() const;
+
void set_app_types(const smart_objects::SmartObject& app_types);
void set_vr_synonyms(const smart_objects::SmartObject& vr_synonyms);
void set_mobile_app_id(const std::string& policy_app_id);
@@ -95,6 +96,9 @@ class DynamicApplicationDataImpl : public virtual Application {
const smart_objects::SmartObject* keyboard_props() const;
const smart_objects::SmartObject* menu_title() const;
const smart_objects::SmartObject* menu_icon() const;
+ const smart_objects::SmartObject* day_color_scheme() const;
+ const smart_objects::SmartObject* night_color_scheme() const;
+ const std::string& display_layout() const;
void load_global_properties(const smart_objects::SmartObject& properties_so);
void set_help_prompt(const smart_objects::SmartObject& help_prompt);
@@ -109,6 +113,9 @@ class DynamicApplicationDataImpl : public virtual Application {
void set_keyboard_props(const smart_objects::SmartObject& keyboard_props);
void set_menu_title(const smart_objects::SmartObject& menu_title);
void set_menu_icon(const smart_objects::SmartObject& menu_icon);
+ void set_day_color_scheme(const smart_objects::SmartObject& color_scheme);
+ void set_night_color_scheme(const smart_objects::SmartObject& color_scheme);
+ void set_display_layout(const std::string& layout);
/*
* @brief Adds a command to the in application menu
*/
@@ -263,6 +270,9 @@ class DynamicApplicationDataImpl : public virtual Application {
smart_objects::SmartObject* menu_title_;
smart_objects::SmartObject* menu_icon_;
smart_objects::SmartObject* tbt_show_command_;
+ smart_objects::SmartObject* day_color_scheme_;
+ smart_objects::SmartObject* night_color_scheme_;
+ std::string display_layout_;
CommandsMap commands_;
mutable sync_primitives::Lock commands_lock_;
diff --git a/src/components/application_manager/include/application_manager/request_controller.h b/src/components/application_manager/include/application_manager/request_controller.h
index d3a5a0b821..c0bae1aac8 100644
--- a/src/components/application_manager/include/application_manager/request_controller.h
+++ b/src/components/application_manager/include/application_manager/request_controller.h
@@ -289,6 +289,13 @@ class RequestController {
*/
std::list<RequestPtr> notification_list_;
+ /**
+ * @brief Map keeping track of how many duplicate messages were sent for a
+ * given correlation id, to prevent early termination of a request
+ */
+ std::map<uint32_t, uint32_t> duplicate_message_count_;
+ sync_primitives::Lock duplicate_message_count_lock_;
+
/*
* timer for checking requests timeout
*/
diff --git a/src/components/application_manager/include/application_manager/smart_object_keys.h b/src/components/application_manager/include/application_manager/smart_object_keys.h
index e79b34c55f..60c0f73244 100644
--- a/src/components/application_manager/include/application_manager/smart_object_keys.h
+++ b/src/components/application_manager/include/application_manager/smart_object_keys.h
@@ -178,17 +178,29 @@ extern const char* navigation_capability;
extern const char* phone_capability;
extern const char* video_streaming_capability;
extern const char* rc_capability;
+extern const char* day_color_scheme;
+extern const char* night_color_scheme;
+extern const char* primary_color;
+extern const char* secondary_color;
+extern const char* background_color;
+extern const char* red;
+extern const char* green;
+extern const char* blue;
+extern const char* display_layout;
+extern const char* icon_resumed;
// PutFile
extern const char* sync_file_name;
extern const char* file_name;
extern const char* file_type;
extern const char* file_size;
+extern const char* crc32_check_sum;
extern const char* request_type;
extern const char* persistent_file;
extern const char* file_data;
extern const char* space_available;
extern const char* image_type;
+extern const char* is_template;
extern const char* image;
extern const char* type;
extern const char* system_file;
@@ -238,6 +250,7 @@ extern const char* rpm;
extern const char* fuel_level;
extern const char* fuel_level_state;
extern const char* instant_fuel_consumption;
+extern const char* fuel_range;
extern const char* external_temp;
extern const char* vin;
extern const char* prndl;
@@ -274,6 +287,7 @@ extern const char* remote_control;
extern const char* sdl_version;
extern const char* system_software_version;
extern const char* priority;
+extern const char* engine_oil_life;
// resuming
extern const char* application_commands;
diff --git a/src/components/application_manager/src/application_data_impl.cc b/src/components/application_manager/src/application_data_impl.cc
index a81540708c..226c83dbf6 100644
--- a/src/components/application_manager/src/application_data_impl.cc
+++ b/src/components/application_manager/src/application_data_impl.cc
@@ -173,6 +173,9 @@ DynamicApplicationDataImpl::DynamicApplicationDataImpl()
, menu_title_(NULL)
, menu_icon_(NULL)
, tbt_show_command_(NULL)
+ , day_color_scheme_(NULL)
+ , night_color_scheme_(NULL)
+ , display_layout_("")
, commands_()
, commands_lock_(true)
, sub_menu_()
@@ -214,6 +217,16 @@ DynamicApplicationDataImpl::~DynamicApplicationDataImpl() {
tbt_show_command_ = NULL;
}
+ if (day_color_scheme_) {
+ delete day_color_scheme_;
+ day_color_scheme_ = NULL;
+ }
+
+ if (night_color_scheme_) {
+ delete night_color_scheme_;
+ night_color_scheme_ = NULL;
+ }
+
for (CommandsMap::iterator command_it = commands_.begin();
commands_.end() != command_it;
++command_it) {
@@ -290,6 +303,20 @@ const smart_objects::SmartObject* DynamicApplicationDataImpl::menu_icon()
return menu_icon_;
}
+const smart_objects::SmartObject* DynamicApplicationDataImpl::day_color_scheme()
+ const {
+ return day_color_scheme_;
+}
+
+const smart_objects::SmartObject*
+DynamicApplicationDataImpl::night_color_scheme() const {
+ return night_color_scheme_;
+}
+
+const std::string& DynamicApplicationDataImpl::display_layout() const {
+ return display_layout_;
+}
+
void DynamicApplicationDataImpl::load_global_properties(
const smart_objects::SmartObject& properties_so) {
SetGlobalProperties(properties_so.getElement(strings::vr_help_title),
@@ -405,6 +432,28 @@ void DynamicApplicationDataImpl::set_menu_icon(
menu_icon_ = new smart_objects::SmartObject(menu_icon);
}
+void DynamicApplicationDataImpl::set_day_color_scheme(
+ const smart_objects::SmartObject& color_scheme) {
+ if (day_color_scheme_) {
+ delete day_color_scheme_;
+ }
+
+ day_color_scheme_ = new smart_objects::SmartObject(color_scheme);
+}
+
+void DynamicApplicationDataImpl::set_night_color_scheme(
+ const smart_objects::SmartObject& color_scheme) {
+ if (night_color_scheme_) {
+ delete night_color_scheme_;
+ }
+
+ night_color_scheme_ = new smart_objects::SmartObject(color_scheme);
+}
+
+void DynamicApplicationDataImpl::set_display_layout(const std::string& layout) {
+ display_layout_ = layout;
+}
+
void DynamicApplicationDataImpl::SetGlobalProperties(
const smart_objects::SmartObject& param,
void (DynamicApplicationData::*callback)(
diff --git a/src/components/application_manager/src/application_manager_impl.cc b/src/components/application_manager/src/application_manager_impl.cc
index 8d372f4fd2..7b2aaa5437 100644
--- a/src/components/application_manager/src/application_manager_impl.cc
+++ b/src/components/application_manager/src/application_manager_impl.cc
@@ -623,6 +623,13 @@ ApplicationSharedPtr ApplicationManagerImpl::RegisterApplication(
const std::string& bundle_id = app_info[strings::bundle_id].asString();
application->set_bundle_id(bundle_id);
}
+
+ const std::string app_icon_dir(settings_.app_icons_folder());
+ const std::string full_icon_path(app_icon_dir + "/" + policy_app_id);
+ if (file_system::FileExists(full_icon_path)) {
+ application->set_app_icon_path(full_icon_path);
+ }
+
PutDriverDistractionMessageToPostponed(application);
// Stops timer of saving data to resumption in order to
diff --git a/src/components/application_manager/src/commands/mobile/put_file_request.cc b/src/components/application_manager/src/commands/mobile/put_file_request.cc
index 602b420ba0..269c9c814e 100644
--- a/src/components/application_manager/src/commands/mobile/put_file_request.cc
+++ b/src/components/application_manager/src/commands/mobile/put_file_request.cc
@@ -38,6 +38,22 @@
#include "application_manager/application_impl.h"
#include "utils/file_system.h"
+#include <boost/crc.hpp>
+
+namespace {
+/**
+* Calculates CRC32 checksum
+* @param binary_data - input data for which CRC32 should be calculated
+* @return calculated CRC32 checksum
+*/
+uint32_t GetCrc32CheckSum(const std::vector<uint8_t>& binary_data) {
+ const std::size_t file_size = binary_data.size();
+ boost::crc_32_type result;
+ result.process_bytes(&binary_data[0], file_size);
+ return result.checksum();
+}
+
+} // namespace
namespace application_manager {
@@ -137,7 +153,7 @@ void PutFileRequest::Run() {
is_persistent_file_ = false;
bool is_system_file = false;
length_ = binary_data.size();
- bool is_download_compleate = true;
+ bool is_download_complete = true;
bool offset_exist =
(*message_)[strings::msg_params].keyExists(strings::offset);
@@ -187,11 +203,29 @@ void PutFileRequest::Run() {
return;
}
const std::string full_path = file_path + "/" + sync_file_name_;
- UNUSED(full_path);
+ const size_t bin_data_size = binary_data.size();
+
+ if ((*message_)[strings::msg_params].keyExists(strings::crc32_check_sum)) {
+ LOG4CXX_TRACE(logger_, "Binary Data Size: " << bin_data_size);
+ const uint32_t crc_received =
+ (*message_)[strings::msg_params][strings::crc32_check_sum].asUInt();
+ LOG4CXX_TRACE(logger_, "CRC32 SUM Received: " << crc_received);
+ const uint32_t crc_calculated = GetCrc32CheckSum(binary_data);
+ LOG4CXX_TRACE(logger_, "CRC32 SUM Calculated: " << crc_calculated);
+ if (crc_calculated != crc_received) {
+ SendResponse(false,
+ mobile_apis::Result::CORRUPTED_DATA,
+ "CRC Check on file failed. File upload has been cancelled, "
+ "please retry.",
+ &response_params);
+ return;
+ }
+ }
+
LOG4CXX_DEBUG(logger_,
- "Wrtiting " << binary_data.size() << "bytes to " << full_path
- << " (current size is"
- << file_system::FileSize(full_path) << ")");
+ "Writing " << bin_data_size << " bytes to " << full_path
+ << " (current size is"
+ << file_system::FileSize(full_path) << ")");
mobile_apis::Result::eType save_result = application_manager_.SaveBinary(
binary_data, file_path, sync_file_name_, offset_);
@@ -211,7 +245,7 @@ void PutFileRequest::Run() {
if (!is_system_file) {
AppFile file(sync_file_name_,
is_persistent_file_,
- is_download_compleate,
+ is_download_complete,
file_type_);
if (0 == offset_) {
diff --git a/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc b/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
index a3a30ddb20..d32afad00b 100644
--- a/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
+++ b/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
@@ -50,6 +50,7 @@
#include "config_profile/profile.h"
#include "interfaces/MOBILE_API.h"
#include "interfaces/generated_msg_version.h"
+#include "utils/file_system.h"
namespace {
namespace custom_str = utils::custom_string;
@@ -348,6 +349,15 @@ void RegisterAppInterfaceRequest::Run() {
}
}
+ if (msg_params.keyExists(strings::day_color_scheme)) {
+ application->set_day_color_scheme(msg_params[strings::day_color_scheme]);
+ }
+
+ if (msg_params.keyExists(strings::night_color_scheme)) {
+ application->set_night_color_scheme(
+ msg_params[strings::night_color_scheme]);
+ }
+
// Add device to policy table and set device info, if any
policy::DeviceParams dev_params;
if (-1 ==
@@ -710,6 +720,10 @@ void RegisterAppInterfaceRequest::SendRegisterAppInterfaceResponseToMobile(
}
policy::StatusNotifier notify_upd_manager = GetPolicyHandler().AddApplication(
application->policy_app_id(), hmi_types);
+
+ response_params[strings::icon_resumed] =
+ file_system::FileExists(application->app_icon_path());
+
SendResponse(true, result_code, add_info.c_str(), &response_params);
SendOnAppRegisteredNotificationToHMI(
*(application.get()), resumption, need_restore_vr);
@@ -825,7 +839,9 @@ void RegisterAppInterfaceRequest::SendOnAppRegisteredNotificationToHMI(
application[strings::app_name] = application_impl.name();
application[strings::app_id] = application_impl.app_id();
application[hmi_response::policy_app_id] = application_impl.policy_app_id();
- application[strings::icon] = application_impl.app_icon_path();
+ if (file_system::FileExists(application_impl.app_icon_path())) {
+ application[strings::icon] = application_impl.app_icon_path();
+ }
const smart_objects::SmartObject* ngn_media_screen_name =
application_impl.ngn_media_screen_name();
@@ -884,6 +900,18 @@ void RegisterAppInterfaceRequest::SendOnAppRegisteredNotificationToHMI(
device_info[strings::transport_type] =
application_manager_.GetDeviceTransportType(transport_type);
+ const smart_objects::SmartObject* day_color_scheme =
+ application_impl.day_color_scheme();
+ if (day_color_scheme) {
+ application[strings::day_color_scheme] = *day_color_scheme;
+ }
+
+ const smart_objects::SmartObject* night_color_scheme =
+ application_impl.night_color_scheme();
+ if (night_color_scheme) {
+ application[strings::night_color_scheme] = *night_color_scheme;
+ }
+
DCHECK(application_manager_.ManageHMICommand(notification));
}
diff --git a/src/components/application_manager/src/commands/mobile/set_app_icon_request.cc b/src/components/application_manager/src/commands/mobile/set_app_icon_request.cc
index ee544e956a..a100bbb5fb 100644
--- a/src/components/application_manager/src/commands/mobile/set_app_icon_request.cc
+++ b/src/components/application_manager/src/commands/mobile/set_app_icon_request.cc
@@ -31,9 +31,10 @@
POSSIBILITY OF SUCH DAMAGE.
*/
-#include <algorithm>
#include "application_manager/commands/mobile/set_app_icon_request.h"
+#include <algorithm>
+
#include "application_manager/message_helper.h"
#include "application_manager/application_impl.h"
#include "interfaces/MOBILE_API.h"
@@ -90,10 +91,6 @@ void SetAppIconRequest::Run() {
return;
}
- if (is_icons_saving_enabled_) {
- CopyToIconStorage(full_file_path);
- }
-
smart_objects::SmartObject msg_params =
smart_objects::SmartObject(smart_objects::SmartType_Map);
@@ -262,6 +259,11 @@ void SetAppIconRequest::on_event(const event_engine::Event& event) {
const std::string& path =
(*message_)[strings::msg_params][strings::sync_file_name]
[strings::value].asString();
+
+ if (is_icons_saving_enabled_) {
+ CopyToIconStorage(path);
+ }
+
app->set_app_icon_path(path);
LOG4CXX_INFO(logger_,
diff --git a/src/components/application_manager/src/commands/mobile/set_display_layout_request.cc b/src/components/application_manager/src/commands/mobile/set_display_layout_request.cc
index 38b62ce731..ed60ca4928 100644
--- a/src/components/application_manager/src/commands/mobile/set_display_layout_request.cc
+++ b/src/components/application_manager/src/commands/mobile/set_display_layout_request.cc
@@ -48,8 +48,7 @@ SetDisplayLayoutRequest::~SetDisplayLayoutRequest() {}
void SetDisplayLayoutRequest::Run() {
LOG4CXX_AUTO_TRACE(logger_);
- ApplicationConstSharedPtr app =
- application_manager_.application(connection_key());
+ ApplicationSharedPtr app = application_manager_.application(connection_key());
if (!app) {
LOG4CXX_ERROR(logger_, "Application is not registered");
@@ -57,6 +56,58 @@ void SetDisplayLayoutRequest::Run() {
return;
}
+ const smart_objects::SmartObject& msg_params =
+ (*message_)[strings::msg_params];
+
+ std::string old_layout = app->display_layout();
+ std::string new_layout = "";
+
+ if (msg_params.keyExists(strings::display_layout)) {
+ new_layout = msg_params[strings::display_layout].asString();
+ }
+
+ if (new_layout != old_layout &&
+ !new_layout.empty()) { // Template switched, allow any color change
+ LOG4CXX_DEBUG(logger_,
+ "SetDisplayLayoutRequest New Layout: " << new_layout);
+ app->set_display_layout(new_layout);
+ } else {
+ LOG4CXX_DEBUG(logger_, "SetDisplayLayoutRequest No Layout Change");
+ // Template layout is the same as previous layout
+ // Reject message if colors are set
+ if (msg_params.keyExists(strings::day_color_scheme) &&
+ app->day_color_scheme() != NULL &&
+ !(msg_params[strings::day_color_scheme] ==
+ *(app->day_color_scheme()))) {
+ // Color scheme param exists and has been previously set, do not allow
+ // color change
+ LOG4CXX_DEBUG(logger_, "Reject Day Color Scheme Change");
+ SendResponse(false, mobile_apis::Result::REJECTED);
+ return;
+ }
+
+ if (msg_params.keyExists(strings::night_color_scheme) &&
+ app->night_color_scheme() != NULL &&
+ !(msg_params[strings::night_color_scheme] ==
+ *(app->night_color_scheme()))) {
+ // Color scheme param exists and has been previously set, do not allow
+ // color change
+ LOG4CXX_DEBUG(logger_, "Reject Night Color Scheme Change");
+ SendResponse(false, mobile_apis::Result::REJECTED);
+ return;
+ }
+ }
+
+ if (msg_params.keyExists(strings::day_color_scheme)) {
+ LOG4CXX_DEBUG(logger_, "Allow Day Color Scheme Change");
+ app->set_day_color_scheme(msg_params[strings::day_color_scheme]);
+ }
+
+ if (msg_params.keyExists(strings::night_color_scheme)) {
+ LOG4CXX_DEBUG(logger_, "Allow Night Color Scheme Change");
+ app->set_night_color_scheme(msg_params[strings::night_color_scheme]);
+ }
+
(*message_)[strings::msg_params][strings::app_id] = app->app_id();
StartAwaitForInterface(HmiInterfaces::HMI_INTERFACE_UI);
SendHMIRequest(hmi_apis::FunctionID::UI_SetDisplayLayout,
diff --git a/src/components/application_manager/src/hmi_capabilities_impl.cc b/src/components/application_manager/src/hmi_capabilities_impl.cc
index e39b728155..278e4761db 100644
--- a/src/components/application_manager/src/hmi_capabilities_impl.cc
+++ b/src/components/application_manager/src/hmi_capabilities_impl.cc
@@ -282,6 +282,9 @@ void InitCapabilities() {
image_field_name_enum.insert(std::make_pair(
std::string("graphic"), hmi_apis::Common_ImageFieldName::graphic));
image_field_name_enum.insert(
+ std::make_pair(std::string("secondaryGraphic"),
+ hmi_apis::Common_ImageFieldName::secondaryGraphic));
+ image_field_name_enum.insert(
std::make_pair(std::string("showConstantTBTIcon"),
hmi_apis::Common_ImageFieldName::showConstantTBTIcon));
image_field_name_enum.insert(std::make_pair(
diff --git a/src/components/application_manager/src/message_helper/message_helper.cc b/src/components/application_manager/src/message_helper/message_helper.cc
index 9a10c908f1..17c8a08452 100644
--- a/src/components/application_manager/src/message_helper/message_helper.cc
+++ b/src/components/application_manager/src/message_helper/message_helper.cc
@@ -175,6 +175,8 @@ std::pair<std::string,
mobile_apis::VehicleDataType::VEHICLEDATA_FUELLEVEL_STATE),
std::make_pair(strings::instant_fuel_consumption,
mobile_apis::VehicleDataType::VEHICLEDATA_FUELCONSUMPTION),
+ std::make_pair(strings::fuel_range,
+ mobile_apis::VehicleDataType::VEHICLEDATA_FUELRANGE),
std::make_pair(strings::external_temp,
mobile_apis::VehicleDataType::VEHICLEDATA_EXTERNTEMP),
std::make_pair(strings::vin, mobile_apis::VehicleDataType::VEHICLEDATA_VIN),
@@ -217,7 +219,8 @@ std::pair<std::string,
mobile_apis::VehicleDataType::VEHICLEDATA_ACCPEDAL),
std::make_pair(strings::steering_wheel_angle,
mobile_apis::VehicleDataType::VEHICLEDATA_STEERINGWHEEL),
-};
+ std::make_pair(strings::engine_oil_life,
+ mobile_apis::VehicleDataType::VEHICLEDATA_ENGINEOILLIFE)};
const VehicleData MessageHelper::vehicle_data_(
kVehicleDataInitializer,
@@ -1691,6 +1694,9 @@ bool MessageHelper::CreateHMIApplicationStruct(
const smart_objects::SmartObject* app_types = app->app_types();
const smart_objects::SmartObject* ngn_media_screen_name =
app->ngn_media_screen_name();
+ const smart_objects::SmartObject* day_color_scheme = app->day_color_scheme();
+ const smart_objects::SmartObject* night_color_scheme =
+ app->night_color_scheme();
std::string device_name;
std::string mac_address;
std::string transport_type;
@@ -1728,6 +1734,14 @@ bool MessageHelper::CreateHMIApplicationStruct(
message[strings::app_type] = *app_types;
}
+ if (day_color_scheme) {
+ message[strings::day_color_scheme] = *day_color_scheme;
+ }
+
+ if (night_color_scheme) {
+ message[strings::night_color_scheme] = *night_color_scheme;
+ }
+
message[strings::device_info] =
smart_objects::SmartObject(smart_objects::SmartType_Map);
message[strings::device_info][strings::name] = device_name;
diff --git a/src/components/application_manager/src/policies/policy_handler.cc b/src/components/application_manager/src/policies/policy_handler.cc
index bbf391a9f1..559b9c0035 100644
--- a/src/components/application_manager/src/policies/policy_handler.cc
+++ b/src/components/application_manager/src/policies/policy_handler.cc
@@ -1091,8 +1091,7 @@ bool PolicyHandler::ReceiveMessageFromSDK(const std::string& file,
MessageHelper::CreateGetVehicleDataRequest(
correlation_id, vehicle_data_args, application_manager_);
} else {
- LOG4CXX_WARN(logger_, "Exchange wasn't successful, trying another one.");
- policy_manager_->ForcePTExchange();
+ LOG4CXX_WARN(logger_, "Exchange wasn't successful");
}
OnPTUFinished(ret);
return ret;
diff --git a/src/components/application_manager/src/request_controller.cc b/src/components/application_manager/src/request_controller.cc
index 1b9bd7ffb9..f341967842 100644
--- a/src/components/application_manager/src/request_controller.cc
+++ b/src/components/application_manager/src/request_controller.cc
@@ -50,6 +50,7 @@ RequestController::RequestController(const RequestControlerSettings& settings)
: pool_state_(UNDEFINED)
, pool_size_(settings.thread_pool_size())
, request_tracker_(settings)
+ , duplicate_message_count_()
, timer_("AM RequestCtrlTimer",
new timer::TimerTaskImpl<RequestController>(
this, &RequestController::TimeoutThread))
@@ -230,6 +231,21 @@ void RequestController::TerminateRequest(const uint32_t correlation_id,
<< correlation_id << " connection_key = " << connection_key
<< " function_id = " << function_id
<< " force_terminate = " << force_terminate);
+ {
+ AutoLock auto_lock(duplicate_message_count_lock_);
+ auto dup_it = duplicate_message_count_.find(correlation_id);
+ if (duplicate_message_count_.end() != dup_it) {
+ duplicate_message_count_[correlation_id]--;
+ if (0 == duplicate_message_count_[correlation_id]) {
+ duplicate_message_count_.erase(dup_it);
+ }
+ LOG4CXX_DEBUG(logger_,
+ "Ignoring termination request due to duplicate correlation "
+ "ID being sent");
+ return;
+ }
+ }
+
RequestInfoPtr request =
waiting_for_response_.Find(connection_key, correlation_id);
if (!request) {
@@ -474,7 +490,24 @@ void RequestController::Worker::threadMain() {
RequestInfoPtr request_info_ptr =
utils::MakeShared<MobileRequestInfo>(request_ptr, timeout_in_mseconds);
- request_controller_->waiting_for_response_.Add(request_info_ptr);
+ if (!request_controller_->waiting_for_response_.Add(request_info_ptr)) {
+ commands::CommandRequestImpl* cmd_request =
+ dynamic_cast<commands::CommandRequestImpl*>(request_ptr.get());
+ if (cmd_request != NULL) {
+ uint32_t corr_id = cmd_request->correlation_id();
+ request_controller_->duplicate_message_count_lock_.Acquire();
+ auto dup_it =
+ request_controller_->duplicate_message_count_.find(corr_id);
+ if (request_controller_->duplicate_message_count_.end() == dup_it) {
+ request_controller_->duplicate_message_count_[corr_id] = 0;
+ }
+ request_controller_->duplicate_message_count_[corr_id]++;
+ request_controller_->duplicate_message_count_lock_.Release();
+ cmd_request->SendResponse(
+ false, mobile_apis::Result::INVALID_ID, "Duplicate correlation_id");
+ }
+ continue;
+ }
LOG4CXX_DEBUG(logger_, "timeout_in_mseconds " << timeout_in_mseconds);
if (0 != timeout_in_mseconds) {
diff --git a/src/components/application_manager/src/smart_object_keys.cc b/src/components/application_manager/src/smart_object_keys.cc
index 888943d4d6..ddd1107b5e 100644
--- a/src/components/application_manager/src/smart_object_keys.cc
+++ b/src/components/application_manager/src/smart_object_keys.cc
@@ -142,17 +142,29 @@ const char* navigation_capability = "navigationCapability";
const char* phone_capability = "phoneCapability";
const char* video_streaming_capability = "videoStreamingCapability";
const char* rc_capability = "remoteControlCapability";
+const char* day_color_scheme = "dayColorScheme";
+const char* night_color_scheme = "nightColorScheme";
+const char* primary_color = "primaryColor";
+const char* secondary_color = "secondaryColor";
+const char* background_color = "backgroundColor";
+const char* red = "red";
+const char* green = "green";
+const char* blue = "blue";
+const char* display_layout = "displayLayout";
+const char* icon_resumed = "iconResumed";
// PutFile
const char* sync_file_name = "syncFileName";
const char* file_name = "fileName";
const char* file_type = "fileType";
const char* file_size = "fileSize";
+const char* crc32_check_sum = "crc";
const char* request_type = "requestType";
const char* persistent_file = "persistentFile";
const char* file_data = "fileData";
const char* space_available = "spaceAvailable";
const char* image_type = "imageType";
+const char* is_template = "isTemplate";
const char* image = "image";
const char* type = "type";
const char* system_file = "systemFile";
@@ -202,6 +214,7 @@ const char* rpm = "rpm";
const char* fuel_level = "fuelLevel";
const char* fuel_level_state = "fuelLevel_State";
const char* instant_fuel_consumption = "instantFuelConsumption";
+const char* fuel_range = "fuelRange";
const char* external_temp = "externalTemperature";
const char* vin = "vin";
const char* prndl = "prndl";
@@ -238,6 +251,7 @@ const char* remote_control = "remoteControl";
const char* sdl_version = "sdlVersion";
const char* system_software_version = "systemSoftwareVersion";
const char* priority = "priority";
+const char* engine_oil_life = "engineOilLife";
// resuming
const char* application_commands = "applicationCommands";
diff --git a/src/components/application_manager/test/application_manager_impl_test.cc b/src/components/application_manager/test/application_manager_impl_test.cc
index c922c227bb..9cc552f188 100644
--- a/src/components/application_manager/test/application_manager_impl_test.cc
+++ b/src/components/application_manager/test/application_manager_impl_test.cc
@@ -89,6 +89,9 @@ namespace {
const std::string kDirectoryName = "./test_storage";
const uint32_t kTimeout = 10000u;
connection_handler::DeviceHandle kDeviceId = 12345u;
+const std::string kAppId = "someID";
+const uint32_t kConnectionKey = 1232u;
+const std::string kAppName = "appName";
} // namespace
class ApplicationManagerImplTest : public ::testing::Test {
@@ -136,6 +139,8 @@ class ApplicationManagerImplTest : public ::testing::Test {
.WillByDefault(Return(stop_streaming_timeout));
ON_CALL(mock_application_manager_settings_, default_timeout())
.WillByDefault(ReturnRef(kTimeout));
+ ON_CALL(mock_application_manager_settings_,
+ application_list_update_timeout()).WillByDefault(Return(kTimeout));
app_manager_impl_.reset(new am::ApplicationManagerImpl(
mock_application_manager_settings_, mock_policy_settings_));
@@ -941,6 +946,49 @@ TEST_F(ApplicationManagerImplTest, UnregisterAnotherAppDuringAudioPassThru) {
}
}
+TEST_F(ApplicationManagerImplTest,
+ RegisterApplication_PathToTheIconExists_IconWasSet) {
+ file_system::CreateDirectory(kDirectoryName);
+ const std::string full_icon_path = kDirectoryName + "/" + kAppId;
+ ASSERT_TRUE(file_system::CreateFile(full_icon_path));
+
+ smart_objects::SmartObject request_for_registration(
+ smart_objects::SmartType_Map);
+
+ smart_objects::SmartObject& params =
+ request_for_registration[strings::msg_params];
+ params[strings::app_id] = kAppId;
+ params[strings::language_desired] = mobile_api::Language::EN_US;
+ params[strings::hmi_display_language_desired] = mobile_api::Language::EN_US;
+
+ request_for_registration[strings::params][strings::connection_key] =
+ kConnectionKey;
+ request_for_registration[strings::msg_params][strings::app_name] = kAppName;
+ request_for_registration[strings::msg_params][strings::sync_msg_version]
+ [strings::minor_version] = APIVersion::kAPIV2;
+ request_for_registration[strings::msg_params][strings::sync_msg_version]
+ [strings::major_version] = APIVersion::kAPIV3;
+
+ request_for_registration[strings::params][strings::protocol_version] =
+ protocol_handler::MajorProtocolVersion::PROTOCOL_VERSION_2;
+
+ smart_objects::SmartObjectSPtr request_for_registration_ptr =
+ MakeShared<smart_objects::SmartObject>(request_for_registration);
+
+ ApplicationSharedPtr application =
+ app_manager_impl_->RegisterApplication(request_for_registration_ptr);
+ EXPECT_STREQ(kAppName.c_str(), application->name().c_str());
+ EXPECT_STREQ(full_icon_path.c_str(), application->app_icon_path().c_str());
+ EXPECT_EQ(protocol_handler::MajorProtocolVersion::PROTOCOL_VERSION_2,
+ application->protocol_version());
+ EXPECT_EQ(APIVersion::kAPIV2,
+ application->version().min_supported_api_version);
+ EXPECT_EQ(APIVersion::kAPIV3,
+ application->version().max_supported_api_version);
+
+ EXPECT_TRUE(file_system::RemoveDirectory(kDirectoryName, true));
+}
+
} // application_manager_test
} // namespace components
} // namespace test
diff --git a/src/components/application_manager/test/commands/mobile/put_file_test.cc b/src/components/application_manager/test/commands/mobile/put_file_test.cc
index b48ac67501..575daa7217 100644
--- a/src/components/application_manager/test/commands/mobile/put_file_test.cc
+++ b/src/components/application_manager/test/commands/mobile/put_file_test.cc
@@ -77,6 +77,7 @@ const std::string kFileName = "sync_file_name.txt";
const int64_t kOffset = 10u;
const int64_t kZeroOffset = 0u;
const std::string kStorageFolder = "./storage";
+const std::string kFolder = "folder";
const std::string kAppFolder = "app_folder";
}
@@ -344,6 +345,64 @@ TEST_F(PutFileRequestTest, Run_InvalidPutFile_UNSUCCESS) {
command->Run();
}
+TEST_F(PutFileRequestTest, Run_CrcSumEqual_SendSuccessResponse) {
+ binary_data_ = {1u};
+ (*msg_)[am::strings::params][am::strings::binary_data] = binary_data_;
+ const uint32_t correct_crc_sum =
+ 2768625435u; // calculated using the GetCrc32CheckSum method
+ (*msg_)[am::strings::msg_params][am::strings::crc32_check_sum] =
+ correct_crc_sum;
+
+ ExpectReceiveMessageFromSDK();
+ ON_CALL(app_mngr_, get_settings())
+ .WillByDefault(ReturnRef(app_mngr_settings_));
+ ON_CALL(app_mngr_settings_, app_storage_folder())
+ .WillByDefault(ReturnRef(kStorageFolder));
+ ON_CALL(*mock_app_, folder_name()).WillByDefault(Return(kFolder));
+ const size_t available_space = binary_data_.size() + 1;
+ ON_CALL(*mock_app_, GetAvailableDiskSpace())
+ .WillByDefault(Return(available_space));
+ ON_CALL(*mock_app_, AddFile(_)).WillByDefault(Return(true));
+
+ const std::string file_path = kStorageFolder + "/" + kFolder;
+ EXPECT_CALL(app_mngr_, SaveBinary(binary_data_, file_path, kFileName, 0u))
+ .WillOnce(Return(mobile_apis::Result::SUCCESS));
+ EXPECT_CALL(*mock_app_, increment_put_file_in_none_count());
+ ExpectManageMobileCommandWithResultCode(mobile_apis::Result::SUCCESS);
+ PutFileRequestPtr command(CreateCommand<PutFileRequest>(msg_));
+ ASSERT_TRUE(command->Init());
+ command->Run();
+ // The folder was created in the "Run" method
+ EXPECT_TRUE(file_system::RemoveDirectory(kStorageFolder, true));
+}
+
+TEST_F(PutFileRequestTest, Run_CrcSumUnequal_SendCorruptedDataResponse) {
+ binary_data_ = {1u};
+ (*msg_)[am::strings::params][am::strings::binary_data] = binary_data_;
+ const uint32_t incorrect_crc_sum = 0u;
+ (*msg_)[am::strings::msg_params][am::strings::crc32_check_sum] =
+ incorrect_crc_sum;
+
+ ExpectReceiveMessageFromSDK();
+ ON_CALL(app_mngr_, get_settings())
+ .WillByDefault(ReturnRef(app_mngr_settings_));
+ ON_CALL(app_mngr_settings_, app_storage_folder())
+ .WillByDefault(ReturnRef(kStorageFolder));
+ ON_CALL(*mock_app_, folder_name()).WillByDefault(Return(kFolder));
+ const size_t available_space = binary_data_.size() + 1;
+ ON_CALL(*mock_app_, GetAvailableDiskSpace())
+ .WillByDefault(Return(available_space));
+ ON_CALL(*mock_app_, AddFile(_)).WillByDefault(Return(true));
+
+ ExpectManageMobileCommandWithResultCode(mobile_apis::Result::CORRUPTED_DATA);
+ EXPECT_CALL(app_mngr_, SaveBinary(_, _, _, _)).Times(0);
+ PutFileRequestPtr command(CreateCommand<PutFileRequest>(msg_));
+ ASSERT_TRUE(command->Init());
+ command->Run();
+ // The folder was created in the "Run" method
+ EXPECT_TRUE(file_system::RemoveDirectory(kStorageFolder, true));
+}
+
} // namespace put_file
} // namespace mobile_commands_test
} // namespace commands_test
diff --git a/src/components/application_manager/test/commands/mobile/set_app_icon_test.cc b/src/components/application_manager/test/commands/mobile/set_app_icon_test.cc
index b278479df8..a5d50502f4 100644
--- a/src/components/application_manager/test/commands/mobile/set_app_icon_test.cc
+++ b/src/components/application_manager/test/commands/mobile/set_app_icon_test.cc
@@ -40,6 +40,8 @@
#include "application_manager/commands/command_request_test.h"
#include "application_manager/mock_application.h"
#include "application_manager/mock_application_manager.h"
+#include "protocol_handler/mock_protocol_handler.h"
+#include "protocol_handler/mock_protocol_handler_settings.h"
#include "application_manager/mock_message_helper.h"
#include "application_manager/event_engine/event.h"
#include "application_manager/mock_hmi_interface.h"
@@ -55,6 +57,9 @@ using am::commands::SetAppIconRequest;
using am::commands::CommandImpl;
using am::commands::MessageSharedPtr;
using am::MockMessageHelper;
+using am::MockHmiInterfaces;
+using test::components::protocol_handler_test::MockProtocolHandler;
+using test::components::protocol_handler_test::MockProtocolHandlerSettings;
using ::utils::SharedPtr;
using ::testing::_;
using ::testing::Return;
@@ -88,6 +93,10 @@ class SetAppIconRequestTest
return msg;
}
+ NiceMock<MockHmiInterfaces> hmi_interfaces_;
+ protocol_handler_test::MockProtocolHandler mock_protocol_handler_;
+ protocol_handler_test::MockProtocolHandlerSettings
+ mock_protocol_handler_settings_;
};
TEST_F(SetAppIconRequestTest, OnEvent_UI_UNSUPPORTED_RESOURCE) {
@@ -107,6 +116,20 @@ TEST_F(SetAppIconRequestTest, OnEvent_UI_UNSUPPORTED_RESOURCE) {
MockAppPtr mock_app = CreateMockApp();
ON_CALL(app_mngr_, application(kConnectionKey))
.WillByDefault(Return(mock_app));
+ ON_CALL(app_mngr_, hmi_interfaces())
+ .WillByDefault(ReturnRef(hmi_interfaces_));
+ ON_CALL(hmi_interfaces_,
+ GetInterfaceState(am::HmiInterfaces::HMI_INTERFACE_UI))
+ .WillByDefault(Return(am::HmiInterfaces::STATE_AVAILABLE));
+
+ ON_CALL(app_mngr_, protocol_handler())
+ .WillByDefault(ReturnRef(mock_protocol_handler_));
+ ON_CALL(mock_protocol_handler_, get_settings())
+ .WillByDefault(ReturnRef(mock_protocol_handler_settings_));
+
+ ON_CALL(mock_protocol_handler_settings_, max_supported_protocol_version())
+ .WillByDefault(
+ Return(protocol_handler::MajorProtocolVersion::PROTOCOL_VERSION_4));
ON_CALL(*mock_app, app_id()).WillByDefault(Return(kConnectionKey));
ON_CALL(*mock_app, set_app_icon_path(_)).WillByDefault(Return(true));
diff --git a/src/components/application_manager/test/commands/mobile/set_display_layout_test.cc b/src/components/application_manager/test/commands/mobile/set_display_layout_test.cc
index 8444b88d63..3e1785a3bd 100644
--- a/src/components/application_manager/test/commands/mobile/set_display_layout_test.cc
+++ b/src/components/application_manager/test/commands/mobile/set_display_layout_test.cc
@@ -69,6 +69,7 @@ const uint32_t kAppId = 1u;
const uint32_t kCmdId = 1u;
const uint32_t kConnectionKey = 2u;
const uint32_t kCorrelationKey = 2u;
+const std::string kLayout = "media";
} // namespace
MATCHER_P(CheckMshCorrId, corr_id, "") {
@@ -189,6 +190,7 @@ TEST_F(SetDisplayLayoutRequestTest, Run_SUCCESS) {
MockAppPtr mock_app(CreateMockApp());
EXPECT_CALL(app_mngr_, application(kConnectionKey))
.WillOnce(Return(mock_app));
+ EXPECT_CALL(*mock_app, display_layout()).WillOnce(ReturnRef(kLayout));
EXPECT_CALL(*mock_app, app_id()).WillOnce(Return(kAppId));
EXPECT_CALL(app_mngr_, GetNextHMICorrelationID())
diff --git a/src/components/application_manager/test/commands/mobile/slider_test.cc b/src/components/application_manager/test/commands/mobile/slider_test.cc
index 54ac3cccc0..53764e3fcd 100644
--- a/src/components/application_manager/test/commands/mobile/slider_test.cc
+++ b/src/components/application_manager/test/commands/mobile/slider_test.cc
@@ -282,9 +282,8 @@ TEST_F(SliderRequestTest, OnEvent_UI_OnResetTimeout_UNSUCCESS) {
CommandPtr command(CreateCommand<SliderRequest>(msg_));
EXPECT_TRUE(command->Init());
- EXPECT_CALL(
- app_mngr_,
- updateRequestTimeout(kConnectionKey, kCorrelationId, kDefaultTimeout));
+ EXPECT_CALL(app_mngr_,
+ updateRequestTimeout(kConnectionKey, kCorrelationId, _));
Event event(hmi_apis::FunctionID::UI_OnResetTimeout);
event.set_smart_object(*msg_);
diff --git a/src/components/application_manager/test/hmi_capabilities.json b/src/components/application_manager/test/hmi_capabilities.json
index 9db6ee78ae..0efcc688bc 100644
--- a/src/components/application_manager/test/hmi_capabilities.json
+++ b/src/components/application_manager/test/hmi_capabilities.json
@@ -263,7 +263,15 @@
},
{
"name": "graphic",
- "imageTypeSupported": [],
+ "imageTypeSupported": [],
+ "imageResolution": {
+ "resolutionWidth": 35,
+ "resolutionHeight": 35
+ }
+ },
+ {
+ "name": "secondaryGraphic",
+ "imageTypeSupported": [],
"imageResolution": {
"resolutionWidth": 35,
"resolutionHeight": 35
diff --git a/src/components/application_manager/test/include/application_manager/mock_application.h b/src/components/application_manager/test/include/application_manager/mock_application.h
index 5bf2f2368e..c46a0b994f 100644
--- a/src/components/application_manager/test/include/application_manager/mock_application.h
+++ b/src/components/application_manager/test/include/application_manager/mock_application.h
@@ -209,6 +209,9 @@ class MockApplication : public ::application_manager::Application {
MOCK_CONST_METHOD0(keyboard_props, const smart_objects::SmartObject*());
MOCK_CONST_METHOD0(menu_title, const smart_objects::SmartObject*());
MOCK_CONST_METHOD0(menu_icon, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(day_color_scheme, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(night_color_scheme, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(display_layout, const std::string&());
MOCK_METHOD1(load_global_properties,
void(const smart_objects::SmartObject& so));
MOCK_METHOD1(set_help_prompt,
@@ -232,6 +235,11 @@ class MockApplication : public ::application_manager::Application {
void(const smart_objects::SmartObject& menu_title));
MOCK_METHOD1(set_menu_icon,
void(const smart_objects::SmartObject& menu_icon));
+ MOCK_METHOD1(set_day_color_scheme,
+ void(const smart_objects::SmartObject& color_scheme));
+ MOCK_METHOD1(set_night_color_scheme,
+ void(const smart_objects::SmartObject& color_scheme));
+ MOCK_METHOD1(set_display_layout, void(const std::string& layout));
MOCK_CONST_METHOD0(audio_stream_retry_number, uint32_t());
MOCK_METHOD1(set_audio_stream_retry_number,
void(const uint32_t& audio_stream_retry_number));
diff --git a/src/components/application_manager/test/policy_handler_test.cc b/src/components/application_manager/test/policy_handler_test.cc
index 77500fd238..d9e1cefa01 100644
--- a/src/components/application_manager/test/policy_handler_test.cc
+++ b/src/components/application_manager/test/policy_handler_test.cc
@@ -408,7 +408,6 @@ TEST_F(PolicyHandlerTest, ReceiveMessageFromSDK_PTNotLoaded) {
// Checks
EXPECT_CALL(*mock_policy_manager_, LoadPT("", msg)).WillOnce(Return(false));
- EXPECT_CALL(*mock_policy_manager_, ForcePTExchange()).WillOnce(Return(""));
EXPECT_CALL(app_manager_, GetNextHMICorrelationID()).Times(0);
EXPECT_CALL(mock_message_helper_, CreateGetVehicleDataRequest(_, _, _))
.Times(0);
diff --git a/src/components/application_manager/test/request_controller/request_controller_test.cc b/src/components/application_manager/test/request_controller/request_controller_test.cc
index e053d51c34..c2912fdc0b 100644
--- a/src/components/application_manager/test/request_controller/request_controller_test.cc
+++ b/src/components/application_manager/test/request_controller/request_controller_test.cc
@@ -62,6 +62,7 @@ using ::application_manager::request_controller::RequestInfo;
using ::testing::Return;
using ::testing::ReturnRef;
using ::testing::NiceMock;
+using ::testing::_;
typedef NiceMock<application_manager_test::MockRequest> MRequest;
typedef utils::SharedPtr<MRequest> RequestPtr;
@@ -114,6 +115,7 @@ class RequestControllerTestClass : public ::testing::Test {
RequestPtr output =
utils::MakeShared<MRequest>(connection_key, correlation_id);
ON_CALL(*output, default_timeout()).WillByDefault(Return(default_timeout));
+ ON_CALL(*output, CheckPermissions()).WillByDefault(Return(true));
return output;
}
@@ -159,6 +161,40 @@ class RequestControllerTestClass : public ::testing::Test {
};
TEST_F(RequestControllerTestClass,
+ AddMobileRequest_DuplicateCorrelationId_INVALID_ID) {
+ RequestPtr request_valid = GetMockRequest();
+ TestAsyncWaiter waiter_valid;
+ ON_CALL(*request_valid, default_timeout()).WillByDefault(Return(0));
+ EXPECT_CALL(*request_valid, Init()).WillOnce(Return(true));
+ EXPECT_CALL(*request_valid, Run())
+ .Times(1)
+ .WillRepeatedly(NotifyTestAsyncWaiter(&waiter_valid));
+
+ EXPECT_EQ(RequestController::SUCCESS,
+ AddRequest(default_settings_,
+ request_valid,
+ RequestInfo::RequestType::MobileRequest,
+ mobile_apis::HMILevel::HMI_NONE));
+ EXPECT_TRUE(waiter_valid.WaitFor(1, 1000));
+
+ // The command should not be run if another command with the same
+ // correlation_id is waiting for a response
+ RequestPtr request_dup_corr_id = GetMockRequest();
+ TestAsyncWaiter waiter_dup;
+ ON_CALL(*request_dup_corr_id, default_timeout()).WillByDefault(Return(0));
+ EXPECT_CALL(*request_dup_corr_id, Init()).WillOnce(Return(true));
+ ON_CALL(*request_dup_corr_id, Run())
+ .WillByDefault(NotifyTestAsyncWaiter(&waiter_dup));
+
+ EXPECT_EQ(RequestController::SUCCESS,
+ AddRequest(default_settings_,
+ request_dup_corr_id,
+ RequestInfo::RequestType::MobileRequest,
+ mobile_apis::HMILevel::HMI_NONE));
+ EXPECT_FALSE(waiter_dup.WaitFor(1, 1000));
+}
+
+TEST_F(RequestControllerTestClass,
CheckPosibilitytoAdd_ZeroValueLimiters_SUCCESS) {
// Test case than pending_requests_amount,
// app_time_scale_max_requests_ and
diff --git a/src/components/application_manager/test/resumption/resumption_data_db_test.cc b/src/components/application_manager/test/resumption/resumption_data_db_test.cc
index 001e06ca58..3b2c0d7b13 100644
--- a/src/components/application_manager/test/resumption/resumption_data_db_test.cc
+++ b/src/components/application_manager/test/resumption/resumption_data_db_test.cc
@@ -271,6 +271,10 @@ void ResumptionDataDBTest::CheckGlobalProportiesData() {
select_image.GetInteger(0));
EXPECT_EQ((*menu_icon_)[am::strings::value].asString(),
select_image.GetString(1));
+ if ((*menu_icon_).keyExists(am::strings::is_template)) {
+ EXPECT_EQ((*menu_icon_)[am::strings::is_template].asBool(),
+ select_image.GetBoolean(2));
+ }
}
if (!select_globalproperties.IsNull(8)) {
utils::dbms::SQLQuery select_tts_chunk(test_db());
diff --git a/src/components/application_manager/test/resumption/resumption_data_test.cc b/src/components/application_manager/test/resumption/resumption_data_test.cc
index 65e01b6119..0f90fe978f 100644
--- a/src/components/application_manager/test/resumption/resumption_data_test.cc
+++ b/src/components/application_manager/test/resumption/resumption_data_test.cc
@@ -381,6 +381,7 @@ void ResumptionDataTest::SetMenuTitleAndIcon() {
sm::SmartObject sm_icon;
sm_icon[am::strings::value] = "test icon";
sm_icon[am::strings::image_type] = ImageType::STATIC;
+ sm_icon[am::strings::is_template] = false;
sm::SmartObject sm_title;
sm_title = "test title";
diff --git a/src/components/application_manager/test/resumption_sql_queries_test.cc b/src/components/application_manager/test/resumption_sql_queries_test.cc
index 28a3383086..0ec902085f 100644
--- a/src/components/application_manager/test/resumption_sql_queries_test.cc
+++ b/src/components/application_manager/test/resumption_sql_queries_test.cc
@@ -197,8 +197,9 @@ class ResumptionSqlQueriesTest : public ::testing::Test {
const int64_t glob_prop_key);
SQLQuery& FillImageTable(SQLQuery& query,
- const int imageType,
- const string& value);
+ const int image_type,
+ const string& value,
+ const bool is_template);
SQLQuery& FillTableLimitedCharacterListTable(
SQLQuery& query, const string& limitedCharacterList);
@@ -456,11 +457,13 @@ void ResumptionSqlQueriesTest::CheckSelectQuery(const string& query_to_check,
}
SQLQuery& ResumptionSqlQueriesTest::FillImageTable(SQLQuery& query,
- const int imageType,
- const string& value) {
+ const int image_type,
+ const string& value,
+ const bool is_template) {
EXPECT_TRUE(query.Prepare(kInsertImage));
- query.Bind(0, imageType);
+ query.Bind(0, image_type);
query.Bind(1, value);
+ query.Bind(2, is_template);
EXPECT_TRUE(query.Exec());
return query;
}
@@ -802,7 +805,10 @@ TEST_F(ResumptionSqlQueriesTest, kChecksResumptionData_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectCountHMILevel_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -829,7 +835,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectCountHMILevel_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectHMILevel_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -854,7 +863,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectHMILevel_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kCheckHMIId_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -879,7 +891,10 @@ TEST_F(ResumptionSqlQueriesTest, kCheckHMIId_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectHMIId_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -904,7 +919,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectHMIId_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectCountHMIId_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -930,7 +948,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectCountHMIId_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kCountHashId_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -956,7 +977,10 @@ TEST_F(ResumptionSqlQueriesTest, kCountHashId_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectHashId_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -990,7 +1014,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectIgnOffTime_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kCheckApplication_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1015,7 +1042,10 @@ TEST_F(ResumptionSqlQueriesTest, kCheckApplication_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kCountApplications_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1032,7 +1062,9 @@ TEST_F(ResumptionSqlQueriesTest, kCountApplications_ExpectDataCorrect) {
device_id,
key);
- key = FillImageTable(temp_query, 1, "tst_img2").LastInsertId();
+ key = FillImageTable(
+ temp_query, 1 /* image_type */, "tst_img2", true /* is_template */)
+ .LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1056,7 +1088,10 @@ TEST_F(ResumptionSqlQueriesTest,
kSelectDataForLoadResumeData_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1084,7 +1119,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kUpdateHMILevel_ExpectDataUpdated) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1117,7 +1155,10 @@ TEST_F(ResumptionSqlQueriesTest, kUpdateHMILevel_ExpectDataUpdated) {
TEST_F(ResumptionSqlQueriesTest, kUpdateIgnOffCount_ExpectDataUpdated) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1148,7 +1189,10 @@ TEST_F(ResumptionSqlQueriesTest, kUpdateIgnOffCount_ExpectDataUpdated) {
TEST_F(ResumptionSqlQueriesTest, kCountApplicationsIgnOff_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1189,7 +1233,10 @@ TEST_F(ResumptionSqlQueriesTest,
kSelectApplicationsIgnOffCount_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1229,7 +1276,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kUpdateSuspendData_ExpectDataUpdated) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1258,7 +1308,10 @@ TEST_F(ResumptionSqlQueriesTest, kUpdateSuspendData_ExpectDataUpdated) {
TEST_F(ResumptionSqlQueriesTest, kDeleteFile_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key1 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -1288,7 +1341,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteApplicationFilesArray_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key1 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -1324,7 +1380,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kDeleteSubMenu_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1355,7 +1414,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteApplicationSubMenuArray_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key)
.LastInsertId();
@@ -1389,7 +1451,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteApplicationSubscriptionsArray_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
key1 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -1426,7 +1491,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kDeleteImageFromCommands_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillCommandTable(temp_query, 1, "tst_menu_name", 1, 2, key1)
.LastInsertId();
key1 = FillGlobalPropertiesTable(
@@ -1456,7 +1524,10 @@ TEST_F(ResumptionSqlQueriesTest, kDeleteImageFromCommands_ExpectDataDeleted) {
TEST_F(ResumptionSqlQueriesTest, kDeleteVrCommands_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillCommandTable(temp_query, 1, "tst_menu_name", 1, 2, key1)
.LastInsertId();
key1 = FillGlobalPropertiesTable(
@@ -1490,7 +1561,10 @@ TEST_F(ResumptionSqlQueriesTest, kDeleteVrCommands_ExpectDataDeleted) {
TEST_F(ResumptionSqlQueriesTest, kDeleteCommands_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillCommandTable(temp_query, 1, "tst_menu_name", 1, 2, key1)
.LastInsertId();
@@ -1522,7 +1596,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteApplicationCommandsArray_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillCommandTable(temp_query, 1, "tst_menu_name", 1, 2, key1)
.LastInsertId();
@@ -1560,7 +1637,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kDeleteImageFromChoiceSet_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillChoiceTable(temp_query,
2,
"tst_menu_name",
@@ -1595,7 +1675,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteVrCommandsFromChoiceSet_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 =
FillChoiceTable(
temp_query, 1, "tst_menu_name", "second_text", "tert_txt", key1)
@@ -1638,7 +1721,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kDeleteChoice_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 =
FillChoiceTable(
temp_query, 1, "tst_menu_name", "second_text", "tert_txt", key1)
@@ -1775,7 +1861,10 @@ TEST_F(ResumptionSqlQueriesTest,
kDeleteImageFromGlobalProperties_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -1804,7 +1893,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kDeletevrHelpItem_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -1834,7 +1926,10 @@ TEST_F(ResumptionSqlQueriesTest, kDeletevrHelpItem_ExpectDataDeleted) {
TEST_F(ResumptionSqlQueriesTest, kDeletevrHelpItemArray_ExpectDataDeleted) {
// Arrange
SQLQuery temp_query(db());
- int64_t key1 = FillImageTable(temp_query, 1, test_image).LastInsertId();
+ int64_t key1 = FillImageTable(temp_query,
+ /*image_type=*/1,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t key2 = FillGlobalPropertiesTable(
temp_query, "vrHelp", "menuTitle", 1, 1, 2, "auto", key1)
.LastInsertId();
@@ -2051,7 +2146,8 @@ TEST_F(ResumptionSqlQueriesTest, kDeleteGlobalProperties_ExpectDataDeleted) {
TEST_F(ResumptionSqlQueriesTest, kSelectCountImage_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- FillImageTable(temp_query, 2, "tst_image");
+ FillImageTable(
+ temp_query, /*image_type=*/2, "tst_image", /*is_template=*/true);
ValToPosPair p1(0, "tst_image");
ValToPosPair p2(1, "");
// Check
@@ -2061,7 +2157,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectCountImage_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectPrimaryKeyImage_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
ValToPosPair p1(0, "tst_image");
ValToPosPair p2(1, "");
// Check
@@ -2071,7 +2170,8 @@ TEST_F(ResumptionSqlQueriesTest, kSelectPrimaryKeyImage_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kInsertImage_ExpectDataInserted) {
// Arrange
SQLQuery temp_query(db());
- FillImageTable(temp_query, 2, "tst_image");
+ FillImageTable(
+ temp_query, /*image_type=*/2, "tst_image", /*is_template=*/true);
const std::string select_count_image = "SELECT COUNT(*) FROM image;";
// Check
CheckSelectQuery(select_count_image, 1, 0);
@@ -2616,7 +2716,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectCommandsFromCommand_ExpectDataCorrect) {
app_id1,
device_id,
9).LastInsertId();
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
FillChoiceTable(
temp_query, 1, "menu_name", "sec_text", "tert_text", image_key)
@@ -2656,7 +2759,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectCommandsFromChoice_ExpectDataCorrect) {
app_id1,
device_id,
9).LastInsertId();
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
int64_t choice_key =
FillChoiceTable(
@@ -2776,7 +2882,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectChoiceSets_ExpectDataCorrect) {
app_id1,
device_id,
9).LastInsertId();
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
int64_t choice_key =
FillChoiceTable(
temp_query, 1, "menu_name", "sec_text", "tert_text", image_key)
@@ -2808,7 +2917,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectChoiceSets_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectImage_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
// Check
ValToPosPair p1(0, IntToString(image_key));
ValToPosPair p2(1, "");
@@ -2846,7 +2958,10 @@ TEST_F(ResumptionSqlQueriesTest,
TEST_F(ResumptionSqlQueriesTest, kSelectGlobalProperties_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ test_image,
+ /*is_template=*/true).LastInsertId();
int64_t glob_prop_key =
FillGlobalPropertiesTable(
temp_query, "tst_vr_title", "tst_menu", 2, 3, 3, "auto", image_key)
@@ -2883,7 +2998,10 @@ TEST_F(ResumptionSqlQueriesTest, kSelectGlobalProperties_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kChecksVrHelpItem_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
int64_t glob_prop_key =
FillGlobalPropertiesTable(
temp_query, "tst_vr_title", "tst_menu", 2, 3, 3, "auto", image_key)
@@ -2900,7 +3018,10 @@ TEST_F(ResumptionSqlQueriesTest, kChecksVrHelpItem_ExpectDataCorrect) {
TEST_F(ResumptionSqlQueriesTest, kSelectVrHelpItem_ExpectDataCorrect) {
// Arrange
SQLQuery temp_query(db());
- int64_t image_key = FillImageTable(temp_query, 2, "tst_image").LastInsertId();
+ int64_t image_key = FillImageTable(temp_query,
+ /*image_type=*/2,
+ "tst_image",
+ /*is_template=*/true).LastInsertId();
int64_t glob_prop_key =
FillGlobalPropertiesTable(
temp_query, "tst_vr_title", "tst_menu", 2, 3, 3, "auto", image_key)
diff --git a/src/components/application_manager/test/sdl_preloaded_pt.json b/src/components/application_manager/test/sdl_preloaded_pt.json
index d6f34c12fc..c5386f612e 100644
--- a/src/components/application_manager/test/sdl_preloaded_pt.json
+++ b/src/components/application_manager/test/sdl_preloaded_pt.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/application_manager/test/sdl_pt_update.json b/src/components/application_manager/test/sdl_pt_update.json
index a332f92382..e013243760 100644
--- a/src/components/application_manager/test/sdl_pt_update.json
+++ b/src/components/application_manager/test/sdl_pt_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1587,12 +1587,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1602,12 +1604,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1617,12 +1621,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1631,12 +1637,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1698,7 +1706,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/hmi_message_handler/include/hmi_message_handler/mb_controller.h b/src/components/hmi_message_handler/include/hmi_message_handler/mb_controller.h
index 98d5260259..60dc50ad7a 100644
--- a/src/components/hmi_message_handler/include/hmi_message_handler/mb_controller.h
+++ b/src/components/hmi_message_handler/include/hmi_message_handler/mb_controller.h
@@ -1,3 +1,33 @@
+/*
+Copyright (c) 2018 Livio, Inc.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+* Neither the name of SmartDeviceLink Consortium, Inc. nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
#ifndef MB_CONTROLLER_H
#define MB_CONTROLLER_H
diff --git a/src/components/hmi_message_handler/include/hmi_message_handler/websocket_session.h b/src/components/hmi_message_handler/include/hmi_message_handler/websocket_session.h
index c084bd7769..9692c4aef4 100644
--- a/src/components/hmi_message_handler/include/hmi_message_handler/websocket_session.h
+++ b/src/components/hmi_message_handler/include/hmi_message_handler/websocket_session.h
@@ -1,3 +1,33 @@
+/*
+Copyright (c) 2018 Livio, Inc.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+* Neither the name of SmartDeviceLink Consortium, Inc. nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
#ifndef WEBSOCKET_SESSION_H
#define WEBSOCKET_SESSION_H
diff --git a/src/components/hmi_message_handler/src/mb_controller.cc b/src/components/hmi_message_handler/src/mb_controller.cc
index ec0d1f8bd8..8d3b11add5 100644
--- a/src/components/hmi_message_handler/src/mb_controller.cc
+++ b/src/components/hmi_message_handler/src/mb_controller.cc
@@ -1,3 +1,32 @@
+/*
+Copyright (c) 2018 Livio, Inc.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+* Neither the name of SmartDeviceLink Consortium, Inc. nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
#include "hmi_message_handler/mb_controller.h"
diff --git a/src/components/hmi_message_handler/src/websocket_session.cc b/src/components/hmi_message_handler/src/websocket_session.cc
index 19227a1555..26f15695c9 100644
--- a/src/components/hmi_message_handler/src/websocket_session.cc
+++ b/src/components/hmi_message_handler/src/websocket_session.cc
@@ -1,3 +1,33 @@
+/*
+Copyright (c) 2018 Livio, Inc.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+* Neither the name of SmartDeviceLink Consortium, Inc. nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
#include "hmi_message_handler/websocket_session.h"
#include "hmi_message_handler/mb_controller.h"
#include <unistd.h>
diff --git a/src/components/interfaces/HMI_API.xml b/src/components/interfaces/HMI_API.xml
index 5d46fce942..ef891f86a1 100644
--- a/src/components/interfaces/HMI_API.xml
+++ b/src/components/interfaces/HMI_API.xml
@@ -624,7 +624,10 @@
<description>The image field for the app icon (set by setAppIcon)</description>
</element>
<element name="graphic">
- <description>The image field for Show</description>
+ <description>The primary image field for Show</description>
+ </element>
+ <element name="secondaryGraphic">
+ <description>The secondary image field for Show</description>
</element>
<element name="showConstantTBTIcon">
<description>The primary image field for ShowConstantTBT</description>
@@ -726,6 +729,36 @@
</enum>
<!--IVI part-->
+<enum name="FuelType">
+ <element name="GASOLINE" />
+ <element name="DIESEL" />
+ <element name="CNG">
+ <description>
+ For vehicles using compressed natural gas.
+ </description>
+ </element>
+ <element name="LPG">
+ <description>
+ For vehicles using liquefied petroleum gas.
+ </description>
+ </element>
+ <element name="HYDROGEN">
+ <description>For FCEV (fuel cell electric vehicle).</description>
+ </element>
+ <element name="BATTERY">
+ <description>For BEV (Battery Electric Vehicle), PHEV (Plug-in Hybrid Electric Vehicle), solar vehicles and other vehicles which run on a battery.</description>
+ </element>
+</enum>
+
+<struct name="FuelRange">
+ <param name="type" type="Common.FuelType" mandatory="false"/>
+ <param name="range" type="Float" minvalue="0" maxvalue="10000" mandatory="false">
+ <description>
+ The estimate range in KM the vehicle can travel based on fuel level and consumption.
+ </description>
+ </param>
+</struct>
+
<enum name="ComponentVolumeStatus">
<description>The volume status of a vehicle component.</description>
<element name="UNKNOWN" internal_name="CVS_UNKNOWN">
@@ -748,6 +781,33 @@
</element>
</enum>
+<enum name="TPMS">
+ <element name="UNKNOWN">
+ <description>If set the status of the tire is not known.</description>
+ </element>
+ <element name="SYSTEM_FAULT">
+ <description>TPMS does not function.</description>
+ </element>
+ <element name="SENSOR_FAULT">
+ <description>The sensor of the tire does not function.</description>
+ </element>
+ <element name="LOW">
+ <description>TPMS is reporting a low tire pressure for the tire.</description>
+ </element>
+ <element name="SYSTEM_ACTIVE">
+ <description>TPMS is active and the tire pressure is monitored.</description>
+ </element>
+ <element name="TRAIN">
+ <description>TPMS is reporting that the tire must be trained.</description>
+ </element>
+ <element name="TRAINING_COMPLETE">
+ <description>TPMS reports the training for the tire is completed.</description>
+ </element>
+ <element name="NOT_TRAINED">
+ <description>TPMS reports the tire is not trained.</description>
+ </element>
+</enum>
+
<enum name="PRNDL">
<description>The selected gear.</description>
<element name="PARK">
@@ -978,6 +1038,8 @@
<element name="VEHICLEDATA_ENGINETORQUE" />
<element name="VEHICLEDATA_ACCPEDAL" />
<element name="VEHICLEDATA_STEERINGWHEEL" />
+ <element name="VEHICLEDATA_FUELRANGE" />
+ <element name="VEHICLEDATA_ENGINEOILLIFE" />
</enum>
<enum name="WiperStatus">
@@ -1821,6 +1883,9 @@
<param name="imageType" type="Common.ImageType" mandatory="true">
<description>Describes, whether it is a static or dynamic image.</description>
</param>
+ <param name="isTemplate" type="Boolean" mandatory="false">
+ <description>Optional value to specify whether it's a template image. A template image can be (re)colored by the HMI as needed by using an image pattern</description>
+ </param>
</struct>
<struct name="DeviceInfo">
@@ -1870,6 +1935,27 @@
</param>
</struct>
+<struct name="RGBColor">
+ <param name="red" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+ <param name="green" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+ <param name="blue" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+</struct>
+
+<struct name="TemplateColorScheme">
+ <description>
+ A color scheme for all display layout templates.
+ </description>
+ <param name="primaryColor" type="Common.RGBColor" mandatory="false">
+ <description>The primary "accent" color</description>
+ </param>
+ <param name="secondaryColor" type="Common.RGBColor" mandatory="false">
+ <description>The secondary "accent" color</description>
+ </param>
+ <param name="backgroundColor" type="Common.RGBColor" mandatory="false">
+ <description>The color of the background</description>
+ </param>
+</struct>
+
<struct name="HMIApplication">
<description>Data type containing information about application needed by HMI.</description>
<param name="appName" type="String" maxlength="100" mandatory="true">
@@ -1927,6 +2013,8 @@
<description>If SDL omits this parameter - none RequestType is allowed for this app</description>
<description>(either this is a pre-registered app or such is dictated by policies).</description>
</param>
+ <param name="dayColorScheme" type="Common.TemplateColorScheme" mandatory="false"></param>
+ <param name="nightColorScheme" type="Common.TemplateColorScheme" mandatory="false"></param>
</struct>
<struct name="MenuParams">
@@ -2253,7 +2341,13 @@
<struct name="SingleTireStatus">
<param name="status" type="Common.ComponentVolumeStatus" mandatory="true">
<description>The status of component volume. See ComponentVolumeStatus.</description>
-</param>
+ </param>
+ <param name="tpms" type="TPMS" mandatory="false">
+ <description>The status of TPMS according to the particular tire.</description>
+ </param>
+ <param name="pressure" type="Float" mandatory="false" minvalue="0" maxvalue="2000">
+ <description>The pressure value of the particular tire in kilo pascal.</description>
+ </param>
</struct>
<struct name="DIDResult">
@@ -3680,6 +3774,8 @@
<param name="appID" type="Integer" mandatory="true">
<description>ID of application related to this RPC.</description>
</param>
+ <param name="dayColorScheme" type="Common.TemplateColorScheme" mandatory="false"></param>
+ <param name="nightColorScheme" type="Common.TemplateColorScheme" mandatory="false"></param>
</function>
<function name="SetDisplayLayout" messagetype="response">
<param name="displayCapabilities" type="Common.DisplayCapabilities" mandatory="false">
@@ -4205,6 +4301,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4244,6 +4343,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Boolean" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
@@ -4281,6 +4383,9 @@
<param name="instantFuelConsumption" type="Common.VehicleDataResult" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Common.VehicleDataResult" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Common.VehicleDataResult" mandatory="false">
<description>The external temperature in degrees celsius.</description>
</param>
@@ -4320,6 +4425,9 @@
<param name="steeringWheelAngle" type="Common.VehicleDataResult" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Common.VehicleDataResult" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Common.VehicleDataResult" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
@@ -4363,6 +4471,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius.</description>
</param>
@@ -4402,6 +4513,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Boolean" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
@@ -4439,6 +4553,9 @@
<param name="instantFuelConsumption" type="Common.VehicleDataResult" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Common.VehicleDataResult" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Common.VehicleDataResult" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4478,6 +4595,9 @@
<param name="steeringWheelAngle" type="Common.VehicleDataResult" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Common.VehicleDataResult" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Common.VehicleDataResult" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
@@ -4516,6 +4636,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4558,6 +4681,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<param name="eCallInfo" type="Boolean" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
</param>
@@ -4593,6 +4719,9 @@
<param name="instantFuelConsumption" type="Float" minvalue="0" maxvalue="25575" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Common.FuelRange" minsize="0" maxsize="100" array="true" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Float" minvalue="-40" maxvalue="100" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4635,6 +4764,9 @@
<param name="steeringWheelAngle" type="Float" minvalue="-2000" maxvalue="2000" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Float" minvalue="0" maxvalue="100" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<param name="eCallInfo" type="Common.ECallInfo" mandatory="false">
<description>Emergency Call notification and confirmation data</description>
</param>
@@ -4671,6 +4803,9 @@
<param name="instantFuelConsumption" type="Float" minvalue="0" maxvalue="25575" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Common.FuelRange" minsize="0" maxsize="100" array="true" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Float" minvalue="-40" maxvalue="100" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
diff --git a/src/components/interfaces/MOBILE_API.xml b/src/components/interfaces/MOBILE_API.xml
index a1c64aecda..101b3a4280 100644
--- a/src/components/interfaces/MOBILE_API.xml
+++ b/src/components/interfaces/MOBILE_API.xml
@@ -135,6 +135,9 @@
<element name="READ_ONLY">
<description>The value being set is read only</description>
</element>
+ <element name="CORRUPTED_DATA">
+ <description>The data sent failed to pass CRC check in receiver end</description>
+ </element>
</enum>
<enum name="ButtonPressMode">
@@ -513,6 +516,8 @@
<element name="VEHICLEDATA_ENGINETORQUE" />
<element name="VEHICLEDATA_ACCPEDAL" />
<element name="VEHICLEDATA_STEERINGWHEEL" />
+ <element name="VEHICLEDATA_FUELRANGE" />
+ <element name="VEHICLEDATA_ENGINEOILLIFE" />
</enum>
<enum name="ButtonName">
@@ -781,7 +786,11 @@
</element>
<element name="graphic">
- <description>The image field for Show</description>
+ <description>The primary image field for Show</description>
+ </element>
+
+ <element name="secondaryGraphic">
+ <description>The secondary image field for Show</description>
</element>
<element name="showConstantTBTIcon">
@@ -899,6 +908,9 @@
<param name="imageType" type="ImageType" mandatory="true">
<description>Describes, whether it is a static or dynamic image.</description>
</param>
+ <param name="isTemplate" type="Boolean" mandatory="false">
+ <description>Optional value to specify whether it's a template image. A template image can be (re)colored by the HMI as needed by using an image pattern</description>
+ </param>
</struct>
<struct name="SoftButton">
@@ -1082,11 +1094,74 @@
<element name="NOT_SUPPORTED" internal_name="CVS_NOT_SUPPORTED">
</element>
</enum>
+
+ <enum name="TPMS">
+ <element name="UNKNOWN">
+ <description>If set the status of the tire is not known.</description>
+ </element>
+ <element name="SYSTEM_FAULT">
+ <description>TPMS does not function.</description>
+ </element>
+ <element name="SENSOR_FAULT">
+ <description>The sensor of the tire does not function.</description>
+ </element>
+ <element name="LOW">
+ <description>TPMS is reporting a low tire pressure for the tire.</description>
+ </element>
+ <element name="SYSTEM_ACTIVE">
+ <description>TPMS is active and the tire pressure is monitored.</description>
+ </element>
+ <element name="TRAIN">
+ <description>TPMS is reporting that the tire must be trained.</description>
+ </element>
+ <element name="TRAINING_COMPLETE">
+ <description>TPMS reports the training for the tire is completed.</description>
+ </element>
+ <element name="NOT_TRAINED">
+ <description>TPMS reports the tire is not trained.</description>
+ </element>
+ </enum>
+ <enum name="FuelType">
+ <element name="GASOLINE" />
+ <element name="DIESEL" />
+ <element name="CNG">
+ <description>
+ For vehicles using compressed natural gas.
+ </description>
+ </element>
+ <element name="LPG">
+ <description>
+ For vehicles using liquefied petroleum gas.
+ </description>
+ </element>
+ <element name="HYDROGEN">
+ <description>For FCEV (fuel cell electric vehicle).</description>
+ </element>
+ <element name="BATTERY">
+ <description>For BEV (Battery Electric Vehicle), PHEV (Plug-in Hybrid Electric Vehicle), solar vehicles and other vehicles which run on a battery.</description>
+ </element>
+ </enum>
+
+ <struct name="FuelRange">
+ <param name="type" type="FuelType" mandatory="false"/>
+ <param name="range" type="Float" minvalue="0" maxvalue="10000" mandatory="false">
+ <description>
+ The estimate range in KM the vehicle can travel based on fuel level and consumption.
+ </description>
+ </param>
+ </struct>
+
<struct name="SingleTireStatus">
<param name="status" type="ComponentVolumeStatus" mandatory="true">
<description>See ComponentVolumeStatus.</description>
</param>
+ <param name="tpms" type="TPMS" mandatory="false">
+ <description>The status of TPMS according to the particular tire.</description>
+ </param>
+ <param name="pressure" type="Float" mandatory="false" minvalue="0" maxvalue="2000">
+ <description>The pressure value of the particular tire in kilo pascal.</description>
+ </param>
</struct>
<enum name="WarningLightStatus">
@@ -2887,7 +2962,27 @@
<description>The position of the haptic rectangle to be highlighted. The center of this rectangle will be "touched" when a press occurs.</description>
</param>
</struct>
-
+
+ <struct name="RGBColor">
+ <param name="red" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+ <param name="green" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+ <param name="blue" type="Integer" minvalue="0" maxvalue="255" mandatory="true" />
+ </struct>
+
+ <struct name="TemplateColorScheme">
+ <description>
+ A color scheme for all display layout templates.
+ </description>
+ <param name="primaryColor" type="RGBColor" mandatory="false">
+ <description>The primary "accent" color</description>
+ </param>
+ <param name="secondaryColor" type="RGBColor" mandatory="false">
+ <description>The secondary "accent" color</description>
+ </param>
+ <param name="backgroundColor" type="RGBColor" mandatory="false">
+ <description>The color of the background</description>
+ </param>
+ </struct>
<!-- Requests/Responses -->
<function name="RegisterAppInterface" functionID="RegisterAppInterfaceID" messagetype="request">
@@ -2988,6 +3083,10 @@
See AppInfo.
</description>
</param>
+
+ <param name="dayColorScheme" type="TemplateColorScheme" mandatory="false"/>
+
+ <param name="nightColorScheme" type="TemplateColorScheme" mandatory="false"/>
</function>
<function name="RegisterAppInterface" functionID="RegisterAppInterfaceID" messagetype="response">
@@ -3090,6 +3189,10 @@
<param name="systemSoftwareVersion" type="String" maxlength="100" mandatory="false" platform="documentation">
<description>The software version of the system that implements the SmartDeviceLink core.</description>
</param>
+ <param name="iconResumed" type="Boolean" mandatory="true">
+ <description>Existence of apps icon at system. If true, apps icon
+ was resumed at system. If false, apps icon is not resumed at system</description>
+ </param>
</function>
<function name="UnregisterAppInterface" functionID="UnregisterAppInterfaceID" messagetype="request">
@@ -4056,6 +4159,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4095,6 +4201,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Boolean" mandatory="false">
@@ -4159,6 +4268,9 @@
<param name="instantFuelConsumption" type="VehicleDataResult" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="VehicleDataResult" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="VehicleDataResult" mandatory="false">
<description>The external temperature in degrees celsius.</description>
</param>
@@ -4198,6 +4310,9 @@
<param name="steeringWheelAngle" type="VehicleDataResult" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="VehicleDataResult" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="VehicleDataResult" mandatory="false">
@@ -4240,6 +4355,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius.</description>
</param>
@@ -4279,6 +4397,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Boolean" mandatory="false">
@@ -4341,6 +4462,9 @@
<param name="instantFuelConsumption" type="VehicleDataResult" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="VehicleDataResult" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="VehicleDataResult" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4380,6 +4504,9 @@
<param name="steeringWheelAngle" type="VehicleDataResult" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="VehicleDataResult" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="VehicleDataResult" mandatory="false">
@@ -4422,6 +4549,9 @@
<param name="instantFuelConsumption" type="Boolean" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="Boolean" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Boolean" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4464,6 +4594,9 @@
<param name="steeringWheelAngle" type="Boolean" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Boolean" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="Boolean" mandatory="false">
@@ -4527,6 +4660,9 @@
<param name="instantFuelConsumption" type="Float" minvalue="0" maxvalue="25575" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="FuelRange" minsize="0" maxsize="100" array="true" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Float" minvalue="-40" maxvalue="100" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -4569,6 +4705,9 @@
<param name="steeringWheelAngle" type="Float" minvalue="-2000" maxvalue="2000" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Float" minvalue="0" maxvalue="100" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Data Items -->
<param name="eCallInfo" type="ECallInfo" mandatory="false">
@@ -5073,6 +5212,9 @@
If offset is set to 0, then length is the total length of the file to be downloaded
</description>
</param>
+ <param name="crc" type="Integer" minvalue="0" maxvalue="4294967295" mandatory="false">
+ <description> Additional CRC32 checksum to protect data integrity up to 512 Mbits . </description>
+ </param>
</function>
<function name="PutFile" functionID="PutFileID" messagetype="response">
@@ -5092,6 +5234,7 @@
<element name="GENERIC_ERROR"/>
<element name="REJECTED"/>
<element name="UNSUPPORTED_REQUEST"/>
+ <element name="CORRUPTED_DATA"/>
</param>
<param name="spaceAvailable" type="Integer" minvalue="0" maxvalue="2000000000" mandatory="true">
@@ -5245,6 +5388,9 @@
</description>
</param>
+ <param name="dayColorScheme" type="TemplateColorScheme" mandatory="false"/>
+
+ <param name="nightColorScheme" type="TemplateColorScheme" mandatory="false"/>
</function>
<function name="SetDisplayLayout" functionID="SetDisplayLayoutID" messagetype="response">
@@ -5745,6 +5891,9 @@
<param name="instantFuelConsumption" type="Float" minvalue="0" maxvalue="25575" mandatory="false">
<description>The instantaneous fuel consumption in microlitres</description>
</param>
+ <param name="fuelRange" type="FuelRange" minsize="0" maxsize="100" array="true" mandatory="false">
+ <description>The estimate range in KM the vehicle can travel based on fuel level and consumption</description>
+ </param>
<param name="externalTemperature" type="Float" minvalue="-40" maxvalue="100" mandatory="false">
<description>The external temperature in degrees celsius</description>
</param>
@@ -5787,6 +5936,9 @@
<param name="steeringWheelAngle" type="Float" minvalue="-2000" maxvalue="2000" mandatory="false">
<description>Current angle of the steering wheel (in deg)</description>
</param>
+ <param name="engineOilLife" type="Float" minvalue="0" maxvalue="100" mandatory="false">
+ <description>The estimated percentage of remaining oil life of the engine.</description>
+ </param>
<!-- Ford Specific Vehicle Data -->
<param name="eCallInfo" type="ECallInfo" mandatory="false">
diff --git a/src/components/policy/policy_external/include/policy/policy_table/enums.h b/src/components/policy/policy_external/include/policy/policy_table/enums.h
index 4f8ae5c98d..fa37cfe7a5 100644
--- a/src/components/policy/policy_external/include/policy/policy_table/enums.h
+++ b/src/components/policy/policy_external/include/policy/policy_table/enums.h
@@ -70,6 +70,7 @@ enum Parameter {
P_FUELLEVEL_STATE,
P_HEADLAMPSTATUS,
P_INSTANTFUELCONSUMPTION,
+ P_FUELRANGE,
P_ODOMETER,
P_TIREPRESSURE,
P_WIPERSTATUS,
@@ -80,6 +81,7 @@ enum Parameter {
P_PRNDL,
P_RPM,
P_STEERINGWHEELANGLE,
+ P_ENGINEOILLIFE,
P_MYKEY,
P_AIRBAGSTATUS,
P_BODYINFORMATION,
diff --git a/src/components/policy/policy_external/include/policy/policy_table_interface_ext.xml b/src/components/policy/policy_external/include/policy/policy_table_interface_ext.xml
index 91518f8f6e..8d5a7054f1 100644
--- a/src/components/policy/policy_external/include/policy/policy_table_interface_ext.xml
+++ b/src/components/policy/policy_external/include/policy/policy_table_interface_ext.xml
@@ -30,6 +30,7 @@
<element name="fuelLevel_State" />
<element name="headLampStatus" />
<element name="instantFuelConsumption" />
+ <element name="fuelRange" />
<element name="odometer" />
<element name="tirePressure" />
<element name="wiperStatus" />
@@ -40,6 +41,7 @@
<element name="prndl" />
<element name="rpm" />
<element name="steeringWheelAngle" />
+ <element name="engineOilLife" />
<element name="myKey" />
<element name="airbagStatus" />
<element name="bodyInformation" />
diff --git a/src/components/policy/policy_external/src/policy_manager_impl.cc b/src/components/policy/policy_external/src/policy_manager_impl.cc
index cc5e64d254..433a7a6bca 100644
--- a/src/components/policy/policy_external/src/policy_manager_impl.cc
+++ b/src/components/policy/policy_external/src/policy_manager_impl.cc
@@ -313,7 +313,10 @@ bool PolicyManagerImpl::LoadPT(const std::string& file,
utils::SharedPtr<policy_table::Table> policy_table_snapshot =
cache_->GenerateSnapshot();
if (!policy_table_snapshot) {
- LOG4CXX_ERROR(logger_, "Failed to create snapshot of policy table");
+ LOG4CXX_ERROR(
+ logger_,
+ "Failed to create snapshot of policy table, trying another exchange");
+ ForcePTExchange();
return false;
}
@@ -327,7 +330,10 @@ bool PolicyManagerImpl::LoadPT(const std::string& file,
// Replace current data with updated
if (!cache_->ApplyUpdate(*pt_update)) {
- LOG4CXX_WARN(logger_, "Unsuccessful save of updated policy table.");
+ LOG4CXX_WARN(
+ logger_,
+ "Unsuccessful save of updated policy table, trying another exchange");
+ ForcePTExchange();
return false;
}
@@ -588,8 +594,7 @@ void PolicyManagerImpl::CheckPermissions(const PTString& app_id,
policy_table::FunctionalGroupings functional_groupings;
cache_->GetFunctionalGroupings(functional_groupings);
- policy_table::Strings app_groups =
- GetGroupsNames(app_group_permissions);
+ policy_table::Strings app_groups = GetGroupsNames(app_group_permissions);
// Undefined groups (without user consent) disallowed by default, since
// OnPermissionsChange notification has no "undefined" section
@@ -621,8 +626,7 @@ void PolicyManagerImpl::CheckPermissions(const PTString& app_id,
}
const bool known_rpc = rpc_permissions.end() != rpc_permissions.find(rpc);
- LOG4CXX_DEBUG(logger_, "Is known rpc " <<
- (known_rpc ? "true" : "false"));
+ LOG4CXX_DEBUG(logger_, "Is known rpc " << (known_rpc ? "true" : "false"));
if (!known_rpc) {
// RPC not found in list == disallowed by backend
result.hmi_level_permitted = kRpcDisallowed;
@@ -644,7 +648,9 @@ void PolicyManagerImpl::CheckPermissions(const PTString& app_id,
rpc_permissions[rpc].hmi_permissions[kUserDisallowedKey].find(
hmi_level)) {
// RPC found in allowed == allowed by backend, but disallowed by user
- LOG4CXX_DEBUG(logger_, "RPC found in allowed == allowed by backend, but disallowed by user");
+ LOG4CXX_DEBUG(
+ logger_,
+ "RPC found in allowed == allowed by backend, but disallowed by user");
result.hmi_level_permitted = kRpcUserDisallowed;
} else {
LOG4CXX_DEBUG(logger_,
@@ -984,7 +990,6 @@ void PolicyManagerImpl::SetUserConsentForApp(
const PermissionConsent& permissions, const NotificationMode mode) {
LOG4CXX_AUTO_TRACE(logger_);
-
cache_->ResetCalculatedPermissions();
PermissionConsent verified_permissions =
EnsureCorrectPermissionConsent(permissions);
@@ -1569,8 +1574,7 @@ void PolicyManagerImpl::OnUpdateStarted() {
uint32_t update_timeout = TimeoutExchangeMSec();
LOG4CXX_DEBUG(logger_,
"Update timeout will be set to (milisec): " << update_timeout);
- send_on_update_sent_out_ =
- !wrong_ptu_update_received_ && !update_status_manager_.IsUpdatePending();
+ send_on_update_sent_out_ = !update_status_manager_.IsUpdatePending();
if (send_on_update_sent_out_) {
update_status_manager_.OnUpdateSentOut(update_timeout);
diff --git a/src/components/policy/policy_external/src/policy_table/enums.cc b/src/components/policy/policy_external/src/policy_table/enums.cc
index 168ff86b27..beea68a276 100644
--- a/src/components/policy/policy_external/src/policy_table/enums.cc
+++ b/src/components/policy/policy_external/src/policy_table/enums.cc
@@ -126,6 +126,8 @@ bool IsValidEnum(Parameter val) {
return true;
case P_INSTANTFUELCONSUMPTION:
return true;
+ case P_FUELRANGE:
+ return true;
case P_ODOMETER:
return true;
case P_TIREPRESSURE:
@@ -146,6 +148,8 @@ bool IsValidEnum(Parameter val) {
return true;
case P_STEERINGWHEELANGLE:
return true;
+ case P_ENGINEOILLIFE:
+ return true;
case P_MYKEY:
return true;
case P_AIRBAGSTATUS:
@@ -215,6 +219,8 @@ const char* EnumToJsonString(Parameter val) {
return "headLampStatus";
case P_INSTANTFUELCONSUMPTION:
return "instantFuelConsumption";
+ case P_FUELRANGE:
+ return "fuelRange";
case P_ODOMETER:
return "odometer";
case P_TIREPRESSURE:
@@ -235,6 +241,8 @@ const char* EnumToJsonString(Parameter val) {
return "rpm";
case P_STEERINGWHEELANGLE:
return "steeringWheelAngle";
+ case P_ENGINEOILLIFE:
+ return "engineOilLife";
case P_MYKEY:
return "myKey";
case P_AIRBAGSTATUS:
@@ -311,6 +319,9 @@ bool EnumFromJsonString(const std::string& literal, Parameter* result) {
} else if ("instantFuelConsumption" == literal) {
*result = P_INSTANTFUELCONSUMPTION;
return true;
+ } else if ("fuelRange" == literal) {
+ *result = P_FUELRANGE;
+ return true;
} else if ("odometer" == literal) {
*result = P_ODOMETER;
return true;
@@ -341,6 +352,9 @@ bool EnumFromJsonString(const std::string& literal, Parameter* result) {
} else if ("steeringWheelAngle" == literal) {
*result = P_STEERINGWHEELANGLE;
return true;
+ } else if ("engineOilLife" == literal) {
+ *result = P_ENGINEOILLIFE;
+ return true;
} else if ("myKey" == literal) {
*result = P_MYKEY;
return true;
diff --git a/src/components/policy/policy_external/src/sql_pt_representation.cc b/src/components/policy/policy_external/src/sql_pt_representation.cc
index 6cc68cb102..4315d99b3a 100644
--- a/src/components/policy/policy_external/src/sql_pt_representation.cc
+++ b/src/components/policy/policy_external/src/sql_pt_representation.cc
@@ -559,10 +559,10 @@ void SQLPTRepresentation::GatherModuleConfig(
LOG4CXX_WARN(logger_, "Incorrect select statement for endpoints");
} else {
while (endpoints.Next()) {
- std::stringstream stream;
- stream << "0x0" << endpoints.GetInteger(1);
- config->endpoints[stream.str()][endpoints.GetString(2)].push_back(
- endpoints.GetString(0));
+ const std::string& url = endpoints.GetString(0);
+ const std::string& service = endpoints.GetString(1);
+ const std::string& app_id = endpoints.GetString(2);
+ config->endpoints[service][app_id].push_back(url);
}
}
diff --git a/src/components/policy/policy_external/test/json/PTU.json b/src/components/policy/policy_external/test/json/PTU.json
index 7316c7539d..c231340f44 100644
--- a/src/components/policy/policy_external/test/json/PTU.json
+++ b/src/components/policy/policy_external/test/json/PTU.json
@@ -15,7 +15,7 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -472,12 +472,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -493,12 +495,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -514,12 +518,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -534,12 +540,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/PTU2.json b/src/components/policy/policy_external/test/json/PTU2.json
index c1a6bccb68..4970c40e60 100644
--- a/src/components/policy/policy_external/test/json/PTU2.json
+++ b/src/components/policy/policy_external/test/json/PTU2.json
@@ -15,7 +15,7 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -472,12 +472,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -493,12 +495,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -514,12 +518,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -534,12 +540,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/PTU3.json b/src/components/policy/policy_external/test/json/PTU3.json
index 56939a789a..98037cf594 100644
--- a/src/components/policy/policy_external/test/json/PTU3.json
+++ b/src/components/policy/policy_external/test/json/PTU3.json
@@ -15,7 +15,7 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -472,12 +472,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -493,12 +495,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -514,12 +518,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -534,12 +540,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/PTU_default_app.json b/src/components/policy/policy_external/test/json/PTU_default_app.json
index 833d46316a..b036d96b50 100644
--- a/src/components/policy/policy_external/test/json/PTU_default_app.json
+++ b/src/components/policy/policy_external/test/json/PTU_default_app.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -295,7 +295,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_default_app_app_invalid_values_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_default_app_app_invalid_values_RequestType_array.json
index 1e5b1c46a4..49ed46f16c 100644
--- a/src/components/policy/policy_external/test/json/PTU_default_app_app_invalid_values_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_default_app_app_invalid_values_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -293,7 +293,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_default_app_empty_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_default_app_empty_RequestType_array.json
index 76365ee4bb..66af76309a 100644
--- a/src/components/policy/policy_external/test/json/PTU_default_app_empty_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_default_app_empty_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -290,7 +290,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_default_app_omitted_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_default_app_omitted_RequestType_array.json
index b380fa2de5..0a7c059097 100644
--- a/src/components/policy/policy_external/test/json/PTU_default_app_omitted_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_default_app_omitted_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -289,7 +289,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_default_app_one_invalid_value_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_default_app_one_invalid_value_RequestType_array.json
index b8793b6cdc..08f12a21c8 100644
--- a/src/components/policy/policy_external/test/json/PTU_default_app_one_invalid_value_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_default_app_one_invalid_value_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -296,7 +296,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app.json b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app.json
index 833d46316a..b036d96b50 100644
--- a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app.json
+++ b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -295,7 +295,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_empty_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_empty_RequestType_array.json
index 8a183b45d5..6aeb637503 100644
--- a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_empty_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_empty_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -290,7 +290,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_invalid_values_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_invalid_values_RequestType_array.json
index 6ffc42c3e4..8c68aaeb89 100644
--- a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_invalid_values_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_invalid_values_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -291,7 +291,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_omitted_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_omitted_RequestType_array.json
index 24d0871d18..0ae0761f27 100644
--- a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_omitted_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_omitted_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -283,7 +283,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_one_invalid_value_RequestType_array.json b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_one_invalid_value_RequestType_array.json
index b674913268..6b170089fe 100644
--- a/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_one_invalid_value_RequestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_pre_data_consent_app_one_invalid_value_RequestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -296,7 +296,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_with_empty_requestType_array.json b/src/components/policy/policy_external/test/json/PTU_with_empty_requestType_array.json
index 7e0836a805..f232d8fec7 100644
--- a/src/components/policy/policy_external/test/json/PTU_with_empty_requestType_array.json
+++ b/src/components/policy/policy_external/test/json/PTU_with_empty_requestType_array.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1592,12 +1592,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1607,12 +1609,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1622,12 +1626,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1636,12 +1642,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1703,7 +1711,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_with_invalid_requestType_between_correct.json b/src/components/policy/policy_external/test/json/PTU_with_invalid_requestType_between_correct.json
index a056c3ce9c..942c862d4f 100644
--- a/src/components/policy/policy_external/test/json/PTU_with_invalid_requestType_between_correct.json
+++ b/src/components/policy/policy_external/test/json/PTU_with_invalid_requestType_between_correct.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1595,12 +1595,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1610,12 +1612,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1625,12 +1629,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1639,12 +1645,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1706,7 +1714,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_with_one_invalid_requestType.json b/src/components/policy/policy_external/test/json/PTU_with_one_invalid_requestType.json
index c7e0a727fe..c72fdbe6cb 100644
--- a/src/components/policy/policy_external/test/json/PTU_with_one_invalid_requestType.json
+++ b/src/components/policy/policy_external/test/json/PTU_with_one_invalid_requestType.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1592,12 +1592,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1607,12 +1609,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1622,12 +1626,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1636,12 +1642,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1703,7 +1711,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/PTU_without_requestType_field.json b/src/components/policy/policy_external/test/json/PTU_without_requestType_field.json
index a96ef74bd1..b783ac0cc2 100644
--- a/src/components/policy/policy_external/test/json/PTU_without_requestType_field.json
+++ b/src/components/policy/policy_external/test/json/PTU_without_requestType_field.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1591,12 +1591,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1606,12 +1608,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1621,12 +1625,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1635,12 +1641,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1702,7 +1710,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_reqestType_between_valid.json b/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_reqestType_between_valid.json
index 4c1bf19005..fdf730917f 100644
--- a/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_reqestType_between_valid.json
+++ b/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_reqestType_between_valid.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_requestType.json b/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_requestType.json
index 02801cc976..82b6f762ca 100644
--- a/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_requestType.json
+++ b/src/components/policy/policy_external/test/json/preloadedPT_with_invalid_default_requestType.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_external/test/json/preloadedPT_with_several_invalid_default_requestTypes.json b/src/components/policy/policy_external/test/json/preloadedPT_with_several_invalid_default_requestTypes.json
index a9abeea5a2..713d057f1a 100644
--- a/src/components/policy/policy_external/test/json/preloadedPT_with_several_invalid_default_requestTypes.json
+++ b/src/components/policy/policy_external/test/json/preloadedPT_with_several_invalid_default_requestTypes.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_external/test/json/ptu2_requestType.json b/src/components/policy/policy_external/test/json/ptu2_requestType.json
index 899e58a68d..4765da0771 100644
--- a/src/components/policy/policy_external/test/json/ptu2_requestType.json
+++ b/src/components/policy/policy_external/test/json/ptu2_requestType.json
@@ -16,12 +16,12 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
},
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
}
},
@@ -484,12 +484,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -505,12 +507,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -526,12 +530,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -546,12 +552,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2594,7 +2602,7 @@
"PROPRIETARY"
]
},
- "584421907": {
+ "123454321": {
"keep_context" : false,
"steal_focus" : false,
"priority"
diff --git a/src/components/policy/policy_external/test/json/ptu_requestType.json b/src/components/policy/policy_external/test/json/ptu_requestType.json
index a1f085ac74..5e34c00a81 100644
--- a/src/components/policy/policy_external/test/json/ptu_requestType.json
+++ b/src/components/policy/policy_external/test/json/ptu_requestType.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
},
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2553,7 +2561,7 @@
}
},
"app_policies": {
- "584421907": {
+ "123454321": {
"keep_context": false,
"steal_focus": false,
"priority": "NONE",
diff --git a/src/components/policy/policy_external/test/json/sdl_preloaded_pt.json b/src/components/policy/policy_external/test/json/sdl_preloaded_pt.json
index d6f34c12fc..c5386f612e 100644
--- a/src/components/policy/policy_external/test/json/sdl_preloaded_pt.json
+++ b/src/components/policy/policy_external/test/json/sdl_preloaded_pt.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_external/test/json/sdl_preloaded_pt1.json b/src/components/policy/policy_external/test/json/sdl_preloaded_pt1.json
index 78c5f873d9..5974b22b8e 100644
--- a/src/components/policy/policy_external/test/json/sdl_preloaded_pt1.json
+++ b/src/components/policy/policy_external/test/json/sdl_preloaded_pt1.json
@@ -2308,12 +2308,14 @@
[
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -2327,12 +2329,14 @@
[
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -2346,12 +2350,14 @@
[
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2364,12 +2370,14 @@
[
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2385,11 +2393,11 @@
{
"0x04" :
{
- "default" : [ "http://ivsu.software.ford.com/api/getsoftwareupdates" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/softwareUpdate" ]
},
"0x07" :
{
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 20,
diff --git a/src/components/policy/policy_external/test/json/sdl_preloaded_pt_send_location.json b/src/components/policy/policy_external/test/json/sdl_preloaded_pt_send_location.json
index 49f9a1da3a..8da6906e8b 100644
--- a/src/components/policy/policy_external/test/json/sdl_preloaded_pt_send_location.json
+++ b/src/components/policy/policy_external/test/json/sdl_preloaded_pt_send_location.json
@@ -16,12 +16,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -484,12 +484,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -505,12 +507,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -526,12 +530,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -546,12 +552,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_pt_first_update.json b/src/components/policy/policy_external/test/json/sdl_pt_first_update.json
index e6817da0d3..f8be46d2b5 100644
--- a/src/components/policy/policy_external/test/json/sdl_pt_first_update.json
+++ b/src/components/policy/policy_external/test/json/sdl_pt_first_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1609,12 +1609,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1624,12 +1626,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1639,12 +1643,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1653,12 +1659,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1720,7 +1728,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/sdl_pt_second_update.json b/src/components/policy/policy_external/test/json/sdl_pt_second_update.json
index d5f5f480f3..fe7b036f94 100644
--- a/src/components/policy/policy_external/test/json/sdl_pt_second_update.json
+++ b/src/components/policy/policy_external/test/json/sdl_pt_second_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1609,12 +1609,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1624,12 +1626,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1639,12 +1643,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1653,12 +1659,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1720,7 +1728,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/sdl_pt_update.json b/src/components/policy/policy_external/test/json/sdl_pt_update.json
index 5047d832dd..c79fd26873 100644
--- a/src/components/policy/policy_external/test/json/sdl_pt_update.json
+++ b/src/components/policy/policy_external/test/json/sdl_pt_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1593,12 +1593,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1608,12 +1610,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1623,12 +1627,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1637,12 +1643,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1704,7 +1712,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_have_params.json b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_have_params.json
index 18b0a09040..234f57f2db 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_have_params.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_have_params.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1.json b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1.json
index 3530c01388..d309d58674 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1_omitted_in2.json b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1_omitted_in2.json
index e169aea24a..be38e7d706 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1_omitted_in2.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_2_groups_no_params_in1_omitted_in2.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location.json b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location.json
index df45a0be61..8686f20f0e 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_all_params.json b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_all_params.json
index c471d6ec97..b9b693ed5b 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_all_params.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_all_params.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_no_params.json b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_no_params.json
index 29781d211c..8bbf7ea421 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_no_params.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_no_params.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_some_params.json b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_some_params.json
index 91be06a561..146adaf7a7 100644
--- a/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_some_params.json
+++ b/src/components/policy/policy_external/test/json/sdl_update_pt_send_location_some_params.json
@@ -15,12 +15,12 @@
"endpoints": {
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
},
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
}
},
@@ -483,12 +483,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -504,12 +506,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -525,12 +529,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -545,12 +551,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
diff --git a/src/components/policy/policy_external/test/json/valid_sdl_pt_update.json b/src/components/policy/policy_external/test/json/valid_sdl_pt_update.json
index 56c728f104..bc8d95302c 100644
--- a/src/components/policy/policy_external/test/json/valid_sdl_pt_update.json
+++ b/src/components/policy/policy_external/test/json/valid_sdl_pt_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1585,12 +1585,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1600,12 +1602,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1615,12 +1619,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1629,12 +1635,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1696,7 +1704,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_external/test/policy_manager_impl_ptu_test.cc b/src/components/policy/policy_external/test/policy_manager_impl_ptu_test.cc
index da0cd913b6..947bb5d3ad 100644
--- a/src/components/policy/policy_external/test/policy_manager_impl_ptu_test.cc
+++ b/src/components/policy/policy_external/test/policy_manager_impl_ptu_test.cc
@@ -574,8 +574,7 @@ TEST_F(PolicyManagerImplTest2, GetUpdateUrl) {
CreateLocalPT(preloaded_pt_filename_);
GetPTU(kValidSdlPtUpdateJson);
// Check expectations
- const std::string update_url(
- "http://policies.telematics.ford.com/api/policies");
+ const std::string update_url("http://x.x.x.x:3000/api/1/policies");
EXPECT_EQ(update_url, policy_manager_->GetUpdateUrl(7));
EXPECT_EQ("", policy_manager_->GetUpdateUrl(4));
}
diff --git a/src/components/policy/policy_external/test/policy_manager_impl_test_base.cc b/src/components/policy/policy_external/test/policy_manager_impl_test_base.cc
index 0608799535..48e86d24b7 100644
--- a/src/components/policy/policy_external/test/policy_manager_impl_test_base.cc
+++ b/src/components/policy/policy_external/test/policy_manager_impl_test_base.cc
@@ -238,8 +238,8 @@ void PolicyManagerImplTest::TearDown() {
// PolicyManagerImplTest2 class methods
PolicyManagerImplTest2::PolicyManagerImplTest2()
: app_id_1_("123456789")
- , app_id_2_("1766825573")
- , app_id_3_("584421907")
+ , app_id_2_("1010101010")
+ , app_id_3_("123454321")
, device_id_1_("XXX123456789ZZZ")
, device_id_2_("08-00-27-CE-76-FE")
, application_id_("1234")
@@ -629,7 +629,7 @@ PolicyManagerImplTest_RequestTypes::PolicyManagerImplTest_RequestTypes()
"PTU_pre_data_consent_app_one_invalid_value_RequestType_"
"array."
"json"}
- , kAppId("1766825573")
+ , kAppId("1010101010")
, kDefaultAppId(policy::kDefaultId)
, app_storage_folder_("storage3")
, preloaded_pt_filename_(kSdlPreloadedPtJson) {}
diff --git a/src/components/policy/policy_regular/include/policy/policy_table/enums.h b/src/components/policy/policy_regular/include/policy/policy_table/enums.h
index 4eb35d2aa4..bd3319dba6 100644
--- a/src/components/policy/policy_regular/include/policy/policy_table/enums.h
+++ b/src/components/policy/policy_regular/include/policy/policy_table/enums.h
@@ -70,6 +70,7 @@ enum Parameter {
P_FUELLEVEL_STATE,
P_HEADLAMPSTATUS,
P_INSTANTFUELCONSUMPTION,
+ P_FUELRANGE,
P_ODOMETER,
P_TIREPRESSURE,
P_WIPERSTATUS,
@@ -80,6 +81,7 @@ enum Parameter {
P_PRNDL,
P_RPM,
P_STEERINGWHEELANGLE,
+ P_ENGINEOILLIFE,
P_MYKEY,
P_AIRBAGSTATUS,
P_BODYINFORMATION,
diff --git a/src/components/policy/policy_regular/policy_table_interface_ext.xml b/src/components/policy/policy_regular/policy_table_interface_ext.xml
index 468eec2b0b..4f87a9e254 100644
--- a/src/components/policy/policy_regular/policy_table_interface_ext.xml
+++ b/src/components/policy/policy_regular/policy_table_interface_ext.xml
@@ -1,3 +1,4 @@
+
<?xml version="1.0" standalone="no"?>
<?xml-stylesheet type="text/xml" href="protocol2html.xsl"?>
@@ -30,6 +31,7 @@
<element name="fuelLevel_State" />
<element name="headLampStatus" />
<element name="instantFuelConsumption" />
+ <element name="fuelRange" />
<element name="odometer" />
<element name="tirePressure" />
<element name="wiperStatus" />
@@ -40,6 +42,7 @@
<element name="prndl" />
<element name="rpm" />
<element name="steeringWheelAngle" />
+ <element name="engineOilLife" />
<element name="myKey" />
<element name="airbagStatus" />
<element name="bodyInformation" />
diff --git a/src/components/policy/policy_regular/src/policy_manager_impl.cc b/src/components/policy/policy_regular/src/policy_manager_impl.cc
index 4feae19a2a..5226a15aeb 100644
--- a/src/components/policy/policy_regular/src/policy_manager_impl.cc
+++ b/src/components/policy/policy_regular/src/policy_manager_impl.cc
@@ -196,7 +196,10 @@ bool PolicyManagerImpl::LoadPT(const std::string& file,
utils::SharedPtr<policy_table::Table> policy_table_snapshot =
cache_->GenerateSnapshot();
if (!policy_table_snapshot) {
- LOG4CXX_ERROR(logger_, "Failed to create snapshot of policy table");
+ LOG4CXX_ERROR(
+ logger_,
+ "Failed to create snapshot of policy table, trying another exchange");
+ ForcePTExchange();
return false;
}
@@ -209,7 +212,10 @@ bool PolicyManagerImpl::LoadPT(const std::string& file,
// Replace current data with updated
if (!cache_->ApplyUpdate(*pt_update)) {
- LOG4CXX_WARN(logger_, "Unsuccessful save of updated policy table.");
+ LOG4CXX_WARN(
+ logger_,
+ "Unsuccessful save of updated policy table, trying another exchange");
+ ForcePTExchange();
return false;
}
diff --git a/src/components/policy/policy_regular/src/policy_table/enums.cc b/src/components/policy/policy_regular/src/policy_table/enums.cc
index 34d12420d8..2145f06a4b 100644
--- a/src/components/policy/policy_regular/src/policy_table/enums.cc
+++ b/src/components/policy/policy_regular/src/policy_table/enums.cc
@@ -127,6 +127,8 @@ bool IsValidEnum(Parameter val) {
return true;
case P_INSTANTFUELCONSUMPTION:
return true;
+ case P_FUELRANGE:
+ return true;
case P_ODOMETER:
return true;
case P_TIREPRESSURE:
@@ -147,6 +149,8 @@ bool IsValidEnum(Parameter val) {
return true;
case P_STEERINGWHEELANGLE:
return true;
+ case P_ENGINEOILLIFE:
+ return true;
case P_MYKEY:
return true;
case P_AIRBAGSTATUS:
@@ -185,6 +189,8 @@ const char* EnumToJsonString(Parameter val) {
return "headLampStatus";
case P_INSTANTFUELCONSUMPTION:
return "instantFuelConsumption";
+ case P_FUELRANGE:
+ return "fuelRange";
case P_ODOMETER:
return "odometer";
case P_TIREPRESSURE:
@@ -205,6 +211,8 @@ const char* EnumToJsonString(Parameter val) {
return "rpm";
case P_STEERINGWHEELANGLE:
return "steeringWheelAngle";
+ case P_ENGINEOILLIFE:
+ return "engineOilLife";
case P_MYKEY:
return "myKey";
case P_AIRBAGSTATUS:
@@ -251,6 +259,9 @@ bool EnumFromJsonString(const std::string& literal, Parameter* result) {
} else if ("instantFuelConsumption" == literal) {
*result = P_INSTANTFUELCONSUMPTION;
return true;
+ } else if ("fuelRange" == literal) {
+ *result = P_FUELRANGE;
+ return true;
} else if ("odometer" == literal) {
*result = P_ODOMETER;
return true;
@@ -281,6 +292,9 @@ bool EnumFromJsonString(const std::string& literal, Parameter* result) {
} else if ("steeringWheelAngle" == literal) {
*result = P_STEERINGWHEELANGLE;
return true;
+ } else if ("engineOilLife" == literal) {
+ *result = P_ENGINEOILLIFE;
+ return true;
} else if ("myKey" == literal) {
*result = P_MYKEY;
return true;
diff --git a/src/components/policy/policy_regular/test/PTU.json b/src/components/policy/policy_regular/test/PTU.json
index 6d663e9a0c..7d6837f94e 100644
--- a/src/components/policy/policy_regular/test/PTU.json
+++ b/src/components/policy/policy_regular/test/PTU.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_regular/test/PTU2.json b/src/components/policy/policy_regular/test/PTU2.json
index 4062e94516..7a5c29410c 100644
--- a/src/components/policy/policy_regular/test/PTU2.json
+++ b/src/components/policy/policy_regular/test/PTU2.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_regular/test/PTU3.json b/src/components/policy/policy_regular/test/PTU3.json
index 78596189da..1b3340ec8c 100644
--- a/src/components/policy/policy_regular/test/PTU3.json
+++ b/src/components/policy/policy_regular/test/PTU3.json
@@ -83,7 +83,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_regular/test/PTU4.json b/src/components/policy/policy_regular/test/PTU4.json
index ab4c2f8927..9aa04dd8ba 100644
--- a/src/components/policy/policy_regular/test/PTU4.json
+++ b/src/components/policy/policy_regular/test/PTU4.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_regular/test/policy_manager_impl_test.cc b/src/components/policy/policy_regular/test/policy_manager_impl_test.cc
index f76e856cd0..5fd0a48f7c 100644
--- a/src/components/policy/policy_regular/test/policy_manager_impl_test.cc
+++ b/src/components/policy/policy_regular/test/policy_manager_impl_test.cc
@@ -181,7 +181,7 @@ class PolicyManagerImplTest2 : public ::testing::Test {
public:
PolicyManagerImplTest2()
: app_id1("123456789")
- , app_id2("1766825573")
+ , app_id2("1010101010")
, dev_id1("XXX123456789ZZZ")
, dev_id2("08-00-27-CE-76-FE")
, PTU_request_types(Json::arrayValue) {}
diff --git a/src/components/policy/policy_regular/test/ptu2_requestType.json b/src/components/policy/policy_regular/test/ptu2_requestType.json
index 50364397fd..e127b2fad6 100644
--- a/src/components/policy/policy_regular/test/ptu2_requestType.json
+++ b/src/components/policy/policy_regular/test/ptu2_requestType.json
@@ -17,12 +17,12 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
},
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
}
},
@@ -485,12 +485,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -506,12 +508,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -527,12 +531,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -547,12 +553,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2595,7 +2603,7 @@
"PROPRIETARY"
]
},
- "584421907": {
+ "123454321": {
"keep_context": false,
"steal_focus": false,
"priority": "NONE",
diff --git a/src/components/policy/policy_regular/test/ptu_requestType.json b/src/components/policy/policy_regular/test/ptu_requestType.json
index 44bd8356fe..bd6a86dac3 100644
--- a/src/components/policy/policy_regular/test/ptu_requestType.json
+++ b/src/components/policy/policy_regular/test/ptu_requestType.json
@@ -17,12 +17,12 @@
"endpoints": {
"0x07": {
"default": [
- "http://policies.telematics.ford.com/api/policies"
+ "http://x.x.x.x:3000/api/1/policies"
]
},
"0x04": {
"default": [
- "http://ivsu.software.ford.com/api/getsoftwareupdates"
+ "http://x.x.x.x:3000/api/1/softwareUpdate"
]
}
},
@@ -485,12 +485,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -506,12 +508,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -527,12 +531,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -547,12 +553,14 @@
"parameters": [
"bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -2590,7 +2598,7 @@
"PROPRIETARY"
]
},
- "584421907": {
+ "123454321": {
"keep_context": false,
"steal_focus": false,
"priority": "NONE",
diff --git a/src/components/policy/policy_regular/test/sdl_preloaded_pt.json b/src/components/policy/policy_regular/test/sdl_preloaded_pt.json
index d6f34c12fc..c5386f612e 100644
--- a/src/components/policy/policy_regular/test/sdl_preloaded_pt.json
+++ b/src/components/policy/policy_regular/test/sdl_preloaded_pt.json
@@ -14,7 +14,7 @@
625],
"endpoints": {
"0x07": {
- "default": ["http://policies.telematics.ford.com/api/policies"]
+ "default": ["http://x.x.x.x:3000/api/1/policies"]
}
},
"notifications_per_minute_by_priority": {
@@ -349,12 +349,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -366,12 +368,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -383,12 +387,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
@@ -399,12 +405,14 @@
"LIMITED"],
"parameters": ["bodyInformation",
"deviceStatus",
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"]
diff --git a/src/components/policy/policy_regular/test/sdl_pt_first_update.json b/src/components/policy/policy_regular/test/sdl_pt_first_update.json
index e6817da0d3..f8be46d2b5 100644
--- a/src/components/policy/policy_regular/test/sdl_pt_first_update.json
+++ b/src/components/policy/policy_regular/test/sdl_pt_first_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1609,12 +1609,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1624,12 +1626,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1639,12 +1643,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1653,12 +1659,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1720,7 +1728,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_regular/test/sdl_pt_second_update.json b/src/components/policy/policy_regular/test/sdl_pt_second_update.json
index d5f5f480f3..fe7b036f94 100644
--- a/src/components/policy/policy_regular/test/sdl_pt_second_update.json
+++ b/src/components/policy/policy_regular/test/sdl_pt_second_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1609,12 +1609,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1624,12 +1626,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1639,12 +1643,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1653,12 +1659,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1720,7 +1728,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_regular/test/sdl_pt_update.json b/src/components/policy/policy_regular/test/sdl_pt_update.json
index a332f92382..e013243760 100644
--- a/src/components/policy/policy_regular/test/sdl_pt_update.json
+++ b/src/components/policy/policy_regular/test/sdl_pt_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1587,12 +1587,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1602,12 +1604,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1617,12 +1621,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1631,12 +1637,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1698,7 +1706,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/policy/policy_regular/test/valid_sdl_pt_update.json b/src/components/policy/policy_regular/test/valid_sdl_pt_update.json
index 56c728f104..bc8d95302c 100644
--- a/src/components/policy/policy_regular/test/valid_sdl_pt_update.json
+++ b/src/components/policy/policy_regular/test/valid_sdl_pt_update.json
@@ -1,7 +1,7 @@
{
"policy_table" : {
"app_policies" : {
- "1766825573" : {
+ "1010101010" : {
"AppHMIType" : [ "MEDIA" ],
"certificate" : "akdjfhaliuygrglurng",
"default_hmi" : "BACKGROUND",
@@ -1585,12 +1585,14 @@
"GetVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1600,12 +1602,14 @@
"OnVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"vin",
@@ -1615,12 +1619,14 @@
"SubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1629,12 +1635,14 @@
"UnsubscribeVehicleData" : {
"hmi_levels" : [ "BACKGROUND", "FULL", "LIMITED" ],
"parameters" : [
+ "engineOilLife",
"engineTorque",
"externalTemperature",
"fuelLevel",
"fuelLevel_State",
"headLampStatus",
"instantFuelConsumption",
+ "fuelRange",
"odometer",
"tirePressure",
"wiperStatus"
@@ -1696,7 +1704,7 @@
},
"endpoints" : {
"0x07" : {
- "default" : [ "http://policies.telematics.ford.com/api/policies" ]
+ "default" : [ "http://x.x.x.x:3000/api/1/policies" ]
}
},
"exchange_after_x_days" : 30,
diff --git a/src/components/remote_control/test/include/mock_application.h b/src/components/remote_control/test/include/mock_application.h
index a46b48673d..ef7c1d63a7 100644
--- a/src/components/remote_control/test/include/mock_application.h
+++ b/src/components/remote_control/test/include/mock_application.h
@@ -216,6 +216,9 @@ class MockApplication : public ::application_manager::Application {
MOCK_CONST_METHOD0(keyboard_props, const smart_objects::SmartObject*());
MOCK_CONST_METHOD0(menu_title, const smart_objects::SmartObject*());
MOCK_CONST_METHOD0(menu_icon, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(day_color_scheme, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(night_color_scheme, const smart_objects::SmartObject*());
+ MOCK_CONST_METHOD0(display_layout, const std::string&());
MOCK_METHOD1(load_global_properties,
void(const smart_objects::SmartObject& so));
MOCK_METHOD1(set_help_prompt,
@@ -239,6 +242,11 @@ class MockApplication : public ::application_manager::Application {
void(const smart_objects::SmartObject& menu_title));
MOCK_METHOD1(set_menu_icon,
void(const smart_objects::SmartObject& menu_icon));
+ MOCK_METHOD1(set_day_color_scheme,
+ void(const smart_objects::SmartObject& color_scheme));
+ MOCK_METHOD1(set_night_color_scheme,
+ void(const smart_objects::SmartObject& color_scheme));
+ MOCK_METHOD1(set_display_layout, void(const std::string& layout));
MOCK_CONST_METHOD0(audio_stream_retry_number, uint32_t());
MOCK_METHOD1(set_audio_stream_retry_number,
void(const uint32_t& audio_stream_retry_number));
diff --git a/src/components/security_manager/docs/FORD.OpenSDL.SDD.Security.dox b/src/components/security_manager/docs/SDL.SDD.Security.dox
index 42da2364d3..ba35bc116e 100644
--- a/src/components/security_manager/docs/FORD.OpenSDL.SDD.Security.dox
+++ b/src/components/security_manager/docs/SDL.SDD.Security.dox
@@ -32,12 +32,12 @@ deployment concepts, to accomplish their respective tasks without reliance on th
\anchor security_manager_rationale
## 1.1 Rationale
Security Manager implements SDL Architectural Solution according to:
-- https://smartdevicelink.com/en/guides/core/software-architecture-document/components-view/#security-manager
+- https://smartdevicelink.com/en/docs/sdl-core/master/software-architecture-document/components-view/#security-manager
\anchor security_manager_scope
## 1.2 Scope
Security Manager component extracted as a separate module for
-Ford channel data protection.
+SDL channel data protection.
This components is used to:
- Provide security communications
- Protect income and outcome business layer data from interception
@@ -100,30 +100,30 @@ protocol layer response on handshake procedure finish.
\anchor security_manager_class_structure
### 2.2 Class Structure
-The following UML class digram shows the component structure.
-![Security Manager class diagram](sm_class_digram.png)
-For more information about class digram follow:
+The following UML class diagram shows the component structure.
+![Security Manager class diagram](sm_class_diagram.png)
+For more information about class diagram follow:
- http://www.uml-diagrams.org/class-diagrams-overview.htqml
- https://sourcemaking.com/uml/modeling-it-systems/structural-view/class-diagram
\anchor security_manager_sequence_diagram
### 2.3 Sequence diagram
-The following UML sequence digram shows the component dynamic behavior.
-For more information about sequence digram follow:
+The following UML sequence diagram shows the component dynamic behavior.
+For more information about sequence diagram follow:
- http://www.uml-diagrams.org/sequence-diagrams.html
- https://sourcemaking.com/uml/modeling-it-systems/external-view/use-case-sequence-diagram
Security first initialization on session:
-![Start encryption](sm_sequence_digram_init.png)
+![Start encryption](sm_sequence_diagram_init.png)
Security initialization for service on session with already initialized security:
-![Initialization](sm_sequence_digram_verify.png)
+![Initialization](sm_sequence_diagram_verify.png)
Decryption procedure:
-![Decryption](sm_sequence_digram_decryption.png)
+![Decryption](sm_sequence_diagram_decryption.png)
Encryption procedure:
-![Encryption](sm_sequence_digram_encryption.png)
+![Encryption](sm_sequence_diagram_encryption.png)
\anchor security_manager_state_chart
### 2.4 State chart diagram
@@ -215,7 +215,7 @@ data using OpenSSl API.
\page security_manager_references_and_history 5 References and history
\anchor security_manager_references
### 5.1 References
-- [Software Architecture Document](https://smartdevicelink.com/en/guides/core/software-architecture-document/table-of-contents/)
+- [Software Architecture Document](https://smartdevicelink.com/en/docs/sdl-core/master/software-architecture-document/table-of-contents/)
- [OpenSSL API](https://www.openssl.org/docs/manmaster/ssl/)
- [TLS 1.1 RFC](https://tools.ietf.org/html/rfc4346)
- [TLS 1.2 RFC](https://tools.ietf.org/html/rfc5246)
@@ -236,6 +236,6 @@ Document approve history
| | | | |
For more precise document change history follow github history -
-- https://github.com/smartdevicelink/sdl_core/commits/master/src/components/security_manager/docs/security_manager_software_detailed_design.dox
-- https://github.com/smartdevicelink/sdl_core/commits/develop/src/components/security_manager/docs/security_manager_software_detailed_design.dox
+- https://github.com/smartdevicelink/sdl_core/commits/master/src/components/security_manager/docs/SDL.SDD.Security.dox
+- https://github.com/smartdevicelink/sdl_core/commits/develop/src/components/security_manager/docs/SDL.SDD.Security.dox
*/ \ No newline at end of file
diff --git a/src/components/security_manager/docs/assets/sm_class_digram.png b/src/components/security_manager/docs/assets/sm_class_diagram.png
index 61e300f4e7..61e300f4e7 100644
--- a/src/components/security_manager/docs/assets/sm_class_digram.png
+++ b/src/components/security_manager/docs/assets/sm_class_diagram.png
Binary files differ
diff --git a/src/components/security_manager/docs/assets/sm_sequence_digram_decryption.png b/src/components/security_manager/docs/assets/sm_sequence_diagram_decryption.png
index 849fe45b88..849fe45b88 100644
--- a/src/components/security_manager/docs/assets/sm_sequence_digram_decryption.png
+++ b/src/components/security_manager/docs/assets/sm_sequence_diagram_decryption.png
Binary files differ
diff --git a/src/components/security_manager/docs/assets/sm_sequence_digram_encryption.png b/src/components/security_manager/docs/assets/sm_sequence_diagram_encryption.png
index 66dffd265e..66dffd265e 100644
--- a/src/components/security_manager/docs/assets/sm_sequence_digram_encryption.png
+++ b/src/components/security_manager/docs/assets/sm_sequence_diagram_encryption.png
Binary files differ
diff --git a/src/components/security_manager/docs/assets/sm_sequence_digram_init.png b/src/components/security_manager/docs/assets/sm_sequence_diagram_init.png
index 334b42b258..334b42b258 100644
--- a/src/components/security_manager/docs/assets/sm_sequence_digram_init.png
+++ b/src/components/security_manager/docs/assets/sm_sequence_diagram_init.png
Binary files differ
diff --git a/src/components/security_manager/docs/assets/sm_sequence_digram_verify.png b/src/components/security_manager/docs/assets/sm_sequence_diagram_verify.png
index cb040c918b..cb040c918b 100644
--- a/src/components/security_manager/docs/assets/sm_sequence_digram_verify.png
+++ b/src/components/security_manager/docs/assets/sm_sequence_diagram_verify.png
Binary files differ
diff --git a/src/components/security_manager/src/crypto_manager_impl.cc b/src/components/security_manager/src/crypto_manager_impl.cc
index 8db1d633a7..bdf266fda8 100644
--- a/src/components/security_manager/src/crypto_manager_impl.cc
+++ b/src/components/security_manager/src/crypto_manager_impl.cc
@@ -142,8 +142,13 @@ bool CryptoManagerImpl::Init() {
#endif
switch (get_settings().security_manager_protocol_name()) {
case SSLv3:
+#ifdef OPENSSL_NO_SSL3
+ LOG4CXX_WARN(logger_, "OpenSSL does not support SSL3 protocol");
+ return false;
+#else
method = is_server ? SSLv3_server_method() : SSLv3_client_method();
break;
+#endif
case TLSv1:
method = is_server ? TLSv1_server_method() : TLSv1_client_method();
break;
diff --git a/src/components/security_manager/src/ssl_context_impl.cc b/src/components/security_manager/src/ssl_context_impl.cc
index 69e22dc44e..bccb885511 100644
--- a/src/components/security_manager/src/ssl_context_impl.cc
+++ b/src/components/security_manager/src/ssl_context_impl.cc
@@ -354,7 +354,7 @@ bool CryptoManagerImpl::SSLContextImpl::WriteHandshakeData(
if (ret <= 0) {
is_handshake_pending_ = false;
ResetConnection();
- return Handshake_Result_AbnormalFail;
+ return false;
}
}
return true;
diff --git a/src/components/security_manager/test/ssl_context_test.cc b/src/components/security_manager/test/ssl_context_test.cc
index 945059e58c..a77cd98b27 100644
--- a/src/components/security_manager/test/ssl_context_test.cc
+++ b/src/components/security_manager/test/ssl_context_test.cc
@@ -228,7 +228,7 @@ class SSLTestParam : public testing::TestWithParam<ProtocolAndCipher> {
GetParam().server_ciphers_list);
const bool crypto_manager_initialization = crypto_manager->Init();
- EXPECT_TRUE(crypto_manager_initialization);
+ ASSERT_TRUE(crypto_manager_initialization);
mock_client_manager_settings_ = utils::MakeShared<
NiceMock<security_manager_test::MockCryptoManagerSettings> >();
@@ -241,7 +241,7 @@ class SSLTestParam : public testing::TestWithParam<ProtocolAndCipher> {
GetParam().client_ciphers_list);
const bool client_manager_initialization = client_manager->Init();
- EXPECT_TRUE(client_manager_initialization);
+ ASSERT_TRUE(client_manager_initialization);
server_ctx = crypto_manager->CreateSSLContext();
client_ctx = client_manager->CreateSSLContext();
@@ -261,9 +261,12 @@ class SSLTestParam : public testing::TestWithParam<ProtocolAndCipher> {
}
void TearDown() OVERRIDE {
- crypto_manager->ReleaseSSLContext(server_ctx);
- client_manager->ReleaseSSLContext(client_ctx);
-
+ if (crypto_manager) {
+ crypto_manager->ReleaseSSLContext(server_ctx);
+ }
+ if (client_manager) {
+ client_manager->ReleaseSSLContext(client_ctx);
+ }
delete crypto_manager;
delete client_manager;
}
@@ -303,10 +306,10 @@ class SSLTestParam : public testing::TestWithParam<ProtocolAndCipher> {
mock_crypto_manager_settings_;
utils::SharedPtr<NiceMock<security_manager_test::MockCryptoManagerSettings> >
mock_client_manager_settings_;
- security_manager::CryptoManager* crypto_manager;
- security_manager::CryptoManager* client_manager;
- security_manager::SSLContext* server_ctx;
- security_manager::SSLContext* client_ctx;
+ security_manager::CryptoManager* crypto_manager = NULL;
+ security_manager::CryptoManager* client_manager = NULL;
+ security_manager::SSLContext* server_ctx = NULL;
+ security_manager::SSLContext* client_ctx = NULL;
std::string certificate_data_base64_;
};
@@ -323,11 +326,15 @@ INSTANTIATE_TEST_CASE_P(
ProtocolAndCipher(security_manager::TLSv1_1,
security_manager::TLSv1_1,
kFordCipher,
- kFordCipher),
+ kFordCipher)
+#ifndef OPENSSL_NO_SSL3
+ ,
ProtocolAndCipher(security_manager::SSLv3,
security_manager::SSLv3,
kFordCipher,
- kFordCipher)));
+ kFordCipher)
+#endif
+ ));
INSTANTIATE_TEST_CASE_P(
IncorrectProtocolAndCiphers,
@@ -336,18 +343,10 @@ INSTANTIATE_TEST_CASE_P(
security_manager::TLSv1_1,
kFordCipher,
kFordCipher),
- ProtocolAndCipher(security_manager::TLSv1,
- security_manager::SSLv3,
- kFordCipher,
- kFordCipher),
ProtocolAndCipher(security_manager::TLSv1_1,
security_manager::TLSv1,
kFordCipher,
kFordCipher),
- ProtocolAndCipher(security_manager::TLSv1_1,
- security_manager::SSLv3,
- kFordCipher,
- kFordCipher),
ProtocolAndCipher(security_manager::TLSv1_2,
security_manager::TLSv1,
kFordCipher,
@@ -355,6 +354,16 @@ INSTANTIATE_TEST_CASE_P(
ProtocolAndCipher(security_manager::TLSv1_2,
security_manager::TLSv1_1,
kFordCipher,
+ kFordCipher)
+#ifndef OPENSSL_NO_SSL3
+ ,
+ ProtocolAndCipher(security_manager::TLSv1,
+ security_manager::SSLv3,
+ kFordCipher,
+ kFordCipher),
+ ProtocolAndCipher(security_manager::TLSv1_1,
+ security_manager::SSLv3,
+ kFordCipher,
kFordCipher),
ProtocolAndCipher(security_manager::TLSv1_2,
security_manager::SSLv3,
@@ -367,7 +376,9 @@ INSTANTIATE_TEST_CASE_P(
ProtocolAndCipher(security_manager::SSLv3,
security_manager::TLSv1_1,
kFordCipher,
- kFordCipher)));
+ kFordCipher)
+#endif
+ ));
TEST_F(SSLTest, OnTSL2Protocol_BrokenHandshake) {
ASSERT_EQ(security_manager::SSLContext::Handshake_Result_Success,
@@ -521,11 +532,15 @@ INSTANTIATE_TEST_CASE_P(
ProtocolAndCipher(security_manager::TLSv1_1,
security_manager::TLSv1_2,
kFordCipher,
- kFordCipher),
+ kFordCipher)
+#ifndef OPENSSL_NO_SSL3
+ ,
ProtocolAndCipher(security_manager::SSLv3,
security_manager::TLSv1_2,
kFordCipher,
- kFordCipher)));
+ kFordCipher)
+#endif
+ ));
TEST_P(SSLTestForTLS1_2, HandshakeFailed) {
ASSERT_EQ(security_manager::SSLContext::Handshake_Result_Success,
diff --git a/src/components/smart_objects/include/smart_objects/number_schema_item.h b/src/components/smart_objects/include/smart_objects/number_schema_item.h
index d549b9891a..34c5e3a8a6 100644
--- a/src/components/smart_objects/include/smart_objects/number_schema_item.h
+++ b/src/components/smart_objects/include/smart_objects/number_schema_item.h
@@ -39,6 +39,7 @@
#include "smart_objects/default_shema_item.h"
#include "smart_objects/schema_item_parameter.h"
#include "utils/convert_utils.h"
+#include "utils/helpers.h"
namespace NsSmartDeviceLink {
namespace NsSmartObjects {
@@ -123,15 +124,16 @@ bool TNumberSchemaItem<NumberType>::isValidNumberType(SmartType type) {
NumberType value(0);
if ((SmartType_Double == type) && (typeid(double) == typeid(value))) {
return true;
- } else if ((SmartType_Integer == type) &&
- (typeid(int32_t) == typeid(value) ||
- typeid(uint32_t) == typeid(value) ||
- typeid(int64_t) == typeid(value) ||
- typeid(double) == typeid(value))) {
+ } else if (((SmartType_Integer == type) || (SmartType_UInteger == type)) &&
+ helpers::Compare<const std::type_info&, helpers::EQ, helpers::ONE>(
+ typeid(value),
+ typeid(int32_t),
+ typeid(uint32_t),
+ typeid(int64_t),
+ typeid(double))) {
return true;
- } else {
- return false;
}
+ return false;
}
template <typename NumberType>
diff --git a/src/components/smart_objects/src/number_schema_item.cc b/src/components/smart_objects/src/number_schema_item.cc
index 78be9fe85d..9789434523 100644
--- a/src/components/smart_objects/src/number_schema_item.cc
+++ b/src/components/smart_objects/src/number_schema_item.cc
@@ -41,7 +41,7 @@ SmartType TNumberSchemaItem<int32_t>::getSmartType() const {
template <>
SmartType TNumberSchemaItem<uint32_t>::getSmartType() const {
- return SmartType_Integer;
+ return SmartType_UInteger;
}
template <>
diff --git a/src/components/utils/src/file_system.cc b/src/components/utils/src/file_system.cc
index 62a91ad1f3..62a090550d 100644
--- a/src/components/utils/src/file_system.cc
+++ b/src/components/utils/src/file_system.cc
@@ -71,17 +71,14 @@ int64_t file_system::FileSize(const std::string& path) {
size_t file_system::DirectorySize(const std::string& path) {
size_t size = 0;
- int32_t return_code = 0;
DIR* directory = NULL;
- struct dirent dir_element_;
- struct dirent* dir_element = &dir_element_;
+
struct dirent* result = NULL;
struct stat file_info = {0};
directory = opendir(path.c_str());
if (NULL != directory) {
- return_code = readdir_r(directory, dir_element, &result);
- for (; NULL != result && 0 == return_code;
- return_code = readdir_r(directory, dir_element, &result)) {
+ result = readdir(directory);
+ for (; NULL != result; result = readdir(directory)) {
if (0 == strcmp(result->d_name, "..") ||
0 == strcmp(result->d_name, ".")) {
continue;
@@ -229,19 +226,15 @@ bool file_system::DeleteFile(const std::string& name) {
}
void file_system::remove_directory_content(const std::string& directory_name) {
- int32_t return_code = 0;
DIR* directory = NULL;
- struct dirent dir_element_;
- struct dirent* dir_element = &dir_element_;
struct dirent* result = NULL;
directory = opendir(directory_name.c_str());
if (NULL != directory) {
- return_code = readdir_r(directory, dir_element, &result);
+ result = readdir(directory);
- for (; NULL != result && 0 == return_code;
- return_code = readdir_r(directory, dir_element, &result)) {
+ for (; NULL != result; result = readdir(directory)) {
if (0 == strcmp(result->d_name, "..") ||
0 == strcmp(result->d_name, ".")) {
continue;
@@ -295,18 +288,14 @@ std::vector<std::string> file_system::ListFiles(
return listFiles;
}
- int32_t return_code = 0;
DIR* directory = NULL;
- struct dirent dir_element_;
- struct dirent* dir_element = &dir_element_;
struct dirent* result = NULL;
directory = opendir(directory_name.c_str());
if (NULL != directory) {
- return_code = readdir_r(directory, dir_element, &result);
+ result = readdir(directory);
- for (; NULL != result && 0 == return_code;
- return_code = readdir_r(directory, dir_element, &result)) {
+ for (; NULL != result; result = readdir(directory)) {
if (0 == strcmp(result->d_name, "..") ||
0 == strcmp(result->d_name, ".")) {
continue;
diff --git a/src/components/utils/test/policy.sql b/src/components/utils/test/policy.sql
index 292855734e..d588d695a6 100644
--- a/src/components/utils/test/policy.sql
+++ b/src/components/utils/test/policy.sql
@@ -263,7 +263,7 @@ BEGIN TRANSACTION;
CREATE INDEX IF NOT EXISTS `consent_group.fk_consent_group_functional_group1_idx`
ON `consent_group`(`functional_group_id`);
CREATE TABLE IF NOT EXISTS `endpoint`(
- `service` INTEGER NOT NULL,
+ `service` VARCHAR(100) NOT NULL,
`url` VARCHAR(100) NOT NULL,
`application_id` VARCHAR(45) NOT NULL COLLATE NOCASE,
CONSTRAINT `fk_endpoint_application1`