Skip to content

Commit

Permalink
Kafka connectString generation with brokerHost variable
Browse files Browse the repository at this point in the history
  • Loading branch information
hokiegeek2 authored and andreas-schroeder committed Aug 10, 2017
1 parent f4caac3 commit 3dde610
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion check/setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func (check *HealthCheck) connect(firstConnection bool, stop <-chan struct{}) er
func (check *HealthCheck) tryConnectOnce(createBrokerTopic, createReplicationTopic *bool) error {
pauseTime := check.config.retryInterval
// connect to kafka cluster
connectString := []string{fmt.Sprintf("localhost:%d", check.config.brokerPort)}
connectString := []string{fmt.Sprintf("%s:%d", check.config.brokerHost, check.config.brokerPort)}
err := check.broker.Dial(connectString, check.brokerConfig())
if err != nil {
log.Printf("unable to connect to broker, retrying in %s (%s)", pauseTime.String(), err)
Expand Down

0 comments on commit 3dde610

Please sign in to comment.