Removes commented out code (#48902)

pull/48909/head
Tim Rupp 6 years ago committed by GitHub
parent e6d586f703
commit 8d2beea1cf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -80,39 +80,3 @@ class F5RestClient(F5BaseClient):
if response.status not in [200]:
return None, response.content
return session, None
# TODO(This section of code should be developed to support proxy_to)
#
# def get_identifier(self, proxy_to):
# if re.search(r'([0-9-a-z]+\-){4}[0-9-a-z]+', proxy_to, re.I):
# return proxy_to
# return self.get_device_uuid(proxy_to)
#
# def get_device_uuid(self, proxy_to):
# uri = "https://{0}:{1}/mgmt/shared/resolver/device-groups/cm-cloud-managed-devices/devices/?$filter=hostname+eq+'{2}'&$select=uuid".format(
# self.provider['server'], self.provider['server_port'], proxy_to
# )
# resp = self.client.api.get(uri)
# try:
# response = resp.json()
# except ValueError as ex:
# raise F5ModuleError(str(ex))
#
# if 'code' in response and response['code'] == 400:
# if 'message' in response:
# raise F5ModuleError(response['message'])
# else:
# raise F5ModuleError(resp.content)
#
# if len(collection) > 1:
# raise F5ModuleError(
# "More that one managed device was found with this hostname. "
# "'proxy_to' devices must be unique. Consider specifying the UUID of the device."
# )
# elif len(collection) == 0:
# raise F5ModuleError(
# "No device was found with that hostname"
# )
# else:
# resource = collection.pop()
# return resource.pop('uuid', None)

Loading…
Cancel
Save