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

when endpoint discovery is not used, adding an endpoint fails #212

Open
woodsaj opened this issue Sep 7, 2018 · 3 comments
Open

when endpoint discovery is not used, adding an endpoint fails #212

woodsaj opened this issue Sep 7, 2018 · 3 comments

Comments

@woodsaj
Copy link
Contributor

woodsaj commented Sep 7, 2018

No description provided.

@woodsaj woodsaj changed the title when endpoint discovery is skipped, adding an endpoint fails when endpoint discovery is not used, adding an endpoint fails Dec 17, 2018
@woodsaj
Copy link
Contributor Author

woodsaj commented Dec 17, 2018

If endpoint discover is skipped or fails (eg due to not using a hostname) then adding a check fails.
No error is reported back to the user, clicking the "Add" button doesnt do anything.

Looking at the developer tools, the following is sent to /api/v2/endpoints

{"tags":["test"],"name":"foo blah","checks":[{"enabled":true,"frequency":10,"route":{"type":"byIds","config":{"ids":[87,89,949]}},"settings":{"hostname":"grafana.com","timeout":5},"healthSettings":{"num_collectors":2,"steps":3}}]}

The response is:

{"meta":{"code":400,"message":"unknown check type. ","type":"error"},"body":null}

So the issue looks to be due to individual check defaults not being set.
ie, after https://github.com/raintank/worldping-app/blob/master/src/components/endpoint/endpoint_config.js#L471
we need to

this.checks["http"] = defaultCheck("http");
this.checks["https"] = defaultCheck("https");
this.checks["ping"] = defaultCheck("ping");
this.checks["dns"] = defaultCheck("dns");

@luizferreira094
Copy link

+1

@luizferreira094
Copy link

Having the same issue here,
I'm trying to create an endpoint for monitoring with my internal probe, and i get the same error, when trying to apply the config.
PS: Tried in all configs (Ping, DNS, HTTP and HTTPS)

WorldPing version: 1.2.6
Grafana version: v6.1.3

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