Skip to content

Commit ee58ab6

Browse files
authored
Merge branch 'master' into agent-from-xml
2 parents b61de4f + d8f2298 commit ee58ab6

File tree

125 files changed

+1454
-1162
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

125 files changed

+1454
-1162
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ The changelog generator relies on the presence of the upgrade guidelines section
8787
- [ ] There is automated testing or an explanation as to why this change has no tests.
8888
- [ ] New public classes, fields, and methods are annotated with `@Restricted` or have `@since TODO` Javadocs, as appropriate.
8989
- [ ] New deprecations are annotated with `@Deprecated(since = "TODO")` or `@Deprecated(forRemoval = true, since = "TODO")`, if applicable.
90-
- [ ] New or substantially changed JavaScript is not defined inline and does not call `eval` to ease future introduction of Content Security Policy (CSP) directives (see [documentation](https://www.jenkins.io/doc/developer/security/csp/)).
90+
- [ ] UI changes do not introduce regressions when enforcing the current default rules of [Content Security Policy Plugin](https://plugins.jenkins.io/csp/). In particular, new or substantially changed JavaScript is not defined inline and does not call `eval` to ease future introduction of Content Security Policy (CSP) directives (see [documentation](https://www.jenkins.io/doc/developer/security/csp/)).
9191
- [ ] For dependency updates, there are links to external changelogs and, if possible, full differentials.
9292
- [ ] For new APIs and extension points, there is a link to at least one consumer.
9393

.github/workflows/changelog.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
env:
3636
GITHUB_AUTH: github-actions:${{ secrets.GITHUB_TOKEN }}
3737
- name: Upload Changelog YAML
38-
uses: actions/upload-artifact@v4
38+
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
3939
with:
4040
name: changelog.yaml
4141
path: changelog.yaml

.github/workflows/publish-release-artifact.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
steps:
1919
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2020
- name: Set up JDK 21
21-
uses: actions/setup-java@ead9eaa3cfe0b0fc2fa749519ae09c3d4f4080b0 #v 5.0.0
21+
uses: actions/setup-java@de5a937a1dc73fbc1a67d7d1aa4bebc1082f3190 #v 5.0.0
2222
with:
2323
distribution: "temurin"
2424
java-version: 21
@@ -74,7 +74,7 @@ jobs:
7474
wget -q https://get.jenkins.io/${REPO}/${PROJECT_VERSION}/${FILE_NAME}
7575
- name: Upload Release Asset
7676
id: upload-war
77-
uses: softprops/action-gh-release@6da8fa9354ddfdc4aeace5fc48d7f679b5214090 # v2.4.1
77+
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
7878
env:
7979
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8080
with:
@@ -109,7 +109,7 @@ jobs:
109109
- name: Upload Release Asset
110110
id: upload-deb
111111
if: always()
112-
uses: softprops/action-gh-release@6da8fa9354ddfdc4aeace5fc48d7f679b5214090 # v2.4.1
112+
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
113113
env:
114114
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
115115
with:
@@ -145,7 +145,7 @@ jobs:
145145
- name: Upload Release Asset
146146
id: upload-rpm
147147
if: always()
148-
uses: softprops/action-gh-release@6da8fa9354ddfdc4aeace5fc48d7f679b5214090 # v2.4.1
148+
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
149149
env:
150150
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
151151
with:
@@ -181,7 +181,7 @@ jobs:
181181
- name: Upload Release Asset
182182
id: upload-msi
183183
if: always()
184-
uses: softprops/action-gh-release@6da8fa9354ddfdc4aeace5fc48d7f679b5214090 # v2.4.1
184+
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
185185
env:
186186
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
187187
with:
@@ -217,7 +217,7 @@ jobs:
217217
- name: Upload Release Asset
218218
id: upload-suse-rpm
219219
if: always()
220-
uses: softprops/action-gh-release@6da8fa9354ddfdc4aeace5fc48d7f679b5214090 # v2.4.1
220+
uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2.4.2
221221
env:
222222
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
223223
with:

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ axes.values().combinations {
218218

219219
def athAxes = [
220220
platforms: ['linux'],
221-
jdks: [17],
221+
jdks: [21],
222222
browsers: ['firefox'],
223223
]
224224
athAxes.values().combinations {

ath.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ set -o xtrace
66
cd "$(dirname "$0")"
77

88
# https://github.com/jenkinsci/acceptance-test-harness/releases
9-
export ATH_VERSION=6388.v40780b_42e87e
9+
export ATH_VERSION=6446.v64eb_f0dfb_26d
1010

1111
if [[ $# -eq 0 ]]; then
12-
export JDK=17
12+
export JDK=21
1313
export BROWSER=firefox
1414
else
1515
export JDK=$1

bom/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ THE SOFTWARE.
109109
<dependency>
110110
<groupId>commons-codec</groupId>
111111
<artifactId>commons-codec</artifactId>
112-
<version>1.19.0</version>
112+
<version>1.20.0</version>
113113
</dependency>
114114
<dependency>
115115
<groupId>commons-collections</groupId>

core/src/main/java/hudson/FilePath.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -718,10 +718,14 @@ private static void unzip(File dir, File zipFile) throws IOException {
718718
int mode = e.getUnixMode();
719719
if (mode != 0) // Ant returns 0 if the archive doesn't record the access mode
720720
target.chmod(mode);
721-
} catch (InterruptedException ex) {
721+
} catch (InterruptedException | NoSuchFileException ex) {
722722
LOGGER.log(Level.WARNING, "unable to set permissions", ex);
723723
}
724-
Files.setLastModifiedTime(Util.fileToPath(f), e.getLastModifiedTime());
724+
try {
725+
Files.setLastModifiedTime(Util.fileToPath(f), e.getLastModifiedTime());
726+
} catch (NoSuchFileException ex) {
727+
LOGGER.log(Level.WARNING, "unable to set last modified time", ex);
728+
}
725729
}
726730
}
727731
}

core/src/main/java/hudson/console/AnnotatedLargeText.java

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -241,8 +241,10 @@ public long writeRawLogTo(long start, OutputStream out) throws IOException {
241241

242242
@CheckReturnValue
243243
public long writeHtmlTo(long start, Writer w) throws IOException {
244+
StaplerRequest2 req = Stapler.getCurrentRequest2();
245+
StaplerResponse2 rsp = Stapler.getCurrentResponse2();
244246
ConsoleAnnotationOutputStream<T> caw = new ConsoleAnnotationOutputStream<>(
245-
w, createAnnotator(Stapler.getCurrentRequest2()), context, charset);
247+
w, createAnnotator(req), context, charset);
246248
long r = super.writeLogTo(start, caw);
247249

248250
ByteArrayOutputStream baos = new ByteArrayOutputStream();
@@ -251,9 +253,12 @@ public long writeHtmlTo(long start, Writer w) throws IOException {
251253
oos.writeLong(System.currentTimeMillis()); // send timestamp to prevent a replay attack
252254
oos.writeObject(caw.getConsoleAnnotator());
253255
oos.close();
254-
StaplerResponse2 rsp = Stapler.getCurrentResponse2();
255-
if (rsp != null)
256-
rsp.setHeader("X-ConsoleAnnotator", Base64.getEncoder().encodeToString(baos.toByteArray()));
256+
String state = Base64.getEncoder().encodeToString(baos.toByteArray());
257+
if (isStreamingRequest(req)) {
258+
putStreamingMeta("consoleAnnotator", state);
259+
} else if (rsp != null) {
260+
rsp.setHeader("X-ConsoleAnnotator", state);
261+
}
257262
return r;
258263
}
259264

core/src/main/java/hudson/console/ConsoleAnnotationOutputStream.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public class ConsoleAnnotationOutputStream<T> extends LineTransformationOutputSt
5757
/**
5858
* Reused buffer that stores char representation of a single line.
5959
*/
60-
private final LineBuffer line = new LineBuffer(256);
60+
private final LineBuffer line = new LineBuffer(4096);
6161
/**
6262
* {@link OutputStream} that writes to {@link #line}.
6363
*/
@@ -173,8 +173,8 @@ private LineBuffer(int initialSize) {
173173

174174
private void reset() {
175175
StringBuffer buf = getStringBuffer();
176-
if (buf.length() > 4096)
177-
out = new StringWriter(256);
176+
if (buf.length() > 64 * 1024)
177+
out = new StringWriter(4096);
178178
else
179179
buf.setLength(0);
180180
}

core/src/main/java/hudson/model/Actionable.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,10 +138,11 @@ private <T> Collection<? extends Action> createFor(TransientActionFactory<T> taf
138138
*/
139139
@NonNull
140140
public <T extends Action> List<T> getActions(Class<T> type) {
141-
List<T> _actions = Util.filter(getActions(), type);
141+
List<T> _actions = new ArrayList<>();
142142
for (TransientActionFactory<?> taf : TransientActionFactory.factoriesFor(getClass(), type)) {
143143
_actions.addAll(Util.filter(createFor(taf), type));
144144
}
145+
_actions.addAll(Util.filter(getActions(), type));
145146
return Collections.unmodifiableList(_actions);
146147
}
147148

0 commit comments

Comments
 (0)