13828 Commits

Author SHA1 Message Date
Alexander A. Klimov
449e5c026d GHA: drop EOL EL7 2024-08-06 10:59:34 +02:00
Alexander Aleksandrovič Klimov
6a7b440cfd
Merge pull request #10084 from Icinga/win2143
Bump Windows deps
2024-06-12 13:03:05 +02:00
Alexander A. Klimov
d856cab9d9 Bump OpenSSL shipped for Windows to v3.0.14 2024-06-12 10:25:11 +02:00
Alexander A. Klimov
3a3454e1b5 Bump Boost shipped for Windows to v1.85
Note: For doc/21-development.md use:

perl -pi -e 's/(boost[-\w]*?1[-_]?)84/${1}85/g' doc/21-development.md
2024-06-12 10:25:11 +02:00
Julian Brost
5243241b33 HttpServerConnection: use exceptions for error handling
When a HTTP connection dies prematurely while the response is sent,
`http::async_write()` sets the error code to something like broken pipe for
example. When calling `async_flush()` afterwards, it sometimes happens that
this never returns. This results in a resource leak as the coroutine isn't
cleaned up. This commit makes the individual functions throw exceptions instead
of silently ignoring the errors, resulting in the function terminating early
and also resulting in an error being logged as well.
2024-06-10 13:19:46 +02:00
Alexander A. Klimov
8ff7121e93 ApiListener#ListenerCoroutineProc(): get remote endpoint ASAP for logging
On incoming connection timeout we log the remote endpoint which isn't
available if it was already disconnected - an exception is thrown.  Get it
as long as we're still connected not to lose it, nor to get an exception.
2024-06-10 13:19:46 +02:00
Yonas Habteab
dfffb29c81 ApiListener: Reset m_LogMessageCount when rotating
Closing and re-opening that very same log file shouldn't reset the
counter, otherwise some log files may exceed the max limit per file as
their offset indicator is reset each time they are re-opened.
2024-06-10 13:19:46 +02:00
Yonas Habteab
ed8156db28 Drop redundant CpuBoundWork usage in JsonRpcConnection::Disconnect()
Although there is locking involved here, it shoudln't take too long for
the thread to actually acquire it, since there aren't that many threads
dealing with endpoint clients concurrently. It's just wasting pointless
time trying to obtain a CPU slot.
2024-06-10 13:19:46 +02:00
Yonas Habteab
e66f8567de HttpServerConnection: Drop superfluous CpuBoundWork usage 2024-06-10 13:19:46 +02:00
Yonas Habteab
599a54aae0 EventsHandler: Drop superfluous CpuBoundWork usage 2024-06-10 13:19:46 +02:00
Yonas Habteab
0f2478fb28 Drop redundant CpuBoundWork usages in lib/remote 2024-06-10 13:19:46 +02:00
Eric Lippmann
771070549c IoEngine: Always log coroutine exception diagnostics
While analyzing a possible memory leak, we encountered several coroutine
exception messages, which unfortunately do not provide any information
about what exactly went wrong, as exception diagnostics were previously
only logged at the notice level.
2024-06-10 13:19:46 +02:00
Alexander Aleksandrovič Klimov
62a92c10b5
Merge pull request #10075 from Icinga/gha2143
Update GitHub actions
2024-06-10 10:59:37 +02:00
Alexander Aleksandrovič Klimov
39be31c305 CMakeLists.txt: set(CPACK_WIX_INSTALL_SCOPE NONE)
to stick to CMake pre-v3.29 behavior. CMake v3.29 introduces CPACK_WIX_INSTALL_SCOPE. Its default conflicts with the ALLUSERS property in our icinga-installer/icinga2.wixpatch.cmake.
2024-06-07 15:50:54 +02:00
Alexander Aleksandrovič Klimov
8b6c73166c GHA: Docker: don't run on support/* branches
PRs to them are already covered and we don't need support* image tags.
2024-06-07 15:49:10 +02:00
Alexander Aleksandrovič Klimov
469bc7e9fd GHA: drop Debian 10
which will be EOL in 2.5 months.
2024-06-07 15:49:10 +02:00
Alexander Aleksandrovič Klimov
00d77443a0 GHA: add upcoming Fedora 40 2024-06-07 15:49:10 +02:00
Alexander Aleksandrovič Klimov
a00e57c06b GHA: add upcoming Ubuntu 24.04 2024-06-07 15:49:10 +02:00
Alexander A. Klimov
6ba41b01e4 GHA AUTHORS check: handle PRs from forks
where the ref names differ compared to own PRs. Instead refer to the base branch and the head branch via generic HEAD^<parent number> where HEAD is a merge commit.
2024-06-07 15:49:10 +02:00
Alexander Aleksandrovič Klimov
fc4ff8b7af
Merge pull request #9971 from Icinga/2142
Icinga 2.14.2
v2.14.2
2024-01-17 19:49:18 +01:00
Alexander Aleksandrovič Klimov
d6a2528af5
Merge pull request #9970 from Icinga/2142backport
Log HTTP request processing time and ship Boost 1.84 on Windows
2024-01-17 19:11:54 +01:00
Alexander Aleksandrovič Klimov
37d9ae752f
Merge pull request #9969 from Icinga/influx-disk-9948-214
Influx DB: truncate timestamps to whole seconds to save disk space
2024-01-17 19:04:39 +01:00
Alexander A. Klimov
5bb2024976 Icinga 2.14.2 2024-01-17 17:53:00 +01:00
Alexander A. Klimov
fd5f3c57d9 Bump Boost shipped for Windows to v1.84
Note: For doc/21-development.md use:

perl -pi -e 's/(boost[-\w]*?1[-_]?)83/${1}84/g' doc/21-development.md

(cherry picked from commit 77313d751c8ae78f0114f62c248455bfadf47041)
2024-01-17 17:11:10 +01:00
Alexander A. Klimov
6817a148bd HttpServerConnection: log request processing time as well
(cherry picked from commit b6874cc8d40336fbc9eb6c60e9d1be9313365a58)
2024-01-17 17:11:10 +01:00
Alexander A. Klimov
3a274ac305 Revert "Influx DB: don't unneccessarily truncate timestamps to whole seconds"
This reverts commit eaa3cd83adf860732b955a77b8f5fca7e30c65c2.

(cherry picked from commit cc9db3756fa68b303c13258cbb1500d691b1b770)
2024-01-17 17:07:13 +01:00
Alexander A. Klimov
1b5bc20e50 Revert "Remove no-op InfluxDB URL param"
This reverts commit 21f548d3c07189c6a413cf88c2b60cc9ada73497.

(cherry picked from commit fc5b1178c643d37dfa1ce8512966b95961bac18f)
2024-01-17 17:07:13 +01:00
Alexander Aleksandrovič Klimov
f2c83fbbf2
Merge pull request #9950 from Icinga/probot/sync-changelog/support/2.14/9fa41f3b4fbae83d4ca5bbfce4771031b6bd1fa4
CHANGELOG.md: add v2.13.9
v2.14.1
2023-12-20 17:30:01 +01:00
Alexander A. Klimov
b85cd98eb1 CHANGELOG.md: add v2.13.9 2023-12-20 16:27:56 +00:00
Alexander Aleksandrovič Klimov
9fa41f3b4f
Merge pull request #9940 from Icinga/2141
Icinga 2.14.1
2023-12-20 17:27:43 +01:00
Alexander Aleksandrovič Klimov
61d190f892
Merge pull request #9947 from Icinga/2141morebackport
Truncate too big notification command lines, fix GelfWriter deadlock and return 503 in /v1/console/* during reload
2023-12-20 12:44:07 +01:00
Alexander Aleksandrovič Klimov
3ddbbebc63
Merge pull request #9946 from Icinga/2141backport
Disable TLS renegotiation, bump Windows deps and fix Icinga DB crashes
2023-12-20 12:40:41 +01:00
Alexander A. Klimov
41b692793b Icinga 2.14.1 2023-12-20 10:56:15 +01:00
Alexander A. Klimov
fecb209fe0 GelfWriter: protect m_Stream via m_WorkQueue, not ObjectLock(this)
On shutdown or HA re-connect ConfigObject#SetAuthority(false) is called which
does ObjectLock(this) and ConfigObject#Pause(). GelfWriter#Pause(), with the
above ObjectLock, calls m_WorkQueue.Join(). But items inside that also doing
ObjectLock(this) cause a deadlock.
2023-12-20 10:46:51 +01:00
Mattia Codato
85c5a7c901 Prevent calls to command API while the configuration is reloading.
Fixes #9840
2023-12-20 10:46:51 +01:00
Alexander A. Klimov
0eeac3b385 PluginNotificationTask::ScriptFunc(): on Linux truncate output and comment
not to run into an exec(3) error E2BIG due to a too long argument.
This sends a notification with truncated output instead of not sending.
2023-12-20 10:46:51 +01:00
Alexander A. Klimov
7efdae6a53 IcingaDB#SendConfigDelete(): fix missing nullptr check before deref 2023-12-20 10:30:01 +01:00
Alexander A. Klimov
79efda7a14 Icinga DB downtime history: provide cancel_time where has_been_cancelled may be 1
The table sla_history_downtime requires a downtime_end.
The Go daemon takes the cancel_time if has_been_cancelled is 1.
So we must supply a cancel_time whereever has_been_cancelled is 1.
Otherwise the Go daemon can't process some entries.
2023-12-20 10:30:01 +01:00
Alexander A. Klimov
8c9f3ede4a Bump OpenSSL shipped for Windows to v3.0.12 2023-12-20 10:14:00 +01:00
Alexander A. Klimov
4547c1e5a3 Bump Boost shipped for Windows to v1.83
Note: For doc/21-development.md use:

perl -pi -e 's/(boost[-\w]*?1[-_]?)82/${1}83/g' doc/21-development.md
2023-12-20 10:14:00 +01:00
Alexander A. Klimov
ec77b6f1e3 Disable TLS renegotiation
The API doesn't need it and a customer's security scanner
is afraid of a potential DoS attack vector.
2023-12-20 10:14:00 +01:00
Alexander Aleksandrovič Klimov
bbb45894dd
Merge pull request #9944 from Icinga/targeted-api-filter-214
FilterUtility::GetFilterTargets(): don't run filter for specific object(s) for all objects
2023-12-19 17:40:59 +01:00
Alexander Aleksandrovič Klimov
b55a14d536
Merge pull request #9921 from Icinga/doc2141
Update documentation
2023-12-19 17:01:31 +01:00
Alexander A. Klimov
03aa5adb7a Tests: config_apply/gettargetservices_*: use BOOST_CHECK_EQUAL_COLLECTIONS()
to show the value diff in case of mismatch.

Co-authored-by: Yonas Habteab <yonas.habteab@icinga.com>
2023-12-19 15:19:20 +01:00
Alexander A. Klimov
b99db24100 Test ApplyRule::GetTarget*s() 2023-12-19 15:19:20 +01:00
Alexander A. Klimov
bcbb1aee52 FilterUtility::GetFilterTargets(): don't run filter for specific object(s) for all objects 2023-12-19 15:19:20 +01:00
Alexander A. Klimov
60b7e96adc ApplyRule::GetTarget*s(): support constant strings from variables
in addition to literal strings. This is for sandboxed filters with some
variables pre-set by the caller. They're "constant" in that scope, too.
2023-12-19 15:19:20 +01:00
Alexander A. Klimov
8248fa110c Introduce DictExpression#GetExpressions() 2023-12-19 15:19:20 +01:00
Alexander A. Klimov
5c10bad86f Introduce Dictionary#GetRef() 2023-12-19 15:19:20 +01:00
Alexander Aleksandrovič Klimov
5059d0f8b0
Merge pull request #9933 from Icinga/renew-the-ca-9890-214
ApiListener#Start(): auto-renew CA on its owner
2023-12-19 15:15:00 +01:00