Skip to content

Commit

Permalink
update client if credentials have changed
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanielc committed Apr 13, 2017
1 parent 5408057 commit 0b27c84
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## v1.2.1 [2017-04-13]

### Bugfixes

- [#1323](https://github.com/influxdata/kapacitor/pull/1323): Fix issue where credentials to InfluxDB could not be updated dynamically.

## v1.2.0 [2017-01-23]

### Release Notes
Expand Down
4 changes: 3 additions & 1 deletion influxdb/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,9 @@ func (c *HTTPClient) Update(new Config) error {
return err
}
c.urls = urls
if old.Timeout != new.Timeout || old.Transport != new.Transport {
if old.Credentials != new.Credentials ||
old.Timeout != new.Timeout ||
old.Transport != new.Transport {
//Replace the client
tr := new.Transport
if tr == nil {
Expand Down

0 comments on commit 0b27c84

Please sign in to comment.