List of usage examples for com.amazonaws.services.rds.model DBClusterMember isClusterWriter
Boolean isClusterWriter
To view the source code for com.amazonaws.services.rds.model DBClusterMember isClusterWriter.
Click Source Link
Value that is true if the cluster member is the primary instance for the DB cluster and false otherwise.
From source file:com.airbnb.billow.RDSInstance.java
private boolean checkIfMaster(DBInstance instance, DBCluster cluster) { if (instance.getDBClusterIdentifier() == null || cluster == null) { // It's NOT a member of a DB cluster return readReplicaSourceDBInstanceIdentifier == null; } else {//from www .j a va 2 s . com // It's a member of a DB cluster for (DBClusterMember member : cluster.getDBClusterMembers()) { if (member.getDBInstanceIdentifier().equals(dBInstanceIdentifier) && member.isClusterWriter()) { return true; } } return false; } }