diff options
author | Joshua Reich <jreich@research.att.com> | 2018-09-21 16:44:25 -0700 |
---|---|---|
committer | Joshua Reich <jreich@research.att.com> | 2018-09-27 12:53:38 -0700 |
commit | daa096b8149e18e69e1344e01cf4627d7e0dede5 (patch) | |
tree | c8dd5ea368d5ef615bb5e3780fcf751de4371c99 /controlloop/common/eventmanager/src/main/java | |
parent | 72d5a239ff15617b2d218d3b8f3f8a2099007142 (diff) |
Yet more sonar issues in drools-applications
removed unused imports and variable definitions
moved variable declarations above methods
refactored deeply nested if/while
removed code smell due to unecessary use of static keyword
moved string literals to left side of comparator
fixed logging of exceptions
immediately return expression instead of assigning it to the temporary variable
Change-Id: Idfd2a2bdf3c2f3bbfcb54a06b713d57bc867b3ab
Issue-ID: POLICY-1129
Signed-off-by: Joshua Reich <jreich@research.att.com>
Diffstat (limited to 'controlloop/common/eventmanager/src/main/java')
-rw-r--r-- | controlloop/common/eventmanager/src/main/java/org/onap/policy/controlloop/eventmanager/ControlLoopEventManager.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/controlloop/common/eventmanager/src/main/java/org/onap/policy/controlloop/eventmanager/ControlLoopEventManager.java b/controlloop/common/eventmanager/src/main/java/org/onap/policy/controlloop/eventmanager/ControlLoopEventManager.java index 4ab7b494f..e9fc27734 100644 --- a/controlloop/common/eventmanager/src/main/java/org/onap/policy/controlloop/eventmanager/ControlLoopEventManager.java +++ b/controlloop/common/eventmanager/src/main/java/org/onap/policy/controlloop/eventmanager/ControlLoopEventManager.java @@ -499,9 +499,7 @@ public class ControlLoopEventManager implements LockCallback, Serializable { this.currentOperation.getTargetEntity(), this.onset.getRequestId(), this); this.targetLock = lock; - LockResult<GuardResult, TargetLock> lockResult = - LockResult.createLockResult(GuardResult.LOCK_ACQUIRED, lock); - return lockResult; + return LockResult.createLockResult(GuardResult.LOCK_ACQUIRED, lock); } // // Have we acquired it already? |