-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Refactor OAuth2 client credentials channel creation
This commit refactors the `create_oauth2_client_credentials_channel` function in the `pyzeebe.channel.oauth_channel` module. The function is responsible for creating a channel connected to a Camunda Cloud cluster using OAuth2 client credentials for authentication. It takes various parameters such as the target address, client ID, client secret, authorization server, scope, audience, and expiration time. The function returns a GRPC channel connected to the Zeebe Gateway. The refactoring improves the code structure and readability of the function, making it easier to maintain and understand. This change is necessary to provide support for authenticating with Camunda Cloud using OAuth2 client credentials. Co-authored-by: dependabot[bot] <[email protected]>
- Loading branch information
Showing
4 changed files
with
121 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
# from pyzeebe.channel.camunda_cloud_channel import create_camunda_cloud_channel # FIXME: could be removed | ||
from pyzeebe.channel.insecure_channel import create_insecure_channel | ||
from pyzeebe.channel.oauth_channel import ( | ||
create_camunda_cloud_channel, | ||
create_oauth2_client_credentials_channel, | ||
from pyzeebe.channel.camunda_cloud_channel import ( | ||
create_camunda_cloud_channel, # FIXME: could be removed | ||
) | ||
from pyzeebe.channel.insecure_channel import create_insecure_channel | ||
|
||
# from pyzeebe.channel.oauth_channel import ( | ||
# create_camunda_cloud_channel, | ||
# create_oauth2_client_credentials_channel, | ||
# ) | ||
from pyzeebe.channel.secure_channel import create_secure_channel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters