configuration#
- class Configuration#
- Bases: - object- A class for the configuration of - ApiClient.- This class contains certain configuration methods and data required by the api client. - Parameters:
- scheme ( - str) – (- scheme) URI scheme for connecting to the cluster (HTTP or HTTPS using SSL/TLS) (Default https)
- host ( - str, required) – (- host) A host name to connect which can be either IPv4, IPv6 or FQDN (Default localhost)
- port ( - int) – (- port) A port number to connect (Default 9440)
- username ( - str, required) – (- username) A username for HTTP basic authentication
- password ( - str, required) – (- password) A password for HTTP basic authentication
- debug ( - bool) – (- debug) Runs the client in debug mode by enabling/disabling debug logging (Default False)
- verify_ssl ( - bool) – (- verify_ssl) Verify SSL certificate of cluster the client will connect to (Default True)
- max_redirects ( - int) – (- max_redirects) Maximum redirect attempts to be made (Default 1)
- max_retry_attempts ( - int) – (- max_retry_attempts) Maximum retry attempts to be made in case of status codes [408, 429, 503, 504] (Default 5)
- backoff_factor ( - float) –- ( - backoff_factor) Backoff factor by which the retry request is delayed with specific number of seconds (Default 3).- This is calculated by the following formula: - {backoff_factor} * (2 * ({number of retries so far} - 1)) 
- logger_file ( - str) – (- logger_file) File location to which logs are written to
- connect_timeout ( - int) – (- connect_timeout) Connection timeout in milliseconds for all operations (Default 30000)
- read_timeout ( - int) – (- read_timeout) Read timeout in milliseconds for all operations (Default 30000)
- download_directory ( - str) – (- download_directory) Directory location on local for files to download
- download_chunk_size ( - int) – (- download_chunk_size) Chunk size in bytes for files to download (Default 8*1024 bytes)
- root_ca_certificate_file ( - str) – (- root_ca_certificate_file) PEM encoded Root CA certificate file path
- client_certificate_file ( - str) – (- client_certificate_file) PEM encoded client certificate file path
- client_key_file ( - str) – (- client_key_file) PEM encoded client key file path
 
 - property backoff_factor#
- Backoff factor by which the retry request is delayed with specific number of seconds (Default 3). - This is calculated by the following formula: - {backoff_factor} * (2 * ({number of retries so far} - 1)) - Type:
- float
 
 - property connect_timeout#
- Connect timeout for an operation in milliseconds. - Type:
- int
 
 - property debug#
- Runs the client in debug mode by enabling/disabling debug logging (Default False). - Default logging level is INFO and all associated loggers’ levels are toggled between INFO and DEBUG by this flag. - Type:
- bool
 
 - property default_connect_timeout#
- Default connection timeout in milliseconds for a HTTP request (Default 30000). - Type:
- int
 
 - property default_read_timeout#
- Default read timeout in milliseconds for a HTTP request (Default 30000). - Type:
- int
 
 - property download_chunk_size#
- Chunk size for downloading files (Default 8*1024 bytes). - Type:
- int
 
 - property download_directory#
- Directory path for downloading files (Default current directory). - Type:
- str
 
 - get_basic_auth_token()#
- Gets HTTP basic authentication header (string). - Returns:
- A token for basic HTTP authentication. 
- Return type:
- str
 
 - property host#
- Host name to connect which can be either IPv4, IPv6 or FQDN (Default localhost). - Type:
- str
 
 - property logger_file#
- File location to which debug logs are written to. - If the logger_file is None, then a logger is configured with a console stream handler and all the file handlers are removed. Otherwise, a logger is configured with a file handler and stream handlers are removed. - Configured file handlers are time based handlers which are rotated everyday at midnight. - Type:
- str
 
 - property logger_format#
- The log format for file or stream log handler. - Type:
- str
 
 - property max_redirects#
- Maximum allowed redirect attempts for a HTTP call (Default 1). - Type:
- int
 
 - property max_retry_attempts#
- Maximum allowed retry attempts for a HTTP call in case of response status codes [408, 429, 503, 504] (Default 5). - Type:
- int
 
 - property password#
- Password to connect to a cluster. - Type:
- str
 
 - property port#
- Port number to connect (Default 9440). - Type:
- int
 
 - property proxy_host#
- Host for the proxy URI. - Type:
- str
 
 - property proxy_password#
- Password for the proxy authentication. - Type:
- str
 
 - property proxy_port#
- Port number for the proxy URI. - Type:
- int
 
 - property proxy_scheme#
- Scheme for the proxy URI. - Type:
- str
 
 - property proxy_username#
- Username for the proxy authentication. - Type:
- str
 
 - property read_timeout#
- Read timeout for an operation in milliseconds. - Type:
- int
 
 - property scheme#
- URI scheme for connecting to the cluster (HTTP or HTTPS using SSL/TLS) (Default https). - Type:
- str
 
 - set_api_key(key)#
- Set API key - Parameters:
- key ( - str) – API key for authentication
 
 - to_debug_report()#
- Prints the information about current OS, Python, API and SDK versions for debugging purposes 
 - property user_agent#
- Value for User-Agent header. - Type:
- str
 
 - property username#
- Username to connect to a cluster. - Type:
- str
 
 - property verify_ssl#
- A flag to enable/disable verification the SSL certificate of target cluster. - Type:
- bool