Commit Graph

320 Commits

Author SHA1 Message Date
Basil Crow 7006cded64
[JENKINS-73278] Migrate core from EE 8 to EE 9 (#9672)
Co-authored-by: Kevin Guerroudj <91883215+Kevin-CB@users.noreply.github.com>
Co-authored-by: Daniel Beck <1831569+daniel-beck@users.noreply.github.com>
2024-09-03 14:59:04 -07:00
Basil Crow 53b271283b
Deprecate `hudson.Util#XS_DATETIME_FORMATTER` (#9088)
Co-authored-by: Mark Waite <mark.earl.waite@gmail.com>
2024-03-30 07:29:29 -06:00
Basil Crow f8a6ee542d
Deprecate `Util#RFC822_DATETIME_FORMATTER` (#9085) 2024-03-30 07:23:47 -06:00
Markus Winter d9cbaa006a
[JENKINS-71726] [JENKINS-71727] remove inline javascript (#8313)
* [JENKINS-71727] remove inline javascript

Also JENKINS-71726

* missing id

* fix script tag

Co-authored-by: Kevin Guerroudj <91883215+Kevin-CB@users.noreply.github.com>

---------

Co-authored-by: Kevin Guerroudj <91883215+Kevin-CB@users.noreply.github.com>
Co-authored-by: Mark Waite <mark.earl.waite@gmail.com>
2023-11-20 04:36:12 -07:00
SujathaH 4a262f5e71
Replace MD5 digest with SHA256 while logging payload in Mock class called from tests (#8319) 2023-08-11 17:59:26 +02:00
Basil Crow 8240e0736c
Remove usages of `org.apache.commons.io.output.NullOutputStream` (#8144) 2023-06-16 08:44:01 +01:00
Basil Crow d3417ebec9
Forward compatibility for Commons IO 2.13.0 in `hudson.Util#loadFile` (#8142) 2023-06-15 09:57:18 +02:00
Benoit Lacelle c48728d0f4
Use `String#isEmpty` where possible (#7690) 2023-04-08 08:04:47 -07:00
Daniel Beck b7ca1a87ee
Document at-since for Util#fullEncode (#7086)
Co-authored-by: Daniel Beck <daniel-beck@users.noreply.github.com>
2022-09-12 08:19:08 +01:00
Basil Crow 6b0dc184bf
[JENKINS-67624] `FileAlreadyExistsException` on startup (#7027) 2022-08-24 10:45:13 -07:00
Basil Crow 76e5c98dd3
Use try-with-resources where possible (#6765) 2022-07-04 17:36:33 -07:00
Alex 680aab31fd
Fill in `@since TODO` annotations (#6396) 2022-03-24 23:22:19 -07:00
Stefan Spieker eecfbf2a33
Deprecate `Util.copyFile()` (#6272)
* deprecate copyFile

* Update core/src/main/java/hudson/Util.java

Co-authored-by: Daniel Beck <1831569+daniel-beck@users.noreply.github.com>

Co-authored-by: Daniel Beck <1831569+daniel-beck@users.noreply.github.com>
2022-02-13 20:59:27 +01:00
Basil Crow e27b310065
Enable whitespace-related Checkstyle checks (#6149) 2022-01-03 08:55:03 -08:00
Basil Crow 86dec5a136
Fill in some deprecation TODOs (#6148) 2022-01-01 07:54:19 -08:00
Basil Crow 27646d11e4
[JENKINS-67372] Restore support for symbolic links in the Jenkins home directory (#6059) 2021-12-18 11:17:05 -08:00
Basil Crow 337a6f18a5
Reduce usages of Ant (#6041) 2021-12-11 12:48:18 -08:00
Basil Crow 2ea1148286
Fix `CatchingUnchecked` Error Prone violations (#5950)
Co-authored-by: James Nord <jtnord@users.noreply.github.com>
2021-12-10 09:51:30 -08:00
Basil Crow f29b478983
Fix `UnnecessarilyFullyQualified` Error Prone violations (#5737) 2021-09-20 09:45:37 +01:00
Basil Crow 632033d6ad
Sort imports (#5732) 2021-09-18 09:39:42 +01:00
Basil Crow f12f400a5c
Consistently use `issues.jenkins.io` for issue links (#5724) 2021-09-13 20:07:44 +01:00
Brady Shober 471f7c38c8
Encode special characters for generated shell command (#5636)
Co-authored-by: Wadeck Follonier <Wadeck@users.noreply.github.com>
2021-08-24 07:59:54 +01:00
Basil Crow 0913566aef
Remove native `chmod(2)` and `stat(2)` support (#5606) 2021-07-23 00:05:06 +08:00
Basil Crow bd7c823c27
Remove unnecessary parentheses (#5576) 2021-06-25 09:23:37 +01:00
Daniel Beck 952d02d596 Change old issue references from #... to JENKINS-... 2021-05-15 08:48:27 +02:00
Basil Crow c904989067
Deprecate `Util#join(Collection, String)` in favor of `String#join(CharSequence, Iterable)` (#5467) 2021-05-09 08:08:59 +01:00
Basil Crow 95e85495ca
Enable AvoidStarImport Checkstyle check (#5420) 2021-04-28 17:28:39 +08:00
Jesse Glick f6098a1df4
Fixing deprecation link in Util.isAbsoluteUri 2021-04-05 18:05:39 -04:00
StefanSpieker 58499905f8
replaced MS_SHOULD_BE_FINAL general spotbugs exclude with individual excludes (#5235) 2021-03-08 07:58:49 +00:00
Daniel Beck 9b8e3ca937
Update RestrictedSince annotations with version numbers (#5277)
Co-authored-by: Daniel Beck <daniel-beck@users.noreply.github.com>
2021-02-23 08:13:46 +00:00
Daniel Beck 90f2d5e3dd
Add at-since annotations up to 2.279 (#5276)
Co-authored-by: Daniel Beck <daniel-beck@users.noreply.github.com>
2021-02-23 08:13:23 +00:00
Vincent Latombe 4ff3f04436
[JENKINS-63828] It is legal to have a CloudProvisioningListener not implementing canProvision
I got confused in
3992a30efb
by Cloud#canProvision which was abstract vs.
CloudProvisioningListener#canProvision which wasn't and was returning
null.
2020-10-07 14:44:15 +02:00
Vincent Latombe 3992a30efb
Add `CloudState` to be passed to `Cloud#provision` and `Cloud#canProvision` methods. (#4922)
Co-authored-by: Jesse Glick <jglick@cloudbees.com>
2020-09-25 21:34:05 +01:00
Tim Van Holder 7c2abcfa94 [JENKINS-62723] Extend JavaDoc with `@throws` 2020-07-08 00:09:21 +02:00
Tim Van Holder 9c088c27f2 [JENKINS-62723] Further fix for Util.isOverridden
This handles the remaining case (override provided by default implementation of an interface).
2020-07-07 22:23:40 +02:00
Tim Van Holder ccc0e34724 [JENKINS-62723] Improve Util.isOverridden
It will now deal with final/abstract methods appropriately.
It will also clearly report bad arguments (base not base of derived, or base does not declare the method).
Added a unit test for interface cases.

Small gap to be looked into: overrides provided via default implementation of a (derived) interface.
2020-07-07 22:09:59 +02:00
Daniel Beck a53ef93cca
Use the 'agent' term more often (#4777)
* Use the 'agent' term more often

* More cleanup

* Another occurrence

Co-authored-by: Daniel Beck <daniel-beck@users.noreply.github.com>
2020-06-09 18:00:37 +02:00
James Nord bdcb2fb222 Merge remote-tracking branch 'origin/master' into kill-jsr-305 2020-03-30 12:40:44 +01:00
Tim Jacomb 6572cfe4b4
Merge pull request #3941 from jsoref/JENKINS-56643
[JENKINS-56643] Util.createSymlink: prefer Files.move(..., ATOMIC_MOVE)
2020-03-28 09:08:04 +00:00
James Nord 1f946961b9 s/javax.annotation.CheckForNull/edu.umd.cs.findbugs.annotations.CheckForNull/g 2020-03-26 16:12:35 +00:00
James Nord 819f80b12f s/javax.annotation.Nonnull/edu.umd.cs.findbugs.annotations.NonNull/g 2020-03-26 11:14:41 +00:00
James Nord a7fcc8e447 s/javax.annotation.Nullable/edu.umd.cs.findbugs.annotations.Nullable/g 2020-03-26 11:11:22 +00:00
Jeff Thompson bf9ee2ecf4 Address review comments. 2020-01-23 14:59:51 -07:00
Jeff Thompson 348a26f77e Narrow the suppression.
And add TODO connected with JENKINS tickets for relevant issues.
2020-01-23 14:59:51 -07:00
Jeff Thompson c76ee59810 Add findsecbugs plugin to spotbugs.
And suppress existing warnings. We should clean some of them up, but that's for different PRs.
2020-01-23 14:53:53 -07:00
Stefan Spieker 2fbc94bb87 set spotbugs ICAST_IDIV_CAST_TO_DOUBLE to ignore, because precision loss is intended 2019-12-31 10:50:09 +01:00
James Nord 7228af5bb1 [JENKINS-60351] - Make it possible to disable multiple deletion attempts by setting hudson.Util.maxFileDeletionRetries to zero (#4382)
* [JENKINS-60351] It should be possible to disable a retry of the
PathRemover

This does not address the issues that the comments and code in
hudons.Util are inconsistent if they are for retries or total number of
attempts (they are currently total number of attempts)

* [JENKINS-60351] Make the code conform to the documentation

maxRetries should control the number of retries not the number of
attempts.

* rename field from DELETION_MAX to DELETION_RETRIES
2019-12-20 11:07:33 +01:00
Basil Crow 861855953b Replace <code>…</code> with {@code …} 2019-10-19 14:02:59 -07:00
Raihaan Shouhell e5166f7f8d Foreach loops 2019-10-01 13:49:43 +08:00
jesse-houghton d763b4cb11 Added missing null check and associated test (#4204) 2019-09-20 09:36:18 +02:00