def METHOD_NAME(self):
    meta = {}
    if self.agent_url:
        try:
            resp = requests.get(self.agent_url + ECS_AGENT_METADATA_PATH, timeout=1).json()
            if "Version" in resp:
                match = AGENT_VERSION_EXP.search(resp.get("Version"))
                if match is not None and len(match.groups()) == 1:
                    meta['ecs_version'] = match.group(1)
        except Exception as e:
            self.log.debug("Error getting ECS version: %s" % str(e))
    return meta