[JENKINS-10615]

Reproduced the problem. Workspace is getting released prematurely, before publishers run. This has all sorts of serious problems.

(cherry picked from commit 61cf2df0660e507fab20442f44e917d75f946917)
[FIXED JENKINS-10615]

Hold on to the lease until the very end.
Previously, the lease was only held until the main build section is over, before publishers start running.

(cherry picked from commit d183345007ecd6fae01565975fb48ddec6e47af4)

Conflicts:
	changelog.html
[FIXED JENKINS-20415] Lack of type safety in JENKINS-20143 fix sometimes caused CCEs.
(cherry picked from commit bdbac284723940e5b2dfd37dd194524305de29c2)

Conflicts:
	changelog.html
Recording all the fixes in this new release

(cherry picked from commit 4137c46182a0652d2eed2897a1e797bdc3f8c7f9)

Conflicts:
	changelog.html
[FIXED JENKINS-20163]

Integrated the fix in Stapler.

(cherry picked from commit d8eca0f5e7f8c57bf991039d8d255640547ed237)

Conflicts:
	changelog.html
	core/pom.xml