version up, default GET http method, metrics

pull/659/head
hunterlong 2020-06-12 18:23:30 -07:00
parent 95e294f553
commit e27b8de55e
4 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,6 @@
# 0.90.49 (06-12-2020)
- Added additional prometheus /metrics for better debugging
# 0.90.48 (06-11-2020)
- Modified shutdown routine to make command exit with code 0
- Modified install.sh for correct installation

View File

@ -109,6 +109,7 @@ func Samples() error {
s6 := &Service{
Name: "Private Service",
Domain: "https://push.statping.com",
Method: "GET",
Interval: 30,
Type: "http",
Timeout: 120,

View File

@ -191,6 +191,9 @@ func DurationReadable(d time.Duration) string {
func HttpRequest(url, method string, content interface{}, headers []string, body io.Reader, timeout time.Duration, verifySSL bool, customTLS *tls.Config) ([]byte, *http.Response, error) {
var err error
var req *http.Request
if method == "" {
method = "GET"
}
t1 := Now()
if req, err = http.NewRequest(method, url, body); err != nil {
return nil, nil, err

View File

@ -1 +1 @@
0.90.48
0.90.49