Skip to content
Merged
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 @@ -246,7 +246,7 @@ def get(
get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/eventhubs/{eventHubName}/consumergroups/{consumerGroupName}'}

def list_by_event_hub(
self, resource_group_name, namespace_name, event_hub_name, custom_headers=None, raw=False, **operation_config):
self, resource_group_name, namespace_name, event_hub_name, skip=None, top=None, custom_headers=None, raw=False, **operation_config):
"""Gets all the consumer groups in a Namespace. An empty feed is returned
if no consumer group exists in the Namespace.

Expand All @@ -257,6 +257,14 @@ def list_by_event_hub(
:type namespace_name: str
:param event_hub_name: The Event Hub name
:type event_hub_name: str
:param skip: Skip is only used if a previous operation returned a
partial result. If a previous response contains a nextLink element,
the value of the nextLink element will include a skip parameter that
specifies a starting point to use for subsequent calls.
:type skip: int
:param top: May be used to limit the number of results to the most
recent N usageDetails.
:type top: int
:param dict custom_headers: headers that will be added to the request
:param bool raw: returns the direct response alongside the
deserialized response
Expand Down Expand Up @@ -284,6 +292,10 @@ def internal_paging(next_link=None, raw=False):
# Construct parameters
query_parameters = {}
query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str')
if skip is not None:
query_parameters['$skip'] = self._serialize.query("skip", skip, 'int', maximum=1000, minimum=0)
if top is not None:
query_parameters['$top'] = self._serialize.query("top", top, 'int', maximum=1000, minimum=1)

else:
url = next_link
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,22 @@ def __init__(self, client, config, serializer, deserializer):
self.config = config

def list_by_namespace(
self, resource_group_name, namespace_name, custom_headers=None, raw=False, **operation_config):
self, resource_group_name, namespace_name, skip=None, top=None, custom_headers=None, raw=False, **operation_config):
"""Gets all the Event Hubs in a Namespace.

:param resource_group_name: Name of the resource group within the
azure subscription.
:type resource_group_name: str
:param namespace_name: The Namespace name
:type namespace_name: str
:param skip: Skip is only used if a previous operation returned a
partial result. If a previous response contains a nextLink element,
the value of the nextLink element will include a skip parameter that
specifies a starting point to use for subsequent calls.
:type skip: int
:param top: May be used to limit the number of results to the most
recent N usageDetails.
:type top: int
:param dict custom_headers: headers that will be added to the request
:param bool raw: returns the direct response alongside the
deserialized response
Expand All @@ -71,6 +79,10 @@ def internal_paging(next_link=None, raw=False):
# Construct parameters
query_parameters = {}
query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str')
if skip is not None:
query_parameters['$skip'] = self._serialize.query("skip", skip, 'int', maximum=1000, minimum=0)
if top is not None:
query_parameters['$top'] = self._serialize.query("top", top, 'int', maximum=1000, minimum=1)

else:
url = next_link
Expand Down