listTopicSubscriptions method
Lists the names of the attached subscriptions on this topic.
The topic
can be just the simple name or it can be the fully quantified
name in the format: projects/{project}/topics/{topic}
.
Implementation
Future<ListTopicSubscriptionsResponse> listTopicSubscriptions({
int? pageSize,
String? pageToken,
int retries = 5,
required String topic,
}) async {
assert(_initialized);
_logger.fine('[listTopicSubscriptions]: start -- [$topic]');
try {
return await _execute(
executor: () async {
final result = await _pubsubApi.projects.topics.subscriptions.list(
topic.startsWith('projects/')
? topic
: 'projects/$_projectId/topics/$topic',
pageSize: pageSize,
pageToken: pageToken,
);
return result;
},
retries: retries,
);
} finally {
_logger.fine('[listTopicSubscriptions]: complete -- [$topic]');
}
}