fix: プロトコルを指定した場合一部の計測が指定されたプロトコルを使用しない問題を修正
docker-ci / docker (push) Successful in 1m10s
Details
docker-ci / docker (push) Successful in 1m10s
Details
This commit is contained in:
parent
b94aa5e9aa
commit
8054429f40
|
@ -79,7 +79,7 @@ func collectPing() {
|
|||
time.Sleep(5 * time.Second)
|
||||
var buf = bytes.NewBuffer([]byte(`{}`))
|
||||
start := time.Now()
|
||||
resp, err := http.Post("https://"+endpoint+"/api/ping", "application/json", buf)
|
||||
resp, err := http.Post(protocol+"://"+endpoint+"/api/ping", "application/json", buf)
|
||||
if err != nil {
|
||||
logrus.WithField("type", "ping").Warning(err)
|
||||
continue
|
||||
|
@ -132,7 +132,7 @@ type OnlineUsers struct {
|
|||
func collectOnlineUsers() {
|
||||
for {
|
||||
time.Sleep(1 * time.Minute)
|
||||
response, err := http.Get("https://" + endpoint + "/api/get-online-users-count")
|
||||
response, err := http.Get(protocol + "://" + endpoint + "/api/get-online-users-count")
|
||||
if err != nil {
|
||||
logrus.WithField("type", "online-users").Warning(err)
|
||||
continue
|
||||
|
|
Loading…
Reference in New Issue