|
|
@ -708,7 +708,6 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
}
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
int index = 1;
|
|
|
|
|
|
|
|
List<String> subscribedUsers = new ArrayList<>();
|
|
|
|
List<String> subscribedUsers = new ArrayList<>();
|
|
|
|
String sql = "SELECT "
|
|
|
|
String sql = "SELECT "
|
|
|
|
+ "US.USER_NAME AS USER "
|
|
|
|
+ "US.USER_NAME AS USER "
|
|
|
@ -716,10 +715,10 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
+ "WHERE "
|
|
|
|
+ "WHERE "
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
try (PreparedStatement stmt = conn.prepareStatement(sql)) {
|
|
|
|
try (PreparedStatement stmt = conn.prepareStatement(sql)) {
|
|
|
|
stmt.setInt(index++, appReleaseId);
|
|
|
|
stmt.setInt(1, appReleaseId);
|
|
|
|
stmt.setInt(index++, tenantId);
|
|
|
|
stmt.setInt(2, tenantId);
|
|
|
|
stmt.setInt(index++, offsetValue);
|
|
|
|
stmt.setInt(3, offsetValue);
|
|
|
|
stmt.setInt(index, limitValue);
|
|
|
|
stmt.setInt(4, limitValue);
|
|
|
|
try (ResultSet rs = stmt.executeQuery()) {
|
|
|
|
try (ResultSet rs = stmt.executeQuery()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
subscribedUsers.add(rs.getString("USER"));
|
|
|
|
subscribedUsers.add(rs.getString("USER"));
|
|
|
@ -749,7 +748,6 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
}
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
int index = 1;
|
|
|
|
|
|
|
|
List<String> subscribedRoles = new ArrayList<>();
|
|
|
|
List<String> subscribedRoles = new ArrayList<>();
|
|
|
|
String sql = "SELECT "
|
|
|
|
String sql = "SELECT "
|
|
|
|
+ "US.ROLE_NAME AS ROLE "
|
|
|
|
+ "US.ROLE_NAME AS ROLE "
|
|
|
@ -757,10 +755,10 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
+ "WHERE "
|
|
|
|
+ "WHERE "
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
try (PreparedStatement ps = conn.prepareStatement(sql)) {
|
|
|
|
try (PreparedStatement ps = conn.prepareStatement(sql)) {
|
|
|
|
ps.setInt(index++, appReleaseId);
|
|
|
|
ps.setInt(1, appReleaseId);
|
|
|
|
ps.setInt(index++, tenantId);
|
|
|
|
ps.setInt(2, tenantId);
|
|
|
|
ps.setInt(index++, offsetValue);
|
|
|
|
ps.setInt(3, offsetValue);
|
|
|
|
ps.setInt(index, limitValue);
|
|
|
|
ps.setInt(4, limitValue);
|
|
|
|
try (ResultSet rs = ps.executeQuery()) {
|
|
|
|
try (ResultSet rs = ps.executeQuery()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
subscribedRoles.add(rs.getString("ROLE"));
|
|
|
|
subscribedRoles.add(rs.getString("ROLE"));
|
|
|
@ -790,7 +788,6 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
}
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
Connection conn = this.getDBConnection();
|
|
|
|
int index = 1;
|
|
|
|
|
|
|
|
List<String> subscribedGroups = new ArrayList<>();
|
|
|
|
List<String> subscribedGroups = new ArrayList<>();
|
|
|
|
String sql = "SELECT "
|
|
|
|
String sql = "SELECT "
|
|
|
|
+ "GS.GROUP_NAME AS GROUPS "
|
|
|
|
+ "GS.GROUP_NAME AS GROUPS "
|
|
|
@ -798,10 +795,10 @@ public class GenericSubscriptionDAOImpl extends AbstractDAOImpl implements Subsc
|
|
|
|
+ "WHERE "
|
|
|
|
+ "WHERE "
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
+ "AP_APP_RELEASE_ID = ? AND TENANT_ID = ? LIMIT ?,?";
|
|
|
|
try (PreparedStatement ps = conn.prepareStatement(sql)) {
|
|
|
|
try (PreparedStatement ps = conn.prepareStatement(sql)) {
|
|
|
|
ps.setInt(index++, appReleaseId);
|
|
|
|
ps.setInt(1, appReleaseId);
|
|
|
|
ps.setInt(index++, tenantId);
|
|
|
|
ps.setInt(2, tenantId);
|
|
|
|
ps.setInt(index++, offsetValue);
|
|
|
|
ps.setInt(3, offsetValue);
|
|
|
|
ps.setInt(index, limitValue);
|
|
|
|
ps.setInt(4, limitValue);
|
|
|
|
try (ResultSet rs = ps.executeQuery()) {
|
|
|
|
try (ResultSet rs = ps.executeQuery()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
while (rs.next()) {
|
|
|
|
subscribedGroups.add(rs.getString("GROUPS"));
|
|
|
|
subscribedGroups.add(rs.getString("GROUPS"));
|
|
|
|