if (getSecurityGroups() != null) sb.append("SecurityGroups: ").append(getSecurityGroups()).append(","); if (getReplicationGroupId() != null) sb.append("ReplicationGroupId: ").append(getReplicationGroupId()).append(","); if (getSnapshotRetentionLimit() != null) sb.append("SnapshotRetentionLimit: ").append(getSnapshotRetentionLimit()).append(",");
hashCode = prime * hashCode + ((getAutoMinorVersionUpgrade() == null) ? 0 : getAutoMinorVersionUpgrade().hashCode()); hashCode = prime * hashCode + ((getSecurityGroups() == null) ? 0 : getSecurityGroups().hashCode()); hashCode = prime * hashCode + ((getReplicationGroupId() == null) ? 0 : getReplicationGroupId().hashCode()); hashCode = prime * hashCode + ((getSnapshotRetentionLimit() == null) ? 0 : getSnapshotRetentionLimit().hashCode()); hashCode = prime * hashCode + ((getSnapshotWindow() == null) ? 0 : getSnapshotWindow().hashCode());
if (other.getSecurityGroups() != null && other.getSecurityGroups().equals(this.getSecurityGroups()) == false) return false; if (other.getReplicationGroupId() == null ^ this.getReplicationGroupId() == null) return false; if (other.getReplicationGroupId() != null && other.getReplicationGroupId().equals(this.getReplicationGroupId()) == false) return false; if (other.getSnapshotRetentionLimit() == null ^ this.getSnapshotRetentionLimit() == null)
if (getSecurityGroups() != null) sb.append("SecurityGroups: ").append(getSecurityGroups()).append(","); if (getReplicationGroupId() != null) sb.append("ReplicationGroupId: ").append(getReplicationGroupId()).append(","); if (getSnapshotRetentionLimit() != null) sb.append("SnapshotRetentionLimit: ").append(getSnapshotRetentionLimit()).append(",");
Map<String,List<CacheCluster>> cacheMap = cacheClusterList.stream().collect(Collectors.groupingBy(cluster-> cluster.getReplicationGroupId()!=null?cluster.getReplicationGroupId():cluster.getCacheClusterId())); Map<String,ReplicationGroup> replGrpMap = replicationGroupList.stream().collect(Collectors.toMap(rplGrp -> rplGrp.getReplicationGroupId(),rplGrp->rplGrp));
hashCode = prime * hashCode + ((getAutoMinorVersionUpgrade() == null) ? 0 : getAutoMinorVersionUpgrade().hashCode()); hashCode = prime * hashCode + ((getSecurityGroups() == null) ? 0 : getSecurityGroups().hashCode()); hashCode = prime * hashCode + ((getReplicationGroupId() == null) ? 0 : getReplicationGroupId().hashCode()); hashCode = prime * hashCode + ((getSnapshotRetentionLimit() == null) ? 0 : getSnapshotRetentionLimit().hashCode()); hashCode = prime * hashCode + ((getSnapshotWindow() == null) ? 0 : getSnapshotWindow().hashCode());
if (other.getSecurityGroups() != null && other.getSecurityGroups().equals(this.getSecurityGroups()) == false) return false; if (other.getReplicationGroupId() == null ^ this.getReplicationGroupId() == null) return false; if (other.getReplicationGroupId() != null && other.getReplicationGroupId().equals(this.getReplicationGroupId()) == false) return false; if (other.getSnapshotRetentionLimit() == null ^ this.getSnapshotRetentionLimit() == null)
this.autoMinorVersionUpgrade = cacheCluster.getAutoMinorVersionUpgrade(); this.securityGroups = cacheCluster.getSecurityGroups().toString(); this.replicationGroupId = cacheCluster.getReplicationGroupId(); this.snapshotRetentionLimit = cacheCluster.getSnapshotRetentionLimit(); this.snapshotWindow = cacheCluster.getSnapshotWindow();