BroadbandForum / obuspa

OB-USP-AGENT is a system daemon providing a User Services Platform (USP) Agent. https://github.com/BroadbandForum/obuspa/wiki
BSD 3-Clause "New" or "Revised" License
88 stars 61 forks source link

Dependent object question #77

Closed dmounday closed 1 year ago

dmounday commented 1 year ago

Is the following an error in obuspa, a specification error in TR-181, or my misunderstanding? A Get Device.LocalAgent.Controller. returns all MTP protocol sub-objects regardless of the value of the .Controller.{i}.MTP.{i}.Protocol parameter. TR-181 describes each protocol sub-object as only present if the object corresponds to the value of the Protocol parameter. For example the TR-181 of .MTP.{i}.STOMP. description is: If the USP Endpoint uses the STOMP Message Transport Protocol (MTP), then this object contains STOMP Client specific configuration parameters related to how this Controller communicates with the STOMP Server. This object MUST be present if, and only if, Protocol is STOMP.

The response from obuspa is: resolved_path_results { resolved_path: "Device.LocalAgent.Controller.1.MTP.1." result_params { key: "Alias" value: "cpe-1" } result_params { key: "Enable" value: "true" } result_params { key: "Protocol" value: "WebSocket" } } resolved_path_results { resolved_path: "Device.LocalAgent.Controller.1.MTP.1.STOMP." result_params { key: "Reference" value: "" } result_params { key: "Destination" value: "" } } resolved_path_results { resolved_path: "Device.LocalAgent.Controller.1.MTP.1.CoAP." result_params { key: "Host" value: "" } result_params { key: "Port" value: "5683" } result_params { key: "Path" value: "" } result_params { key: "EnableEncryption" value: "true" } } resolved_path_results { resolved_path: "Device.LocalAgent.Controller.1.MTP.1.MQTT." result_params { key: "Reference" value: "" } result_params { key: "Topic" value: "" } } resolved_path_results { resolved_path: "Device.LocalAgent.Controller.1.MTP.1.WebSocket." result_params { key: "Host" value: "0.0.0.0" } result_params { key: "Port" value: "8183" } result_params { key: "Path" value: "/gs-server" } result_params { key: "EnableEncryption" value: "false" } result_params { key: "KeepAliveInterval" value: "30" } result_params { key: "CurrentRetryCount" value: "0" } result_params { key: "SessionRetryMinimumWaitInterval" value: "5" } result_params { key: "SessionRetryIntervalMultiplier" value: "2000" } }

holme-r commented 1 year ago

TR-181 added this caveat after OBUSPA was released. OBUSPA just hasn't caught up yet. This is a low priority issue, since a controller would need to understand that Protocol was a discriminator when interpreting the response, regardless of whether the caveat was implemented or not.

holme-r commented 1 year ago

Closing as discussion closed.