ClientΒΆ

class ceilometerclient.client.AuthPlugin(auth_system=None, **kwargs)

Bases: ceilometerclient.apiclient.auth.BaseAuthPlugin

opt_names = ['tenant_id', 'region_name', 'auth_token', 'service_type', 'endpoint_type', 'cacert', 'auth_url', 'insecure', 'cert_file', 'key_file', 'cert', 'key', 'tenant_name', 'project_name', 'project_id', 'project_domain_id', 'project_domain_name', 'user_id', 'user_domain_id', 'user_domain_name', 'password', 'username', 'endpoint']
sufficient_options()

Check if all required options are present.

Raises:AuthPluginOptionsMissing
token_and_endpoint(endpoint_type, service_type)
ceilometerclient.client.Client(version, *args, **kwargs)
class ceilometerclient.client.SessionClient(*args, **kwargs)

Bases: keystoneauth1.adapter.LegacyJsonAdapter

request(url, method, **kwargs)
ceilometerclient.client.get_auth_plugin(endpoint, **kwargs)
ceilometerclient.client.get_client(version, **kwargs)

Get an authenticated client, based on the credentials in the kwargs.

Parameters:
  • version – the API version to use (‘1’ or ‘2’)
  • kwargs

    keyword args containing credentials, either:

    • session: a keystoneauth/keystoneclient session object
    • service_type: The default service_type for URL discovery
    • service_name: The default service_name for URL discovery
    • interface: The default interface for URL discovery
      (Default: public)
    • region_name: The default region_name for URL discovery
    • endpoint_override: Always use this endpoint URL for requests
      for this ceiloclient
    • auth: An auth plugin to use instead of the session one
    • user_agent: The User-Agent string to set
      (Default is python-ceilometer-client)
    • connect_retries: the maximum number of retries that should be
      attempted for connection errors
    • logger: A logging object

    or (DEPRECATED):

    • os_auth_token: (DEPRECATED) pre-existing token to re-use,
      use os_token instead
    • os_token: pre-existing token to re-use
    • ceilometer_url: (DEPRECATED) Ceilometer API endpoint,
      use os_endpoint instead
    • os_endpoint: Ceilometer API endpoint

    or (DEPRECATED):

    • os_username: name of user
    • os_password: user’s password
    • os_user_id: user’s id
    • os_user_domain_id: the domain id of the user
    • os_user_domain_name: the domain name of the user
    • os_project_id: the user project id
    • os_tenant_id: V2 alternative to os_project_id
    • os_project_name: the user project name
    • os_tenant_name: V2 alternative to os_project_name
    • os_project_domain_name: domain name for the user project
    • os_project_domain_id: domain id for the user project
    • os_auth_url: endpoint to authenticate against
    • os_cert|os_cacert: path of CA TLS certificate
    • os_key: SSL private key
    • os_insecure: allow insecure SSL (no cert verification)
ceilometerclient.client.record_time(*args, **kwds)

Record the time of a specific action.

Parameters:
  • times (list) – A list of tuples holds time data.
  • enabled (bool) – Whether timing is enabled.
  • args – Other data to be stored besides time data, these args will be joined to a string.

Previous topic

Client Reference

Next topic

Exc

Project Source

This Page