Reference documentation and code samples for the Managed Service for Apache Kafka V1 API class Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.
Client for the ManagedKafka service.
The service that a client application uses to manage Apache Kafka clusters, topics and consumer groups.
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::ConfigurationConfigure the ManagedKafka Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all ManagedKafka clients ::Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.configure do |config| config.timeout = 10.0 end
#add_acl_entry
def add_acl_entry(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::AddAclEntryResponse
def add_acl_entry(acl: nil, acl_entry: nil) -> ::Google::Cloud::ManagedKafka::V1::AddAclEntryResponseIncremental update: Adds an acl entry to an acl. Creates the acl if it does not exist yet.
def add_acl_entry(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::AddAclEntryResponseadd_acl_entry via a request object, either of type
AddAclEntryRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::AddAclEntryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def add_acl_entry(acl: nil, acl_entry: nil) -> ::Google::Cloud::ManagedKafka::V1::AddAclEntryResponseadd_acl_entry via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
acl (::String) — Required. The name of the acl to add the acl entry to.
Structured like:
projects/{project}/locations/{location}/clusters/{cluster}/acls/{acl_id}.The structure of
acl_iddefines the Resource Pattern (resource_type, resource_name, pattern_type) of the acl. SeeAcl.namefor details. - acl_entry (::Google::Cloud::ManagedKafka::V1::AclEntry, ::Hash) — Required. The acl entry to add.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::AddAclEntryResponse)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::AddAclEntryRequest.new # Call the add_acl_entry method. result = client.add_acl_entry request # The returned object is of type Google::Cloud::ManagedKafka::V1::AddAclEntryResponse. p result
#configure
def configure() { |config| ... } -> Client::ConfigurationConfigure the ManagedKafka Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
#create_acl
def create_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Acl
def create_acl(parent: nil, acl_id: nil, acl: nil) -> ::Google::Cloud::ManagedKafka::V1::AclCreates a new acl in the given project, location, and cluster.
def create_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Aclcreate_acl via a request object, either of type
CreateAclRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::CreateAclRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_acl(parent: nil, acl_id: nil, acl: nil) -> ::Google::Cloud::ManagedKafka::V1::Aclcreate_acl via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent cluster in which to create the acl.
Structured like
projects/{project}/locations/{location}/clusters/{cluster}. -
acl_id (::String) — Required. The ID to use for the acl, which will become the final component
of the acl's name. The structure of
acl_iddefines the Resource Pattern (resource_type, resource_name, pattern_type) of the acl.acl_idis structured like one of the following:For acls on the cluster:
clusterFor acls on a single resource within the cluster:
topic/{resource_name}consumerGroup/{resource_name}transactionalId/{resource_name}For acls on all resources that match a prefix:
topicPrefixed/{resource_name}consumerGroupPrefixed/{resource_name}transactionalIdPrefixed/{resource_name}For acls on all resources of a given type (i.e. the wildcard literal ""):
allTopics(represents `topic/)allConsumerGroups(representsconsumerGroup/)allTransactionalIds(representstransactionalId/`) -
acl (::Google::Cloud::ManagedKafka::V1::Acl, ::Hash) — Required. Configuration of the acl to create. Its
namefield is ignored.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Acl)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::CreateAclRequest.new # Call the create_acl method. result = client.create_acl request # The returned object is of type Google::Cloud::ManagedKafka::V1::Acl. p result
#create_cluster
def create_cluster(request, options = nil) -> ::Gapic::Operation
def create_cluster(parent: nil, cluster_id: nil, cluster: nil, request_id: nil) -> ::Gapic::OperationCreates a new cluster in a given project and location.
def create_cluster(request, options = nil) -> ::Gapic::Operationcreate_cluster via a request object, either of type
CreateClusterRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::CreateClusterRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_cluster(parent: nil, cluster_id: nil, cluster: nil, request_id: nil) -> ::Gapic::Operationcreate_cluster via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent region in which to create the cluster. Structured like
projects/{project}/locations/{location}. -
cluster_id (::String) — Required. The ID to use for the cluster, which will become the final
component of the cluster's name. The ID must be 1-63 characters long, and
match the regular expression
[a-z]([-a-z0-9]*[a-z0-9])?to comply with RFC 1035.This value is structured like:
my-cluster-id. -
cluster (::Google::Cloud::ManagedKafka::V1::Cluster, ::Hash) — Required. Configuration of the cluster to create. Its
namefield is ignored. -
request_id (::String) — Optional. An optional request ID to identify requests. Specify a unique
request ID to avoid duplication of requests. If a request times out or
fails, retrying with the same ID allows the server to recognize the
previous attempt. For at least 60 minutes, the server ignores duplicate
requests bearing the same ID.
For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID within 60 minutes of the last request, the server checks if an original operation with the same request ID was received. If so, the server ignores the second request.
The request ID must be a valid UUID. A zero UUID is not supported (00000000-0000-0000-0000-000000000000).
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::Operation)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::CreateClusterRequest.new # Call the create_cluster method. result = client.create_cluster request # The returned object is of type Gapic::Operation. You can use it to # check the status of an operation, cancel it, or wait for results. # Here is how to wait for a response. result.wait_until_done! timeout: 60 if result.response? p result.response else puts "No response received." end
#create_topic
def create_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topic
def create_topic(parent: nil, topic_id: nil, topic: nil) -> ::Google::Cloud::ManagedKafka::V1::TopicCreates a new topic in a given project and location.
def create_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topiccreate_topic via a request object, either of type
CreateTopicRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::CreateTopicRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def create_topic(parent: nil, topic_id: nil, topic: nil) -> ::Google::Cloud::ManagedKafka::V1::Topiccreate_topic via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent cluster in which to create the topic.
Structured like
projects/{project}/locations/{location}/clusters/{cluster}. -
topic_id (::String) — Required. The ID to use for the topic, which will become the final
component of the topic's name.
This value is structured like:
my-topic-name. -
topic (::Google::Cloud::ManagedKafka::V1::Topic, ::Hash) — Required. Configuration of the topic to create. Its
namefield is ignored.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Topic)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::CreateTopicRequest.new # Call the create_topic method. result = client.create_topic request # The returned object is of type Google::Cloud::ManagedKafka::V1::Topic. p result
#delete_acl
def delete_acl(request, options = nil) -> ::Google::Protobuf::Empty
def delete_acl(name: nil) -> ::Google::Protobuf::EmptyDeletes an acl.
def delete_acl(request, options = nil) -> ::Google::Protobuf::Emptydelete_acl via a request object, either of type
DeleteAclRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::DeleteAclRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_acl(name: nil) -> ::Google::Protobuf::Emptydelete_acl via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the acl to delete.
Structured like:
projects/{project}/locations/{location}/clusters/{cluster}/acls/{acl_id}.The structure of
acl_iddefines the Resource Pattern (resource_type, resource_name, pattern_type) of the acl. SeeAcl.namefor details.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Protobuf::Empty)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::DeleteAclRequest.new # Call the delete_acl method. result = client.delete_acl request # The returned object is of type Google::Protobuf::Empty. p result
#delete_cluster
def delete_cluster(request, options = nil) -> ::Gapic::Operation
def delete_cluster(name: nil, request_id: nil) -> ::Gapic::OperationDeletes a single cluster.
def delete_cluster(request, options = nil) -> ::Gapic::Operationdelete_cluster via a request object, either of type
DeleteClusterRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::DeleteClusterRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_cluster(name: nil, request_id: nil) -> ::Gapic::Operationdelete_cluster via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- name (::String) — Required. The name of the cluster to delete.
-
request_id (::String) — Optional. An optional request ID to identify requests. Specify a unique
request ID to avoid duplication of requests. If a request times out or
fails, retrying with the same ID allows the server to recognize the
previous attempt. For at least 60 minutes, the server ignores duplicate
requests bearing the same ID.
For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID within 60 minutes of the last request, the server checks if an original operation with the same request ID was received. If so, the server ignores the second request.
The request ID must be a valid UUID. A zero UUID is not supported (00000000-0000-0000-0000-000000000000).
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::Operation)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::DeleteClusterRequest.new # Call the delete_cluster method. result = client.delete_cluster request # The returned object is of type Gapic::Operation. You can use it to # check the status of an operation, cancel it, or wait for results. # Here is how to wait for a response. result.wait_until_done! timeout: 60 if result.response? p result.response else puts "No response received." end
#delete_consumer_group
def delete_consumer_group(request, options = nil) -> ::Google::Protobuf::Empty
def delete_consumer_group(name: nil) -> ::Google::Protobuf::EmptyDeletes a single consumer group.
def delete_consumer_group(request, options = nil) -> ::Google::Protobuf::Emptydelete_consumer_group via a request object, either of type
DeleteConsumerGroupRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::DeleteConsumerGroupRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_consumer_group(name: nil) -> ::Google::Protobuf::Emptydelete_consumer_group via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the consumer group to delete.
projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/{consumerGroup}.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Protobuf::Empty)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::DeleteConsumerGroupRequest.new # Call the delete_consumer_group method. result = client.delete_consumer_group request # The returned object is of type Google::Protobuf::Empty. p result
#delete_topic
def delete_topic(request, options = nil) -> ::Google::Protobuf::Empty
def delete_topic(name: nil) -> ::Google::Protobuf::EmptyDeletes a single topic.
def delete_topic(request, options = nil) -> ::Google::Protobuf::Emptydelete_topic via a request object, either of type
DeleteTopicRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::DeleteTopicRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def delete_topic(name: nil) -> ::Google::Protobuf::Emptydelete_topic via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the topic to delete.
projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Protobuf::Empty)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::DeleteTopicRequest.new # Call the delete_topic method. result = client.delete_topic request # The returned object is of type Google::Protobuf::Empty. p result
#get_acl
def get_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Acl
def get_acl(name: nil) -> ::Google::Cloud::ManagedKafka::V1::AclReturns the properties of a single acl.
def get_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Aclget_acl via a request object, either of type
GetAclRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::GetAclRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_acl(name: nil) -> ::Google::Cloud::ManagedKafka::V1::Aclget_acl via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the acl to return.
Structured like:
projects/{project}/locations/{location}/clusters/{cluster}/acls/{acl_id}.The structure of
acl_iddefines the Resource Pattern (resource_type, resource_name, pattern_type) of the acl. SeeAcl.namefor details.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Acl)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::GetAclRequest.new # Call the get_acl method. result = client.get_acl request # The returned object is of type Google::Cloud::ManagedKafka::V1::Acl. p result
#get_cluster
def get_cluster(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Cluster
def get_cluster(name: nil) -> ::Google::Cloud::ManagedKafka::V1::ClusterReturns the properties of a single cluster.
def get_cluster(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Clusterget_cluster via a request object, either of type
GetClusterRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::GetClusterRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_cluster(name: nil) -> ::Google::Cloud::ManagedKafka::V1::Clusterget_cluster via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- name (::String) — Required. The name of the cluster whose configuration to return.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Cluster)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::GetClusterRequest.new # Call the get_cluster method. result = client.get_cluster request # The returned object is of type Google::Cloud::ManagedKafka::V1::Cluster. p result
#get_consumer_group
def get_consumer_group(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroup
def get_consumer_group(name: nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupReturns the properties of a single consumer group.
def get_consumer_group(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupget_consumer_group via a request object, either of type
GetConsumerGroupRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::GetConsumerGroupRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_consumer_group(name: nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupget_consumer_group via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the consumer group whose configuration to return.
projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/{consumerGroup}.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::ConsumerGroup)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::GetConsumerGroupRequest.new # Call the get_consumer_group method. result = client.get_consumer_group request # The returned object is of type Google::Cloud::ManagedKafka::V1::ConsumerGroup. p result
#get_topic
def get_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topic
def get_topic(name: nil) -> ::Google::Cloud::ManagedKafka::V1::TopicReturns the properties of a single topic.
def get_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topicget_topic via a request object, either of type
GetTopicRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::GetTopicRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_topic(name: nil) -> ::Google::Cloud::ManagedKafka::V1::Topicget_topic via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- name (::String) — Required. The name of the topic whose configuration to return. Structured like: projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Topic)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::GetTopicRequest.new # Call the get_topic method. result = client.get_topic request # The returned object is of type Google::Cloud::ManagedKafka::V1::Topic. p result
#initialize
def initialize() { |config| ... } -> ClientCreate a new ManagedKafka client object.
- (config) — Configure the ManagedKafka client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a client using a custom configuration client = ::Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new do |config| config.timeout = 10.0 end
#list_acls
def list_acls(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>
def list_acls(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>Lists the acls in a given cluster.
def list_acls(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>list_acls via a request object, either of type
ListAclsRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::ListAclsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_acls(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>list_acls via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent cluster whose acls are to be listed.
Structured like
projects/{project}/locations/{location}/clusters/{cluster}. - page_size (::Integer) — Optional. The maximum number of acls to return. The service may return fewer than this value. If unset or zero, all acls for the parent is returned.
-
page_token (::String) — Optional. A page token, received from a previous
ListAclscall. Provide this to retrieve the subsequent page.When paginating, all other parameters provided to
ListAclsmust match the call that provided the page token.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Acl>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::ListAclsRequest.new # Call the list_acls method. result = client.list_acls request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::ManagedKafka::V1::Acl. p item end
#list_clusters
def list_clusters(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>
def list_clusters(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>Lists the clusters in a given project and location.
def list_clusters(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>list_clusters via a request object, either of type
ListClustersRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::ListClustersRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_clusters(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>list_clusters via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent location whose clusters are to be listed. Structured
like
projects/{project}/locations/{location}. - page_size (::Integer) — Optional. The maximum number of clusters to return. The service may return fewer than this value. If unspecified, server will pick an appropriate default.
-
page_token (::String) — Optional. A page token, received from a previous
ListClusterscall. Provide this to retrieve the subsequent page.When paginating, all other parameters provided to
ListClustersmust match the call that provided the page token. - filter (::String) — Optional. Filter expression for the result.
- order_by (::String) — Optional. Order by fields for the result.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Cluster>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::ListClustersRequest.new # Call the list_clusters method. result = client.list_clusters request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::ManagedKafka::V1::Cluster. p item end
#list_consumer_groups
def list_consumer_groups(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>
def list_consumer_groups(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>Lists the consumer groups in a given cluster.
def list_consumer_groups(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>list_consumer_groups via a request object, either of type
ListConsumerGroupsRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::ListConsumerGroupsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_consumer_groups(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>list_consumer_groups via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent cluster whose consumer groups are to be listed.
Structured like
projects/{project}/locations/{location}/clusters/{cluster}. - page_size (::Integer) — Optional. The maximum number of consumer groups to return. The service may return fewer than this value. If unset or zero, all consumer groups for the parent is returned.
-
page_token (::String) — Optional. A page token, received from a previous
ListConsumerGroupscall. Provide this to retrieve the subsequent page.When paginating, all other parameters provided to
ListConsumerGroupsmust match the call that provided the page token.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::ConsumerGroup>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::ListConsumerGroupsRequest.new # Call the list_consumer_groups method. result = client.list_consumer_groups request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::ManagedKafka::V1::ConsumerGroup. p item end
#list_topics
def list_topics(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>
def list_topics(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>Lists the topics in a given cluster.
def list_topics(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>list_topics via a request object, either of type
ListTopicsRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::ListTopicsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_topics(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>list_topics via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent cluster whose topics are to be listed. Structured like
projects/{project}/locations/{location}/clusters/{cluster}. - page_size (::Integer) — Optional. The maximum number of topics to return. The service may return fewer than this value. If unset or zero, all topics for the parent is returned.
-
page_token (::String) — Optional. A page token, received from a previous
ListTopicscall. Provide this to retrieve the subsequent page.When paginating, all other parameters provided to
ListTopicsmust match the call that provided the page token.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::ManagedKafka::V1::Topic>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::ListTopicsRequest.new # Call the list_topics method. result = client.list_topics request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::ManagedKafka::V1::Topic. p item end
#location_client
def location_client() -> Google::Cloud::Location::Locations::ClientGet the associated client for mix-in of the Locations.
- (Google::Cloud::Location::Locations::Client)
#logger
def logger() -> LoggerThe logger used for request/response debug logging.
- (Logger)
#operations_client
def operations_client() -> ::Google::Cloud::ManagedKafka::V1::ManagedKafka::OperationsGet the associated client for long-running operations.
#remove_acl_entry
def remove_acl_entry(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponse
def remove_acl_entry(acl: nil, acl_entry: nil) -> ::Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponseIncremental update: Removes an acl entry from an acl. Deletes the acl if its acl entries become empty (i.e. if the removed entry was the last one in the acl).
def remove_acl_entry(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponseremove_acl_entry via a request object, either of type
RemoveAclEntryRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::RemoveAclEntryRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def remove_acl_entry(acl: nil, acl_entry: nil) -> ::Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponseremove_acl_entry via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
acl (::String) — Required. The name of the acl to remove the acl entry from.
Structured like:
projects/{project}/locations/{location}/clusters/{cluster}/acls/{acl_id}.The structure of
acl_iddefines the Resource Pattern (resource_type, resource_name, pattern_type) of the acl. SeeAcl.namefor details. - acl_entry (::Google::Cloud::ManagedKafka::V1::AclEntry, ::Hash) — Required. The acl entry to remove.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponse)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::RemoveAclEntryRequest.new # Call the remove_acl_entry method. result = client.remove_acl_entry request # The returned object is of type Google::Cloud::ManagedKafka::V1::RemoveAclEntryResponse. p result
#universe_domain
def universe_domain() -> StringThe effective universe domain
- (String)
#update_acl
def update_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Acl
def update_acl(acl: nil, update_mask: nil) -> ::Google::Cloud::ManagedKafka::V1::AclUpdates the properties of a single acl.
def update_acl(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Aclupdate_acl via a request object, either of type
UpdateAclRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::UpdateAclRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_acl(acl: nil, update_mask: nil) -> ::Google::Cloud::ManagedKafka::V1::Aclupdate_acl via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
acl (::Google::Cloud::ManagedKafka::V1::Acl, ::Hash) — Required. The updated acl. Its
nameandetagfields must be populated.acl_entriesmust not be empty in the updated acl; to remove all acl entries for an acl, use DeleteAcl. - update_mask (::Google::Protobuf::FieldMask, ::Hash) — Optional. Field mask is used to specify the fields to be overwritten in the Acl resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Acl)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::UpdateAclRequest.new # Call the update_acl method. result = client.update_acl request # The returned object is of type Google::Cloud::ManagedKafka::V1::Acl. p result
#update_cluster
def update_cluster(request, options = nil) -> ::Gapic::Operation
def update_cluster(update_mask: nil, cluster: nil, request_id: nil) -> ::Gapic::OperationUpdates the properties of a single cluster.
def update_cluster(request, options = nil) -> ::Gapic::Operationupdate_cluster via a request object, either of type
UpdateClusterRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::UpdateClusterRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_cluster(update_mask: nil, cluster: nil, request_id: nil) -> ::Gapic::Operationupdate_cluster via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. Field mask is used to specify the fields to be overwritten in the cluster resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The mask is required and a value of * will update all fields.
-
cluster (::Google::Cloud::ManagedKafka::V1::Cluster, ::Hash) — Required. The cluster to update. Its
namefield must be populated. -
request_id (::String) — Optional. An optional request ID to identify requests. Specify a unique
request ID to avoid duplication of requests. If a request times out or
fails, retrying with the same ID allows the server to recognize the
previous attempt. For at least 60 minutes, the server ignores duplicate
requests bearing the same ID.
For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID within 60 minutes of the last request, the server checks if an original operation with the same request ID was received. If so, the server ignores the second request.
The request ID must be a valid UUID. A zero UUID is not supported (00000000-0000-0000-0000-000000000000).
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::Operation)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::UpdateClusterRequest.new # Call the update_cluster method. result = client.update_cluster request # The returned object is of type Gapic::Operation. You can use it to # check the status of an operation, cancel it, or wait for results. # Here is how to wait for a response. result.wait_until_done! timeout: 60 if result.response? p result.response else puts "No response received." end
#update_consumer_group
def update_consumer_group(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroup
def update_consumer_group(update_mask: nil, consumer_group: nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupUpdates the properties of a single consumer group.
def update_consumer_group(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupupdate_consumer_group via a request object, either of type
UpdateConsumerGroupRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::UpdateConsumerGroupRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_consumer_group(update_mask: nil, consumer_group: nil) -> ::Google::Cloud::ManagedKafka::V1::ConsumerGroupupdate_consumer_group via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. Field mask is used to specify the fields to be overwritten in the ConsumerGroup resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The mask is required and a value of * will update all fields.
-
consumer_group (::Google::Cloud::ManagedKafka::V1::ConsumerGroup, ::Hash) — Required. The consumer group to update. Its
namefield must be populated.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::ConsumerGroup)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::UpdateConsumerGroupRequest.new # Call the update_consumer_group method. result = client.update_consumer_group request # The returned object is of type Google::Cloud::ManagedKafka::V1::ConsumerGroup. p result
#update_topic
def update_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topic
def update_topic(update_mask: nil, topic: nil) -> ::Google::Cloud::ManagedKafka::V1::TopicUpdates the properties of a single topic.
def update_topic(request, options = nil) -> ::Google::Cloud::ManagedKafka::V1::Topicupdate_topic via a request object, either of type
UpdateTopicRequest or an equivalent Hash.
- request (::Google::Cloud::ManagedKafka::V1::UpdateTopicRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def update_topic(update_mask: nil, topic: nil) -> ::Google::Cloud::ManagedKafka::V1::Topicupdate_topic via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- update_mask (::Google::Protobuf::FieldMask, ::Hash) — Required. Field mask is used to specify the fields to be overwritten in the Topic resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. The mask is required and a value of * will update all fields.
-
topic (::Google::Cloud::ManagedKafka::V1::Topic, ::Hash) — Required. The topic to update. Its
namefield must be populated.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::ManagedKafka::V1::Topic)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/managed_kafka/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::ManagedKafka::V1::ManagedKafka::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::ManagedKafka::V1::UpdateTopicRequest.new # Call the update_topic method. result = client.update_topic request # The returned object is of type Google::Cloud::ManagedKafka::V1::Topic. p result