Google Cloud Pub/Sub C++ Client 2.13.0
A C++ Client Library for Google Cloud Pub/Sub
|
Contains all the Cloud Pub/Sub C++ client types and functions. More...
Classes | |
class | AckHandler |
Defines the interface to acknowledge and reject messages. More... | |
struct | BackoffPolicyOption |
The backoff policy. More... | |
class | BigQueryConfigBuilder |
A helper class to build google::pubsub::v1::BigQueryConfig protos. More... | |
class | BlockingPublisher |
Publish messages to the Cloud Pub/Sub service. More... | |
class | BlockingPublisherConnection |
A connection to the Cloud Pub/Sub service to publish events. More... | |
class | CloudStorageConfigBuilder |
A helper class to build google::pubsub::v1::CloudStorageConfig protos. More... | |
struct | CompressionAlgorithmOption |
Compression algorithm. More... | |
struct | CompressionThresholdOption |
Compression threshold. More... | |
struct | ConnectionOptionsTraits |
The Cloud Pub/Sub connection traits. More... | |
class | ExactlyOnceAckHandler |
Defines the interface to acknowledge and reject messages. More... | |
struct | FullPublisherActionOption |
The action taken by a full publisher. More... | |
struct | MaxBatchBytesOption |
The maximum size for the messages in a batch. More... | |
struct | MaxBatchMessagesOption |
The maximum number of messages in a batch. More... | |
struct | MaxConcurrencyOption |
The maximum callback concurrency. More... | |
struct | MaxDeadlineExtensionOption |
The maximum time by which the deadline for each incoming message is extended. More... | |
struct | MaxDeadlineTimeOption |
The maximum deadline for each incoming message. More... | |
struct | MaxHoldTimeOption |
The maximum hold time for the messages. More... | |
struct | MaxOutstandingBytesOption |
The maximum number of outstanding bytes per streaming pull. More... | |
struct | MaxOutstandingMessagesOption |
The maximum number of outstanding messages per streaming pull. More... | |
struct | MaxPendingBytesOption |
The maximum size for pending messages. More... | |
struct | MaxPendingMessagesOption |
The maximum number of pending messages. More... | |
class | Message |
The C++ representation for a Cloud Pub/Sub messages. More... | |
class | MessageBuilder |
Constructs Message objects. More... | |
struct | MessageOrderingOption |
Publisher message ordering. More... | |
struct | MinDeadlineExtensionOption |
The minimum time by which the deadline for each incoming message is extended. More... | |
class | Publisher |
Publish messages to the Cloud Pub/Sub service. More... | |
class | PublisherConnection |
A connection to the Cloud Pub/Sub service to publish events. More... | |
class | PublisherOptions |
Configuration options for a Publisher . More... | |
class | PullAckHandler |
Defines the interface to acknowledge and reject messages. More... | |
struct | PullResponse |
The response for a blocking pull. More... | |
class | PushConfigBuilder |
Helper class to create google::pubsub::v1::PushConfig protos. More... | |
struct | RetryPolicyOption |
The retry policy. More... | |
class | Schema |
Objects of this class identify a Cloud Pub/Sub schema. More... | |
struct | SchemaServiceBackoffPolicyOption |
Use with google::cloud::Options to configure the backoff policy. More... | |
class | SchemaServiceClient |
Service for doing schema-related operations. More... | |
class | SchemaServiceConnection |
The SchemaServiceConnection object for SchemaServiceClient . More... | |
class | SchemaServiceConnectionIdempotencyPolicy |
struct | SchemaServiceConnectionIdempotencyPolicyOption |
Use with google::cloud::Options to configure which operations are retried. More... | |
struct | SchemaServiceRetryPolicyOption |
Use with google::cloud::Options to configure the retry policy. More... | |
struct | ShutdownPollingPeriodOption |
How often the session polls for automatic shutdowns. More... | |
class | Snapshot |
Objects of this class identify a Cloud Pub/Sub snapshot. More... | |
class | SnapshotBuilder |
Build a request to create a Cloud Pub/Sub snapshot. More... | |
class | Subscriber |
Receive messages from the Cloud Pub/Sub service. More... | |
class | SubscriberConnection |
A connection to the Cloud Pub/Sub service to receive events. More... | |
class | SubscriberOptions |
Configure how a Subscriber handles incoming messages. More... | |
class | Subscription |
Objects of this class identify a Cloud Pub/Sub subscription. More... | |
class | SubscriptionAdminClient |
Performs subscription administrative operations in Cloud Pub/Sub. More... | |
class | SubscriptionAdminConnection |
A connection to Cloud Pub/Sub for subscription-related administrative operations. More... | |
class | SubscriptionBuilder |
Create a Cloud Pub/Sub subscription configuration. More... | |
struct | SubscriptionOption |
Override the default subscription for a request. More... | |
class | Topic |
Objects of this class identify a Cloud Pub/Sub topic. More... | |
class | TopicAdminClient |
Performs topic admin operations in Cloud Pub/Sub. More... | |
class | TopicAdminConnection |
A connection to Cloud Pub/Sub for topic-related administrative operations. More... | |
class | TopicBuilder |
Builds requests to create or update a Cloud Pub/Sub topic. More... | |
Typedefs | |
using | ApplicationCallback = std::function< void(Message, AckHandler)> |
Defines the interface for application-level callbacks. More... | |
using | ExactlyOnceApplicationCallback = std::function< void(pubsub::Message, ExactlyOnceAckHandler)> |
Defines the interface for application-level callbacks with exactly-once delivery. More... | |
using | BackoffPolicy = ::google::cloud::internal::BackoffPolicy |
The base class for backoff policies. More... | |
using | ExponentialBackoffPolicy = google::cloud::internal::ExponentialBackoffPolicy |
A truncated exponential backoff policy with randomized periods. More... | |
using | ConnectionOptions = ::google::cloud::ConnectionOptions< ConnectionOptionsTraits > |
Configure a connection for Cloud Pub/Sub services. More... | |
using | PubsubMessageDataType = std::decay< decltype(std::declval< google::pubsub::v1::PubsubMessage >().data())>::type |
Defines the type for message data. More... | |
using | PolicyOptionList = OptionList< RetryPolicyOption, BackoffPolicyOption > |
The list of all "policy" options. More... | |
using | PublisherOptionList = OptionList< MaxHoldTimeOption, MaxBatchMessagesOption, MaxBatchBytesOption, MaxPendingMessagesOption, MaxPendingBytesOption, MessageOrderingOption, FullPublisherActionOption, CompressionThresholdOption > |
The list of options specific to publishers. More... | |
using | SubscriberOptionList = OptionList< MaxDeadlineTimeOption, MaxDeadlineExtensionOption, MinDeadlineExtensionOption, MaxOutstandingMessagesOption, MaxOutstandingBytesOption, MaxConcurrencyOption, ShutdownPollingPeriodOption, SubscriptionOption > |
The list of options specific to subscribers. More... | |
using | RetryPolicy = ::google::cloud::internal::TraitBasedRetryPolicy< pubsub_internal::RetryTraits > |
The base class for retry policies. More... | |
using | LimitedTimeRetryPolicy = ::google::cloud::internal::LimitedTimeRetryPolicy< pubsub_internal::RetryTraits > |
A retry policy that limits based on time. More... | |
using | LimitedErrorCountRetryPolicy = google::cloud::internal::LimitedErrorCountRetryPolicy< pubsub_internal::RetryTraits > |
A retry policy that limits the number of times a request can fail. More... | |
using | SchemaServiceRetryPolicy = ::google::cloud::internal::TraitBasedRetryPolicy< pubsub_internal::SchemaServiceRetryTraits > |
using | SchemaServiceLimitedTimeRetryPolicy = ::google::cloud::internal::LimitedTimeRetryPolicy< pubsub_internal::SchemaServiceRetryTraits > |
using | SchemaServiceLimitedErrorCountRetryPolicy = ::google::cloud::internal::LimitedErrorCountRetryPolicy< pubsub_internal::SchemaServiceRetryTraits > |
using | SchemaServicePolicyOptionList = OptionList< SchemaServiceRetryPolicyOption, SchemaServiceBackoffPolicyOption, SchemaServiceConnectionIdempotencyPolicyOption > |
The options applicable to SchemaService. More... | |
using | ListSubscriptionsRange = google::cloud::internal::PaginationRange< google::pubsub::v1::Subscription > |
An input range to stream Cloud Pub/Sub subscriptions. More... | |
using | ListSnapshotsRange = google::cloud::internal::PaginationRange< google::pubsub::v1::Snapshot > |
An input range to stream Cloud Pub/Sub snapshots. More... | |
using | ListTopicsRange = google::cloud::internal::PaginationRange< google::pubsub::v1::Topic > |
An input range to stream Cloud Pub/Sub topics. More... | |
using | ListTopicSubscriptionsRange = google::cloud::internal::PaginationRange< std::string > |
An input range to stream the Cloud Pub/Sub subscriptions of a topic. More... | |
using | ListTopicSnapshotsRange = google::cloud::internal::PaginationRange< std::string > |
An input range to stream the Cloud Pub/Sub snapshots of a topic. More... | |
Enumerations | |
enum class | FullPublisherAction { kIgnored , kRejects , kBlocks } |
Actions taken by a full publisher. More... | |
Functions | |
std::shared_ptr< BlockingPublisherConnection > | MakeBlockingPublisherConnection (Options opts={}) |
Creates a new BlockingPublisherConnection object to work with BlockingPublisher . More... | |
Options | IAMPolicyOptions (Options opts={}) |
Convenience function to initialize a google::cloud::iam::IAMPolicyConnection . More... | |
std::shared_ptr< PublisherConnection > | MakePublisherConnection (Topic topic, std::initializer_list< internal::NonConstructible >) |
Creates a new PublisherConnection object to work with Publisher . More... | |
std::shared_ptr< PublisherConnection > | MakePublisherConnection (Topic topic, Options opts={}) |
Creates a new PublisherConnection object to work with Publisher . More... | |
std::shared_ptr< PublisherConnection > | MakePublisherConnection (Topic topic, PublisherOptions options, ConnectionOptions connection_options={}, std::unique_ptr< RetryPolicy const > retry_policy={}, std::unique_ptr< BackoffPolicy const > backoff_policy={}) |
Creates a new PublisherConnection object to work with Publisher . More... | |
std::shared_ptr< SchemaServiceConnection > | MakeSchemaServiceConnection (Options options={}) |
A factory function to construct an object of type SchemaServiceConnection . More... | |
std::unique_ptr< SchemaServiceConnectionIdempotencyPolicy > | MakeDefaultSchemaServiceConnectionIdempotencyPolicy () |
std::shared_ptr< SubscriberConnection > | MakeSubscriberConnection (Subscription subscription, std::initializer_list< internal::NonConstructible >) |
Creates a new SubscriberConnection object to work with Subscriber . More... | |
std::shared_ptr< SubscriberConnection > | MakeSubscriberConnection (Subscription subscription, Options opts={}) |
Creates a new SubscriberConnection object to work with Subscriber . More... | |
std::shared_ptr< SubscriberConnection > | MakeSubscriberConnection (Subscription subscription, SubscriberOptions options, ConnectionOptions connection_options={}, std::unique_ptr< pubsub::RetryPolicy const > retry_policy={}, std::unique_ptr< pubsub::BackoffPolicy const > backoff_policy={}) |
Creates a new SubscriberConnection object to work with Subscriber . More... | |
std::shared_ptr< SubscriptionAdminConnection > | MakeSubscriptionAdminConnection (std::initializer_list< internal::NonConstructible >) |
Creates a new SubscriptionAdminConnection object to work with SubscriptionAdminClient . More... | |
std::shared_ptr< SubscriptionAdminConnection > | MakeSubscriptionAdminConnection (Options opts={}) |
Creates a new SubscriptionAdminConnection object to work with SubscriptionAdminClient . More... | |
std::shared_ptr< SubscriptionAdminConnection > | MakeSubscriptionAdminConnection (ConnectionOptions const &options, std::unique_ptr< pubsub::RetryPolicy const > retry_policy={}, std::unique_ptr< pubsub::BackoffPolicy const > backoff_policy={}) |
Creates a new SubscriptionAdminConnection object to work with SubscriptionAdminClient . More... | |
std::shared_ptr< TopicAdminConnection > | MakeTopicAdminConnection (std::initializer_list< internal::NonConstructible >) |
Creates a new TopicAdminConnection object to work with TopicAdminClient . More... | |
std::shared_ptr< TopicAdminConnection > | MakeTopicAdminConnection (Options opts={}) |
Creates a new TopicAdminConnection object to work with TopicAdminClient . More... | |
std::shared_ptr< TopicAdminConnection > | MakeTopicAdminConnection (ConnectionOptions const &options, std::unique_ptr< pubsub::RetryPolicy const > retry_policy={}, std::unique_ptr< pubsub::BackoffPolicy const > backoff_policy={}) |
Creates a new TopicAdminConnection object to work with TopicAdminClient . More... | |
Contains all the Cloud Pub/Sub C++ client types and functions.
using google::cloud::pubsub::ApplicationCallback = typedef std::function<void(Message, AckHandler)> |
Defines the interface for application-level callbacks.
Applications provide a callable compatible with this type to receive messages. They acknowledge (or reject) messages using AckHandler
. This is a move-only type to support asynchronously acknowledgments.
using google::cloud::pubsub::BackoffPolicy = typedef ::google::cloud::internal::BackoffPolicy |
The base class for backoff policies.
using google::cloud::pubsub::ConnectionOptions = typedef ::google::cloud::ConnectionOptions<ConnectionOptionsTraits> |
Configure a connection for Cloud Pub/Sub services.
using google::cloud::pubsub::ExactlyOnceApplicationCallback = typedef std::function<void(pubsub::Message, ExactlyOnceAckHandler)> |
Defines the interface for application-level callbacks with exactly-once delivery.
Applications provide a callable compatible with this type to receive messages. They acknowledge (or reject) messages using ExactlyOnceAckHandler
. This is a move-only type to support asynchronous acknowledgments.
using google::cloud::pubsub::ExponentialBackoffPolicy = typedef google::cloud::internal::ExponentialBackoffPolicy |
A truncated exponential backoff policy with randomized periods.
using google::cloud::pubsub::LimitedErrorCountRetryPolicy = typedef google::cloud::internal::LimitedErrorCountRetryPolicy< pubsub_internal::RetryTraits> |
A retry policy that limits the number of times a request can fail.
using google::cloud::pubsub::LimitedTimeRetryPolicy = typedef ::google::cloud::internal::LimitedTimeRetryPolicy< pubsub_internal::RetryTraits> |
A retry policy that limits based on time.
using google::cloud::pubsub::ListSnapshotsRange = typedef google::cloud::internal::PaginationRange<google::pubsub::v1::Snapshot> |
An input range to stream Cloud Pub/Sub snapshots.
This type models an input range of google::pubsub::v1::Snapshot
objects. Applications can make a single pass through the results.
using google::cloud::pubsub::ListSubscriptionsRange = typedef google::cloud::internal::PaginationRange<google::pubsub::v1::Subscription> |
An input range to stream Cloud Pub/Sub subscriptions.
This type models an input range of google::pubsub::v1::Subscription
objects. Applications can make a single pass through the results.
using google::cloud::pubsub::ListTopicSnapshotsRange = typedef google::cloud::internal::PaginationRange<std::string> |
An input range to stream the Cloud Pub/Sub snapshots of a topic.
This type models an input range of std::string
objects. Applications can make a single pass through the results.
using google::cloud::pubsub::ListTopicsRange = typedef google::cloud::internal::PaginationRange<google::pubsub::v1::Topic> |
An input range to stream Cloud Pub/Sub topics.
This type models an input range of google::pubsub::v1::Topic
objects. Applications can make a single pass through the results.
using google::cloud::pubsub::ListTopicSubscriptionsRange = typedef google::cloud::internal::PaginationRange<std::string> |
An input range to stream the Cloud Pub/Sub subscriptions of a topic.
This type models an input range of std::string
objects. Applications can make a single pass through the results.
using google::cloud::pubsub::PolicyOptionList = typedef OptionList<RetryPolicyOption, BackoffPolicyOption> |
The list of all "policy" options.
The list of options specific to publishers.
using google::cloud::pubsub::PubsubMessageDataType = typedef std::decay< decltype(std::declval<google::pubsub::v1::PubsubMessage>().data())>::type |
Defines the type for message data.
Inside Google some protobuf fields of type bytes
are mapped to a different type than std::string
. This is the case for message data. We use this type to automatically detect what is the representation for this field and use the correct mapping.
External users of the Cloud Pub/Sub C++ client library should treat this as a complicated typedef
for std::string
. We have no plans to change the type in the external version of the C++ client library for the foreseeable future. In the eventuality that we do decide to change the type, this would be a reason update the library major version number, and we would give users time to migrate.
In other words, external users of the Cloud Pub/Sub C++ client should simply write std::string
where this type appears. For Google projects that must compile both inside and outside Google, this alias may be convenient.
using google::cloud::pubsub::RetryPolicy = typedef ::google::cloud::internal::TraitBasedRetryPolicy< pubsub_internal::RetryTraits> |
The base class for retry policies.
using google::cloud::pubsub::SchemaServiceLimitedErrorCountRetryPolicy = typedef ::google::cloud::internal::LimitedErrorCountRetryPolicy< pubsub_internal::SchemaServiceRetryTraits> |
using google::cloud::pubsub::SchemaServiceLimitedTimeRetryPolicy = typedef ::google::cloud::internal::LimitedTimeRetryPolicy< pubsub_internal::SchemaServiceRetryTraits> |
using google::cloud::pubsub::SchemaServicePolicyOptionList = typedef OptionList<SchemaServiceRetryPolicyOption, SchemaServiceBackoffPolicyOption, SchemaServiceConnectionIdempotencyPolicyOption> |
The options applicable to SchemaService.
using google::cloud::pubsub::SchemaServiceRetryPolicy = typedef ::google::cloud::internal::TraitBasedRetryPolicy< pubsub_internal::SchemaServiceRetryTraits> |
|
strong |
std::shared_ptr< BlockingPublisherConnection > google::cloud::pubsub::MakeBlockingPublisherConnection | ( | Options | opts = {} | ) |
Creates a new BlockingPublisherConnection
object to work with BlockingPublisher
.
The BlockingPublisherConnection
class is provided for applications wanting to mock the BlockingPublisher
behavior in their tests. It is not intended for direct use.
BlockingPublisherConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the same Options
from GrpcOptionList
and CommonOptionList
. However, this behavior is not guaranteed and applications should not rely on it.BlockingPublisherConnection
opts | The options to use for this call. Expected options are any of the types in the following option lists. |
std::unique_ptr< SchemaServiceConnectionIdempotencyPolicy > google::cloud::pubsub::MakeDefaultSchemaServiceConnectionIdempotencyPolicy | ( | ) |
std::shared_ptr< PublisherConnection > google::cloud::pubsub::MakePublisherConnection | ( | Topic | topic, |
Options | opts = {} |
||
) |
Creates a new PublisherConnection
object to work with Publisher
.
The PublisherConnection
class is provided for applications wanting to mock the Publisher
behavior in their tests. It is not intended for direct use.
PublisherConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the same Options
from GrpcOptionList
and CommonOptionList
. However, this behavior is not guaranteed and applications should not rely on it.PublisherConnection
topic | the Cloud Pub/Sub topic used by the returned PublisherConnection . |
opts | The options to use for this call. Expected options are any of the types in the following option lists. |
std::shared_ptr< PublisherConnection > google::cloud::pubsub::MakePublisherConnection | ( | Topic | topic, |
PublisherOptions | options, | ||
ConnectionOptions | connection_options = {} , |
||
std::unique_ptr< RetryPolicy const > | retry_policy = {} , |
||
std::unique_ptr< BackoffPolicy const > | backoff_policy = {} |
||
) |
Creates a new PublisherConnection
object to work with Publisher
.
The PublisherConnection
class is not intended for direct use in applications, it is provided for applications wanting to mock the Publisher
behavior in their tests.
PublisherConnection
is relatively expensive. This typically initiate connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the identical values for options
. However, this behavior is not guaranteed and applications should not rely on it.PublisherConnection
topic | the Cloud Pub/Sub topic used by the returned PublisherConnection . |
options | configure the batching policy and other parameters in the returned connection. |
connection_options | (optional) general configuration for this connection, this type is also used to configure pubsub::Subscriber . |
retry_policy | (optional) configure the retry loop. |
backoff_policy | (optional) configure the backoff period between retries. |
MakePublisherConnection
method which accepts google::cloud::Options
instead. std::shared_ptr< PublisherConnection > google::cloud::pubsub::MakePublisherConnection | ( | Topic | topic, |
std::initializer_list< internal::NonConstructible > | |||
) |
Creates a new PublisherConnection
object to work with Publisher
.
MakePublisherConnection(topic, {})
from breaking, due to ambiguity.MakePublisherConnection(topic)
instead. std::shared_ptr< SchemaServiceConnection > google::cloud::pubsub::MakeSchemaServiceConnection | ( | Options | options = {} | ) |
A factory function to construct an object of type SchemaServiceConnection
.
The returned connection object should not be used directly; instead it should be passed as an argument to the constructor of SchemaServiceClient.
The optional options
argument may be used to configure aspects of the returned SchemaServiceConnection
. Expected options are any of the types in the following option lists:
google::cloud::CommonOptionList
google::cloud::GrpcOptionList
google::cloud::UnifiedCredentialsOptionList
google::cloud::pubsub::SchemaServicePolicyOptionList
GOOGLE_CLOUD_CPP_ENABLE_CLOG=yes
in the environment.options | (optional) Configure the SchemaServiceConnection created by this function. |
std::shared_ptr< SubscriberConnection > google::cloud::pubsub::MakeSubscriberConnection | ( | Subscription | subscription, |
Options | opts = {} |
||
) |
Creates a new SubscriberConnection
object to work with Subscriber
.
The SubscriberConnection
class is not intended for direct use in applications, it is provided for applications wanting to mock the Subscriber
behavior in their tests.
SubscriberConnection
is relatively expensive. This typically initiate connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the same Options
from GrpcOptionList
and CommonOptionList
. However, this behavior is not guaranteed and applications should not rely on it.SubscriberConnection
subscription | the Cloud Pub/Sub subscription used by the returned connection. |
opts | The options to use for this call. Expected options are any of the types in the following option lists. |
std::shared_ptr< SubscriberConnection > google::cloud::pubsub::MakeSubscriberConnection | ( | Subscription | subscription, |
std::initializer_list< internal::NonConstructible > | |||
) |
Creates a new SubscriberConnection
object to work with Subscriber
.
MakeSubscriberConnection(subscription, {})
from breaking, due to ambiguity.MakeSubscriberConnection(subscription)
instead. std::shared_ptr< SubscriberConnection > google::cloud::pubsub::MakeSubscriberConnection | ( | Subscription | subscription, |
SubscriberOptions | options, | ||
ConnectionOptions | connection_options = {} , |
||
std::unique_ptr< pubsub::RetryPolicy const > | retry_policy = {} , |
||
std::unique_ptr< pubsub::BackoffPolicy const > | backoff_policy = {} |
||
) |
Creates a new SubscriberConnection
object to work with Subscriber
.
The SubscriberConnection
class is not intended for direct use in applications, it is provided for applications wanting to mock the Subscriber
behavior in their tests.
SubscriberConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the identical values for options
. However, this behavior is not guaranteed and applications should not rely on it.SubscriberConnection
subscription | the Cloud Pub/Sub subscription used by the returned connection. |
options | configure the flow control and other parameters in the returned connection. |
connection_options | (optional) general configuration for this connection, this type is also used to configure pubsub::Publisher . |
retry_policy | control for how long (or how many times) are retryable RPCs attempted. |
backoff_policy | controls the backoff behavior between retry attempts, typically some form of exponential backoff with jitter. |
MakeSubscriberConnection
function which accepts google::cloud::Options
instead. std::shared_ptr< SubscriptionAdminConnection > google::cloud::pubsub::MakeSubscriptionAdminConnection | ( | ConnectionOptions const & | options, |
std::unique_ptr< pubsub::RetryPolicy const > | retry_policy = {} , |
||
std::unique_ptr< pubsub::BackoffPolicy const > | backoff_policy = {} |
||
) |
Creates a new SubscriptionAdminConnection
object to work with SubscriptionAdminClient
.
The SubscriptionAdminConnection
class is not intended for direct use in applications, it is provided for applications wanting to mock the SubscriptionAdminClient
behavior in their tests.
SubscriptionAdminConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the identical values for options
. However, this behavior is not guaranteed and applications should not rely on it.SubscriberConnection
options | (optional) configure the SubscriptionAdminConnection created by this function. |
retry_policy | control for how long (or how many times) are retryable RPCs attempted. |
backoff_policy | controls the backoff behavior between retry attempts, typically some form of exponential backoff with jitter. |
MakeSubscriptionAdminConnection
function that accepts google::cloud::Options
instead. std::shared_ptr< SubscriptionAdminConnection > google::cloud::pubsub::MakeSubscriptionAdminConnection | ( | Options | opts = {} | ) |
Creates a new SubscriptionAdminConnection
object to work with SubscriptionAdminClient
.
The SubscriptionAdminConnection
class is provided for applications wanting to mock the SubscriptionAdminClient
behavior in their tests. It is not intended for direct use.
SubscriptionAdminConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the same Options
from GrpcOptionList
and CommonOptionList
. However, this behavior is not guaranteed and applications should not rely on it.SubscriptionAdminClient
opts | The options to use for this call. Expected options are any of the types in the following option lists. |
std::shared_ptr< SubscriptionAdminConnection > google::cloud::pubsub::MakeSubscriptionAdminConnection | ( | std::initializer_list< internal::NonConstructible > | ) |
Creates a new SubscriptionAdminConnection
object to work with SubscriptionAdminClient
.
MakeSubscriptionAdminConnection({})
from breaking, due to ambiguity.MakeSubscriptionAdminConnection()
instead. std::shared_ptr< TopicAdminConnection > google::cloud::pubsub::MakeTopicAdminConnection | ( | ConnectionOptions const & | options, |
std::unique_ptr< pubsub::RetryPolicy const > | retry_policy = {} , |
||
std::unique_ptr< pubsub::BackoffPolicy const > | backoff_policy = {} |
||
) |
Creates a new TopicAdminConnection
object to work with TopicAdminClient
.
The TopicAdminConnection
class is provided for applications wanting to mock the TopicAdminClient
behavior in their tests. It is not intended for direct use.
TopicAdminConnection
is relatively expensive. This typically initiate connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the identical values for options
. However, this behavior is not guaranteed and applications should not rely on it.TopicAdminClient
options | (optional) configure the TopicAdminConnection created by this function. |
retry_policy | control for how long (or how many times) are retryable RPCs attempted. |
backoff_policy | controls the backoff behavior between retry attempts, typically some form of exponential backoff with jitter. |
MakeTopicAdminConnection
function that accepts google::cloud::Options
instead. std::shared_ptr< TopicAdminConnection > google::cloud::pubsub::MakeTopicAdminConnection | ( | Options | opts = {} | ) |
Creates a new TopicAdminConnection
object to work with TopicAdminClient
.
The TopicAdminConnection
class is provided for applications wanting to mock the TopicAdminClient
behavior in their tests. It is not intended for direct use.
TopicAdminConnection
is relatively expensive. This typically initiates connections to the service, and therefore these objects should be shared and reused when possible. Note that gRPC reuses existing OS resources (sockets) whenever possible, so applications may experience better performance on the second (and subsequent) calls to this function with the same Options
from GrpcOptionList
and CommonOptionList
. However, this behavior is not guaranteed and applications should not rely on it.TopicAdminClient
opts | The options to use for this call. Expected options are any of the types in the following option lists. |
std::shared_ptr< TopicAdminConnection > google::cloud::pubsub::MakeTopicAdminConnection | ( | std::initializer_list< internal::NonConstructible > | ) |
Creates a new TopicAdminConnection
object to work with TopicAdminClient
.
MakeTopicAdminConnection({})
from breaking, due to ambiguity.MakeTopicAdminConnection()
instead.