Commit Graph

161 Commits

Author SHA1 Message Date
Michael Friedrich 55d7da30ca Metrics: Expose problem/handled counts for hosts/services
With the addition of problem/handled as checkable runtime
attributes in #7096 we should also expose them via CIB
into

- icinga check
- /v1/status/CIB
- IcingaApplication runtime macros

This originates from a request by @phil-or at the recent
Icinga meetup in Linz.
2019-08-29 17:04:23 +02:00
Alexander A. Klimov efc7f2cf8d Correct current_concurrent_checks to actually running checks
refs #7416
2019-08-15 13:39:01 +02:00
Michael Friedrich c2e1d023e2
Merge pull request #7421 from Icinga/feature/threadpool-metric
Expose metric current_pending_callbacks
2019-08-15 10:51:31 +02:00
Alexander A. Klimov 448a991404 Expose metric current_pending_callbacks 2019-08-14 17:22:27 +02:00
Michael Friedrich 5b36ff0787 Properly parse the Icinga version for minimum version in the 'icinga' check
fixes #7415
2019-08-14 13:15:05 +02:00
Michael Friedrich 8098f4d54d Improve type logging for notifications 2019-07-16 13:46:16 +02:00
Michael Friedrich 406ecb448c Internal methods must update the 'command' key in the check result
Currently this is `null` which isn't really correct.

As otherwise, it is tremendously hard to figure out which check
command was involved, if you're not looking at the `.check_command`
checkable object.
2019-07-10 10:15:15 +02:00
Michael Friedrich 2acf3a6941 Indicate a warning in the 'icinga' check when cluster stage validation failed
- success: clear the last failed attribute
- failed: populate it with the output and current timestamp

This can be used to highlight this in the 'icinga' check task.
Since 2.9 we don't have problems with circular library dependencies
with just one linked binary, therefore it is safe to include libremote
in libmethods here.
2019-06-19 14:46:11 +02:00
Michael Friedrich 2ba2134eda
Merge pull request #7156 from Icinga/feature/itl-sleep
Implement sleep CheckCommand
2019-05-24 15:42:46 +02:00
htriem 75df3879f2 Implement sleep CheckCommand in memory
Implements a check task with Utility::Sleep and custom var parameter sleep_time (default value: 1s)

refs #6964
2019-05-02 16:24:42 +02:00
Michael Friedrich 1706b297a5 Implement last_notification_result handling for Notification objects 2019-03-28 10:43:35 +01:00
Michael Friedrich 458f997a18 Replace Copyright header with a short version, part II 2019-02-25 15:09:36 +01:00
Michael Friedrich d14a88235d Replace Copyright header with a short version, part I
CLion -> replace in path
2019-02-25 14:48:22 +01:00
Michael Friedrich 3d45d0bcf6 Minor styleguide 2018-10-29 13:45:18 +01:00
Max Rosin 2366df6057 Fix the Icinga2 version check for versions with more than 5 characters
The previous implementation assumed that every version number will have
5 characters. With the release of 2.10.0 this does not work anymore.
The new implementation extracts everything from the second character to
the first dash. This should work as long as the version string is in a
format like 'v2.10.1-8-gaebe6da'.

fixes Icinga#6703
2018-10-19 15:37:32 +02:00
Michael Friedrich eabea68c56 icinga.com: Update config files (ITL, etc.) 2018-10-18 09:37:59 +02:00
Michael Friedrich dea5ec614e icinga.com: Update CMakeLists.txt 2018-10-18 09:35:18 +02:00
Michael Friedrich dab53448bc icinga.com: Update *.{h,c}pp 2018-10-18 09:27:04 +02:00
Michael Friedrich 617925374b Fix that check_timeout was used for Event/Notification commands too
We may add specific timeouts for event/notification commands
later, for now the original timeout inside the EventCommand/NotificationCommand
is used.

fixes #6304
2018-09-28 14:32:57 +02:00
Gunnar Beutner 1a8692d972 Implement support for namespaces 2018-08-13 13:44:31 +02:00
Gunnar Beutner d9c0b6f806 Refactor REGISTER_SCRIPTFUNCTION_* macros 2018-08-13 13:44:31 +02:00
Christopher Schirner b870e84904 Only check lag if connected 2018-07-31 10:41:14 +02:00
Christopher Schirner 35038f72d6 Invert connected check 2018-07-31 10:40:54 +02:00
Michael Friedrich 4a68ed9a5f Ensure that icinga_min_version parameter is optional
Seen that here: https://github.com/Icinga/icinga2/issues/6319#issuecomment-390195058

refs #5960
refs #3998
2018-05-18 15:11:56 +02:00
Michael Friedrich 5b19784b25 Change log level for failed event command execution
refs #5692
2018-05-11 15:24:37 +02:00
Noah Hilverling d0a97ddf64 Add counter for current concurrent checks to Icinga check
fixes #4939
2018-03-01 15:01:55 +01:00
Jean Flach a71ab1e126 Rename macro RequireNotNull to REQUIRE_NOT_NULL 2018-02-21 13:47:46 +01:00
Noah Hilverling 6bebdf8a87 Add marco RequireNotNull
This is used to fix a number of possible nullptr dereferences
2018-02-21 13:47:46 +01:00
Michael Friedrich bdeba19a00 Add more metrics and details to built-in 'random' check
This helps us with demo graphs in Graphite/InfluxDB as well
as other historical views.

fixes #5787
2018-02-06 16:01:07 +01:00
Noah Hilverling e1e06ce767
Merge pull request #5988 from Icinga/fix/concurrent-checks-limit-cluster
Fix concurrent checks limit while using command_endpoint
2018-02-06 14:13:49 +01:00
Markus Frosch 279e9fbe6c methods: Remove unused clrchecktask feature
fixes #6054
2018-02-01 15:52:12 +01:00
Noah Hilverling 06e381ceea Add metrics about RemoteCheckQueue to Icinga check, API and logs
refs #4841
2018-01-29 16:07:35 +01:00
Gunnar Beutner 94e6be1a65 Remove unused includes 2018-01-22 09:52:29 +01:00
Jean Flach 1da6b2c883 Fix whitespaces in CMakeLists files
Uses 2 space indentation as standard
2018-01-19 09:19:40 +01:00
Michael Friedrich 88f740b13c Move the endpoint list into a new line for the 'cluster' check
If you have many satellites/clients, the list view in Icinga Web 2
will get overly long. Moving the list for connected/not connected
endpoints into a new line makes this check more beautiful.

fixes #5444
2018-01-18 15:43:01 +01:00
Gunnar Beutner 2a9dceb367 Use CMake object libraries for our libs 2018-01-17 04:28:21 +01:00
Gunnar Beutner c2fb9fe226 Use initializer lists for arrays and dictionaries 2018-01-16 12:27:44 +01:00
Michael Friedrich 6c68ef0955 Fix non-unity builds with the icinga check
refs #5958
2018-01-12 11:04:54 +01:00
Gunnar Beutner e490b3d2d2 Fix macro warning from the icinga check 2018-01-09 09:16:59 +01:00
Michael Friedrich b1aeff7569 Add minimum version check to the built-in icinga command
fixes #3998
2018-01-08 19:44:54 +01:00
Gunnar Beutner e3ad0be769 Apply clang-tidy fix 'modernize-use-auto' 2018-01-04 12:24:57 +01:00
Gunnar Beutner 621eed3f13 Apply clang-tidy fix 'modernize-pass-by-value' 2018-01-04 12:24:57 +01:00
Gunnar Beutner ac155d1dda Apply clang-tidy fix 'modernize-redundant-void-arg' 2018-01-04 12:24:57 +01:00
Gunnar Beutner 75e2473616 Clean up source lists in the CMakeLists.txt files 2018-01-03 11:47:46 +01:00
Gunnar Beutner 90496b5456 Build libraries as static libraries 2018-01-02 23:29:48 +01:00
Michael Insel 158ae2188e Change copyright header for 2018 2018-01-02 12:08:55 +01:00
Jean Flach 2636e6a77a Whitespace fix
What does this change?
* Remove use of spaces for formatting
These could be found by using `grep -r -l -P '^\t+ +[^*]'
* Removal of training whitespaces
* A few lines longer than 120 chars
2017-12-20 14:53:52 +01:00
Gunnar Beutner 1ad83886ac Replace a few more NULLs with nullptr 2017-12-14 15:37:20 +01:00
Gunnar Beutner 75def4b074
Merge pull request #5753 from Icinga/fix/ringbuffer-does-not-get-updated-if-nothing-is-written-5750
Fix that RingBuffer does not get updated and add metrics about communication between endpoints
2017-12-12 11:32:18 +01:00
Noah Hilverling 5519626f84 Add metrics about communication between endpoints
refs #5509
2017-12-11 10:20:25 +01:00