Since we have the confirmed regression due to the binary compatibility change, I think we need to restore the compatibility.
OTOH, I restricted the class, so all users will be forced to stop using it when they updgrade the core.
* [JENKINS-47718] - Deprecate User#getUser(String)
`User#getUser(String)` method causes lots of confusion for plugin developers. It implicitly creates a user if it cannot be found, and in many cases this is actually a not-expected behavior. This change deprecates the method and to creates a new `User#getOrCreate()` which is more explicit
* [JENKINS-47718] - Address comments from @jglick
* [JENKINS-34138] Adding equals/hashCode methods so that installs don't step on each other
* [JENKINS-34138] Added issue reference to unit tests
* [JENKINS-34138] - changed the order of equals / hashcode
* Always use NIO to detect symlinks
* Make assertion failure message consistent
* Catch NoSuchFileException to keep tests passing
* Make method name more specific and simlify assumption
* Remove obsolete comment and reword the main comment in isSymlink
* Deprecate Kernel32Util#isJunctionOrSymlink
* Use assumptions for junction creation and add messages to assumptions
* Replace deprecated code with recommended alternative
* Add comment explaining call to DosFileAttributes#isOther
* Do not fall back to native code when creating symlinks
* Log FileSystemExceptions when creating symbolic links
* Catch InvalidPathException and rethrow as IOException
* Deprecate Kernel32Utils#createSymbolicLink and #getWin32FileAttributes
* Preserve original logging behavior on Windows and remove useless call to Util#displayIOException
Due to the implementation specifics, some classes in the core are serializable only over Remoting.
This change just marks these classes and utilizes the convenience method in the interface for serialization/deserialization operations.
In case of having 1000s of ongoing builds opening main pages can take
some time if list of executors are opened. It happens because for every
queury that comes from jelly we re-calculate the value from scratch. And
calculation needs to load some builds from disk. The worst thing is that it
happens for every user separately.
* Avoid having "authenticated" twice in the group membership of a user
- this occur when the SecurityRealm potentially already grants that role (like in github-oauth-plugin)
* - changed as requested by Oleg
- the list has a maximum of roles.length and in reality it's either roles.length or (roles.length-1), so the maximum is ok
* - fix problem of missing the "authenticated" authority
* - convert the Groovy script to a Java version
- the Groovy test was not run by default (IIUC Groovy scripts are not compiled if placed in java src folder)
Fixes JENKINS-45294, JENKINS-47425, JENKINS-47901, JENKINS-47942 + about 50 reported FindBugs issues (JENKINS-37566). There are 13 FindBugs issues left, work in progress.