Google-Cloud-Pubsub-V1
view release on metacpan or search on metacpan
lib/Google/Pubsub/V1/Pubsub.pm view on Meta::CPAN
Type: Message (.google.pubsub.v1.IngestionFailureEvent.CloudStorageFailure)
=item * B<aws_msk_failure>
Type: Message (.google.pubsub.v1.IngestionFailureEvent.AwsMskFailureReason)
=item * B<azure_event_hubs_failure>
Type: Message (.google.pubsub.v1.IngestionFailureEvent.AzureEventHubsFailureReason)
=item * B<confluent_cloud_failure>
Type: Message (.google.pubsub.v1.IngestionFailureEvent.ConfluentCloudFailureReason)
=item * B<aws_kinesis_failure>
Type: Message (.google.pubsub.v1.IngestionFailureEvent.AwsKinesisFailureReason)
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::JavaScriptUDF ===
# Fields for JavaScriptUDF
# Field: function_name Type: 9 ()
# Field: code Type: 9 ()
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::JavaScriptUDF - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::JavaScriptUDF->new(
function_name => $value,
);
=head1 FIELDS
=over 4
=item * B<function_name>
Type: String
=item * B<code>
Type: String
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::AIInference ===
# Fields for AIInference
# Field: endpoint Type: 9 ()
# Field: unstructured_inference Type: 11 (.google.pubsub.v1.AIInference.UnstructuredInference)
# Field: service_account_email Type: 9 ()
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::AIInference - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::AIInference->new(
endpoint => $value,
);
=head1 FIELDS
=over 4
=item * B<endpoint>
Type: String
=item * B<unstructured_inference>
Type: Message (.google.pubsub.v1.AIInference.UnstructuredInference)
=item * B<service_account_email>
Type: String
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::MessageTransform ===
# Fields for MessageTransform
# Field: javascript_udf Type: 11 (.google.pubsub.v1.JavaScriptUDF)
# Field: ai_inference Type: 11 (.google.pubsub.v1.AIInference)
# Field: enabled Type: 8 ()
# Field: disabled Type: 8 ()
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::MessageTransform - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::MessageTransform->new(
javascript_udf => $value,
);
=head1 FIELDS
=over 4
=item * B<javascript_udf>
Type: Message (.google.pubsub.v1.JavaScriptUDF)
=item * B<ai_inference>
Type: Message (.google.pubsub.v1.AIInference)
=item * B<enabled>
Type: Bool
=item * B<disabled>
Type: Bool
=back
=cut
lib/Google/Pubsub/V1/Pubsub.pm view on Meta::CPAN
=head1 NAME
Google::Pubsub::V1::Pubsub::DeadLetterPolicy - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::DeadLetterPolicy->new(
dead_letter_topic => $value,
);
=head1 FIELDS
=over 4
=item * B<dead_letter_topic>
Type: String
=item * B<max_delivery_attempts>
Type: Int32
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::ExpirationPolicy ===
# Fields for ExpirationPolicy
# Field: ttl Type: 11 (.google.protobuf.Duration)
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::ExpirationPolicy - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::ExpirationPolicy->new(
ttl => $value,
);
=head1 FIELDS
=over 4
=item * B<ttl>
Type: Message (.google.protobuf.Duration)
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::PushConfig ===
# Fields for PushConfig
# Field: push_endpoint Type: 9 ()
# Field: attributes Type: 11 (.google.pubsub.v1.PushConfig.AttributesEntry)
# Field: oidc_token Type: 11 (.google.pubsub.v1.PushConfig.OidcToken)
# Field: pubsub_wrapper Type: 11 (.google.pubsub.v1.PushConfig.PubsubWrapper)
# Field: no_wrapper Type: 11 (.google.pubsub.v1.PushConfig.NoWrapper)
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::PushConfig - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::PushConfig->new(
push_endpoint => $value,
);
=head1 FIELDS
=over 4
=item * B<push_endpoint>
Type: String
=item * B<attributes>
Type: Message (.google.pubsub.v1.PushConfig.AttributesEntry)
=item * B<oidc_token>
Type: Message (.google.pubsub.v1.PushConfig.OidcToken)
=item * B<pubsub_wrapper>
Type: Message (.google.pubsub.v1.PushConfig.PubsubWrapper)
=item * B<no_wrapper>
Type: Message (.google.pubsub.v1.PushConfig.NoWrapper)
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::BigQueryConfig ===
# Fields for BigQueryConfig
# Field: table Type: 9 ()
# Field: use_topic_schema Type: 8 ()
# Field: write_metadata Type: 8 ()
# Field: drop_unknown_fields Type: 8 ()
# Field: state Type: 14 (.google.pubsub.v1.BigQueryConfig.State)
# Field: use_table_schema Type: 8 ()
# Field: service_account_email Type: 9 ()
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::BigQueryConfig - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::BigQueryConfig->new(
table => $value,
);
=head1 FIELDS
=over 4
=item * B<table>
Type: String
=item * B<use_topic_schema>
Type: Bool
=item * B<write_metadata>
lib/Google/Pubsub/V1/Pubsub.pm view on Meta::CPAN
=item * B<subscription>
Type: String
=item * B<time>
Type: Message (.google.protobuf.Timestamp)
=item * B<snapshot>
Type: String
=back
=cut
# === Message: Google::Pubsub::V1::Pubsub::SeekResponse ===
# Fields for SeekResponse
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::SeekResponse - Compiled Protocol Buffers message class
=head1 SYNOPSIS
use Google::Pubsub::V1::Pubsub;
my $msg = Google::Pubsub::V1::Pubsub::SeekResponse->new(
);
=head1 FIELDS
=over 4
=back
=cut
# === Service Client: Google::Pubsub::V1::Pubsub::PublisherClient ===
package Google::Pubsub::V1::Pubsub::PublisherClient;
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::PublisherClient - Client stub representing the remote Publisher service
=head1 DESCRIPTION
This class acts as a local client stub for the remote gRPC service.
It delegates call dispatching to an underlying L<Google::gRPC::Client>
instance, ensuring type-safe request parsing and response mapping.
=head1 CONFIGURATION AND ENVIRONMENT
=head2 target
The endpoint target address. Defaults to C<pubsub.googleapis.com:443>.
=head2 credentials
The authentication credentials provider. Defaults to application default credentials via L<Google::Auth>.
=cut
use Moo;
use Google::Auth;
use Google::gRPC::Client;
has credentials => ( is => 'ro', default => sub { Google::Auth->default() } );
has target => ( is => 'ro', default => 'pubsub.googleapis.com:443' );
has _grpc_client => (
is => 'ro',
lazy => 1,
builder => sub {
my $self = shift;
return Google::gRPC::Client->new(
target => $self->target,
auth_token => $self->credentials->get_token(),
);
}
);
sub create_topic {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::Topic->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'CreateTopic',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::Topic',
});
}
sub update_topic {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::UpdateTopicRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'UpdateTopic',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::Topic',
});
}
sub publish {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::PublishRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'Publish',
lib/Google/Pubsub/V1/Pubsub.pm view on Meta::CPAN
}
sub list_topic_snapshots {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::ListTopicSnapshotsRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'ListTopicSnapshots',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::ListTopicSnapshotsResponse',
});
}
sub delete_topic {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::DeleteTopicRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'DeleteTopic',
request => $req,
response_class => 'Google::Protobuf::Empty::Empty',
});
}
sub detach_subscription {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::DetachSubscriptionRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Publisher',
method => 'DetachSubscription',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::DetachSubscriptionResponse',
});
}
# === Service Client: Google::Pubsub::V1::Pubsub::SubscriberClient ===
package Google::Pubsub::V1::Pubsub::SubscriberClient;
=pod
=head1 NAME
Google::Pubsub::V1::Pubsub::SubscriberClient - Client stub representing the remote Subscriber service
=head1 DESCRIPTION
This class acts as a local client stub for the remote gRPC service.
It delegates call dispatching to an underlying L<Google::gRPC::Client>
instance, ensuring type-safe request parsing and response mapping.
=head1 CONFIGURATION AND ENVIRONMENT
=head2 target
The endpoint target address. Defaults to C<pubsub.googleapis.com:443>.
=head2 credentials
The authentication credentials provider. Defaults to application default credentials via L<Google::Auth>.
=cut
use Moo;
use Google::Auth;
use Google::gRPC::Client;
has credentials => ( is => 'ro', default => sub { Google::Auth->default() } );
has target => ( is => 'ro', default => 'pubsub.googleapis.com:443' );
has _grpc_client => (
is => 'ro',
lazy => 1,
builder => sub {
my $self = shift;
return Google::gRPC::Client->new(
target => $self->target,
auth_token => $self->credentials->get_token(),
);
}
);
sub create_subscription {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::Subscription->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Subscriber',
method => 'CreateSubscription',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::Subscription',
});
}
sub get_subscription {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::GetSubscriptionRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Subscriber',
method => 'GetSubscription',
request => $req,
response_class => 'Google::Pubsub::V1::Pubsub::Subscription',
});
}
sub update_subscription {
my ($self, $args) = @_;
my $req = ref($args) eq 'HASH'
? Google::Pubsub::V1::Pubsub::UpdateSubscriptionRequest->new($args)
: $args;
return $self->_grpc_client->call({
service => 'google.pubsub.v1.Subscriber',
method => 'UpdateSubscription',
( run in 2.072 seconds using v1.01-cache-2.11-cpan-81fc1098f69 )