diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java
index 9d0f3d8..17f6dea 100644
--- a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java
+++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java
@@ -1,22 +1,18 @@
-/*-
- * ============LICENSE_START=======================================================
- * SDC
- * ================================================================================
- * Copyright (C) 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=========================================================
- */
+/*
+* Copyright © 2016-2018 European Support Limited
+*
+* 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.
+*/
 
 package org.openecomp.sdc.action.dao.types;
 
@@ -24,15 +20,15 @@
 import com.datastax.driver.mapping.annotations.Frozen;
 import com.datastax.driver.mapping.annotations.PartitionKey;
 import com.datastax.driver.mapping.annotations.Table;
+
+import java.util.Date;
+import java.util.Set;
+import java.util.stream.Collectors;
+
 import org.openecomp.core.utilities.json.JsonUtil;
 import org.openecomp.sdc.action.types.Action;
 import org.openecomp.sdc.versioning.dao.types.Version;
 
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.stream.Collectors;
-
 
 @Table(keyspace = "dox", name = "Action")
 public class ActionEntity {
@@ -51,17 +47,17 @@
   @Column(name = "name")
   private String name;
   @Column(name = "vendor_list")
-  private List<String> vendorList;
+  private Set<String> vendorList;
   @Column(name = "category_list")
-  private List<String> categoryList;
+  private Set<String> categoryList;
   @Column(name = "timestamp")
   private Date timestamp;
   @Column(name = "user")
   private String user;
   @Column(name = "supportedModels")
-  private List<String> supportedModels;
+  private Set<String> supportedModels;
   @Column(name = "supportedComponents")
-  private List<String> supportedComponents;
+  private Set<String> supportedComponents;
   @Column(name = "data")
   private String data;
 
@@ -119,7 +115,7 @@
     this.name = name;
   }
 
-  public List<String> getVendorList() {
+  public Set<String> getVendorList() {
     return vendorList;
   }
 
@@ -128,18 +124,12 @@
    *
    * @param vendorList the vendor list
    */
-  public void setVendorList(List<String> vendorList) {
-    if (vendorList != null && !vendorList.isEmpty()) {
-      List<String> lowerCaseVendorList = new ArrayList<>();
-      lowerCaseVendorList
-          .addAll(vendorList.stream().map(String::toLowerCase).collect(Collectors.toList()));
-      this.vendorList = lowerCaseVendorList;
-    } else {
-      this.vendorList = vendorList;
-    }
+  public void setVendorList(Set<String> vendorList) {
+    this.vendorList = vendorList != null && !vendorList.isEmpty() ?
+                              vendorList.stream().map(String::toLowerCase).collect(Collectors.toSet()) : vendorList;
   }
 
-  public List<String> getCategoryList() {
+  public Set<String> getCategoryList() {
     return categoryList;
   }
 
@@ -148,15 +138,10 @@
    *
    * @param categoryList the category list
    */
-  public void setCategoryList(List<String> categoryList) {
-    if (categoryList != null && !categoryList.isEmpty()) {
-      List<String> lowerCaseCategoryList = new ArrayList<>();
-      lowerCaseCategoryList
-          .addAll(categoryList.stream().map(String::toLowerCase).collect(Collectors.toList()));
-      this.categoryList = lowerCaseCategoryList;
-    } else {
-      this.categoryList = categoryList;
-    }
+  public void setCategoryList(Set<String> categoryList) {
+    this.categoryList = categoryList != null && !categoryList.isEmpty() ?
+                                categoryList.stream().map(String::toLowerCase).collect(Collectors.toSet()) :
+                                categoryList;
   }
 
   public Date getTimestamp() {
@@ -175,19 +160,19 @@
     this.user = user;
   }
 
-  public List<String> getSupportedModels() {
+  public Set<String> getSupportedModels() {
     return supportedModels;
   }
 
-  public void setSupportedModels(List<String> supportedModels) {
+  public void setSupportedModels(Set<String> supportedModels) {
     this.supportedModels = supportedModels;
   }
 
-  public List<String> getSupportedComponents() {
+  public Set<String> getSupportedComponents() {
     return supportedComponents;
   }
 
-  public void setSupportedComponents(List<String> supportedComponents) {
+  public void setSupportedComponents(Set<String> supportedComponents) {
     this.supportedComponents = supportedComponents;
   }
 
diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java
index cde97bc..0acd051 100644
--- a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java
+++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java
@@ -1,34 +1,33 @@
-/*-
- * ============LICENSE_START=======================================================
- * SDC
- * ================================================================================
- * Copyright (C) 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=========================================================
- */
+/*
+* Copyright © 2016-2018 European Support Limited
+*
+* 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.
+*/
+
 
 package org.openecomp.sdc.action.types;
 
+import java.util.Date;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Set;
+
 import org.openecomp.sdc.action.ActionConstants;
 import org.openecomp.sdc.action.dao.types.ActionEntity;
 import org.openecomp.sdc.versioning.dao.types.Version;
 
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.List;
-
 public class Action implements Comparable {
   private String actionUuId;
   private String actionInvariantUuId;
@@ -40,8 +39,8 @@
   private List<String> categoryList;
   private Date timestamp;
   private String user;
-  private List<HashMap<String, String>> supportedModels;
-  private List<HashMap<String, String>> supportedComponents;
+  private List<Map<String, String>> supportedModels;
+  private List<Map<String, String>> supportedComponents;
   //private List<HashMap<String,String>> artifacts;
   private List<ActionArtifact> artifacts;
   private String data;
@@ -151,19 +150,19 @@
     this.user = user;
   }
 
-  public List<HashMap<String, String>> getSupportedModels() {
+  public List<Map<String, String>> getSupportedModels() {
     return supportedModels;
   }
 
-  public void setSupportedModels(List<HashMap<String, String>> supportedModels) {
+  public void setSupportedModels(List<Map<String, String>> supportedModels) {
     this.supportedModels = supportedModels;
   }
 
-  public List<HashMap<String, String>> getSupportedComponents() {
+  public List<Map<String, String>> getSupportedComponents() {
     return supportedComponents;
   }
 
-  public void setSupportedComponents(List<HashMap<String, String>> supportedComponents) {
+  public void setSupportedComponents(List<Map<String, String>> supportedComponents) {
     this.supportedComponents = supportedComponents;
   }
 
@@ -197,8 +196,12 @@
     destination.setActionInvariantUuId(
         this.getActionInvariantUuId() != null ? this.getActionInvariantUuId().toUpperCase() : null);
     destination.setName(this.getName() != null ? this.getName().toLowerCase() : null);
-    destination.setVendorList(this.getVendorList());
-    destination.setCategoryList(this.getCategoryList());
+    if (Objects.nonNull(this.getVendorList())) {
+      destination.setVendorList(new HashSet<>(this.getVendorList()));
+    }
+    if (Objects.nonNull(this.getCategoryList())) {
+      destination.setCategoryList(new HashSet<>(this.getCategoryList()));
+    }
     destination.setTimestamp(this.getTimestamp());
     destination.setUser(this.getUser());
     destination.setVersion(Version.valueOf(this.getVersion()));
@@ -213,10 +216,10 @@
     return destination;
   }
 
-  private List<String> getIdFromMap(List<HashMap<String, String>> map, String idName) {
-    List<String> list = new ArrayList<>();
+  private Set<String> getIdFromMap(List<Map<String, String>> map, String idName) {
+    Set<String> list = new HashSet<>();
     if (map != null && !map.isEmpty()) {
-      for (HashMap<String, String> entry : map) {
+      for (Map<String, String> entry : map) {
         if (entry.containsKey(idName)) {
           list.add(entry.get(idName) != null ? entry.get(idName).toLowerCase() : null);
         }
diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java
index c2d67a7..5320b5d 100644
--- a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java
+++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java
@@ -16,6 +16,30 @@
 
 package org.openecomp.sdc.action.dao.impl;
 
+import static com.datastax.driver.core.querybuilder.QueryBuilder.eq;
+import static com.datastax.driver.core.querybuilder.QueryBuilder.in;
+import static com.datastax.driver.core.querybuilder.QueryBuilder.set;
+import static org.openecomp.core.nosqldb.impl.cassandra.CassandraSessionFactory.getSession;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_CATEGORY;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_MODEL;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_NAME;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_NONE;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_OPEN_ECOMP_COMPONENT;
+import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_VENDOR;
+import static org.openecomp.sdc.action.ActionConstants.STATUS;
+import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY;
+import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY_DB;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_NOT_LOCKED_CODE;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_NOT_LOCKED_MSG;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_QUERY_FAILURE_CODE;
+import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_QUERY_FAILURE_MSG;
+
 import com.datastax.driver.core.ResultSet;
 import com.datastax.driver.core.Row;
 import com.datastax.driver.core.Statement;
@@ -25,6 +49,16 @@
 import com.datastax.driver.mapping.Result;
 import com.datastax.driver.mapping.annotations.Accessor;
 import com.datastax.driver.mapping.annotations.Query;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.stream.Collectors;
+
 import org.openecomp.core.dao.impl.CassandraBaseDao;
 import org.openecomp.core.nosqldb.api.NoSqlDb;
 import org.openecomp.core.nosqldb.factory.NoSqlDbFactory;
@@ -54,14 +88,6 @@
 import org.openecomp.sdc.versioning.types.VersionableEntityMetadata;
 import org.slf4j.MDC;
 
-import java.util.*;
-import java.util.stream.Collectors;
-
-import static com.datastax.driver.core.querybuilder.QueryBuilder.*;
-import static org.openecomp.core.nosqldb.impl.cassandra.CassandraSessionFactory.getSession;
-import static org.openecomp.sdc.action.ActionConstants.*;
-import static org.openecomp.sdc.action.errors.ActionErrorConstants.*;
-
 
 public class ActionDaoImpl extends CassandraBaseDao<ActionEntity> implements ActionDao {
   private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface();
@@ -330,7 +356,7 @@
         ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID,
             TARGET_ENTITY_DB);
         Result<ActionEntity> result =
-            accessor.getActionsByInvId(actionInvariantUuId, viewableVersions);
+            accessor.getActionsByInvId(actionInvariantUuId, new ArrayList<>(viewableVersions));
         ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false);
         log.metrics("");
         if (result != null) {
@@ -365,7 +391,7 @@
           versions.add(versionInfoEntity.getCandidate().getVersion());
           ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID,
               TARGET_ENTITY_DB);
-          Result<ActionEntity> result = accessor.getActionsByInvId(actionInvariantUuId, versions);
+          Result<ActionEntity> result = accessor.getActionsByInvId(actionInvariantUuId, new ArrayList<>(versions));
           ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false);
           log.metrics("");
           if (result != null) {
@@ -482,7 +508,7 @@
     Result<ActionEntity> getAllActions();
 
     @Query("SELECT * FROM Action where actionInvariantUuId = ? and version in ? ")
-    Result<ActionEntity> getActionsByInvId(String actionInvariantUuId, Set<Version> versions);
+    Result<ActionEntity> getActionsByInvId(String actionInvariantUuId, List<Version> versions);
 
     @Query("SELECT * FROM Action where supportedModels CONTAINS ?")
     Result<ActionEntity> getActionsByModel(String resource);
diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml
index 88002d9..1642ca2 100644
--- a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml
+++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml
@@ -14,6 +14,11 @@
 
     <dependencies>
         <dependency>
+            <groupId>com.datastax.cassandra</groupId>
+            <artifactId>cassandra-driver-extras</artifactId>
+            <version>${datastax.cassandra.version}</version>
+        </dependency>
+        <dependency>
             <groupId>org.openecomp.sdc.core</groupId>
             <artifactId>openecomp-session-lib</artifactId>
             <version>${project.version}</version>
diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java
index 3404887..4df6773 100644
--- a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java
+++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java
@@ -16,16 +16,19 @@
 
 package org.openecomp.sdc.versioning.dao.impl;
 
+import com.datastax.driver.extras.codecs.enums.EnumNameCodec;
 import com.datastax.driver.mapping.Mapper;
 import com.datastax.driver.mapping.Result;
 import com.datastax.driver.mapping.annotations.Accessor;
 import com.datastax.driver.mapping.annotations.Query;
+
+import java.util.Collection;
+
 import org.openecomp.core.dao.impl.CassandraBaseDao;
 import org.openecomp.core.nosqldb.api.NoSqlDb;
 import org.openecomp.sdc.versioning.dao.VersionInfoDao;
 import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity;
-
-import java.util.Collection;
+import org.openecomp.sdc.versioning.dao.types.VersionStatus;
 
 public class VersionInfoDaoImpl extends CassandraBaseDao<VersionInfoEntity>
     implements VersionInfoDao {
@@ -40,6 +43,8 @@
     this.noSqlDb = noSqlDb;
     this.mapper = this.noSqlDb.getMappingManager().mapper(VersionInfoEntity.class);
     this.accessor = this.noSqlDb.getMappingManager().createAccessor(VersionInfoAccessor.class);
+    this.noSqlDb.getMappingManager().getSession().getCluster().getConfiguration().getCodecRegistry()
+            .register(new EnumNameCodec<>(VersionStatus.class));
   }
 
   @Override
