Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce usage of deprecated Acegi methods #204

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ public void stop(Throwable cause) throws Exception {
// JENKINS-37154: we might be inside the VM thread, so do not do anything which might block on the VM thread
Timer.get().submit(new Runnable() {
@Override public void run() {
try (ACLContext context = ACL.as(ACL.SYSTEM)) {
try (ACLContext context = ACL.as2(ACL.SYSTEM2)) {
postSettlement();
} catch (IOException | InterruptedException x) {
LOGGER.log(Level.WARNING, "failed to abort " + getContext(), x);
Expand Down Expand Up @@ -427,7 +427,7 @@ private Map<String,Object> parseValue(StaplerRequest request) throws ServletExce

Run<?, ?> run = getRun();
CredentialsParameterBinder binder = CredentialsParameterBinder.getOrCreate(run);
String userId = Jenkins.getAuthentication().getName();
String userId = Jenkins.getAuthentication2().getName();
for (ParameterValue val : vals) {
if (val instanceof CredentialsParameterValue) {
binder.bindCredentialsParameter(userId, (CredentialsParameterValue) val);
Expand Down
Loading