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

Add resource, command, and device tags to reading/event #1294

Closed
FelixTing opened this issue Jan 31, 2023 · 2 comments · Fixed by #1297
Closed

Add resource, command, and device tags to reading/event #1294

FelixTing opened this issue Jan 31, 2023 · 2 comments · Fixed by #1297
Assignees
Labels
enhancement New feature or request

Comments

@FelixTing
Copy link
Member

🚀 Feature Request

Relevant Package [REQUIRED]

device-sdk

Description [REQUIRED]

Based on edgexfoundry/go-mod-core-contracts#767
Device, device resource, and device command now have the Tags map[string]interface{} field that allows users to provide additional information. device-sdk should add these tags to reading/event.

Describe the solution you'd like

Before sending out an event, do the following:

  1. Add device resource tags in reading level
  2. Add device command tags in event level
  3. Add device tags in event level

The device tags should take precedence over the device command tags if the tag name is the same.

Describe alternatives you've considered

Have you considered any alternative solutions or workarounds?
@TomBrennan-Eaton
Copy link

What's the "Why?" here? Why put the tags in every Event, when they are available in metadata?
Event size is always a concern, though the contribution from Tags appears to be small.

@cloudxxx8
Copy link
Member

@TomBrennan-Eaton the tags will be only if they are defined in Profile or Device. Their default value is empty, so this won't increase any size for the normal usage.
We found some users need the additional information in Event or Reading.
For example, the users might want the sunspec mapping information in the readings. https://sunspec.org/
When the data is sent out to the northbound, they might not be able to access core-metadata from the edge side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants