Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[webpubsub] regen with hub as a client parameter #21684

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ class WebPubSubServiceClientConfiguration(Configuration):
Note that all parameters used to create this instance are saved as instance
attributes.

:param hub: Target hub name, which should start with alphabetic characters and only contain alpha-numeric characters or underscore.
:type hub: str
:param endpoint: HTTP or HTTPS endpoint for the Web PubSub service instance.
:type endpoint: str
:param credential: Credential needed for the client to connect to Azure.
Expand All @@ -36,6 +38,7 @@ class WebPubSubServiceClientConfiguration(Configuration):

def __init__(
self,
hub, # type: str
endpoint, # type: str
credential, # type: "TokenCredential"
**kwargs # type: Any
Expand All @@ -44,11 +47,14 @@ def __init__(
super(WebPubSubServiceClientConfiguration, self).__init__(**kwargs)
api_version = kwargs.pop('api_version', "2021-10-01") # type: str

if hub is None:
raise ValueError("Parameter 'hub' must not be None.")
if endpoint is None:
raise ValueError("Parameter 'endpoint' must not be None.")
if credential is None:
raise ValueError("Parameter 'credential' must not be None.")

self.hub = hub
self.endpoint = endpoint
self.credential = credential
self.api_version = api_version
Expand Down
Loading