retrieve uuid from endpoint address, use it with service url as device id #630
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it:
refs #250
This PR retrieve the Onvif device uuid and use it with service url to form the device id reported to Agent.
According to ONVIF core spec sec 7.3.1. The combination of an wsadis:Address
and wsadis:ReferenceProperties provide a stable and globally-unique identifier.
We can use "wsadis:Address + wsadis:ReferenceProperties.Address" as the identifier of Onvif devices. The DH needs to expose the uuid to brokers so brokers have the same information to uniquely identify a device.
7.3.1 Endpoint reference
A device or an endpoint that takes the client role should use a URN:UUID [RFC4122] as the address property
of its endpoint reference.
The device or an endpoint that takes the client role shall use a stable, globally unique identifier that is constant
across network interfaces as part of its endpoint reference property. The combination of an wsadis:Address
and wsadis:ReferenceProperties provide a stable and globally-unique identifier.
Special notes for your reviewer:
If applicable:
cargo fmt
)cargo build
)cargo clippy
)cargo test
)cargo doc
)