...
This parameter is only allowed for GET methods on api, datastore, and data resources. A 400 Bad Request error is returned if used for other methods or resource types.
Fields example
http:/ncmp/v1localhost:8282/chrests/335ff/data/ds/ncmpnetwork-datastorestopology:passthrough-running?fields=_3gpp-common-managed-element:ManagedElement/_3gpp-nr-nrm-gnbcucpfunction:GNBCUCPFunction(pLMNId;gNBId;gNBIdLength)network-topology/topology=topology-netconf/node=PNFDemo/yang-ext:mount/gnodeb:cells/cellinfolist=1?fields=cell-uuid;cell-id
Depth
The "depth" parameter is used to specify the number of nest levels returned in a response for a GET method. The first nest-level consists of the requested data node itself. Any child nodes which are contained within a parent node have a depth value that is 1 greater than its parent.
...
By default, the server will include all sub-resources within a retrieved resource, which have the same resource type as the requested resource. Only one level of sub-resources with a different media type than the target resource will be returned.
Depth Example
http:/ncmp/v1/ch/335fflocalhost:8282/rests/data/ds/ncmpnetwork-datastorestopology:passthrough-running?fields=_3gpp-common-managed-element:ManagedElement/_3gpp-nr-nrm-gnbcucpfunction:GNBCUCPFunction(pLMNId;gNBId;gNBIdLength)network-topology/topology=topology-netconf/node=PNFDemo/yang-ext:mount/gnodeb:cells/cellinfolist=1?fields=cell-uuid;cell-id&depth=1
The support/limitations of both parameters as implemented by the 'rests' ODL module interface (SDN-C)
A seen in the video of the parent spike fields and depth are implemented in the rests odl interface
...
The "rests" odl interface supports fields and depth parameters
rests Interface Fields Examples
GET cell details - http://localhost:8282/rests/data/network-topology:network-topology/topology=topology-netconf/node=PNFDemo/yang-ext:mount/gnodeb:cells/cellinfolist=1
GET cell details with filtering - http://localhost:8282/rests/data/network-topology:network-topology/topology=topology-netconf/node=PNFDemo/yang-ext:mount/gnodeb:cells/cellinfolist=1?fields=cell-uuid
GET multiple fields with filtering - http://localhost:8282/rests/data/network-topology:network-topology/topology=topology-netconf/node=PNFDemo/yang-ext:mount/gnodeb:cells/cellinfolist=1?fields=cell-uuid;cell-id
rests Interface Depth Examples
If the "fields" parameter is used to select descendant data nodes, then these nodes and all of their ancestor nodes have a "depth" value of "1".
Info |
---|
rests interface supports application/yang-data+json format |
...