diff options
author | Jim Hahn <jrh3@att.com> | 2019-07-10 15:42:40 -0400 |
---|---|---|
committer | Jim Hahn <jrh3@att.com> | 2019-07-17 08:53:11 -0400 |
commit | 6dee9fba7e3c471bab358d8567a9e3e0a3fca769 (patch) | |
tree | a51ebc52fdeed43f678b085234869dadf8902c33 | |
parent | 254e206198b72376ca31fe5950b805335a4376b4 (diff) |
Fix checkstyle issues in api-active-standby-management
Also deleted the checkstyle suppression file.
Change-Id: I3518f29c75061dced8f507b274388f7588859037
Issue-ID: POLICY-1901
Signed-off-by: Jim Hahn <jrh3@att.com>
7 files changed, 19 insertions, 50 deletions
diff --git a/api-active-standby-management/checkstyle-suppressions.xml b/api-active-standby-management/checkstyle-suppressions.xml deleted file mode 100644 index b6fa7eff..00000000 --- a/api-active-standby-management/checkstyle-suppressions.xml +++ /dev/null @@ -1,30 +0,0 @@ -<?xml version="1.0"?> -<!-- - ============LICENSE_START======================================================= - Copyright (C) 2018 AT&T Technologies. All rights reserved. - ================================================================================ - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - - SPDX-License-Identifier: Apache-2.0 - ============LICENSE_END========================================================= ---> - -<!DOCTYPE suppressions PUBLIC - "-//Puppy Crawl//DTD Suppressions 1.0//EN" - "http://www.puppycrawl.com/dtds/suppressions_1_0.dtd"> - -<suppressions> - <suppress checks="AbbreviationAsWordInName" - files="ActiveStandbyFeatureAPI.java" - lines="1-9999"/> -</suppressions> diff --git a/api-active-standby-management/pom.xml b/api-active-standby-management/pom.xml index 0d6861bd..9182c5a8 100644 --- a/api-active-standby-management/pom.xml +++ b/api-active-standby-management/pom.xml @@ -2,7 +2,7 @@ ============LICENSE_START======================================================= ECOMP Policy Engine - Drools PDP ================================================================================ - Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + Copyright (C) 2017, 2019 AT&T Intellectual Property. All rights reserved. ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -69,7 +69,6 @@ <includeTestResources>true</includeTestResources> <excludes> </excludes> - <suppressionsLocation>${project.baseUri}checkstyle-suppressions.xml</suppressionsLocation> <consoleOutput>true</consoleOutput> <failsOnViolation>true</failsOnViolation> <violationSeverity>warning</violationSeverity> diff --git a/api-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeatureAPI.java b/api-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeatureApi.java index 5f99e6bb..8637fa5c 100644 --- a/api-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeatureAPI.java +++ b/api-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeatureApi.java @@ -28,13 +28,13 @@ import org.onap.policy.common.utils.services.OrderedServiceImpl; * appropriate points in the application, the code iterates through this list, invoking these * optional methods. */ -public interface ActiveStandbyFeatureAPI extends OrderedService { +public interface ActiveStandbyFeatureApi extends OrderedService { /** * 'FeatureAPI.impl.getList()' returns an ordered list of objects implementing the 'FeatureAPI' * interface. */ - public static OrderedServiceImpl<ActiveStandbyFeatureAPI> impl = - new OrderedServiceImpl<>(ActiveStandbyFeatureAPI.class); + public static OrderedServiceImpl<ActiveStandbyFeatureApi> impl = + new OrderedServiceImpl<>(ActiveStandbyFeatureApi.class); /** * Returns the resourceName (PDP ID) for the Drools-PDP that is diff --git a/feature-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeature.java b/feature-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeature.java index 1872a3a9..c34f9ace 100644 --- a/feature-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeature.java +++ b/feature-active-standby-management/src/main/java/org/onap/policy/drools/activestandby/ActiveStandbyFeature.java @@ -47,7 +47,7 @@ import org.slf4j.LoggerFactory; * 'PolicyContainer' and 'Main'. It was moved here as part of making this * a separate optional feature. */ -public class ActiveStandbyFeature implements ActiveStandbyFeatureAPI, +public class ActiveStandbyFeature implements ActiveStandbyFeatureApi, PolicySessionFeatureApi, PolicyEngineFeatureApi { // get an instance of logger private static final Logger logger = diff --git a/feature-active-standby-management/src/main/resources/META-INF/services/org.onap.policy.drools.activestandby.ActiveStandbyFeatureAPI b/feature-active-standby-management/src/main/resources/META-INF/services/org.onap.policy.drools.activestandby.ActiveStandbyFeatureApi index 5296f8b7..5296f8b7 100644 --- a/feature-active-standby-management/src/main/resources/META-INF/services/org.onap.policy.drools.activestandby.ActiveStandbyFeatureAPI +++ b/feature-active-standby-management/src/main/resources/META-INF/services/org.onap.policy.drools.activestandby.ActiveStandbyFeatureApi diff --git a/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/AllSeemsWellTest.java b/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/AllSeemsWellTest.java index ea9418bf..0c04e3d9 100644 --- a/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/AllSeemsWellTest.java +++ b/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/AllSeemsWellTest.java @@ -38,7 +38,7 @@ import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; import org.onap.policy.common.im.StateManagement; -import org.onap.policy.drools.activestandby.ActiveStandbyFeatureAPI; +import org.onap.policy.drools.activestandby.ActiveStandbyFeatureApi; import org.onap.policy.drools.activestandby.ActiveStandbyProperties; import org.onap.policy.drools.activestandby.DroolsPdpEntity; import org.onap.policy.drools.activestandby.DroolsPdpImpl; @@ -254,8 +254,8 @@ public class AllSeemsWellTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testAllSeemsWell activeStandbyFeature.getResourceName(): {}", diff --git a/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/StandbyStateManagementTest.java b/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/StandbyStateManagementTest.java index 1a52456e..ac4269a9 100644 --- a/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/StandbyStateManagementTest.java +++ b/feature-active-standby-management/src/test/java/org/onap/policy/drools/controller/test/StandbyStateManagementTest.java @@ -43,7 +43,7 @@ import org.onap.policy.common.im.AdministrativeStateException; import org.onap.policy.common.im.IntegrityMonitor; import org.onap.policy.common.im.StandbyStatusException; import org.onap.policy.common.im.StateManagement; -import org.onap.policy.drools.activestandby.ActiveStandbyFeatureAPI; +import org.onap.policy.drools.activestandby.ActiveStandbyFeatureApi; import org.onap.policy.drools.activestandby.ActiveStandbyProperties; import org.onap.policy.drools.activestandby.DroolsPdp; import org.onap.policy.drools.activestandby.DroolsPdpEntity; @@ -810,8 +810,8 @@ public class StandbyStateManagementTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testColdStandby activeStandbyFeature.getResourceName(): {}", @@ -941,8 +941,8 @@ public class StandbyStateManagementTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testHotStandby1 activeStandbyFeature.getResourceName(): {}", @@ -1098,8 +1098,8 @@ public class StandbyStateManagementTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testHotStandby2 activeStandbyFeature.getResourceName(): {}", @@ -1255,8 +1255,8 @@ public class StandbyStateManagementTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testLocking1 activeStandbyFeature.getResourceName(): {}", @@ -1503,8 +1503,8 @@ public class StandbyStateManagementTest { // Create an ActiveStandbyFeature and initialize it. It will discover the StateManagementFeature // that has been created. - ActiveStandbyFeatureAPI activeStandbyFeature = null; - for (ActiveStandbyFeatureAPI feature : ActiveStandbyFeatureAPI.impl.getList()) { + ActiveStandbyFeatureApi activeStandbyFeature = null; + for (ActiveStandbyFeatureApi feature : ActiveStandbyFeatureApi.impl.getList()) { ((PolicySessionFeatureApi) feature).globalInit(null, configDir); activeStandbyFeature = feature; logger.debug("testLocking2 activeStandbyFeature.getResourceName(): {}", |