summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/onap/dcae/common
diff options
context:
space:
mode:
authors00370346 <swarup.nayak1@huawei.com>2019-03-27 10:06:03 +0530
committers00370346 <swarup.nayak1@huawei.com>2019-03-27 10:06:03 +0530
commit0429a71c2ca41cd311473c9485fa98bbcadaa542 (patch)
tree154e705c0e5c5ee5d8d1d774b8591b18e71ded15 /src/main/java/org/onap/dcae/common
parent82c26b5b8e7e92dfd9108684290e3a596b800e62 (diff)
Issue-ID: DCAEGEN2-1055 RestConfCollector bug fixes
Change-Id: I4623217ab69eaeecf1b5704172ad4de37e641312 Signed-off-by: s00370346 <swarup.nayak1@huawei.com>
Diffstat (limited to 'src/main/java/org/onap/dcae/common')
-rw-r--r--src/main/java/org/onap/dcae/common/ControllerActivationState.java25
-rw-r--r--src/main/java/org/onap/dcae/common/EventProcessor.java4
2 files changed, 27 insertions, 2 deletions
diff --git a/src/main/java/org/onap/dcae/common/ControllerActivationState.java b/src/main/java/org/onap/dcae/common/ControllerActivationState.java
new file mode 100644
index 0000000..deb2b1f
--- /dev/null
+++ b/src/main/java/org/onap/dcae/common/ControllerActivationState.java
@@ -0,0 +1,25 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * org.onap.dcaegen2.collectors.restconf
+ * ================================================================================
+ * Copyright (C) 2018-2019 Huawei. 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.onap.dcae.common;
+
+public enum ControllerActivationState {
+ INIT, ACTIVE, NONE;
+}
diff --git a/src/main/java/org/onap/dcae/common/EventProcessor.java b/src/main/java/org/onap/dcae/common/EventProcessor.java
index 164aed3..cf44921 100644
--- a/src/main/java/org/onap/dcae/common/EventProcessor.java
+++ b/src/main/java/org/onap/dcae/common/EventProcessor.java
@@ -76,9 +76,9 @@ public class EventProcessor implements Runnable {
private void sendEventsToStreams(String[] streamIdList, EventData ev) {
for (String aStreamIdList : streamIdList) {
log.info("Invoking publisher for streamId:" + aStreamIdList);
- if (!ev.getConn().getEvent_ruleId().equals("")) {
+ if (!ev.getConn().getEventRuleId().equals("")) {
JSONObject customHeader = new JSONObject();
- customHeader.put("rule-id", ev.getConn().getEvent_ruleId());
+ customHeader.put("rule-id", ev.getConn().getEventRuleId());
eventPublisher.sendEvent(overrideEvent(customHeader, ev.getEventObj()), aStreamIdList);
} else {
eventPublisher.sendEvent(ev.getEventObj(), aStreamIdList);