diff --git a/code/ddns-lambda.py b/code/ddns-lambda.py index 3750702..af0cdfa 100755 --- a/code/ddns-lambda.py +++ b/code/ddns-lambda.py @@ -73,7 +73,7 @@ LOGGER = logging.getLogger() account_id = None region = None -VERSION = '1.2.0b87' +VERSION = '1.2.0b88' # Read Env variables DEBUG_LOG_LEVEL = os.environ.get('DebugLogLevel', 'INFO') @@ -1035,7 +1035,7 @@ def lambda_handler( LOGGER.debug(f"cname_target: {final_private_dns_name} {lineno()}") if emr_status.is_cluster: LOGGER.info( - f"instance {instance_id}: is_cluster && is_master cluster_id {cluster_id} setting CNAME {cf_hostname} in zone {cf_zonename} {lineno()}") + f"instance {instance_id}: is_cluster && is_master cluster_id {emr_status.cluster_id} setting CNAME {cf_hostname} in zone {cf_zonename} {lineno()}") create_response = create_resource_record( route53, @@ -3308,17 +3308,12 @@ def discover_emr_cluster(tags): :return (bool,str): Tuple containing is_master, is_cluster, and cluster_id if it's a cluster. cluster_id will be empty if not a cluster. """ - LOGGER.info(f"discover_emr tags {tags}") cluster_tuple = namedtuple('EMRCluster', ['is_cluster', 'is_master', 'cluster_id']) cluster_id = tags.get('emr:elasticmapreduce:job-flow-id', '') - LOGGER.info(f"discover_emr cluster_id {cluster_id}") is_master = tags.get('emr:elasticmapreduce:instance-group-role', '') == 'MASTER' - LOGGER.info(f"discover_emr is_master {is_master}") is_cluster = cluster_id != '' - LOGGER.info(f"discover_emr is_cluster {is_cluster}") result = cluster_tuple(is_cluster, is_master, cluster_id) - LOGGER.info(f"discover_emr: {str(result)} {lineno()}") return result