def DELETE(self, rse, scheme, hostname=None, port=None): """ Deletes a protocol entry for the provided RSE. HTTP Success: 200 OK HTTP Error: 401 Unauthorized 404 Resource not Found 500 InternalError """ try: del_protocols(rse, issuer=ctx.env.get('issuer'), vo=ctx.env.get('vo'), scheme=scheme, hostname=hostname, port=port) except RSEProtocolNotSupported as error: raise generate_http_error(404, 'RSEProtocolNotSupported', error.args[0]) except RSENotFound as error: raise generate_http_error(404, 'RSENotFound', error.args[0]) except RucioException as error: raise generate_http_error(500, error.__class__.__name__, error.args[0]) except Exception as error: print(error) print(format_exc()) raise InternalError(error) raise OK()
def delete(self, rse, scheme, hostname=None, port=None): """ Deletes a protocol entry for the provided RSE. .. :quickref: Protocol; Delete an RSE protocol. :param rse: The RSE name. :param scheme: The protocol identifier. :param hostname: The hostname defined for the scheme, used if more than one scheme is registered with the same identifier. :param port: The port registered for the hostname, ued if more than one scheme is registered with the same identifier and hostname. :status 200: OK. :status 401: Invalid Auth Token. :status 404: RSE not found. :status 404: RSE Protocol Not Supported. :status 500: Internal Error. """ try: del_protocols(rse, issuer=request.environ.get('issuer'), scheme=scheme, hostname=hostname, port=port) except RSEProtocolNotSupported, error: return generate_http_error_flask(404, 'RSEProtocolNotSupported', error.args[0])
def DELETE(self, rse, scheme, hostname=None, port=None): """ Deletes a protocol entry for the provided RSE. HTTP Success: 200 OK HTTP Error: 401 Unauthorized 404 Resource not Found 500 InternalError """ try: del_protocols(rse, issuer=ctx.env.get('issuer'), scheme=scheme, hostname=hostname, port=port) except RSEProtocolNotSupported, e: raise generate_http_error(404, 'RSEProtocolNotSupported', e[0][0])
def DELETE(self, rse, scheme, hostname=None, port=None): """ Deletes a protocol entry for the provided RSE. HTTP Success: 200 OK HTTP Error: 401 Unauthorized 404 Resource not Found 500 InternalError """ try: del_protocols(rse, issuer=ctx.env.get('issuer'), scheme=scheme, hostname=hostname, port=port) except RSEProtocolNotSupported, error: raise generate_http_error(404, 'RSEProtocolNotSupported', error[0][0])