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

Backporting for 2.426.1 #8658

Merged
merged 8 commits into from
Oct 31, 2023
2 changes: 1 addition & 1 deletion core/src/main/java/hudson/model/Slave.java
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ protected Slave(@NonNull String name, String nodeDescription, String remoteFS, i
this.numExecutors = numExecutors;
this.mode = mode;
this.remoteFS = Util.fixNull(remoteFS).trim();
this.labelAtomSet = Collections.unmodifiableSet(Label.parse(labelString));
_setLabelString(labelString);
this.launcher = launcher;
this.retentionStrategy = retentionStrategy;
getAssignedLabels(); // compute labels now
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ THE SOFTWARE.
<changelog.url>https://www.jenkins.io/changelog</changelog.url>

<!-- Bundled Remoting version -->
<remoting.version>3148.v532a_7e715ee3</remoting.version>
<remoting.version>3160.vd76b_9ddd10cc</remoting.version>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for pointing to that difference! I had missed that there is an additional bug fix that is included in remoting 3160 as delivered in Jenkins 2.428. The additional fix is JENKINS-65368 Remoting agent.jar does not work behind proxy. I've labeled that bug report as 2.426.1-fixed in Jira and included it in the pull request description

<!-- Minimum Remoting version, which is tested for API compatibility -->
<remoting.minimum.supported.version>4.13</remoting.minimum.supported.version>

Expand All @@ -98,7 +98,7 @@ THE SOFTWARE.
<bridge-method-injector.version>1.29</bridge-method-injector.version>
<spotless.check.skip>false</spotless.check.skip>
<!-- Make sure to keep the jetty-maven-plugin version in war/pom.xml in sync with the Jetty release in Winstone: -->
<winstone.version>6.13</winstone.version>
<winstone.version>6.14</winstone.version>
</properties>

<!--
Expand Down
2 changes: 1 addition & 1 deletion war/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -636,7 +636,7 @@ THE SOFTWARE.
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>10.0.16</version>
<version>10.0.17</version>
<configuration>
<!--
Reload webapp when you hit ENTER. (See JETTY-282 for more)
Expand Down
37 changes: 18 additions & 19 deletions war/src/main/js/components/dropdowns/hetero-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,23 @@ function generateHandles() {
});
}

function convertInputsToButtons(e) {
let oldInputs = e.querySelectorAll("INPUT.hetero-list-add");
oldInputs.forEach((oldbtn) => {
let btn = document.createElement("button");
btn.setAttribute("type", "button");
btn.classList.add("hetero-list-add", "jenkins-button");
btn.innerText = oldbtn.getAttribute("value");
if (oldbtn.hasAttribute("suffix")) {
btn.setAttribute("suffix", oldbtn.getAttribute("suffix"));
}
let chevron = createElementFromHtml(Symbols.CHEVRON_DOWN);
btn.appendChild(chevron);
oldbtn.parentNode.appendChild(btn);
oldbtn.remove();
});
}

function generateButtons() {
behaviorShim.specify(
"DIV.hetero-list-container",
Expand All @@ -31,26 +48,8 @@ function generateButtons() {
return;
}

convertInputsToButtons(e);
let btn = Array.from(e.querySelectorAll("BUTTON.hetero-list-add")).pop();
if (!btn) {
let oldbtn = Array.from(
e.querySelectorAll("INPUT.hetero-list-add"),
).pop();
if (!oldbtn) {
return;
}
btn = document.createElement("button");
btn.setAttribute("type", "button");
btn.classList.add("hetero-list-add", "jenkins-button");
btn.innerText = oldbtn.getAttribute("value");
if (oldbtn.hasAttribute("suffix")) {
btn.setAttribute("suffix", oldbtn.getAttribute("suffix"));
}
let chevron = createElementFromHtml(Symbols.CHEVRON_DOWN);
btn.appendChild(chevron);
oldbtn.parentNode.appendChild(btn);
oldbtn.remove();
}

let prototypes = e.lastElementChild;
while (!prototypes.classList.contains("prototypes")) {
Expand Down
12 changes: 1 addition & 11 deletions war/src/main/webapp/scripts/hudson-behavior.js
Original file line number Diff line number Diff line change
Expand Up @@ -639,17 +639,7 @@ function updateValidationArea(validationArea, content) {
// Only change content if different, causes an unnecessary animation otherwise
if (validationArea.innerHTML !== content) {
validationArea.innerHTML = content;
validationArea.style.height =
validationArea.children[0].offsetHeight + "px";

// Only include the notice in the validation-error-area, move all other elements out
if (validationArea.children.length > 1) {
Array.from(validationArea.children)
.slice(1)
.forEach((element) => {
validationArea.after(element);
});
}
validationArea.style.height = "auto";

Behaviour.applySubtree(validationArea);
// For errors with additional details, apply the subtree to the expandable details pane
Expand Down
Loading