From 7328b3f1e9eb1804911dfe9dcede792fd711d51f Mon Sep 17 00:00:00 2001 From: "Benjamin, Max (mb388a)" Date: Sun, 21 Apr 2019 11:11:21 -0400 Subject: Status message for create vf module event audit Added appc to application-test due to new dependency in openstack Updated exception class to inject mock into class for junits. Added error handling support for when create audit fails. Added error handling for when create audit fails and added test Updated test schema file to create table and added field. Updated pom file to relfect typo in change made. Updated locaton of pojos for audit code Updated test schema file to create table and added field. Updated pom file to relfect typo in change made. Comitting files that i forgot to stage from previous commit Updated locaton of pojos for audit code Additional fixes including vnfcname and null check Fixed bug in delete audit failure check and reverted gateway change. Change-Id: I993ce377dd6407960a65b4940d83d8162b24633c Issue-ID: SO-1792 Signed-off-by: Benjamin, Max (mb388a) --- .../org/onap/so/objects/audit/AAIObjectAudit.java | 56 ++++++++++++++++++++++ .../onap/so/objects/audit/AAIObjectAuditList.java | 46 ++++++++++++++++++ 2 files changed, 102 insertions(+) create mode 100644 common/src/main/java/org/onap/so/objects/audit/AAIObjectAudit.java create mode 100644 common/src/main/java/org/onap/so/objects/audit/AAIObjectAuditList.java (limited to 'common') diff --git a/common/src/main/java/org/onap/so/objects/audit/AAIObjectAudit.java b/common/src/main/java/org/onap/so/objects/audit/AAIObjectAudit.java new file mode 100644 index 0000000000..a27e8fbbd1 --- /dev/null +++ b/common/src/main/java/org/onap/so/objects/audit/AAIObjectAudit.java @@ -0,0 +1,56 @@ +package org.onap.so.objects.audit; + +import java.io.Serializable; +import java.net.URI; +import org.apache.commons.lang3.builder.ToStringBuilder; + +public class AAIObjectAudit implements Serializable { + + /** + * + */ + private static final long serialVersionUID = -4560928512855386021L; + private boolean doesObjectExist = false; + private Object aaiObject; + private URI resourceURI; + private String aaiObjectType; + + @Override + public String toString() { + return new ToStringBuilder(this).append("doesObjectExist", doesObjectExist).append("aaiObject", aaiObject) + .append("resourceURI", resourceURI).append("aaiObjectType", aaiObjectType).toString(); + } + + public String getAaiObjectType() { + return aaiObjectType; + } + + public void setAaiObjectType(String aaiObjectType) { + this.aaiObjectType = aaiObjectType; + } + + public boolean isDoesObjectExist() { + return doesObjectExist; + } + + public void setDoesObjectExist(boolean doesObjectExist) { + this.doesObjectExist = doesObjectExist; + } + + public Object getAaiObject() { + return aaiObject; + } + + public void setAaiObject(Object aaiObject) { + this.aaiObject = aaiObject; + } + + public URI getResourceURI() { + return resourceURI; + } + + public void setResourceURI(URI resourceURI) { + this.resourceURI = resourceURI; + } + +} diff --git a/common/src/main/java/org/onap/so/objects/audit/AAIObjectAuditList.java b/common/src/main/java/org/onap/so/objects/audit/AAIObjectAuditList.java new file mode 100644 index 0000000000..675701d598 --- /dev/null +++ b/common/src/main/java/org/onap/so/objects/audit/AAIObjectAuditList.java @@ -0,0 +1,46 @@ +package org.onap.so.objects.audit; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; +import org.apache.commons.lang3.builder.ToStringBuilder; + + +public class AAIObjectAuditList implements Serializable { + + /** + * + */ + private static final long serialVersionUID = 6712662349909726930L; + private List auditList = new ArrayList<>(); + private String auditType; + private String heatStackName; + + @Override + public String toString() { + return new ToStringBuilder(this).append("auditList", auditList).toString(); + } + + public List getAuditList() { + return auditList; + } + + + public String getAuditType() { + return auditType; + } + + + public void setAuditType(String auditType) { + this.auditType = auditType; + } + + public String getHeatStackName() { + return heatStackName; + } + + public void setHeatStackName(String heatStackName) { + this.heatStackName = heatStackName; + } + +} -- cgit 1.2.3-korg