YARN-4298. Fix findbugs warnings in hadoop-yarn-common. Contributed by Sunil G.

(cherry picked from commit 8c0133f3d4)
This commit is contained in:
Akira Ajisaka 2015-11-24 18:40:33 +09:00
parent 49ed955c91
commit ac0ddc4fec
2 changed files with 5 additions and 2 deletions

View File

@ -1009,6 +1009,9 @@ Release 2.8.0 - UNRELEASED
YARN-4367. SLS webapp doesn't load. (kasha)
YARN-4298. Fix findbugs warnings in hadoop-yarn-common.
(Sunil G via aajisaka)
Release 2.7.3 - UNRELEASED
INCOMPATIBLE CHANGES

View File

@ -386,7 +386,7 @@ public class AllocateResponsePBImpl extends AllocateResponse {
}
@Override
public Priority getApplicationPriority() {
public synchronized Priority getApplicationPriority() {
AllocateResponseProtoOrBuilder p = viaProto ? proto : builder;
if (this.appPriority != null) {
return this.appPriority;
@ -399,7 +399,7 @@ public class AllocateResponsePBImpl extends AllocateResponse {
}
@Override
public void setApplicationPriority(Priority priority) {
public synchronized void setApplicationPriority(Priority priority) {
maybeInitBuilder();
if (priority == null)
builder.clearApplicationPriority();