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

IBM MQ metadata #6979

Merged
merged 26 commits into from
Jul 17, 2020
Merged

IBM MQ metadata #6979

merged 26 commits into from
Jul 17, 2020

Conversation

steveny91
Copy link
Contributor

What does this PR do?

This PR attempts to add the functionality to have the check pick up the version of the IBM MQ server.

Motivation

Assigned as a embed task

Additional Notes

N/A

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • PR title must be written as a CHANGELOG entry (see why)
  • Files changes must correspond to the primary purpose of the PR as described in the title (small unrelated changes should have their own PR)
  • PR must have changelog/ and integration/ labels attached

@steveny91 steveny91 requested a review from a team as a code owner June 25, 2020 18:28
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/tests/test_metadata.py Outdated Show resolved Hide resolved
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/tests/test_metadata.py Outdated Show resolved Hide resolved
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/tests/test_ibm_mq_int.py Outdated Show resolved Hide resolved
Copy link
Member

@mgarabed mgarabed left a comment

Choose a reason for hiding this comment

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

Nice stuff!

ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/tests/test_ibm_mq_int.py Outdated Show resolved Hide resolved
ibm_mq/tests/test_ibm_mq_int.py Outdated Show resolved Hide resolved
@steveny91 steveny91 requested a review from a team as a code owner June 26, 2020 01:43
Copy link
Member

@AlexandreYang AlexandreYang left a comment

Choose a reason for hiding this comment

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

I think there is a big drawback using a shell command, it only works if the agent is running on the MQ Server itself. We should try to get the version via PCF command instead :)

ibm_mq/datadog_checks/ibm_mq/data/conf.yaml.example Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Jun 29, 2020

@steveny91
Copy link
Contributor Author

I changed up the method of collection to what @AlexandreYang suggested, update the metadata collection test. Please let me know if anything needs changing. Thanks!

Copy link
Member

@AlexandreYang AlexandreYang left a comment

Choose a reason for hiding this comment

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

Nice, thx for using PCF command instead. I left few comments. :)

ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/datadog_checks/ibm_mq/ibm_mq.py Outdated Show resolved Hide resolved
ibm_mq/tests/conftest.py Outdated Show resolved Hide resolved
@steveny91
Copy link
Contributor Author

@AlexandreYang I've updated the check with most of your comments. The only one I left out was the dependency upgrade of pymqi to 1.11.1. For whatever reason, upgrading to 1.11.1 breaks the py2 tests. I get this error when stepping through:

-> self.channel_metric_collector.get_pcf_channel_metrics(queue_manager)
(Pdb) self.channel_metric_collector.get_pcf_channel_metrics(queue_manager)
*** NotImplementedError: Unpack for type ((4,)) not implemented

Not sure if you've come across this error before.

@hithwen hithwen force-pushed the steven-y-ibm-mq-metadata-e2e branch from 0caf7b3 to 58737ce Compare July 13, 2020 11:49
@hithwen hithwen force-pushed the steven-y-ibm-mq-metadata-e2e branch from 2edc93a to 04df8a4 Compare July 15, 2020 08:24
@hithwen hithwen changed the title IBM MQ version functionality IBM MQ metadata Jul 15, 2020
@hithwen hithwen force-pushed the steven-y-ibm-mq-metadata-e2e branch from df61e36 to e3e99cc Compare July 15, 2020 10:25
@hithwen hithwen merged commit 1b6259e into master Jul 17, 2020
@hithwen hithwen deleted the steven-y-ibm-mq-metadata-e2e branch July 17, 2020 14:17
github-actions bot pushed a commit that referenced this pull request Jul 17, 2020
* Added version metadata collection

Co-authored-by: Julia Simon <611228+hithwen@users.noreply.github.com> 1b6259e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants