Skip to content

Commit 9a2d505

Browse files
Merge pull request #13 from newrelic/fix_metrics_with_inventory
[IHOST-177] Do not return metrics when only INVENTORY flag provided
2 parents 0c6cc4c + ba50470 commit 9a2d505

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

CHANGELOG.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,31 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](http://keepachangelog.com/)
55
and this project adheres to [Semantic Versioning](http://semver.org/).
66

7+
## Next Release (date TBD)
8+
### Fixed
9+
- Issue where the plugin returned metrics when only inventory was requested.
10+
711
## 1.1.4 (2018-10-19)
812

913
### Bugs fixed
1014

1115
#### Allow rate and deltas
1216

13-
Metrics of type rate and delta cannot be added unless there is a namespacing attribute on the metric-set.
17+
- Metrics of type rate and delta cannot be added unless there is a namespacing attribute on the metric-set.
1418

1519
## 1.1.3 (2018-10-12)
1620

1721
### Changed:
1822

1923
#### Update to SDKv3
2024

21-
Updated the integration code from the previous version of the SDK to [SDK v3](https://github.com/newrelic/infra-integrations-sdk/#upgrading-from-sdk-v2-to-v3).
25+
- Updated the integration code from the previous version of the SDK to [SDK v3](https://github.com/newrelic/infra-integrations-sdk/#upgrading-from-sdk-v2-to-v3).
2226

2327
### Added:
2428

2529
#### Old password support
2630

27-
Previously when trying to run Mysql integration on a mysql-server with old password support https://dev.mysql.com/doc/refman/5.6/en/server-system-variables.html#sysvar_old_passwords integration won't run. If customer has set old_passwords=1 at the MySQL server integration can now connect to it.
31+
- Previously when trying to run Mysql integration on a mysql-server with old password support https://dev.mysql.com/doc/refman/5.6/en/server-system-variables.html#sysvar_old_passwords integration won't run. If customer has set old_passwords=1 at the MySQL server integration can now connect to it.
2832

2933
#### Ignore bin folder
3034

@@ -33,7 +37,7 @@ Previously when trying to run Mysql integration on a mysql-server with old passw
3337
### Bugs fixed
3438

3539
#### Hostname issue
36-
Integration CLI-arguments are no longer overridden by environment-variables
40+
- Integration CLI-arguments are no longer overridden by environment-variables
3741
As CLI-args are used by the NRI agent `HOSTNAME` that is a common bash env-var is not used to set MySql-host unless no hostname is provided via config.
3842

3943
## 1.1.2 (2018-10-16)

src/mysql.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ func main() {
4444
log.SetupLogging(args.Verbose)
4545

4646
e := i.LocalEntity()
47-
ms := e.NewMetricSet("MysqlSample", metric.Attr("hostname", args.Hostname))
4847

4948
db, err := openDB(generateDSN(args))
5049
fatalIfErr(err)
@@ -58,6 +57,7 @@ func main() {
5857
}
5958

6059
if args.HasMetrics() {
60+
ms := e.NewMetricSet("MysqlSample", metric.Attr("hostname", args.Hostname))
6161
populateMetrics(ms, rawMetrics)
6262
}
6363

0 commit comments

Comments
 (0)