(self, application_tags, dd_tag)
return tags
Splits the YARN application tags string, if formatted as
        "key1:val1,key2:val2" into Datadog application tags as such:
            app_key1: val1
            app_key2: val2
Splits the YARN application tags string, if formatted as
        "key1:val1,key2:val2" into Datadog application tags as such:
            app_key1: val1
            app_key2: val2
Splits the YARN application tags string if formatted as key1 : val1 key2 : val2 into Datadog application tags as such : app_key1 : val1 app_key2 : val2
def _split_yarn_application_tags(self, application_tags, dd_tag):
        """Splits the YARN application tags string, if formatted as
        "key1:val1,key2:val2" into Datadog application tags as such:
            app_key1: val1
            app_key2: val2
        """
        tags = []
        kv_pairs = [x.split(':') for x in application_tags.split(',')]
        try:
            for tag_key, tag_value in kv_pairs:
                tags.append('app_{tag}:{value}'.format(tag=tag_key, value=tag_value))
        except ValueError:
            self.log.warning("Unable to split string %s with YARN application tags", application_tags)
            # Reverting to default behavior.
            tags.append('{tag}:{value}'.format(tag=dd_tag, value=application_tags))
        return tags
def _split_yarn_application_tags ( self , application_tags , dd_tag ) : tags = [ ] kv_pairs = [ x . split ( ':' ) for x in application_tags . split ( ',' ) ] try : for tag_key , tag_value in kv_pairs : tags . append ( 'app_{tag}:{value}' . format ( tag = tag_key , value = tag_value ) ) except ValueError : self . log . warning ( "Unable to split string %s with YARN application tags" , application_tags ) # Reverting to default behavior. tags . append ( '{tag}:{value}' . format ( tag = dd_tag , value = application_tags ) ) return tags