in src/main/java/software/amazon/msk/auth/iam/internals/AuthenticationRequestParams.java [58:67]
public static AuthenticationRequestParams create(@NonNull String host,
AWSCredentials credentials,
@NonNull String userAgent) throws IllegalArgumentException {
Region region = Optional.ofNullable(regionMetadata.tryGetRegionByEndpointDnsSuffix(host))
.orElseGet(() -> Regions.getCurrentRegion());
if (region == null) {
throw new IllegalArgumentException("Host " + host + " does not belong to a valid region.");
}
return new AuthenticationRequestParams(VERSION_1, host, credentials, region, userAgent);
}