class documentation

Oauth2 Authentication implementation

Method __init__ Create the Oauth2 authentication provider instance.
Instance Variable auth Undocumented
def __init__(self, auth_params_string: str): (source)

Create the Oauth2 authentication provider instance.

You can create the instance by setting the necessary fields in the JSON string.

auth = AuthenticationOauth2('{"issuer_url": "xxx", "private_key": "yyy"}')

The valid JSON fields are:

  • issuer_url (required)

    The URL of the authentication provider which allows the Pulsar client to obtain an access token.

  • private_key (required)

    The URL to the JSON credentials file. It supports the following pattern formats:

    • /path/to/file
    • file:///path/to/file
    • file:/path/to/file
    • data:application/json;base64,<base64-encoded-value>

    The file content or the based64 encoded value is the encoded JSON string that contains the following fields:

    • client_id
    • client_secret
  • audience

    The OAuth 2.0 "resource server" identifier for a Pulsar cluster.

  • scope

    The scope of an access request.

Parameters
auth_params_string:strJSON encoded configuration for Oauth2 client

Undocumented