Skip to content

Commit

Permalink
Merge pull request #83 from DataDog/jaime/instancefail
Browse files Browse the repository at this point in the history
[jmx] if the exception is an IOException, throw it. Instance should be removed.
  • Loading branch information
truthbk committed Mar 22, 2016
2 parents 2c485f0 + 6cb005b commit b957b28
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,6 @@ jdk:
notifications:
slack:
secure: bUPdpDtrBYvlJ93AmfqvPU6ZSZhFHZJiIoNf0bXJVNZyxp2rjfMC8BG6XkesbKk62s7NJM0yfZhhLAzjNG3tSA9iL5i3npbl8kRaUi2zEDOCEG0zZ+FX2NxTiNH937S6QRmCBHe9/KEkSRuMY3HNRUidAq8w6dVCrWxxj5NwxjU=

addons:
hostname: dd-jmxfetch-testhost
2 changes: 2 additions & 0 deletions src/main/java/org/datadog/jmxfetch/Instance.java
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,8 @@ public LinkedList<HashMap<String, Object>> getMetrics() throws IOException {
if (this.failingAttributes.contains(jmxAttr)) {
this.failingAttributes.remove(jmxAttr);
}
} catch (IOException e) {
throw e;
} catch (Exception e) {
LOGGER.debug("Cannot get metrics for attribute: " + jmxAttr, e);
if (this.failingAttributes.contains(jmxAttr)) {
Expand Down

0 comments on commit b957b28

Please sign in to comment.