summaryrefslogtreecommitdiffstats
path: root/auth
diff options
context:
space:
mode:
authorJonathan Gathman <jonathan.gathman@att.com>2019-09-17 08:24:00 +0000
committerGerrit Code Review <gerrit@onap.org>2019-09-17 08:24:00 +0000
commitdcc2eb2195c07a5557b58103594cd30ecf72e6c7 (patch)
tree5a0434733d487dfd2cd9e6baf443c5f094594189 /auth
parentf59081e0ce173f1786325c85385491e76b376ad0 (diff)
parentf9901518f13b32233541032667a5ff3aca9e17f8 (diff)
Merge "Sonar fix: ApprovalDAO.java"
Diffstat (limited to 'auth')
-rw-r--r--auth/auth-cass/src/main/java/org/onap/aaf/auth/dao/cass/ApprovalDAO.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/auth/auth-cass/src/main/java/org/onap/aaf/auth/dao/cass/ApprovalDAO.java b/auth/auth-cass/src/main/java/org/onap/aaf/auth/dao/cass/ApprovalDAO.java
index 7e90bbb9..5583dc03 100644
--- a/auth/auth-cass/src/main/java/org/onap/aaf/auth/dao/cass/ApprovalDAO.java
+++ b/auth/auth-cass/src/main/java/org/onap/aaf/auth/dao/cass/ApprovalDAO.java
@@ -57,6 +57,7 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
private PSInfo psByTicket;
private PSInfo psByStatus;
+ private static final int KEYLIMIT = 1;
public ApprovalDAO(AuthzTrans trans, Cluster cluster, String keyspace) {
super(trans, ApprovalDAO.class.getSimpleName(),cluster,keyspace,Data.class,TABLE, readConsistency(trans,TABLE), writeConsistency(trans,TABLE));
@@ -71,7 +72,6 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
init(trans);
}
- private static final int KEYLIMIT = 1;
public static class Data {
public UUID id;
public UUID ticket;
@@ -81,7 +81,6 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
public String status;
public String memo;
public String operation;
-// public Date last_notified;
public Date updated;
}
@@ -102,7 +101,6 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
data.status = row.getString(5);
data.memo = row.getString(6);
data.operation = row.getString(7);
-// data.last_notified = row.getTimestamp(8);
// This is used to get "WRITETIME(STATUS)" from Approval, which gives us an "updated"
if (row.getColumnDefinitions().size()>8) {
// Rows reported in MicroSeconds
@@ -117,8 +115,8 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
}
@Override
- protected void body(Data data, int _idx, Object[] obj) {
- int idx = _idx;
+ protected void body(Data data, int idxParam, Object[] obj) {
+ int idx = idxParam;
obj[idx]=data.ticket;
obj[++idx]=data.user;
obj[++idx]=data.approver;
@@ -126,7 +124,6 @@ public class ApprovalDAO extends CassDAOImpl<AuthzTrans,ApprovalDAO.Data> {
obj[++idx]=data.status;
obj[++idx]=data.memo;
obj[++idx]=data.operation;
-// obj[++idx]=data.last_notified;
}
}