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

feat(inputs.opcua_listener): Add monitoring params #13923

Merged
merged 15 commits into from
Oct 10, 2023

Conversation

reindlt
Copy link
Contributor

@reindlt reindlt commented Sep 14, 2023

Required for all PRs

resolves #13891

new structs have been added to input client representing monitoring and data change filter parameters

new function has been added to subscribe client in order to override default values for parameters that have been specified in the config

monitoring parameters have been added to existing tests for subscribe client

@telegraf-tiger telegraf-tiger bot added the feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin label Sep 14, 2023
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,

Thank you very much for the PR! I have a few comments and questions below for you to review.

Thanks!

plugins/inputs/opcua_listener/sample.conf Outdated Show resolved Hide resolved
plugins/inputs/opcua_listener/README.md Outdated Show resolved Hide resolved
plugins/common/opcua/input/input_client.go Show resolved Hide resolved
plugins/inputs/opcua_listener/subscribe_client.go Outdated Show resolved Hide resolved
plugins/inputs/opcua_listener/README.md Outdated Show resolved Hide resolved
plugins/inputs/opcua_listener/subscribe_client.go Outdated Show resolved Hide resolved
plugins/inputs/opcua_listener/subscribe_client.go Outdated Show resolved Hide resolved
@srebhan srebhan added area/opcua plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins labels Sep 18, 2023
@telegraf-tiger
Copy link
Contributor

Download PR build artifacts for linux_amd64.tar.gz, darwin_amd64.tar.gz, and windows_amd64.zip.
Downloads for additional architectures and packages are available below.

🥳 This pull request decreases the Telegraf binary size by -2.36 % for linux amd64 (new size: 197.3 MB, nightly size 202.1 MB)

📦 Click here to get additional PR build artifacts

Artifact URLs

DEB RPM TAR GZ ZIP
amd64.deb aarch64.rpm darwin_amd64.tar.gz windows_amd64.zip
arm64.deb armel.rpm darwin_arm64.tar.gz windows_arm64.zip
armel.deb armv6hl.rpm freebsd_amd64.tar.gz windows_i386.zip
armhf.deb i386.rpm freebsd_armv7.tar.gz
i386.deb ppc64le.rpm freebsd_i386.tar.gz
mips.deb riscv64.rpm linux_amd64.tar.gz
mipsel.deb s390x.rpm linux_arm64.tar.gz
ppc64el.deb x86_64.rpm linux_armel.tar.gz
riscv64.deb linux_armhf.tar.gz
s390x.deb linux_i386.tar.gz
linux_mips.tar.gz
linux_mipsel.tar.gz
linux_ppc64le.tar.gz
linux_riscv64.tar.gz
linux_s390x.tar.gz

@reindlt reindlt force-pushed the feat/monitoring-params branch from 5eaf36e to ea65973 Compare October 3, 2023 13:46
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@powersj powersj added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Oct 3, 2023
@powersj powersj assigned srebhan and unassigned powersj Oct 3, 2023
Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution @reindlt. Only two minor comments from my side...

plugins/inputs/opcua_listener/subscribe_client.go Outdated Show resolved Hide resolved
plugins/inputs/opcua_listener/subscribe_client.go Outdated Show resolved Hide resolved
@srebhan srebhan changed the title feat(opcua_listener): add monitoring params feat(inputs.opcua_listener): Add monitoring params Oct 4, 2023
@reindlt
Copy link
Contributor Author

reindlt commented Oct 6, 2023

@srebhan thanks for taking over the corrections.

It seems that the failed checks are not related to changes within this PR.

@srebhan srebhan merged commit 474aff5 into influxdata:master Oct 10, 2023
4 checks passed
@github-actions github-actions bot added this to the v1.29.0 milestone Oct 10, 2023
@reindlt reindlt deleted the feat/monitoring-params branch October 12, 2023 06:52
@JeroenVanHoye
Copy link

Hi,
Does this feature work? Because when adding the monitoring parameters like this to a nodeconfig inside a group, I get the following error. I just copied the config from the example. When I remove the monitoring_params completely the config works.

Config:
{name="Val_PV", identifier="0:08TT20402.HMI.Val_PV", monitoring_params={sampling_interval="0s", queue_size=10, discard_oldest=true, data_change_filter={trigger="Status", deadband_type="Absolute", deadband_value=0.0}}},

Error:
error parsing opcua_listener, line 50: (input.NodeSettings.MonitoringParams) cannot unmarshal TOML array table into input.MonitoringParameters (need slice)

@srebhan
Copy link
Member

srebhan commented Apr 26, 2024

@JeroenVanHoye please do not comment on old PR but open a new issue with your (redacted) config and the corresponding log...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/opcua feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

opcua_listener: set individual values for monitoring parameters instead of relying on defaults
4 participants