Open kinok opened 8 years ago
Hey @joelegasse, thanks for your relevant review. I agree with all your remarks, just made the changes.
Hey there, Any chance to have a review of this PR? Thank you guys
Also Amazon ELB requires 200 and does not work with 204.
Getting an error with this PR:
goroutine 1 [running]:
github.com/influxdata/influxdb-relay/relay.NewHTTP(0xc420016761, 0xb, 0xc420014e21, 0xe, 0xc4200167e5, 0x0, 0x0, 0x0, 0xc8, 0xc42009c2c0, ...)
/go/src/github.com/influxdata/influxdb-relay/relay/http.go:61 +0xdf
github.com/influxdata/influxdb-relay/relay.New(0xc4200561e0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
/go/src/github.com/influxdata/influxdb-relay/relay/relay.go:18 +0x15b
main.main()
/go/src/github.com/influxdata/influxdb-relay/main.go:31 +0x1a1
panic: assignment to entry in nil map
Fix:
- h := new(HTTP)
-
- h.addr = cfg.Addr
- h.name = cfg.Name
+ h := &HTTP{
+ addr: cfg.Addr,
+ name: cfg.Name,
+ pingResponseHeaders: map[string]string{},
+ }
Soooo...this is still an issue. Google gcp still only accepts 200 response codes. This has been open since 2016 and never fixed? It has been adjusted in both influxdb and telegraf. See this issue: https://github.com/influxdata/telegraf/pull/5704/files
Hey guys,
We had a problem regarding the hardcoded
204 No Content
of/ping
response code. Indeed, Google Cloud Plateformhttp health-checks
only accept200 OK
. With this PR, you'll be able to control what response code of/ping
you want/need to have, from the config file, usingdefault-ping-response
.Thank you guys for this great tool!