S3GatewayClient

Client to interact with the S3Gateway

class DIRAC.DataManagementSystem.Client.S3GatewayClient.S3GatewayClient(url=None, **kwargs)

Bases: DIRAC.Core.Base.Client.Client

Client code to the S3Gateway

__init__(url=None, **kwargs)

Constructor function.

property call

To be removed once we’re sure self.call has been removed

Type

Deprecated

createPresignedUrl(storageName, s3_method, urls, expiration=3600, **kwargs)

Generate a presigned URL for a given object, given method, and given storage Permissions are checked against the DFC

Parameters
  • storageName – SE name

  • s3_method – name of the S3 client method we want to perform.

  • urls – Iterable of urls. If s3_method is put_object, it must be a dict <url:fields> where fields is a dictionary (see ~DIRAC.Resources.Storage.S3Storage.S3Storage.createPresignedUrl)

  • expiration – duration of the token

executeRPC(*parms, **kws)

This method extracts some parameters from kwargs that are used as parameter of the constructor or RPCClient. Unfortunately, only a few of all the available parameters of BaseClient are exposed.

Parameters
  • rpc – if an RPC client is passed, use that one

  • timeout – we can change the timeout on a per call bases. Default is self.timeout

  • url – We can specify which url to use

getClientKWArgs()

Returns a copy of the connection arguments

getServer()

Getter for the server url. Useful ?

httpsClient

alias of DIRAC.Core.Tornado.Client.TornadoClient.TornadoClient

setServer(url)

Set the server URL used by default

Parameters

url – url of the service