-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
snmp ip/mac addr conversion & oid index suffix support #1784
Conversation
@@ -0,0 +1,97 @@ | |||
// +build generate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I built this generator to make management of the mocked commands easier. Having to manually add the command & output to the test file was becoming a PITA.
@@ -0,0 +1,82 @@ | |||
package snmp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I split all the command mocking stuff out of test_snmp.go
to keep the tests clean.
@mattbakerau This should solve your use case (#1729). If you want to take a look at it, and/or try it out, any feedback would be great. @mnctech This should also solve your use case (#1755). If you have any feedback, it would also be appreciated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I can merge when you rebase the changes
Also consolidated the translation code to obtain all info with just 1 command execution. Also split test command mocks out to their own file for cleanliness.
Rebased |
This adds 2 new features to the SNMP plugin:
oid_index_suffix
allows stripping off the trailing part of the OID on the joined table so that the index will match.closes #1755
closes #1729
Required for all PRs: