diff options
Diffstat (limited to 'src/main/java/org/onap/dcae/common')
-rw-r--r-- | src/main/java/org/onap/dcae/common/ControllerActivationState.java | 25 | ||||
-rw-r--r-- | src/main/java/org/onap/dcae/common/EventProcessor.java | 4 |
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);
|