From 4edf0fa48892bf38d0e3838d125e9bf2324b38e0 Mon Sep 17 00:00:00 2001 From: an4828 Date: Fri, 15 Sep 2017 15:28:53 -0400 Subject: Add support for ABATED alerts within CDAP TCA Change-Id: Iae560a2d0a47b30b41cd31206dc481a08e4930f7 Signed-off-by: an4828 Issue-ID: DCAEGEN2-107 Signed-off-by: an4828 --- .../apod/analytics/model/config/ConfigModel.java | 13 + .../model/config/tca/BaseTCAAppConfigModel.java | 17 ++ .../analytics/model/config/tca/BaseTCAHandle.java | 18 ++ .../apod/analytics/model/config/tca/DMAAPInfo.java | 25 ++ .../model/config/tca/StreamsPublishes.java | 17 ++ .../model/config/tca/StreamsSubscribes.java | 17 ++ .../model/config/tca/TCAAppConfigModel.java | 14 + .../model/config/tca/TCAControllerAppConfig.java | 22 ++ .../analytics/model/config/tca/TCAHandleIn.java | 19 ++ .../analytics/model/config/tca/TCAHandleOut.java | 19 ++ .../analytics/model/domain/cef/AlertAction.java | 14 +- .../apod/analytics/model/domain/cef/AlertType.java | 14 +- .../analytics/model/domain/cef/BaseCEFModel.java | 14 +- .../apod/analytics/model/domain/cef/CEFModel.java | 14 +- .../model/domain/cef/CommonEventHeader.java | 92 +++++- .../analytics/model/domain/cef/Criticality.java | 14 +- .../apod/analytics/model/domain/cef/Domain.java | 41 +++ .../apod/analytics/model/domain/cef/Event.java | 14 +- .../analytics/model/domain/cef/EventListener.java | 14 +- .../analytics/model/domain/cef/EventSeverity.java | 14 +- .../apod/analytics/model/domain/cef/Field.java | 53 ++++ .../model/domain/cef/InternalHeaderFields.java | 38 +++ .../domain/cef/MeasurementsForVfScalingFields.java | 48 +++- .../model/domain/cef/NamedArrayOfFields.java | 55 ++++ .../model/domain/cef/PerformanceCounter.java | 14 +- .../apod/analytics/model/domain/cef/Priority.java | 14 +- .../domain/cef/ThresholdCrossingAlertFields.java | 26 +- .../model/domain/cef/VNicPerformance.java | 308 +++++++++++++++++++++ .../analytics/model/domain/cef/VNicUsageArray.java | 79 ------ .../domain/policy/tca/ControlLoopEventStatus.java | 14 + .../domain/policy/tca/ControlLoopSchemaType.java | 13 + .../model/domain/policy/tca/Direction.java | 6 + .../domain/policy/tca/MetricsPerEventName.java | 115 ++++++++ .../policy/tca/MetricsPerFunctionalRole.java | 102 ------- .../model/domain/policy/tca/TCAPolicy.java | 7 +- .../model/domain/policy/tca/Threshold.java | 16 +- .../json/AnalyticsModelObjectMapperSupplier.java | 2 + .../model/util/json/CommonEventFormatModule.java | 18 +- .../model/util/json/TCAControllerConfigModule.java | 39 +++ .../analytics/model/util/json/TCAPolicyModule.java | 15 +- .../util/json/mixin/cef/AlertActionMixin.java | 14 +- .../model/util/json/mixin/cef/AlertTypeMixin.java | 27 +- .../util/json/mixin/cef/BaseCEFModelMixin.java | 14 +- .../json/mixin/cef/CommonEventHeaderMixin.java | 14 +- .../util/json/mixin/cef/CriticalityMixin.java | 14 +- .../model/util/json/mixin/cef/DomainMixin.java | 30 ++ .../util/json/mixin/cef/EventListenerMixin.java | 14 +- .../model/util/json/mixin/cef/EventMixin.java | 14 +- .../util/json/mixin/cef/EventSeverityMixin.java | 14 +- .../model/util/json/mixin/cef/FieldMixin.java | 28 ++ .../json/mixin/cef/InternalHeaderFieldsMixin.java | 28 ++ .../cef/MeasurementsForVfScalingFieldsMixin.java | 24 +- .../json/mixin/cef/NamedArrayOfFieldsMixin.java | 28 ++ .../json/mixin/cef/PerformanceCounterMixin.java | 14 +- .../model/util/json/mixin/cef/PriorityMixin.java | 14 +- .../cef/ThresholdCrossingAlertFieldsMixin.java | 14 +- .../util/json/mixin/cef/VNicUsageArrayMixin.java | 30 +- .../config/tca/BaseTCAAppConfigModelMixin.java | 9 + .../json/mixin/config/tca/BaseTCAHandleMixin.java | 20 ++ .../util/json/mixin/config/tca/DMAAPInfoMixin.java | 13 + .../mixin/config/tca/StreamsPublishesMixin.java | 14 + .../mixin/config/tca/StreamsSubscribesMixin.java | 14 + .../config/tca/TCAControllerAppConfigMixin.java | 17 ++ .../policy/tca/ControlLoopEventStatusMixin.java | 30 ++ .../policy/tca/ControlLoopSchemaTypeMixin.java | 9 + .../mixin/policy/tca/MetricsPerEventNameMixin.java | 28 ++ .../policy/tca/MetricsPerFunctionalRoleMixin.java | 28 -- 67 files changed, 1468 insertions(+), 457 deletions(-) create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/ConfigModel.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAAppConfigModel.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAHandle.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/DMAAPInfo.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsPublishes.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsSubscribes.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAAppConfigModel.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAControllerAppConfig.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleIn.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleOut.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Domain.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Field.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/InternalHeaderFields.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/NamedArrayOfFields.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicPerformance.java delete mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicUsageArray.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopEventStatus.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopSchemaType.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerEventName.java delete mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerFunctionalRole.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/TCAControllerConfigModule.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/DomainMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/FieldMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/InternalHeaderFieldsMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/NamedArrayOfFieldsMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAAppConfigModelMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAHandleMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/DMAAPInfoMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsPublishesMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsSubscribesMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/TCAControllerAppConfigMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopEventStatusMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopSchemaTypeMixin.java create mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerEventNameMixin.java delete mode 100644 dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerFunctionalRoleMixin.java (limited to 'dcae-analytics-model/src/main') diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/ConfigModel.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/ConfigModel.java new file mode 100644 index 0000000..7117bbe --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/ConfigModel.java @@ -0,0 +1,13 @@ +package org.openecomp.dcae.apod.analytics.model.config; + +import java.io.Serializable; + +/** + *

+ * Marker Interface for all Configuration Model Objects + *

+ * + * @author Rajiv Singla . Creation Date: 08/25/2017. + */ +public interface ConfigModel extends Serializable { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAAppConfigModel.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAAppConfigModel.java new file mode 100644 index 0000000..52c90fb --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAAppConfigModel.java @@ -0,0 +1,17 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.openecomp.dcae.apod.analytics.model.domain.BaseDynamicPropertiesProvider; + +/** + *

+ * Base TCA App Config model class + *

+ * + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public abstract class BaseTCAAppConfigModel extends BaseDynamicPropertiesProvider implements TCAAppConfigModel { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAHandle.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAHandle.java new file mode 100644 index 0000000..d0a20ed --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/BaseTCAHandle.java @@ -0,0 +1,18 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public abstract class BaseTCAHandle extends BaseTCAAppConfigModel { + + private String aafPassword; + private String aafUserName; + private DMAAPInfo dmaapInfo; + private String type; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/DMAAPInfo.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/DMAAPInfo.java new file mode 100644 index 0000000..9238582 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/DMAAPInfo.java @@ -0,0 +1,25 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * DMaaP Information nested inside DMaaP Controller config + * + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class DMAAPInfo extends BaseTCAAppConfigModel { + + private static final long serialVersionUID = 1L; + + /** + * DMaaP Topic URL + * + * @param topicUrl new value for DMaaP topic URL + * @return DMaaP Topic URL + */ + private String topicUrl; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsPublishes.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsPublishes.java new file mode 100644 index 0000000..e72ff19 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsPublishes.java @@ -0,0 +1,17 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class StreamsPublishes extends BaseTCAAppConfigModel { + + private static final long serialVersionUID = 1L; + + private TCAHandleOut tcaHandleOut; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsSubscribes.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsSubscribes.java new file mode 100644 index 0000000..6c03c75 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/StreamsSubscribes.java @@ -0,0 +1,17 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class StreamsSubscribes extends BaseTCAAppConfigModel { + + private static final long serialVersionUID = 1L; + + private TCAHandleIn tcaHandleIn; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAAppConfigModel.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAAppConfigModel.java new file mode 100644 index 0000000..636429e --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAAppConfigModel.java @@ -0,0 +1,14 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import org.openecomp.dcae.apod.analytics.model.config.ConfigModel; + +/** + *

+ * Marker Interface for all TCA Facade Models + *

+ * + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public interface TCAAppConfigModel extends ConfigModel { + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAControllerAppConfig.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAControllerAppConfig.java new file mode 100644 index 0000000..8d271df --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAControllerAppConfig.java @@ -0,0 +1,22 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Model Object Representing the App Config passed in by the controller + * + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class TCAControllerAppConfig extends BaseTCAAppConfigModel { + + private static final long serialVersionUID = 1L; + + private String appName; + private String appDescription; + private StreamsPublishes streamsPublishes; + private StreamsSubscribes streamsSubscribes; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleIn.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleIn.java new file mode 100644 index 0000000..6e7d1f4 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleIn.java @@ -0,0 +1,19 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + *

+ * TCA Controller App Config - TCA Handle In + *

+ * + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class TCAHandleIn extends BaseTCAHandle { + + private static final long serialVersionUID = 1L; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleOut.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleOut.java new file mode 100644 index 0000000..312ef5a --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/config/tca/TCAHandleOut.java @@ -0,0 +1,19 @@ +package org.openecomp.dcae.apod.analytics.model.config.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + *

+ * TCA Controller App Config - TCA Handle Out + *

+ * + * @author rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class TCAHandleOut extends BaseTCAHandle { + + private static final long serialVersionUID = 1L; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertAction.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertAction.java index 654820b..664bd4a 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertAction.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertAction.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.domain.cef; /** * Common Event Format Alert Action * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public enum AlertAction implements CEFModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertType.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertType.java index a20c75c..9fc8046 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertType.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/AlertType.java @@ -1,28 +1,28 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; /** * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public enum AlertType implements CEFModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/BaseCEFModel.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/BaseCEFModel.java index bdba70f..5438297 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/BaseCEFModel.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/BaseCEFModel.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -31,7 +31,7 @@ import org.openecomp.dcae.apod.analytics.model.domain.BaseDynamicPropertiesProvi * can be accumalated in a map. *

* - * @author Rajiv Singla . Creation Date: 10/18/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CEFModel.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CEFModel.java index a98b634..8df7d61 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CEFModel.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CEFModel.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -26,7 +26,7 @@ import org.openecomp.dcae.apod.analytics.model.domain.DCAEAnalyticsModel; *

* Marker interface for all DCAE Analytics Common Event Format Model implementations *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public interface CEFModel extends DCAEAnalyticsModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CommonEventHeader.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CommonEventHeader.java index 7cc45d7..b3d625f 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CommonEventHeader.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/CommonEventHeader.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -26,7 +26,7 @@ import lombok.EqualsAndHashCode; /** * Fields common to all Events *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) @@ -41,7 +41,7 @@ public class CommonEventHeader extends BaseCEFModel { * @param domain New value for domain * @return The eventing domain associated with this event */ - private String domain; + private Domain domain; /** * Event key that is unique to the event source @@ -52,12 +52,30 @@ public class CommonEventHeader extends BaseCEFModel { private String eventId; /** - * Function of the source e.g. eNodeB, MME, PCRF + * Unique event name * - * @param functionalRole New value for functional Role - * @return Function of the source e.g. eNodeB, MME, PCRF + * @param eventName New value for event name + * @return Unique event name */ - private String functionalRole; + private String eventName; + + + /** + * Event type e.g. applicationVnf, guestOS, hostOS, platform + * + * @param eventType New value for event type + * @return Event type e.g. applicationVnf, guestOS, hostOS, platform + */ + private String eventType; + + + /** + * Enrichment fields for internal VES Event Listener service use only, not supplied by event sources + * + * @param internalHeaderFields new value for internal Header Fields + * @return Enrichment fields for internal VES Event Listener service use only, not supplied by event sources + */ + private InternalHeaderFields internalHeaderFields; /** @@ -70,6 +88,24 @@ public class CommonEventHeader extends BaseCEFModel { private Long lastEpochMicrosec; + /** + * Three character network function component type as aligned with vfc naming standards + * + * @param nfcNamingCode New value for nfc naming code + * @return Three character network function component type as aligned with vfc naming standards + */ + private String nfcNamingCode; + + + /** + * Four character network function type as aligned with vnf naming standards + * + * @param nfNamingCode New value for nf naming code + * @return Four character network function type as aligned with vnf naming standards + */ + private String nfNamingCode; + + /** * Processing Priority * @@ -80,10 +116,20 @@ public class CommonEventHeader extends BaseCEFModel { /** - * Name of the entity reporting the event, for example, an OAM VM + * UUID identifying the entity reporting the event, for example an OAM VM; must be populated by the + * enrichment process + * + * @param reportingEntityId New value for reporting entity Id. Must be populated by the enrichment process + * @return UUID identifying the entity reporting the event populated by the enrichment process + */ + private String reportingEntityId; + + + /** + * Name of the entity reporting the event, for example, an EMS name; may be the same as sourceName * * @param reportingEntityName New value for reporting Entity Name - * @return Name of the entity reporting the event, for example, an OAM VM + * @return Name of the entity reporting the event, may be the same as sourceName */ private String reportingEntityName; @@ -97,6 +143,15 @@ public class CommonEventHeader extends BaseCEFModel { private Integer sequence; + /** + * UUID identifying the entity experiencing the event issue; must be populated by the enrichment process + * + * @param sourceId New value for source id. Must be populated by the enrichment process + * @return UUID identifying the entity experiencing the event issue + */ + private String sourceId; + + /** * Name of the entity experiencing the event issue * @@ -114,4 +169,13 @@ public class CommonEventHeader extends BaseCEFModel { * @return The earliest unix time associated with the event from any component */ private Long startEpochMicrosec; + + + /** + * Version of the event header + * + * @param version New value for version of the event header + * @return Version of the event header + */ + private Float version; } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Criticality.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Criticality.java index 48a9411..69d23c4 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Criticality.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Criticality.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.domain.cef; /** * Performance Criticality * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public enum Criticality implements CEFModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Domain.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Domain.java new file mode 100644 index 0000000..f945f90 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Domain.java @@ -0,0 +1,41 @@ +/* + * ============LICENSE_START========================================================= + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.dcae.apod.analytics.model.domain.cef; + +/** + * Eventing domain associated with the event + *

+ * Author: rs153v (Rajiv Singla) . Creation Date: 08/15/2017. + */ +public enum Domain implements CEFModel { + + fault, + heartbeat, + measurementsForVfScaling, + mobileFlow, + other, + sipSignaling, + stateChange, + syslog, + thresholdCrossingAlert, + voiceQuality; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Event.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Event.java index 5fe59a4..bb8a13a 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Event.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Event.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -26,7 +26,7 @@ import lombok.EqualsAndHashCode; /** * Generic Event Format *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventListener.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventListener.java index df97ebe..0854790 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventListener.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventListener.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -26,7 +26,7 @@ import lombok.EqualsAndHashCode; /** * Common Event Format - Base Event Listener *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventSeverity.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventSeverity.java index 1021cfb..d7f85fa 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventSeverity.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/EventSeverity.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.domain.cef; /** * CEF Event severity or priority * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public enum EventSeverity implements CEFModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Field.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Field.java new file mode 100644 index 0000000..0bff4ec --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Field.java @@ -0,0 +1,53 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.domain.cef; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Name Value Pair + *

+ * @author Rajiv Singla. Creation Date: 08/15/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class Field extends BaseCEFModel { + + private static final long serialVersionUID = 1L; + + /** + * Name of the Field + * + * @param name New name for the Field + * @return Name of the Field + */ + private String name; + + /** + * Value of the Field + * + * @param value New value for the Field + * @return Value of the Field + */ + private String value; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/InternalHeaderFields.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/InternalHeaderFields.java new file mode 100644 index 0000000..66b6236 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/InternalHeaderFields.java @@ -0,0 +1,38 @@ +/* + * ============LICENSE_START========================================================= + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.dcae.apod.analytics.model.domain.cef; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Enrichment fields for internal VES Event Listener service use only, not supplied by event sources + *

+ * + * @author Rajiv Singla . Creation Date: 08/15/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class InternalHeaderFields extends BaseCEFModel { + + private static final long serialVersionUID = 1L; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/MeasurementsForVfScalingFields.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/MeasurementsForVfScalingFields.java index a6bf113..e492f2d 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/MeasurementsForVfScalingFields.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/MeasurementsForVfScalingFields.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -28,15 +28,31 @@ import java.util.List; /** * Common Event Format - MeasurementsForVfScaling fields *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) public class MeasurementsForVfScalingFields extends BaseCEFModel { - private static final long serialVersionUID = 1L; + /** + * Additional name-value-pair fields + * + * @param additionalFields New value for additional name-value-pair fields + * @return Additional name-value-pair fields + */ + private List additionalFields; + + + /** + * Array of named name-value-pair arrays for additional Measurements + * + * @param additionalMeasurements New value for array of named name-value-pair arrays for additional Measurements + * @return Array of named name-value-pair arrays for additional Measurements + */ + private List additionalMeasurements; + /** * Interval over which measurements are being reported in seconds * @@ -46,12 +62,20 @@ public class MeasurementsForVfScalingFields extends BaseCEFModel { private Long measurementInterval; /** - * Virtual Network Card Usage Array + * Version of the measurementsForVfScaling block + * + * @param measurementsForVfScalingVersion New value for measurementsForVfScaling block + * @return Version of the measurementsForVfScaling block + */ + private Float measurementsForVfScalingVersion; + + /** + * Usage of an array of virtual network interface cards * - * @param vNicUsageArray New value for Virtual Network Card Usage Array - * @return Virtual Network Card Usage Array + * @param vNicPerformanceArray New value for Usage of an array of virtual network interface cards + * @return Usage of an array of virtual network interface cards */ - private List vNicUsageArray; + private List vNicPerformanceArray; } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/NamedArrayOfFields.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/NamedArrayOfFields.java new file mode 100644 index 0000000..bea6a97 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/NamedArrayOfFields.java @@ -0,0 +1,55 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.domain.cef; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.util.List; + +/** + * An array of name value pairs along with a name for the array + *

+ * @author Rajiv Singla. Creation Date: 08/15/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class NamedArrayOfFields extends BaseCEFModel { + + private static final long serialVersionUID = 1L; + + /** + * Name of the NamedArrayOfFields + * + * @param name New name for the Field + * @return Name of the Field + */ + private String name; + + /** + * Array of name value pairs + * + * @param arrayOfFields New value for array of name value pairs + * @return Array of name value pairs + */ + private List arrayOfFields; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/PerformanceCounter.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/PerformanceCounter.java index e84c852..e8dbee9 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/PerformanceCounter.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/PerformanceCounter.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -26,7 +26,7 @@ import lombok.EqualsAndHashCode; /** * Common Event Format - Performance PerformanceCounter * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Priority.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Priority.java index 3cfce75..f2c6674 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Priority.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/Priority.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.domain.cef; /** * Common Event Format - Event processing priority *

- * @author Rajiv Singla . Creation Date: 10/17/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public enum Priority implements CEFModel { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/ThresholdCrossingAlertFields.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/ThresholdCrossingAlertFields.java index 340b788..55dd696 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/ThresholdCrossingAlertFields.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/ThresholdCrossingAlertFields.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.domain.cef; @@ -28,7 +28,7 @@ import java.util.List; /** * Common Event Format - Fields Specific to threshold crossing alert events * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ @Data @EqualsAndHashCode(callSuper = true) @@ -102,10 +102,10 @@ public class ThresholdCrossingAlertFields extends BaseCEFModel { private String dataCollector; /** - * Type of network element - internal field + * Type of network element * - * @param elementType New value for type of network element - internal field - * @return Type of network element - internal field + * @param elementType New value for type of network element + * @return Type of network element */ private String elementType; @@ -134,10 +134,10 @@ public class ThresholdCrossingAlertFields extends BaseCEFModel { private String interfaceName; /** - * Network name - internal field + * Network name * - * @param networkService New value for network name - internal field - * @return Network name - internal field + * @param networkService New value for network name + * @return Network name */ private String networkService; diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicPerformance.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicPerformance.java new file mode 100644 index 0000000..fae162d --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicPerformance.java @@ -0,0 +1,308 @@ +/* + * ============LICENSE_START========================================================= + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.dcae.apod.analytics.model.domain.cef; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * Describes the performance and errors of an identified virtual network interface card + *

+ * @author Rajiv Singla. Creation Date: 08/15/2017. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class VNicPerformance extends BaseCEFModel { + + + private static final long serialVersionUID = 1L; + + /** + * Cumulative count of broadcast packets received as read at the end of the measurement interval + * + * @param receivedBroadcastPacketsAccumulated New value for cumulative count of broadcast packets received as + * read at the end of the measurement interval + * @return Cumulative count of broadcast packets received as read at the end of the measurement interval + */ + private Long receivedBroadcastPacketsAccumulated; + + /** + * Count of broadcast packets received within the measurement interval + * + * @param receivedBroadcastPacketsDelta New value for count of broadcast packets received within the measurement + * interval + * @return Count of broadcast packets received within the measurement interval + */ + private Long receivedBroadcastPacketsDelta; + + /** + * Cumulative count of discarded packets received as read at the end of the measurement interval + * + * @param receivedDiscardedPacketsAccumulated New value for cumulative count of discarded packets received as read + * at the end of the measurement interval + * @return Cumulative count of discarded packets received as read at the end of the measurement interval + */ + private Long receivedDiscardedPacketsAccumulated; + + /** + * Count of discarded packets received within the measurement interval + * + * @param receivedDiscardedPacketsDelta New value for count of discarded packets received within the measurement + * interval + * @return Count of discarded packets received within the measurement interval + */ + private Long receivedDiscardedPacketsDelta; + + /** + * Cumulative count of error packets received as read at the end of the measurement interval + * + * @param receivedErrorPacketsAccumulated New value for cumulative count of error packets received as read at the + * end of the measurement interval + * @return Cumulative count of error packets received as read at the end of the measurement interval + */ + private Long receivedErrorPacketsAccumulated; + + /** + * Count of error packets received within the measurement interval + * + * @param receivedErrorPacketsDelta New value for count of error packets received within the measurement interval + * @return Count of error packets received within the measurement interval + */ + private Long receivedErrorPacketsDelta; + + /** + * Cumulative count of multicast packets received as read at the end of the measurement interval + * + * @param receivedMulticastPacketsAccumulated New value for cumulative count of multicast packets received as + * read at the end of the measurement interval + * @return Cumulative count of multicast packets received as read at the end of the measurement interval + */ + private Long receivedMulticastPacketsAccumulated; + + /** + * Count of multicast packets received within the measurement interval + * + * @param receivedMulticastPacketsDelta New value for count of multicast packets received within the measurement + * interval + * @return Count of multicast packets received within the measurement interval + */ + private Long receivedMulticastPacketsDelta; + + /** + * Cumulative count of octets received as read at the end of the measurement interval + * + * @param receivedOctetsAccumulated New value for cumulative count of octets received as read at the end of the + * measurement interval + * @return Cumulative count of octets received as read at the end of the measurement interval + */ + private Long receivedOctetsAccumulated; + + /** + * Count of octets received within the measurement interval + * + * @param receivedOctetsDelta New value for count of octets received within the measurement interval + * @return Count of octets received within the measurement interval + */ + private Long receivedOctetsDelta; + + /** + * Cumulative count of all packets received as read at the end of the measurement interval + * + * @param receivedTotalPacketsAccumulated New value for cumulative count of all packets received as read at the + * end of the measurement interval + * @return Cumulative count of all packets received as read at the end of the measurement interval + */ + private Long receivedTotalPacketsAccumulated; + + /** + * Count of all packets received within the measurement interval + * + * @param receivedTotalPacketsDelta New value for count of all packets received within the measurement interval + * @return Count of all packets received within the measurement interval + */ + private Long receivedTotalPacketsDelta; + + /** + * Cumulative count of unicast packets received as read at the end of the measurement interval + * + * @param receivedUnicastPacketsAccumulated New value for cumulative count of unicast packets received as read at + * the end of the measurement interval + * @return Cumulative count of unicast packets received as read at the end of the measurement interval + */ + private Long receivedUnicastPacketsAccumulated; + + /** + * Count of unicast packets received within the measurement interval + * + * @param receivedUnicastPacketsDelta New value for count of unicast packets received within the measurement + * interval + * @return Count of unicast packets received within the measurement interval + */ + private Long receivedUnicastPacketsDelta; + + /** + * Cumulative count of broadcast packets transmitted as read at the end of the measurement interval + * + * @param transmittedBroadcastPacketsAccumulated New value for cumulative count of broadcast packets transmitted + * as read at the end of the measurement interval + * @return Cumulative count of broadcast packets transmitted as read at the end of the measurement interval + */ + private Long transmittedBroadcastPacketsAccumulated; + + /** + * Count of broadcast packets transmitted within the measurement interval + * + * @param transmittedBroadcastPacketsDelta New value for count of broadcast packets transmitted within the + * measurement interval + * @return Count of broadcast packets transmitted within the measurement interval + */ + private Long transmittedBroadcastPacketsDelta; + + /** + * Cumulative count of discarded packets transmitted as read at the end of the measurement interval + * + * @param transmittedDiscardedPacketsAccumulated New value for cumulative count of discarded packets transmitted + * as read at the end of the measurement interval + * @return Cumulative count of discarded packets transmitted as read at the end of the measurement interval + */ + private Long transmittedDiscardedPacketsAccumulated; + + /** + * Count of discarded packets transmitted within the measurement interval + * + * @param transmittedDiscardedPacketsDelta New value for count of discarded packets transmitted within the + * measurement interval + * @return Count of discarded packets transmitted within the measurement interval + */ + private Long transmittedDiscardedPacketsDelta; + + /** + * Cumulative count of error packets transmitted as read at the end of the measurement interval + * + * @param transmittedErrorPacketsAccumulated New value for cumulative count of error packets transmitted as read + * at the end of the measurement interval + * @return Cumulative count of error packets transmitted as read at the end of the measurement interval + */ + private Long transmittedErrorPacketsAccumulated; + + /** + * Count of error packets transmitted within the measurement interval + * + * @param transmittedErrorPacketsDelta New value for count of error packets transmitted within the measurement + * interval + * @return Count of error packets transmitted within the measurement interval + */ + private Long transmittedErrorPacketsDelta; + + /** + * Cumulative count of multicast packets transmitted as read at the end of the measurement interval + * + * @param transmittedMulticastPacketsAccumulated New value for cumulative count of multicast packets transmitted + * as read at the end of the measurement interval + * @return Cumulative count of multicast packets transmitted as read at the end of the measurement interval + */ + private Long transmittedMulticastPacketsAccumulated; + + /** + * Count of multicast packets transmitted within the measurement interval + * + * @param transmittedMulticastPacketsDelta New value for count of multicast packets transmitted within the + * measurement interval + * @return Count of multicast packets transmitted within the measurement interval + */ + private Long transmittedMulticastPacketsDelta; + + /** + * Cumulative count of octets transmitted as read at the end of the measurement interval + * + * @param transmittedOctetsAccumulated New value for cumulative count of octets transmitted as read at the end of + * the measurement interval + * @return Cumulative count of octets transmitted as read at the end of the measurement interval + */ + private Long transmittedOctetsAccumulated; + + /** + * Count of octets transmitted within the measurement interval + * + * @param transmittedOctetsDelta New value for count of octets transmitted within the measurement interval + * @return Count of octets transmitted within the measurement interval + */ + private Long transmittedOctetsDelta; + + /** + * Cumulative count of all packets transmitted as read at the end of the measurement interval + * + * @param transmittedTotalPacketsAccumulated New value for cumulative count of all packets transmitted as read at + * the end of the measurement interval + * @return Cumulative count of all packets transmitted as read at the end of the measurement interval + */ + private Long transmittedTotalPacketsAccumulated; + + /** + * Count of all packets transmitted within the measurement interval + * + * @param transmittedTotalPacketsDelta New value for count of all packets transmitted within the measurement + * interval + * @return Count of all packets transmitted within the measurement interval + */ + private Long transmittedTotalPacketsDelta; + + /** + * Cumulative count of unicast packets transmitted as read at the end of the measurement interval + * + * @param transmittedUnicastPacketsAccumulated New value for cumulative count of unicast packets transmitted as + * read at the end of the measurement interval + * @return Cumulative count of unicast packets transmitted as read at the end of the measurement interval + */ + private Long transmittedUnicastPacketsAccumulated; + + + /** + * Count of unicast packets transmitted within the measurement interval + * + * @param transmittedUnicastPacketsDelta New value for count of unicast packets transmitted within the + * measurement interval + * @return Count of unicast packets transmitted within the measurement interval + */ + private Long transmittedUnicastPacketsDelta; + + + /** + * Indicates whether vNicPerformance values are likely inaccurate due to counter overflow or other conditions + * + * @param valuesAreSuspect New value to indicate whether vNicPerformance values are likely inaccurate due to + * counter overflow or other conditions + * @return Indicates whether vNicPerformance values are likely inaccurate due to counter overflow or other + * conditions + */ + private Boolean valuesAreSuspect; + + + /** + * Virtual Network Card Identifier + * + * @param vNicIdentifier New value for Virtual Network Card Identifier + * @return Virtual Network Card Identifier + */ + private String vNicIdentifier; + + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicUsageArray.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicUsageArray.java deleted file mode 100644 index e364ca0..0000000 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/cef/VNicUsageArray.java +++ /dev/null @@ -1,79 +0,0 @@ -/* - * ===============================LICENSE_START====================================== - * dcae-analytics - * ================================================================================ - * Copyright © 2017 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. - * 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. - * ============================LICENSE_END=========================================== - */ - -package org.openecomp.dcae.apod.analytics.model.domain.cef; - -import lombok.Data; -import lombok.EqualsAndHashCode; - -/** - * Usage of an array of virtual network interface cards - *

- * @author Rajiv Singla . Creation Date: 10/17/2016. - */ -@Data -@EqualsAndHashCode(callSuper = true) -public class VNicUsageArray extends BaseCEFModel { - - - private static final long serialVersionUID = 1L; - - /** - * Virtual Network Card - Bytes In - * - * @param bytesIn New value for Virtual Network Card - Bytes In - * @return Virtual Network Card - Bytes In - */ - private Long bytesIn; - - /** - * Virtual Network Card - Bytes Out - * - * @param bytesOut New value for Virtual Network Card - Bytes Out - * @return Virtual Network Card - Bytes Out - */ - private Long bytesOut; - - /** - * Virtual Network Card - Packets In - * - * @param packetsIn New value for Virtual Network Card - Packets In - * @return Virtual Network Card - Packets In - */ - private Long packetsIn; - - /** - * Virtual Network Card - Packets Out - * - * @param packetsOut New value for Virtual Network Card - Packets Out - * @return Virtual Network Card - Packets Out - */ - private Long packetsOut; - - /** - * Virtual Network Card Identifier - * - * @param vNicIdentifier New value for Virtual Network Card Identifier - * @return Virtual Network Card Identifier - */ - private String vNicIdentifier; - - -} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopEventStatus.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopEventStatus.java new file mode 100644 index 0000000..3f780af --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopEventStatus.java @@ -0,0 +1,14 @@ +package org.openecomp.dcae.apod.analytics.model.domain.policy.tca; + +/** + * TCA Policy Control Loop Event Status + * + * Author: rs153v (Rajiv Singla) . Creation Date: 9/11/2017. + */ +public enum ControlLoopEventStatus implements TCAPolicyModel { + + ONSET, + ABATED, + CONTINUE; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopSchemaType.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopSchemaType.java new file mode 100644 index 0000000..63d74ce --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/ControlLoopSchemaType.java @@ -0,0 +1,13 @@ +package org.openecomp.dcae.apod.analytics.model.domain.policy.tca; + +import org.openecomp.dcae.apod.analytics.model.domain.policy.PolicyModel; + +/** + * Control Loop Schema Type + * + * Author: rs153v (Rajiv Singla) . Creation Date: 8/24/2017. + */ +public enum ControlLoopSchemaType implements PolicyModel { + + VNF, VM; +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Direction.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Direction.java index dc85d97..8cad66b 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Direction.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Direction.java @@ -30,6 +30,12 @@ import javax.annotation.Nonnull; */ public enum Direction implements TCAPolicyModel { + EQUAL { + @Override + public Boolean operate(@Nonnull Long value1, @Nonnull Long value2) { + return value1.equals(value2); + } + }, LESS { @Override public Boolean operate(@Nonnull Long value1, @Nonnull Long value2) { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerEventName.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerEventName.java new file mode 100644 index 0000000..add1002 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerEventName.java @@ -0,0 +1,115 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.domain.policy.tca; + +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.util.ArrayList; +import java.util.List; + +/** + * TCA Metrics that need to applied to each Event Name + * + * @author Rajiv Singla . Creation Date: 11/5/2016. + */ +@Data +@EqualsAndHashCode(callSuper = true) +public class MetricsPerEventName extends BaseTCAPolicyModel{ + + + private static final long serialVersionUID = 1L; + + /** + * Event Name to which TCA Policy needs to applied. + * + * @param eventName New value for eventName to which TCA Policy needs to applied + * @return Event Name to which TCA Policy needs to applied + */ + private String eventName; + + /** + * Control Loop Schema Type + * + * @param controlLoopSchemaType New value for Control Loop Schema Type + * @return Control Loop Schema Type + */ + private ControlLoopSchemaType controlLoopSchemaType; + + /** + * Policy Scope + * + * @param policyScope New value for Policy Scope + * @return Policy Scope + */ + private String policyScope; + + /** + * Policy Name + * + * @param policyName New value for Policy Name + * @return Policy Name + */ + private String policyName; + + /** + * Policy Version + * + * @param policyVersion New value for Policy Version + * @return Policy Version + */ + private String policyVersion; + + /** + * Policy Thresholds + * + * @param thresholds New value for Policy Thresholds + * @return Policy Thresholds + */ + private List thresholds; + + + /** + * Creates a deep copy of given {@link MetricsPerEventName} + * + * @param metricsPerEventName metrics Per Event Name that need to copied + * + * @return copy of new metrics per event Name with values copied from given metrics per Event Name + */ + public static MetricsPerEventName copy(final MetricsPerEventName metricsPerEventName) { + final MetricsPerEventName newMetricsPerEventName = new MetricsPerEventName(); + newMetricsPerEventName.setEventName(metricsPerEventName.getEventName()); + newMetricsPerEventName.setControlLoopSchemaType(metricsPerEventName.getControlLoopSchemaType()); + newMetricsPerEventName.setPolicyScope(metricsPerEventName.getPolicyScope()); + newMetricsPerEventName.setPolicyName(metricsPerEventName.getPolicyName()); + newMetricsPerEventName.setPolicyVersion(metricsPerEventName.getPolicyVersion()); + if (metricsPerEventName.getThresholds() != null) { + List newThresholds = new ArrayList<>(metricsPerEventName.getThresholds().size()); + for( Threshold threshold : metricsPerEventName.getThresholds()) { + newThresholds.add(Threshold.copy(threshold)); + } + newMetricsPerEventName.setThresholds(newThresholds); + } + return newMetricsPerEventName; + } + + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerFunctionalRole.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerFunctionalRole.java deleted file mode 100644 index 4edbac1..0000000 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/MetricsPerFunctionalRole.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * ===============================LICENSE_START====================================== - * dcae-analytics - * ================================================================================ - * Copyright © 2017 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. - * 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. - * ============================LICENSE_END=========================================== - */ - -package org.openecomp.dcae.apod.analytics.model.domain.policy.tca; - -import lombok.Data; -import lombok.EqualsAndHashCode; - -import java.util.ArrayList; -import java.util.List; - -/** - * TCA Metrics that need to applied to each functional Role - * - * @author Rajiv Singla . Creation Date: 11/5/2016. - */ -@Data -@EqualsAndHashCode(callSuper = true) -public class MetricsPerFunctionalRole extends BaseTCAPolicyModel{ - - - private static final long serialVersionUID = 1L; - - /** - * Functional Role to which TCA Policy needs to applied. - * - * @param functionalRole New value for Functional Role to which TCA Policy needs to applied - * @return Functional Role to which TCA Policy needs to applied - */ - private String functionalRole; - - /** - * Policy Scope - * - * @param policyScope New value for Policy Scope - * @return Policy Scope - */ - private String policyScope; - - /** - * Policy Name - * - * @param policyName New value for Policy Name - * @return Policy Name - */ - private String policyName; - - /** - * Policy Version - * - * @param policyVersion New value for Policy Version - * @return Policy Version - */ - private String policyVersion; - - /** - * Policy Thresholds - * - * @param thresholds New value for Policy Thresholds - * @return Policy Thresholds - */ - private List thresholds; - - - /** - * Creates a copy of given {@link MetricsPerFunctionalRole} - * - * @param metricsPerFunctionalRole metrics Per functional role that need to copied - * - * @return copy of new metrics per function role with values copied from given metrics per functional role - */ - public static MetricsPerFunctionalRole copy(final MetricsPerFunctionalRole metricsPerFunctionalRole) { - final MetricsPerFunctionalRole newMetricsPerFunctionalRole = new MetricsPerFunctionalRole(); - newMetricsPerFunctionalRole.setFunctionalRole(metricsPerFunctionalRole.getFunctionalRole()); - newMetricsPerFunctionalRole.setPolicyScope(metricsPerFunctionalRole.getPolicyScope()); - newMetricsPerFunctionalRole.setPolicyName(metricsPerFunctionalRole.getPolicyName()); - newMetricsPerFunctionalRole.setPolicyVersion(metricsPerFunctionalRole.getPolicyVersion()); - if (metricsPerFunctionalRole.getThresholds() != null) { - newMetricsPerFunctionalRole.setThresholds(new ArrayList<>(metricsPerFunctionalRole.getThresholds())); - } - return newMetricsPerFunctionalRole; - } - - -} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/TCAPolicy.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/TCAPolicy.java index b62d91d..3ae113a 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/TCAPolicy.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/TCAPolicy.java @@ -22,7 +22,6 @@ package org.openecomp.dcae.apod.analytics.model.domain.policy.tca; import lombok.Data; import lombok.EqualsAndHashCode; -import org.openecomp.dcae.apod.analytics.model.domain.cef.CommonEventHeader; import java.util.List; @@ -40,7 +39,7 @@ public class TCAPolicy extends BaseTCAPolicyModel { private static final long serialVersionUID = 1L; /** - * TCA Policy domain which is associated with TCA incoming CEF message {@link CommonEventHeader#getDomain()} + * TCA Policy domain which is associated with TCA incoming CEF message domain * * @param domain New value for domain * @return Policy domain which is associated with incoming CEF message @@ -50,10 +49,10 @@ public class TCAPolicy extends BaseTCAPolicyModel { /** * Contains TCA Policy metrics that needs to be applied to each Functional Role * - * @param metricsPerFunctionalRole New value for metrics that needs to be applied to each Functional Role + * @param metricsPerEventName New value for metrics that needs to be applied to each Functional Role * @return Contains TCA Policy metrics that needs to be applied to each Functional Role */ - private List metricsPerFunctionalRole; + private List metricsPerEventName; } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Threshold.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Threshold.java index b23d109..e05cc26 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Threshold.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/domain/policy/tca/Threshold.java @@ -42,6 +42,15 @@ public class Threshold extends BaseTCAPolicyModel { */ private String closedLoopControlName; + + /** + * Closed Loop Event Status + * + * @param closedLoopEventStatus New value for Closed Loop Event Status + * @return Closed Loop Event Status + */ + private ControlLoopEventStatus closedLoopEventStatus; + /** * Threshold Version * @@ -85,16 +94,16 @@ public class Threshold extends BaseTCAPolicyModel { /** - * Actual Field value that caused the threshold violation. Ignored for deserialization + * Actual Field value that caused the threshold violation. Note: Ignored for serialization / deserialization * * - * @param actualFieldValue new value value for actual Field value that caused the violation + * @param actualFieldValue new value for actual Field value that caused the violation * @return actual field value that caused the violation */ private Long actualFieldValue; /** - * Creates a copy of give {@link Threshold} + * Creates a deep copy of give {@link Threshold} * * @param threshold threshold that need to be copied * @@ -103,6 +112,7 @@ public class Threshold extends BaseTCAPolicyModel { public static Threshold copy(final Threshold threshold) { final Threshold newThreshold = new Threshold(); newThreshold.setClosedLoopControlName(threshold.getClosedLoopControlName()); + newThreshold.setClosedLoopEventStatus(threshold.getClosedLoopEventStatus()); newThreshold.setFieldPath(threshold.getFieldPath()); newThreshold.setThresholdValue(threshold.getThresholdValue()); newThreshold.setDirection(threshold.getDirection()); diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/AnalyticsModelObjectMapperSupplier.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/AnalyticsModelObjectMapperSupplier.java index 75561a8..d21695a 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/AnalyticsModelObjectMapperSupplier.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/AnalyticsModelObjectMapperSupplier.java @@ -67,6 +67,8 @@ public class AnalyticsModelObjectMapperSupplier implements Supplier - * @author Rajiv Singla . Creation Date: 10/18/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class EventListenerMixin extends BaseCEFModelMixin { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventMixin.java index 9e9c96a..269ddb7 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventMixin.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; /** * Event Json Mixin class *

- * @author Rajiv Singla . Creation Date: 10/18/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class EventMixin extends BaseCEFModelMixin { diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventSeverityMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventSeverityMixin.java index 48aafcf..2c93ffe 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventSeverityMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/EventSeverityMixin.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; @@ -24,7 +24,7 @@ import org.openecomp.dcae.apod.analytics.model.util.json.mixin.JsonMixin; /** * - * @author Rajiv Singla . Creation Date: 11/5/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class EventSeverityMixin implements JsonMixin { } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/FieldMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/FieldMixin.java new file mode 100644 index 0000000..abb58df --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/FieldMixin.java @@ -0,0 +1,28 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; + +/** + * @author Rajiv Singla . Creation Date: 08/15/2017. + */ +public abstract class FieldMixin extends BaseCEFModelMixin { + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/InternalHeaderFieldsMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/InternalHeaderFieldsMixin.java new file mode 100644 index 0000000..0204962 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/InternalHeaderFieldsMixin.java @@ -0,0 +1,28 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; + +/** + * @author Rajiv Singla . Creation Date: 08/15/2017. + */ +public abstract class InternalHeaderFieldsMixin extends BaseCEFModelMixin { + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/MeasurementsForVfScalingFieldsMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/MeasurementsForVfScalingFieldsMixin.java index 8cde5d6..4b761a7 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/MeasurementsForVfScalingFieldsMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/MeasurementsForVfScalingFieldsMixin.java @@ -1,39 +1,39 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; import com.fasterxml.jackson.annotation.JsonGetter; import com.fasterxml.jackson.annotation.JsonSetter; -import org.openecomp.dcae.apod.analytics.model.domain.cef.VNicUsageArray; +import org.openecomp.dcae.apod.analytics.model.domain.cef.VNicPerformance; import java.util.List; /** - * @author Rajiv Singla . Creation Date: 10/18/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class MeasurementsForVfScalingFieldsMixin extends BaseCEFModelMixin { - @JsonSetter("vNicUsageArray") - public abstract void setVNicUsageArray(List vNicUsageArrays); + @JsonSetter("vNicPerformanceArray") + public abstract void setVNicPerformanceArray(List vNicPerformances); - @JsonGetter("vNicUsageArray") - public abstract List getVNicUsageArray(); + @JsonGetter("vNicPerformanceArray") + public abstract List getVNicPerformanceArray(); } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/NamedArrayOfFieldsMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/NamedArrayOfFieldsMixin.java new file mode 100644 index 0000000..603b6b9 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/NamedArrayOfFieldsMixin.java @@ -0,0 +1,28 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; + +/** + * @author Rajiv Singla . Creation Date: 08/15/2017. + */ +public abstract class NamedArrayOfFieldsMixin extends BaseCEFModelMixin { + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PerformanceCounterMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PerformanceCounterMixin.java index 2c049fe..b133318 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PerformanceCounterMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PerformanceCounterMixin.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; /** * CEF Performance Counter Mixin * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class PerformanceCounterMixin extends BaseCEFModelMixin { } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PriorityMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PriorityMixin.java index ee2404e..f095cb2 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PriorityMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/PriorityMixin.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; @@ -24,7 +24,7 @@ import org.openecomp.dcae.apod.analytics.model.util.json.mixin.JsonMixin; /** * - * @author Rajiv Singla . Creation Date: 11/5/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class PriorityMixin implements JsonMixin { } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/ThresholdCrossingAlertFieldsMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/ThresholdCrossingAlertFieldsMixin.java index 44e17ac..97c6be8 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/ThresholdCrossingAlertFieldsMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/ThresholdCrossingAlertFieldsMixin.java @@ -1,21 +1,21 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; @@ -23,7 +23,7 @@ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; /** * Mixin class for ThresholdCrossingAlertFields * - * @author Rajiv Singla . Creation Date: 11/3/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class ThresholdCrossingAlertFieldsMixin extends BaseCEFModelMixin { } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/VNicUsageArrayMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/VNicUsageArrayMixin.java index e882183..295c8c8 100644 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/VNicUsageArrayMixin.java +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/cef/VNicUsageArrayMixin.java @@ -1,48 +1,36 @@ /* - * ===============================LICENSE_START====================================== - * dcae-analytics + * ============LICENSE_START========================================================= + * dcae-analytics * ================================================================================ - * Copyright © 2017 AT&T Intellectual Property. All rights reserved. + * Copyright © 2017 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. - * You may obtain a copy of the License at + * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * 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. - * ============================LICENSE_END=========================================== + * ============LICENSE_END========================================================= */ package org.openecomp.dcae.apod.analytics.model.util.json.mixin.cef; -import com.fasterxml.jackson.annotation.JsonGetter; import com.fasterxml.jackson.annotation.JsonSetter; /** - * @author Rajiv Singla . Creation Date: 10/18/2016. + * @author Rajiv Singla. Creation Date: 08/15/2017. */ public abstract class VNicUsageArrayMixin extends BaseCEFModelMixin { - /** - * Provides hint to Jackson Jackson deserialization to bind "vNicIdentifier" string to "vNicIdentifier" - * variable in CEF parsed Java Object - * - * @param name of the vNicIdentifier - */ @JsonSetter("vNicIdentifier") public abstract void setVNicIdentifier(String name); - /** - * Provides hint to Jackson Jackson serialization to bind "vNicIdentifier" field to "vNicIdentifier" in json - * - * @return name of vNicIdentifier - */ - @JsonGetter("vNicIdentifier") - public abstract String getVNicIdentifier(); + @JsonSetter("vNicIdentifier") + public abstract String setVNicIdentifier(); } diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAAppConfigModelMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAAppConfigModelMixin.java new file mode 100644 index 0000000..2fa82a2 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAAppConfigModelMixin.java @@ -0,0 +1,9 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import org.openecomp.dcae.apod.analytics.model.util.json.mixin.BaseDynamicPropertiesProviderMixin; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public abstract class BaseTCAAppConfigModelMixin extends BaseDynamicPropertiesProviderMixin { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAHandleMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAHandleMixin.java new file mode 100644 index 0000000..6963b9c --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/BaseTCAHandleMixin.java @@ -0,0 +1,20 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import com.fasterxml.jackson.annotation.JsonProperty; +import org.openecomp.dcae.apod.analytics.model.config.tca.DMAAPInfo; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public abstract class BaseTCAHandleMixin extends BaseTCAAppConfigModelMixin { + + @JsonProperty("aaf_password") + String aafPassword; + @JsonProperty("aaf_username") + String aafUserName; + @JsonProperty("dmaap_info") + DMAAPInfo dmaapInfo; + @JsonProperty("type") + String type; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/DMAAPInfoMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/DMAAPInfoMixin.java new file mode 100644 index 0000000..bed8c4e --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/DMAAPInfoMixin.java @@ -0,0 +1,13 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ + +public abstract class DMAAPInfoMixin extends BaseTCAAppConfigModelMixin { + + @JsonProperty("topic_url") + String topicUrl; +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsPublishesMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsPublishesMixin.java new file mode 100644 index 0000000..fb074e5 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsPublishesMixin.java @@ -0,0 +1,14 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import com.fasterxml.jackson.annotation.JsonProperty; +import org.openecomp.dcae.apod.analytics.model.config.tca.TCAHandleOut; +import org.openecomp.dcae.apod.analytics.model.util.json.mixin.policy.tca.BaseTCAPolicyModelMixin; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public abstract class StreamsPublishesMixin extends BaseTCAPolicyModelMixin { + + @JsonProperty("tca_handle_out") + TCAHandleOut tcaHandleOut; +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsSubscribesMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsSubscribesMixin.java new file mode 100644 index 0000000..1593389 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/StreamsSubscribesMixin.java @@ -0,0 +1,14 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import com.fasterxml.jackson.annotation.JsonProperty; +import org.openecomp.dcae.apod.analytics.model.config.tca.TCAHandleIn; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public abstract class StreamsSubscribesMixin extends BaseTCAAppConfigModelMixin { + + @JsonProperty("tca_handle_in") + TCAHandleIn tcaHandleIn; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/TCAControllerAppConfigMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/TCAControllerAppConfigMixin.java new file mode 100644 index 0000000..98a77ec --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/config/tca/TCAControllerAppConfigMixin.java @@ -0,0 +1,17 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.config.tca; + +import com.fasterxml.jackson.annotation.JsonProperty; +import org.openecomp.dcae.apod.analytics.model.config.tca.StreamsPublishes; +import org.openecomp.dcae.apod.analytics.model.config.tca.StreamsSubscribes; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/25/2017. + */ +public abstract class TCAControllerAppConfigMixin extends BaseTCAAppConfigModelMixin { + + @JsonProperty("streams_publishes") + StreamsPublishes streamsPublishes; + @JsonProperty("streams_subscribes") + StreamsSubscribes streamsSubscribes; + +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopEventStatusMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopEventStatusMixin.java new file mode 100644 index 0000000..28798be --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopEventStatusMixin.java @@ -0,0 +1,30 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.policy.tca; + +import org.openecomp.dcae.apod.analytics.model.util.json.mixin.JsonMixin; + +/** + * + * @author Rajiv Singla . Creation Date: 9/11/2017. + */ +public abstract class ControlLoopEventStatusMixin implements JsonMixin { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopSchemaTypeMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopSchemaTypeMixin.java new file mode 100644 index 0000000..f0538ea --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/ControlLoopSchemaTypeMixin.java @@ -0,0 +1,9 @@ +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.policy.tca; + +import org.openecomp.dcae.apod.analytics.model.util.json.mixin.JsonMixin; + +/** + * Author: rs153v (Rajiv Singla) . Creation Date: 8/24/2017. + */ +public abstract class ControlLoopSchemaTypeMixin implements JsonMixin { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerEventNameMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerEventNameMixin.java new file mode 100644 index 0000000..0017a39 --- /dev/null +++ b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerEventNameMixin.java @@ -0,0 +1,28 @@ +/* + * ===============================LICENSE_START====================================== + * dcae-analytics + * ================================================================================ + * Copyright © 2017 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. + * 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. + * ============================LICENSE_END=========================================== + */ + +package org.openecomp.dcae.apod.analytics.model.util.json.mixin.policy.tca; + +/** + * + * @author Rajiv Singla . Creation Date: 11/5/2016. + */ +public abstract class MetricsPerEventNameMixin extends BaseTCAPolicyModelMixin { +} diff --git a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerFunctionalRoleMixin.java b/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerFunctionalRoleMixin.java deleted file mode 100644 index 8ca10fc..0000000 --- a/dcae-analytics-model/src/main/java/org/openecomp/dcae/apod/analytics/model/util/json/mixin/policy/tca/MetricsPerFunctionalRoleMixin.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * ===============================LICENSE_START====================================== - * dcae-analytics - * ================================================================================ - * Copyright © 2017 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. - * 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. - * ============================LICENSE_END=========================================== - */ - -package org.openecomp.dcae.apod.analytics.model.util.json.mixin.policy.tca; - -/** - * - * @author Rajiv Singla . Creation Date: 11/5/2016. - */ -public abstract class MetricsPerFunctionalRoleMixin extends BaseTCAPolicyModelMixin { -} -- cgit 1.2.3-korg