summaryrefslogtreecommitdiffstats
path: root/holmes-actions/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'holmes-actions/src/main/java')
-rw-r--r--holmes-actions/src/main/java/org/onap/holmes/common/engine/dao/EngineEntityDao.java3
-rw-r--r--holmes-actions/src/main/java/org/onap/holmes/common/engine/service/EngineEntityService.java3
-rw-r--r--holmes-actions/src/main/java/org/onap/holmes/common/engine/service/impl/EngineEntityServiceImpl.java5
3 files changed, 10 insertions, 1 deletions
diff --git a/holmes-actions/src/main/java/org/onap/holmes/common/engine/dao/EngineEntityDao.java b/holmes-actions/src/main/java/org/onap/holmes/common/engine/dao/EngineEntityDao.java
index 42e0bf4..5ca38e0 100644
--- a/holmes-actions/src/main/java/org/onap/holmes/common/engine/dao/EngineEntityDao.java
+++ b/holmes-actions/src/main/java/org/onap/holmes/common/engine/dao/EngineEntityDao.java
@@ -33,6 +33,9 @@ public interface EngineEntityDao {
@SqlQuery("SELECT * FROM ENGINE_ENTITY")
List<EngineEntity> getAllEntities();
+ @SqlQuery("SELECT DISTINCT(ENGINEINSTANCE) FROM APLUS_RULE")
+ List<String> getLegacyEngines();
+
@SqlUpdate("INSERT INTO ENGINE_ENTITY VALUES (:id, :ip, :port, :lastModified)")
void insertEntity(@BindBean EngineEntity entity);
diff --git a/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/EngineEntityService.java b/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/EngineEntityService.java
index 0baa4de..b913f38 100644
--- a/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/EngineEntityService.java
+++ b/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/EngineEntityService.java
@@ -16,7 +16,7 @@
package org.onap.holmes.common.engine.service;
-import org.glassfish.jersey.spi.Contract;
+import org.jvnet.hk2.annotations.Contract;
import org.onap.holmes.common.engine.entity.EngineEntity;
import java.util.List;
@@ -25,6 +25,7 @@ import java.util.List;
public interface EngineEntityService {
EngineEntity getEntity(String id);
List<EngineEntity> getAllEntities();
+ List<String> getLegacyEngines();
void updateEntity(EngineEntity entity);
void insertEntity(EngineEntity entity);
void deleteEntity(String id);
diff --git a/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/impl/EngineEntityServiceImpl.java b/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/impl/EngineEntityServiceImpl.java
index 926af13..62d2388 100644
--- a/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/impl/EngineEntityServiceImpl.java
+++ b/holmes-actions/src/main/java/org/onap/holmes/common/engine/service/impl/EngineEntityServiceImpl.java
@@ -46,6 +46,11 @@ public class EngineEntityServiceImpl implements EngineEntityService {
}
@Override
+ public List<String> getLegacyEngines() {
+ return engineEntityDao.getLegacyEngines();
+ }
+
+ @Override
public void updateEntity(EngineEntity entity) {
engineEntityDao.updateEntity(entity);
}