def METHOD_NAME(self, device, log):
    orig = WinRMPlugin()
    orig.queries = self.queries
    orig.powershell_commands = self.powershell_commands
    conn_info = self.conn_info(device)
    def send_event(msg, severity, summary=None):
        self._send_event(msg,
                         device.id,
                         severity,
                         eventClass='/Status/Winrm',
                         key='IISSites',
                         summary=summary)
    output = yield orig.METHOD_NAME(device, log)
    if hasattr(orig, 'error_occurred'):
        send_event(orig.error_occurred, ZenEventClasses.Error)
        defer.returnValue(None)
    else:
        msg = 'Collection completed for {}'.format(device.id)
        send_event(msg, ZenEventClasses.Clear)
    version_results = output.get('version')
    if version_results and version_results.stdout:
        # version should be in 'Version x.x' format
        # 7 and above use the same namespace/query
        try:
            self.iis_version = re.match('Version (\d\.*\d*).*', version_results.stdout[0]).group(1)
        except (IndexError, AttributeError):
            if version_results.stdout:
                log.debug("Malformed version information on {}: {}".format(device.id, version_results.stdout[0]))
            if version_results.stderr:
                log.debug("Error retrieving IIS version on {}: {}".format(device.id, version_results.stderr))
    IIs7Sites = output.get('IIs7Site', ())
    if not self.iis_version:
        if IIs7Sites:
            self.iis_version = '7'
        else:
            self.iis_version = '6'
    for iisSite in IIs7Sites:
        name = iisSite.Name
        query = 'ASSOCIATORS OF {Site.Name="%s"} WHERE ResultClass=Application' % name
        result = yield self.run_query(conn_info, query, log)
        try:
            apps = result.values()[0][0]
            pool = apps.ApplicationPool
        except IndexError:
            pool = 'Unknown'
        iisSite.ApplicationPool = pool
    if not output.get('IIs7Site') and not output.get('IIsWebServerSetting'):
        msg = 'No IIS sites found on {}. Ensure that IIS Management Scripts'\
            ' and Tools have been installed.'.format(device.id)
        log.warn(msg)
        send_event(msg, ZenEventClasses.Warning, summary=msg)
    else:
        msg = "Found IIS sites on {}.".format(device.id)
        send_event(msg, ZenEventClasses.Clear)
    defer.returnValue(output)