-
-
Notifications
You must be signed in to change notification settings - Fork 8.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[JENKINS-72371] rework node monitor configuration (#8719)
* [JENKINS-72371] rework node monitor configuration This PR reworks the way node monitors are configured. It ensures that also monitors which are set to ignored, can be configured. Previously, there was a checkbox before each monitor, where the behaviour was not totally clear. It meant that the monitor is ignored but still collecting data and not disabled as one might think. But when the monitor was disabled any configuration was lost and default values were used. * improve description * fix formatting * add since
- Loading branch information
1 parent
7a2e389
commit 7258cad
Showing
15 changed files
with
115 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
core/src/main/resources/hudson/model/ComputerSet/configure.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
description=Jenkins monitors each attached node for disk space, free temp space, free swap, clock time/sync, and response time. Nodes will be taken offline if any of these values go outside of the configured threshold. | ||
description=Jenkins monitors each attached node for various metrics like free disk space, free temp space, free swap, clock time/sync, response time and others provided by plugins. \ | ||
Some of these monitors are able to mark nodes temporarily offline, when the values go outside the configured thresholds. |
2 changes: 1 addition & 1 deletion
2
core/src/main/resources/hudson/node_monitors/ArchitectureMonitor/help.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<div> | ||
This monitor just shows the architecture of the agent for your information. It | ||
never marks the agent offline. | ||
never marks an agent offline. | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
core/src/main/resources/hudson/node_monitors/NodeMonitor/configure.jelly
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?jelly escape-by-default='true'?> | ||
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:f="/lib/form"> | ||
<j:set var="help" value="${descriptor.helpFile}"/> | ||
<div class="jenkins-form-label help-sibling tr"> | ||
${descriptor.displayName} | ||
<f:helpLink url="${help}" featureName="${descriptor.displayName}"/> | ||
</div> | ||
<f:helpArea /> | ||
<div class="optionalBlock-container jenkins-form-item"> | ||
<div class="form-container"> | ||
<j:if test="${descriptor.canTakeOffline()}"> | ||
<f:entry title="${%Don't mark agents temporarily offline}" field="ignored"> | ||
<f:checkbox checked="${instance.ignored}" /> | ||
</f:entry> | ||
</j:if> | ||
<j:if test="${!descriptor.canTakeOffline()}"> | ||
<f:invisibleEntry> | ||
<f:checkbox name="ignored" checked="false" /> | ||
</f:invisibleEntry> | ||
</j:if> | ||
<st:include page="config.jelly" class="${descriptor.clazz}" optional="true"/> | ||
</div> | ||
</div> | ||
</j:jelly> |
7 changes: 7 additions & 0 deletions
7
core/src/main/resources/hudson/node_monitors/NodeMonitor/help-ignored.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<div> | ||
When checked the agent will | ||
<i>not</i> | ||
be marked temporarily offline in case the monitor detects a problem. But the | ||
monitor will still run to collect data and the corresponding field will be | ||
highlighted in case of a problem. | ||
</div> |
3 changes: 1 addition & 2 deletions
3
core/src/main/resources/hudson/node_monitors/ResponseTimeMonitor/help.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
core/src/main/resources/hudson/node_monitors/SwapSpaceMonitor/help.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<div> | ||
This monitors the available virtual memory (also known as | ||
<code>swap space</code> | ||
). | ||
<p>The exact definition of swap space is platform dependent.</p> | ||
<ul> | ||
<li> | ||
On Windows this is the available space of the page file. As Windows can | ||
automatically increase the page file size, this value doesn't mean much. | ||
</li> | ||
<li> | ||
On Linux this value is retrieved from | ||
<code>/proc/meminfo</code> | ||
. | ||
</li> | ||
<li> | ||
For other Unix systems, the value is obtained from the | ||
<code>top</code> | ||
command. | ||
</li> | ||
</ul> | ||
</div> |