in flink-connector-gcp-pubsub/src/main/java/org/apache/flink/streaming/connectors/gcp/pubsub/PubSubSource.java [338:359]
public PubSubSource<OUT> build() throws IOException {
if (credentials == null) {
credentials = defaultCredentialsProviderBuilder().build().getCredentials();
}
if (pubSubSubscriberFactory == null) {
pubSubSubscriberFactory =
new DefaultPubSubSubscriberFactory(
ProjectSubscriptionName.format(projectName, subscriptionName),
3,
Duration.ofSeconds(15),
100);
}
return new PubSubSource<>(
deserializationSchema,
pubSubSubscriberFactory,
credentials,
new AcknowledgeOnCheckpointFactory(),
new GuavaFlinkConnectorRateLimiter(),
messagePerSecondRateLimit);
}