Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes Un/SubscribeVehicleData requests behavior. #152

Conversation

dev-gh
Copy link
Contributor

@dev-gh dev-gh commented Jul 5, 2015

'appID' parameter had been removed from Un/Subscribe requests for HMI API.
Logic of requests had been changed: un/subscribe request is sent only if
there are no apps subscribed for required parameters.

Implements: APPLINK-13345

Requirements to SDL:

  1. In case app_2 sends SubscribeVehicleData (param_1, param_2) to SDL AND SDL has successfully already subscribed param_1 and param_2 via SubscribeVehicleData to app_1 SDL must:
    1.1. must NOT send SubscribeVehicleData(param_1, param_2) to HMI.
    1.2. respond via SubscribeVehicleData (SUCCESS) to app_2
  2. In case app_1 sends SubscribeVehicleData (param_1) to SDL AND SDL does not have this param_1 in list of stored successfully subscribing params SDL must:
    2.1. transfer SubscribeVehicleData(param_1) to HMI.
    2.2. respond corresponding results received from HMI to app_2:
    2.2.1. in case SDL receives SUCCESS for param_1 SDL must store this param in list AND respond SubscribeVehicleData (SUCCESS) to app_2
    2.2.2. in case SDL receives erroneous result for param_1 SDL must NOT store this param in list AND respond SubscribeVehicleData (Result Code, success:false) to app_2
  3. In case app_2 sends SubscribeVehicleData (param_1, param_3) to SDL AND SDL already subscribes param_1 via SubscribeVehicleData to app_1 SDL must send SubscribeVehicleData ONLY with param_3 to HMI.
  4. In case SDL successfully subscribes param_1 for app_1 and app_2 via SubscribeVehicleData AND app_1 sends UnsubscribeVehicleData (param_1) SDL must:
    4.1. respond via UnsubscribeVehicleData(SUCCESS) to app_1
    4.2. stop sending OnVehicleData (param_1) ONLY to app_1
    (meaning: does not send UnsubscribeVehicleData(param_1) to HMI while there are others app still subscribed on param_1)

HMI_API changes:

  1. param must be removed from SubscribeVehicleData
<function name="SubscribeVehicleData" messagetype="request">
<description>
Subscribes for specific published data items.
The data will be only sent if it has changed.
The application will be notified by the onVehicleData notification whenever new data is available.
To unsubscribe the notifications, use unsubscribe with the same subscriptionType.
</description>
<param name="appID" type="Integer" mandatory="true">
<description>ID of application that requested this RPC.</description>
</param>
<param name="gps" type="Boolean" mandatory="false">
<description>See GPSData</description>
</param>
<param name="speed" type="Boolean" mandatory="false">
<description>The vehicle speed in kilometers per hour</description>
</param>
  1. param must be removed from UnsubscribeVehicleData

    This function is used to unsubscribe the notifications from the subscribeVehicleData function. ID of application that requested this RPC. See GPSData The vehicle speed in kilometers per hour

@AGaliuzov
Copy link
Contributor

Andrey, could you please rebase this pull reques as it could not be merged

'appID' parameter had been removed from Un/Subscribe requests for HMI API.
Logic of requests had been changed: un/subscribe request is sent only if
there are no apps subscribed for required parameters.

Implements: APPLINK-13345
@dev-gh dev-gh force-pushed the feature/Subscribe_unsubcribe_wo_appid branch from 4f3ac72 to 0ad86fe Compare July 26, 2015 11:14
@dev-gh
Copy link
Contributor Author

dev-gh commented Jul 26, 2015

Done.

AGaliuzov added a commit that referenced this pull request Jul 30, 2015
…o_appid

Changes Un/SubscribeVehicleData requests behavior.
@AGaliuzov AGaliuzov merged commit 4c2e03c into smartdevicelink:develop Jul 30, 2015
LitvinenkoIra pushed a commit to LitvinenkoIra/sdl_core that referenced this pull request Jul 17, 2017
…send_param_isSubscribe_to_mobile_if_its_absent_in_HMI_response

Add GetInteriorVehicleData missed subscription handling
@MNikora MNikora deleted the feature/Subscribe_unsubcribe_wo_appid branch April 29, 2020 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants