summaryrefslogtreecommitdiff
path: root/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/rpc_plugins/rc_rpc_plugin/src')
-rw-r--r--src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_helpers.cc1
-rw-r--r--src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_rpc_plugin.cc12
-rw-r--r--src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/resource_allocation_manager_impl.cc1
3 files changed, 12 insertions, 2 deletions
diff --git a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_helpers.cc b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_helpers.cc
index ca0edc90b1..f344dd15a7 100644
--- a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_helpers.cc
+++ b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_helpers.cc
@@ -175,6 +175,7 @@ const std::vector<std::string> RCHelpers::GetModuleTypesList() {
RCAppExtensionPtr RCHelpers::GetRCExtension(
application_manager::Application& app) {
+ LOG4CXX_AUTO_TRACE(logger_);
auto extension_interface = app.QueryInterface(RCRPCPlugin::kRCPluginID);
auto extension =
std::static_pointer_cast<RCAppExtension>(extension_interface);
diff --git a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_rpc_plugin.cc b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_rpc_plugin.cc
index 9005eb7fd0..4e43cff58d 100644
--- a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_rpc_plugin.cc
+++ b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/rc_rpc_plugin.cc
@@ -107,7 +107,12 @@ void RCRPCPlugin::OnPolicyEvent(
void RCRPCPlugin::OnApplicationEvent(
application_manager::plugin_manager::ApplicationEvent event,
application_manager::ApplicationSharedPtr application) {
+ LOG4CXX_AUTO_TRACE(logger_);
if (!application->is_remote_control_supported()) {
+ LOG4CXX_DEBUG(
+ logger_,
+ "Remote control is not supported for application with app_id: "
+ << application->app_id());
return;
}
switch (event) {
@@ -119,8 +124,6 @@ void RCRPCPlugin::OnApplicationEvent(
rc_capabilities_manager_
->GetDriverLocationFromSeatLocationCapability();
extension->SetUserLocation(driver_location);
- resource_allocation_manager_->SendOnRCStatusNotifications(
- NotificationTrigger::APP_REGISTRATION, application);
break;
}
case plugins::kApplicationExit: {
@@ -139,6 +142,11 @@ void RCRPCPlugin::OnApplicationEvent(
extension->SetUserLocation(user_location);
break;
}
+ case plugins::kRCStatusChanged: {
+ resource_allocation_manager_->SendOnRCStatusNotifications(
+ NotificationTrigger::APP_REGISTRATION, application);
+ break;
+ }
default:
break;
}
diff --git a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/resource_allocation_manager_impl.cc b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/resource_allocation_manager_impl.cc
index 97ff2b23da..049f9a3cf3 100644
--- a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/resource_allocation_manager_impl.cc
+++ b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/resource_allocation_manager_impl.cc
@@ -156,6 +156,7 @@ bool ResourceAllocationManagerImpl::IsUserLocationValid(
ModuleUid& module, application_manager::ApplicationSharedPtr app) {
LOG4CXX_AUTO_TRACE(logger_);
const auto extension = RCHelpers::GetRCExtension(*app);
+ DCHECK_OR_RETURN(extension, false);
const auto user_location = extension->GetUserLocation();
const auto module_service_area =
rc_capabilities_manager_.GetModuleServiceArea(module);