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

ZabbixSender Issues #15

Open
wittling opened this issue Oct 27, 2017 · 0 comments
Open

ZabbixSender Issues #15

wittling opened this issue Oct 27, 2017 · 0 comments

Comments

@wittling
Copy link

Couple of things here to look into. First, the call to getPost() will throw an Exception if the isAvailable() flag is false. And the first time this is called (for authentication purposes), this flag is not set. Right below this code that throws the exception, is a "checkAuthentication" call. So I am thinking that the initial call to check the flag and throw the MonitoringException can be removed.

Also - when the response comes back, it is possible to get exceptions from the json parser of the response (especially when API versions change). If this were to happen, it would not be an auth rejection. The code here probably needs to do more work to distinguish between "invalid credentials" (API is up and running and responded with an auth failure) and "other" errors - like for example the API not being available (web server stopped), or some kind of JSON parsing error (looking for a json element that may not be in the response due to an API change on the server side).

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

1 participant