managed/src/main/java/com/yugabyte/yw/common/PlacementInfoUtil.java
// Check if there are multiple zones for deployment in the provider config.
Check if there are multiple zones for deployment in the provider config.
Check if there are multiple zones for deployment in the provider config .
public static boolean isMultiAZ(Provider provider) {
    List<Region> regionList = Region.getByProvider(provider.uuid);
    if (regionList.size() > 1) {
      return true;
    }
    Region region = regionList.get(0);
    if (region == null) {
      throw new RuntimeException("No Regions found");
    }
    List<AvailabilityZone> azList = AvailabilityZone.getAZsForRegion(region.uuid);
    if (azList.size() > 1) {
      return true;
    }
    return false;
  }
public static boolean isMultiAZ ( Provider provider ) { List < Region > regionList = Region . getByProvider ( provider . uuid ) ; if ( regionList . size ( ) > 1 ) { return true ; } Region region = regionList . get ( 0 ) ; if ( region == null ) { throw new RuntimeException ( "No Regions found" ) ; } List < AvailabilityZone > azList = AvailabilityZone . getAZsForRegion ( region . uuid ) ; if ( azList . size ( ) > 1 ) { return true ; } return false ; }
Check if there are multiple zones for deployment in the provider config.
Check if there are multiple zones for deployment in the provider config .