(self)
Send external host tags to the Datadog backend. This is only useful for a REALTIME instance because
        only VMs and Hosts appear as 'datadog hosts'.
Send external host tags to the Datadog backend. This is only useful for a REALTIME instance because
        only VMs and Hosts appear as 'datadog hosts'.
Send external host tags to the Datadog backend . This is only useful for a REALTIME instance because only VMs and Hosts appear as datadog hosts .
def submit_external_host_tags(self):
        # type: () -> None
        """Send external host tags to the Datadog backend. This is only useful for a REALTIME instance because
        only VMs and Hosts appear as 'datadog hosts'."""
        external_host_tags = []

        for resource_type in REALTIME_RESOURCES:
            for mor in self.infrastructure_cache.get_mors(resource_type):
                mor_props = self.infrastructure_cache.get_mor_props(mor)
                mor_tags = self.infrastructure_cache.get_mor_tags(mor)
                hostname = mor_props.get('hostname')
                # Safeguard if some mors have a None hostname
                if not hostname:
                    continue

                mor_tags = mor_props['tags'] + mor_tags
                tags = [t for t in mor_tags if t.split(':')[0] not in self._config.excluded_host_tags]
                tags.extend(self._config.base_tags)
                external_host_tags.append((hostname, {self.__NAMESPACE__: tags}))

        if external_host_tags:
            self.set_external_tags(external_host_tags)
def submit_external_host_tags ( self ) : # type: () -> None external_host_tags = [ ] for resource_type in REALTIME_RESOURCES : for mor in self . infrastructure_cache . get_mors ( resource_type ) : mor_props = self . infrastructure_cache . get_mor_props ( mor ) mor_tags = self . infrastructure_cache . get_mor_tags ( mor ) hostname = mor_props . get ( 'hostname' ) # Safeguard if some mors have a None hostname if not hostname : continue mor_tags = mor_props [ 'tags' ] + mor_tags tags = [ t for t in mor_tags if t . split ( ':' ) [ 0 ] not in self . _config . excluded_host_tags ] tags . extend ( self . _config . base_tags ) external_host_tags . append ( ( hostname , { self . __NAMESPACE__ : tags } ) ) if external_host_tags : self . set_external_tags ( external_host_tags )