-
Notifications
You must be signed in to change notification settings - Fork 70
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
Support 'float' and 'java.lang.Float' #76
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Support 'float' and 'java.lang.Float' attribute types as simple JMX attrbutes.
Introduce a `TestCommon` parent class to refactor JUnit tests. Features: * One-liner `registerMBean` method * One-liner `initApplication` nethod * Automatically unregister MBeans after execution of every test * More eye candies
Add two new methods to `TestCommon` test class to refactor JUnit tests. * `assertMetric`: assert that a specific metric was collected * `assertCoverage`: assert that all -excluding JVM related- metrics were tested. Refactor `TestApp` tests.
|
||
mbs.unregisterMBean(includeObjectName); | ||
// First filter 27 = 13 metrics from java.lang + 14 metrics implicitly defined |
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.
28 = 13 + 15 😉
Love the refactoring of the tests ❤️ Looks great, just tiny comments/indentation to fix, apart from that |
Thanks for the review @olivielpeau 🔢 ➕ 🔢 |
Assert `java.lang.Float` attribute type support.
yannmh
added a commit
that referenced
this pull request
Oct 16, 2015
Support 'float' and 'java.lang.Float'
yannmh
added a commit
to DataDog/dd-agent
that referenced
this pull request
Nov 3, 2015
**Changes** * [BUGFIX] Fix bean name matching logic: `OR`→`AND`. See [#81][] * [FEATURE] Support `float` and `java.lang.Float` attribute types as * simple JMX attributes. See [#76][] * [FEATURE] Support Cassandra > 2.2 metric name structure * (CASSANDRA-4009). See [#79][] * [FEATURE] Support custom JMX Service URL to connect to, on a * per-instance basis. See [#80][] * [IMPROVEMENT] Assign generic alias if not defined. See [#78][] <!--- The following link definition list is generated by PimpMyChangelog ---> [#76]: DataDog/jmxfetch#76 [#78]: DataDog/jmxfetch#78 [#79]: DataDog/jmxfetch#79 [#80]: DataDog/jmxfetch#80 [#81]: DataDog/jmxfetch#81
urosgruber
pushed a commit
to urosgruber/dd-agent
that referenced
this pull request
Dec 23, 2015
**Changes** * [BUGFIX] Fix bean name matching logic: `OR`→`AND`. See [DataDog#81][] * [FEATURE] Support `float` and `java.lang.Float` attribute types as * simple JMX attributes. See [DataDog#76][] * [FEATURE] Support Cassandra > 2.2 metric name structure * (CASSANDRA-4009). See [DataDog#79][] * [FEATURE] Support custom JMX Service URL to connect to, on a * per-instance basis. See [DataDog#80][] * [IMPROVEMENT] Assign generic alias if not defined. See [DataDog#78][] <!--- The following link definition list is generated by PimpMyChangelog ---> [DataDog#76]: DataDog/jmxfetch#76 [DataDog#78]: DataDog/jmxfetch#78 [DataDog#79]: DataDog/jmxfetch#79 [DataDog#80]: DataDog/jmxfetch#80 [DataDog#81]: DataDog/jmxfetch#81
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Support
float
andjava.lang.Float
attribute types as simple JMX attributes. Assert the support of these attribute types with tests.Changes
Support
float
andjava.lang.Float
Support
float
andjava.lang.Float
attribute types as simple JMX attributes.TestCommon
to refactor JUnit testsIntroduce a
TestCommon
parent class to refactor JUnit tests.Features:
registerMBean
methodinitApplication
nethodassertMetric
andassertCoverage
methodsAdd two new methods to
TestCommon
test class to refactor JUnit tests.assertMetric
: assert that a specific metric was collectedassertCoverage
: assert that all -excluding JVM related- metrics weretested.
Refactor
TestApp
tests.Attribute types coverage
Assert the support of these attribute types with tests.