Properly revert job history for matrix and maven jobs (depending on
setup).
Examples paths include:
jobs/someproject/Environment=prod/builds
jobs/someproject/test$test/builds
Only add(T, int) was synchronized (and its javadoc claimed it was the
only one modifying .items), but all the bulk add methods were going
straight to addInternal() and then refreshTable() on their own. Then
countAllPoints() was iterating over items.values() which has undefined
behavior if the underlying Map changed.
Technically I didn't need to synchronize the current implementations of
remove(T) and add(T) since they delegated fully to add(T, int), but
that's leaking implementation details and inviting trouble down the road
when someone doesn't realize that.
Likewise, addInternal() and refreshTable() need not be synchronized
since they're only ever called from already synchronized methods, but
I'm inclined to go for belt & suspenders in the wake of these other
issues.
The contract for JnlpAgentReceiver in case of error on a claimed node is
to call handshake.error() but still return true so other handlers don't
take another crack a it.
Also added unit tests DefaultJnlpSlaveReceiver.
The original method of computing load statistics would compute the total and idle counts independently
which could lead to counting errors while jobs started in between the different state counting operations.
This change switches to returning a `LoadStatisticsSnapshot` so that callers will get a single consistent
view of the counts which was valid for at least one point in time during the collection of the snapshot.
- of course drive mappings are user scoped and can change from user session to user session, so calling them absolute is a bit of a joke... none the less, for our purposes they are absolute enough
Although the plugiun manager was vulnerable getting information
out of Jenkins was harder - however it would still be possible to
do bad things such as reading from /dev/zero on Linux
Added a new EntityResolver that will throw an exception if any attempts
are made to load external entities.
Made the transforer use SAX so that we can use out EntityResolover.
As we can't defend against calls that have already parsed the xml (e.g.
DOMSource) if we are parsed one of those throw an exception (which can be
disabled with a System property.
In this environment, Util.createSymlink and .isSymlink are implemented, but resolveSymlink is not.
(cherry picked from commit 388c4b5e6b)
Conflicts:
changelog.html