Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not log metric #117

Open
jvanst opened this issue Sep 18, 2019 · 1 comment
Open

Could not log metric #117

jvanst opened this issue Sep 18, 2019 · 1 comment

Comments

@jvanst
Copy link

jvanst commented Sep 18, 2019

Hi all,

I am having issues logging a metric, and I have exhausted all my resources. Could someone please point me in the right direction?

Here is the cachet-monitor log file:

time="2019-09-17T23:47:00-04:00" level=info msg="Pinging cachet"
time="2019-09-17T23:47:00-04:00" level=info msg="Ping OK"
time="2019-09-17T23:47:00-04:00" level=info msg="Starting Monitor #0: "
time="2019-09-17T23:47:00-04:00" level=info msg="Features: \n - Type: http\n - Name: authentication\n - Method: GET"
time="2019-09-17T23:48:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:48:01 UTC"
time="2019-09-17T23:48:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:49:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:49:01 UTC"
time="2019-09-17T23:49:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:50:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:50:01 UTC"
time="2019-09-17T23:50:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:51:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:51:01 UTC"
time="2019-09-17T23:51:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:52:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:52:01 UTC"
time="2019-09-17T23:52:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:53:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:53:01 UTC"
time="2019-09-17T23:53:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:54:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:54:01 UTC"
time="2019-09-17T23:54:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:55:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:55:01 UTC"
time="2019-09-17T23:55:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:56:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:56:01 UTC"
time="2019-09-17T23:56:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"
time="2019-09-17T23:57:01-04:00" level=warning msg="authentication is now saturated"
time="2019-09-17T23:57:01-04:00" level=info msg="monitor is up" monitor=authentication time="Tuesday, 17-Sep-19 23:57:01 UTC"
time="2019-09-17T23:57:01-04:00" level=warning msg="Could not log metric! ID: 2, err: <nil>"

Here is my cachet-monitor config:

api:
  url: "https://myapi.com/api/v1"
  token: apikey
  insecure: false
date_format: "Monday, 02-Jan-06 15:04:05 UTC"
monitors:
  - name: authentication
    target: https://google.com
    strict: true
    method: GET
    metric_id: 2
    interval: 60
    timeout: 10
    threshold: 80
    expected_status_code: 200

With a curl request to https://myapi.com/api/v1/metrics/ I can see my current metrics:

{ 
   "meta":{ 
      "pagination":{ 
         "total":1,
         "count":1,
         "per_page":20,
         "current_page":1,
         "total_pages":1,
         "links":{ 
            "next_page":null,
            "previous_page":null
         }
      }
   },
   "data":[ 
      { 
         "id":2,
         "name":"Latency",
         "suffix":"LAG",
         "description":"",
         "default_value":0,
         "calc_type":1,
         "display_chart":true,
         "places":1,
         "default_view":1,
         "threshold":5,
         "order":0,
         "visible":1,
         "created_at":"2019-09-18 03:41:40",
         "updated_at":"2019-09-18 03:51:35",
         "default_view_name":"Last 12 Hours"
      }
   ]
}
@IonVillarreal
Copy link

How did you go ? could you fix it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants