managedkafka

package
v0.227.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 19, 2025 License: BSD-3-Clause Imports: 18 Imported by: 0

Documentation

Overview

Package managedkafka provides access to the Managed Service for Apache Kafka API.

For product documentation, see: https://cloud.google.com/managed-service-for-apache-kafka/docs

Library status

These client libraries are officially supported by Google. However, this library is considered complete and is in maintenance mode. This means that we will address critical bugs and security issues but will not add any new features.

When possible, we recommend using our newer [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go) that are still actively being worked and iterated on.

Creating a client

Usage example:

import "google.golang.org/api/managedkafka/v1"
...
ctx := context.Background()
managedkafkaService, err := managedkafka.NewService(ctx)

In this example, Google Application Default Credentials are used for authentication. For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.

Other authentication options

To use an API key for authentication (note: some APIs do not support API keys), use google.golang.org/api/option.WithAPIKey:

managedkafkaService, err := managedkafka.NewService(ctx, option.WithAPIKey("AIza..."))

To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow, use google.golang.org/api/option.WithTokenSource:

config := &oauth2.Config{...}
// ...
token, err := config.Exchange(ctx, ...)
managedkafkaService, err := managedkafka.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))

See google.golang.org/api/option.ClientOption for details on options.

Index

Constants

View Source
const (
	// See, edit, configure, and delete your Google Cloud data and see the email
	// address for your Google Account.
	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
)

OAuth2 scopes used by this API.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessConfig

type AccessConfig struct {
	// NetworkConfigs: Required. Virtual Private Cloud (VPC) networks that must be
	// granted direct access to the Kafka cluster. Minimum of 1 network is
	// required. Maximum 10 networks can be specified.
	NetworkConfigs []*NetworkConfig `json:"networkConfigs,omitempty"`
	// ForceSendFields is a list of field names (e.g. "NetworkConfigs") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "NetworkConfigs") to include in
	// API requests with the JSON null value. By default, fields with empty values
	// are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

AccessConfig: The configuration of access to the Kafka cluster.

func (AccessConfig) MarshalJSON

func (s AccessConfig) MarshalJSON() ([]byte, error)

type CancelOperationRequest

type CancelOperationRequest struct {
}

CancelOperationRequest: The request message for Operations.CancelOperation.

type CapacityConfig

type CapacityConfig struct {
	// MemoryBytes: Required. The memory to provision for the cluster in bytes. The
	// CPU:memory ratio (vCPU:GiB) must be between 1:1 and 1:8. Minimum: 3221225472
	// (3 GiB).
	MemoryBytes int64 `json:"memoryBytes,omitempty,string"`
	// VcpuCount: Required. The number of vCPUs to provision for the cluster.
	// Minimum: 3.
	VcpuCount int64 `json:"vcpuCount,omitempty,string"`
	// ForceSendFields is a list of field names (e.g. "MemoryBytes") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "MemoryBytes") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

CapacityConfig: A capacity configuration of a Kafka cluster.

func (CapacityConfig) MarshalJSON

func (s CapacityConfig) MarshalJSON() ([]byte, error)

type Cluster

type Cluster struct {
	// CapacityConfig: Required. Capacity configuration for the Kafka cluster.
	CapacityConfig *CapacityConfig `json:"capacityConfig,omitempty"`
	// CreateTime: Output only. The time when the cluster was created.
	CreateTime string `json:"createTime,omitempty"`
	// GcpConfig: Required. Configuration properties for a Kafka cluster deployed
	// to Google Cloud Platform.
	GcpConfig *GcpConfig `json:"gcpConfig,omitempty"`
	// Labels: Optional. Labels as key value pairs.
	Labels map[string]string `json:"labels,omitempty"`
	// Name: Identifier. The name of the cluster. Structured like:
	// projects/{project_number}/locations/{location}/clusters/{cluster_id}
	Name string `json:"name,omitempty"`
	// RebalanceConfig: Optional. Rebalance configuration for the Kafka cluster.
	RebalanceConfig *RebalanceConfig `json:"rebalanceConfig,omitempty"`
	// SatisfiesPzi: Output only. Reserved for future use.
	SatisfiesPzi bool `json:"satisfiesPzi,omitempty"`
	// SatisfiesPzs: Output only. Reserved for future use.
	SatisfiesPzs bool `json:"satisfiesPzs,omitempty"`
	// State: Output only. The current state of the cluster.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - A state was not specified.
	//   "CREATING" - The cluster is being created.
	//   "ACTIVE" - The cluster is active.
	//   "DELETING" - The cluster is being deleted.
	State string `json:"state,omitempty"`
	// UpdateTime: Output only. The time when the cluster was last updated.
	UpdateTime string `json:"updateTime,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "CapacityConfig") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "CapacityConfig") to include in
	// API requests with the JSON null value. By default, fields with empty values
	// are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

Cluster: An Apache Kafka cluster deployed in a location.

func (Cluster) MarshalJSON

func (s Cluster) MarshalJSON() ([]byte, error)

type ConsumerGroup

type ConsumerGroup struct {
	// Name: Identifier. The name of the consumer group. The `consumer_group`
	// segment is used when connecting directly to the cluster. Structured like:
	// projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/{co
	// nsumer_group}
	Name string `json:"name,omitempty"`
	// Topics: Optional. Metadata for this consumer group for all topics it has
	// metadata for. The key of the map is a topic name, structured like:
	// projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}
	Topics map[string]ConsumerTopicMetadata `json:"topics,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "Name") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Name") to include in API requests
	// with the JSON null value. By default, fields with empty values are omitted
	// from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ConsumerGroup: A Kafka consumer group in a given cluster.

func (ConsumerGroup) MarshalJSON

func (s ConsumerGroup) MarshalJSON() ([]byte, error)

type ConsumerPartitionMetadata

type ConsumerPartitionMetadata struct {
	// Metadata: Optional. The associated metadata for this partition, or empty if
	// it does not exist.
	Metadata string `json:"metadata,omitempty"`
	// Offset: Required. The current offset for this partition, or 0 if no offset
	// has been committed.
	Offset int64 `json:"offset,omitempty,string"`
	// ForceSendFields is a list of field names (e.g. "Metadata") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Metadata") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ConsumerPartitionMetadata: Metadata for a consumer group corresponding to a specific partition.

func (ConsumerPartitionMetadata) MarshalJSON

func (s ConsumerPartitionMetadata) MarshalJSON() ([]byte, error)

type ConsumerTopicMetadata

type ConsumerTopicMetadata struct {
	// Partitions: Optional. Metadata for this consumer group and topic for all
	// partition indexes it has metadata for.
	Partitions map[string]ConsumerPartitionMetadata `json:"partitions,omitempty"`
	// ForceSendFields is a list of field names (e.g. "Partitions") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Partitions") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ConsumerTopicMetadata: Metadata for a consumer group corresponding to a specific topic.

func (ConsumerTopicMetadata) MarshalJSON

func (s ConsumerTopicMetadata) MarshalJSON() ([]byte, error)

type Empty

type Empty struct {
	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
}

Empty: A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }

type GcpConfig

type GcpConfig struct {
	// AccessConfig: Required. Access configuration for the Kafka cluster.
	AccessConfig *AccessConfig `json:"accessConfig,omitempty"`
	// KmsKey: Optional. Immutable. The Cloud KMS Key name to use for encryption.
	// The key must be located in the same region as the cluster and cannot be
	// changed. Structured like:
	// projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypt
	// o_key}.
	KmsKey string `json:"kmsKey,omitempty"`
	// ForceSendFields is a list of field names (e.g. "AccessConfig") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "AccessConfig") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

GcpConfig: Configuration properties for a Kafka cluster deployed to Google Cloud Platform.

func (GcpConfig) MarshalJSON

func (s GcpConfig) MarshalJSON() ([]byte, error)

type ListClustersResponse

type ListClustersResponse struct {
	// Clusters: The list of Clusters in the requested parent.
	Clusters []*Cluster `json:"clusters,omitempty"`
	// NextPageToken: A token that can be sent as `page_token` to retrieve the next
	// page of results. If this field is omitted, there are no more results.
	NextPageToken string `json:"nextPageToken,omitempty"`
	// Unreachable: Locations that could not be reached.
	Unreachable []string `json:"unreachable,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "Clusters") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Clusters") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ListClustersResponse: Response for ListClusters.

func (ListClustersResponse) MarshalJSON

func (s ListClustersResponse) MarshalJSON() ([]byte, error)

type ListConsumerGroupsResponse

type ListConsumerGroupsResponse struct {
	// ConsumerGroups: The list of consumer group in the requested parent. The
	// order of the consumer groups is unspecified.
	ConsumerGroups []*ConsumerGroup `json:"consumerGroups,omitempty"`
	// NextPageToken: A token that can be sent as `page_token` to retrieve the next
	// page of results. If this field is omitted, there are no more results.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "ConsumerGroups") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "ConsumerGroups") to include in
	// API requests with the JSON null value. By default, fields with empty values
	// are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ListConsumerGroupsResponse: Response for ListConsumerGroups.

func (ListConsumerGroupsResponse) MarshalJSON

func (s ListConsumerGroupsResponse) MarshalJSON() ([]byte, error)

type ListLocationsResponse

type ListLocationsResponse struct {
	// Locations: A list of locations that matches the specified filter in the
	// request.
	Locations []*Location `json:"locations,omitempty"`
	// NextPageToken: The standard List next-page token.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "Locations") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Locations") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ListLocationsResponse: The response message for Locations.ListLocations.

func (ListLocationsResponse) MarshalJSON

func (s ListLocationsResponse) MarshalJSON() ([]byte, error)

type ListOperationsResponse

type ListOperationsResponse struct {
	// NextPageToken: The standard List next-page token.
	NextPageToken string `json:"nextPageToken,omitempty"`
	// Operations: A list of operations that matches the specified filter in the
	// request.
	Operations []*Operation `json:"operations,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ListOperationsResponse: The response message for Operations.ListOperations.

func (ListOperationsResponse) MarshalJSON

func (s ListOperationsResponse) MarshalJSON() ([]byte, error)

type ListTopicsResponse

type ListTopicsResponse struct {
	// NextPageToken: A token that can be sent as `page_token` to retrieve the next
	// page of results. If this field is omitted, there are no more results.
	NextPageToken string `json:"nextPageToken,omitempty"`
	// Topics: The list of topics in the requested parent. The order of the topics
	// is unspecified.
	Topics []*Topic `json:"topics,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

ListTopicsResponse: Response for ListTopics.

func (ListTopicsResponse) MarshalJSON

func (s ListTopicsResponse) MarshalJSON() ([]byte, error)

type Location

type Location struct {
	// DisplayName: The friendly name for this location, typically a nearby city
	// name. For example, "Tokyo".
	DisplayName string `json:"displayName,omitempty"`
	// Labels: Cross-service attributes for the location. For example
	// {"cloud.googleapis.com/region": "us-east1"}
	Labels map[string]string `json:"labels,omitempty"`
	// LocationId: The canonical id for this location. For example: "us-east1".
	LocationId string `json:"locationId,omitempty"`
	// Metadata: Service-specific metadata. For example the available capacity at
	// the given location.
	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
	// Name: Resource name for the location, which may vary between
	// implementations. For example:
	// "projects/example-project/locations/us-east1"
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "DisplayName") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "DisplayName") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

Location: A resource that represents a Google Cloud location.

func (Location) MarshalJSON

func (s Location) MarshalJSON() ([]byte, error)

type NetworkConfig

type NetworkConfig struct {
	// Subnet: Required. Name of the VPC subnet in which to create Private Service
	// Connect (PSC) endpoints for the Kafka brokers and bootstrap address.
	// Structured like: projects/{project}/regions/{region}/subnetworks/{subnet_id}
	// The subnet must be located in the same region as the Kafka cluster. The
	// project may differ. Multiple subnets from the same parent network must not
	// be specified.
	Subnet string `json:"subnet,omitempty"`
	// ForceSendFields is a list of field names (e.g. "Subnet") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Subnet") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

NetworkConfig: The configuration of a Virtual Private Cloud (VPC) network that can access the Kafka cluster.

func (NetworkConfig) MarshalJSON

func (s NetworkConfig) MarshalJSON() ([]byte, error)

type Operation

type Operation struct {
	// Done: If the value is `false`, it means the operation is still in progress.
	// If `true`, the operation is completed, and either `error` or `response` is
	// available.
	Done bool `json:"done,omitempty"`
	// Error: The error result of the operation in case of failure or cancellation.
	Error *Status `json:"error,omitempty"`
	// Metadata: Service-specific metadata associated with the operation. It
	// typically contains progress information and common metadata such as create
	// time. Some services might not provide such metadata. Any method that returns
	// a long-running operation should document the metadata type, if any.
	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
	// Name: The server-assigned name, which is only unique within the same service
	// that originally returns it. If you use the default HTTP mapping, the `name`
	// should be a resource name ending with `operations/{unique_id}`.
	Name string `json:"name,omitempty"`
	// Response: The normal, successful response of the operation. If the original
	// method returns no data on success, such as `Delete`, the response is
	// `google.protobuf.Empty`. If the original method is standard
	// `Get`/`Create`/`Update`, the response should be the resource. For other
	// methods, the response should have the type `XxxResponse`, where `Xxx` is the
	// original method name. For example, if the original method name is
	// `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
	Response googleapi.RawMessage `json:"response,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "Done") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Done") to include in API requests
	// with the JSON null value. By default, fields with empty values are omitted
	// from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

Operation: This resource represents a long-running operation that is the result of a network API call.

func (Operation) MarshalJSON

func (s Operation) MarshalJSON() ([]byte, error)

type OperationMetadata

type OperationMetadata struct {
	// ApiVersion: Output only. API version used to start the operation.
	ApiVersion string `json:"apiVersion,omitempty"`
	// CreateTime: Output only. The time the operation was created.
	CreateTime string `json:"createTime,omitempty"`
	// EndTime: Output only. The time the operation finished running.
	EndTime string `json:"endTime,omitempty"`
	// RequestedCancellation: Output only. Identifies whether the user has
	// requested cancellation of the operation. Operations that have been cancelled
	// successfully have Operation.error value with a google.rpc.Status.code of 1,
	// corresponding to `Code.CANCELLED`.
	RequestedCancellation bool `json:"requestedCancellation,omitempty"`
	// StatusMessage: Output only. Human-readable status of the operation, if any.
	StatusMessage string `json:"statusMessage,omitempty"`
	// Target: Output only. Server-defined resource path for the target of the
	// operation.
	Target string `json:"target,omitempty"`
	// Verb: Output only. Name of the verb executed by the operation.
	Verb string `json:"verb,omitempty"`
	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
	// unconditionally include in API requests. By default, fields with empty or
	// default values are omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "ApiVersion") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

OperationMetadata: Represents the metadata of the long-running operation.

func (OperationMetadata) MarshalJSON

func (s OperationMetadata) MarshalJSON() ([]byte, error)

type ProjectsLocationsClustersConsumerGroupsDeleteCall

type ProjectsLocationsClustersConsumerGroupsDeleteCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersConsumerGroupsDeleteCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersConsumerGroupsDeleteCall) Do

Do executes the "managedkafka.projects.locations.clusters.consumerGroups.delete" call. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersConsumerGroupsDeleteCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersConsumerGroupsDeleteCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

type ProjectsLocationsClustersConsumerGroupsGetCall

type ProjectsLocationsClustersConsumerGroupsGetCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersConsumerGroupsGetCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersConsumerGroupsGetCall) Do

Do executes the "managedkafka.projects.locations.clusters.consumerGroups.get" call. Any non-2xx status code is an error. Response headers are in either *ConsumerGroup.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersConsumerGroupsGetCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersConsumerGroupsGetCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersConsumerGroupsGetCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

type ProjectsLocationsClustersConsumerGroupsListCall

type ProjectsLocationsClustersConsumerGroupsListCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersConsumerGroupsListCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersConsumerGroupsListCall) Do

Do executes the "managedkafka.projects.locations.clusters.consumerGroups.list" call. Any non-2xx status code is an error. Response headers are in either *ListConsumerGroupsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersConsumerGroupsListCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersConsumerGroupsListCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersConsumerGroupsListCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

func (*ProjectsLocationsClustersConsumerGroupsListCall) PageSize

PageSize sets the optional parameter "pageSize": 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.

func (*ProjectsLocationsClustersConsumerGroupsListCall) PageToken

PageToken sets the optional parameter "pageToken": A page token, received from a previous `ListConsumerGroups` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListConsumerGroups` must match the call that provided the page token.

func (*ProjectsLocationsClustersConsumerGroupsListCall) Pages

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type ProjectsLocationsClustersConsumerGroupsPatchCall

type ProjectsLocationsClustersConsumerGroupsPatchCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersConsumerGroupsPatchCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersConsumerGroupsPatchCall) Do

Do executes the "managedkafka.projects.locations.clusters.consumerGroups.patch" call. Any non-2xx status code is an error. Response headers are in either *ConsumerGroup.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersConsumerGroupsPatchCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersConsumerGroupsPatchCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersConsumerGroupsPatchCall) UpdateMask

UpdateMask sets the optional parameter "updateMask": 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.

type ProjectsLocationsClustersConsumerGroupsService

type ProjectsLocationsClustersConsumerGroupsService struct {
	// contains filtered or unexported fields
}

func NewProjectsLocationsClustersConsumerGroupsService

func NewProjectsLocationsClustersConsumerGroupsService(s *Service) *ProjectsLocationsClustersConsumerGroupsService

func (*ProjectsLocationsClustersConsumerGroupsService) Delete

Delete: Deletes a single consumer group.

  • name: The name of the consumer group to delete. `projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/ {consumerGroup}`.

func (*ProjectsLocationsClustersConsumerGroupsService) Get

Get: Returns the properties of a single consumer group.

  • name: The name of the consumer group whose configuration to return. `projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/ {consumerGroup}`.

func (*ProjectsLocationsClustersConsumerGroupsService) List

List: Lists the consumer groups in a given cluster.

  • parent: The parent cluster whose consumer groups are to be listed. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.

func (*ProjectsLocationsClustersConsumerGroupsService) Patch

Patch: Updates the properties of a single consumer group.

  • name: Identifier. The name of the consumer group. The `consumer_group` segment is used when connecting directly to the cluster. Structured like: projects/{project}/locations/{location}/clusters/{cluster}/consumerGroups/{ consumer_group}.

type ProjectsLocationsClustersCreateCall

type ProjectsLocationsClustersCreateCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersCreateCall) ClusterId

ClusterId sets the optional parameter "clusterId": 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`.

func (*ProjectsLocationsClustersCreateCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersCreateCall) Do

Do executes the "managedkafka.projects.locations.clusters.create" call. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersCreateCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersCreateCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersCreateCall) RequestId

RequestId sets the optional parameter "requestId": 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).

type ProjectsLocationsClustersDeleteCall

type ProjectsLocationsClustersDeleteCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersDeleteCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersDeleteCall) Do

Do executes the "managedkafka.projects.locations.clusters.delete" call. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersDeleteCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersDeleteCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersDeleteCall) RequestId

RequestId sets the optional parameter "requestId": 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).

type ProjectsLocationsClustersGetCall

type ProjectsLocationsClustersGetCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersGetCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersGetCall) Do

Do executes the "managedkafka.projects.locations.clusters.get" call. Any non-2xx status code is an error. Response headers are in either *Cluster.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersGetCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersGetCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersGetCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

type ProjectsLocationsClustersListCall

type ProjectsLocationsClustersListCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersListCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersListCall) Do

Do executes the "managedkafka.projects.locations.clusters.list" call. Any non-2xx status code is an error. Response headers are in either *ListClustersResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersListCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersListCall) Filter

Filter sets the optional parameter "filter": Filter expression for the result.

func (*ProjectsLocationsClustersListCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersListCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

func (*ProjectsLocationsClustersListCall) OrderBy

OrderBy sets the optional parameter "orderBy": Order by fields for the result.

func (*ProjectsLocationsClustersListCall) PageSize

PageSize sets the optional parameter "pageSize": The maximum number of clusters to return. The service may return fewer than this value. If unspecified, server will pick an appropriate default.

func (*ProjectsLocationsClustersListCall) PageToken

PageToken sets the optional parameter "pageToken": A page token, received from a previous `ListClusters` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListClusters` must match the call that provided the page token.

func (*ProjectsLocationsClustersListCall) Pages

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type ProjectsLocationsClustersPatchCall

type ProjectsLocationsClustersPatchCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersPatchCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersPatchCall) Do

Do executes the "managedkafka.projects.locations.clusters.patch" call. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersPatchCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersPatchCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersPatchCall) RequestId

RequestId sets the optional parameter "requestId": 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).

func (*ProjectsLocationsClustersPatchCall) UpdateMask

UpdateMask sets the optional parameter "updateMask": 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.

type ProjectsLocationsClustersService

type ProjectsLocationsClustersService struct {
	ConsumerGroups *ProjectsLocationsClustersConsumerGroupsService

	Topics *ProjectsLocationsClustersTopicsService
	// contains filtered or unexported fields
}

func NewProjectsLocationsClustersService

func NewProjectsLocationsClustersService(s *Service) *ProjectsLocationsClustersService

func (*ProjectsLocationsClustersService) Create

Create: Creates a new cluster in a given project and location.

  • parent: The parent region in which to create the cluster. Structured like `projects/{project}/locations/{location}`.

func (*ProjectsLocationsClustersService) Delete

Delete: Deletes a single cluster.

- name: The name of the cluster to delete.

func (*ProjectsLocationsClustersService) Get

Get: Returns the properties of a single cluster.

- name: The name of the cluster whose configuration to return.

func (*ProjectsLocationsClustersService) List

List: Lists the clusters in a given project and location.

  • parent: The parent location whose clusters are to be listed. Structured like `projects/{project}/locations/{location}`.

func (*ProjectsLocationsClustersService) Patch

Patch: Updates the properties of a single cluster.

  • name: Identifier. The name of the cluster. Structured like: projects/{project_number}/locations/{location}/clusters/{cluster_id}.

type ProjectsLocationsClustersTopicsCreateCall

type ProjectsLocationsClustersTopicsCreateCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersTopicsCreateCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersTopicsCreateCall) Do

Do executes the "managedkafka.projects.locations.clusters.topics.create" call. Any non-2xx status code is an error. Response headers are in either *Topic.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersTopicsCreateCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersTopicsCreateCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersTopicsCreateCall) TopicId

TopicId sets the optional parameter "topicId": 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`.

type ProjectsLocationsClustersTopicsDeleteCall

type ProjectsLocationsClustersTopicsDeleteCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersTopicsDeleteCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersTopicsDeleteCall) Do

Do executes the "managedkafka.projects.locations.clusters.topics.delete" call. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersTopicsDeleteCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersTopicsDeleteCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

type ProjectsLocationsClustersTopicsGetCall

type ProjectsLocationsClustersTopicsGetCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersTopicsGetCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersTopicsGetCall) Do

Do executes the "managedkafka.projects.locations.clusters.topics.get" call. Any non-2xx status code is an error. Response headers are in either *Topic.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersTopicsGetCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersTopicsGetCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersTopicsGetCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

type ProjectsLocationsClustersTopicsListCall

type ProjectsLocationsClustersTopicsListCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersTopicsListCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersTopicsListCall) Do

Do executes the "managedkafka.projects.locations.clusters.topics.list" call. Any non-2xx status code is an error. Response headers are in either *ListTopicsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersTopicsListCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersTopicsListCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersTopicsListCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

func (*ProjectsLocationsClustersTopicsListCall) PageSize

PageSize sets the optional parameter "pageSize": 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.

func (*ProjectsLocationsClustersTopicsListCall) PageToken

PageToken sets the optional parameter "pageToken": A page token, received from a previous `ListTopics` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListTopics` must match the call that provided the page token.

func (*ProjectsLocationsClustersTopicsListCall) Pages

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type ProjectsLocationsClustersTopicsPatchCall

type ProjectsLocationsClustersTopicsPatchCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsClustersTopicsPatchCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsClustersTopicsPatchCall) Do

Do executes the "managedkafka.projects.locations.clusters.topics.patch" call. Any non-2xx status code is an error. Response headers are in either *Topic.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsClustersTopicsPatchCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsClustersTopicsPatchCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsClustersTopicsPatchCall) UpdateMask

UpdateMask sets the optional parameter "updateMask": 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.

type ProjectsLocationsClustersTopicsService

type ProjectsLocationsClustersTopicsService struct {
	// contains filtered or unexported fields
}

func NewProjectsLocationsClustersTopicsService

func NewProjectsLocationsClustersTopicsService(s *Service) *ProjectsLocationsClustersTopicsService

func (*ProjectsLocationsClustersTopicsService) Create

Create: Creates a new topic in a given project and location.

  • parent: The parent cluster in which to create the topic. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.

func (*ProjectsLocationsClustersTopicsService) Delete

Delete: Deletes a single topic.

  • name: The name of the topic to delete. `projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}` .

func (*ProjectsLocationsClustersTopicsService) Get

Get: Returns the properties of a single topic.

  • name: The name of the topic whose configuration to return. Structured like: projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}.

func (*ProjectsLocationsClustersTopicsService) List

List: Lists the topics in a given cluster.

  • parent: The parent cluster whose topics are to be listed. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.

func (*ProjectsLocationsClustersTopicsService) Patch

Patch: Updates the properties of a single topic.

  • name: Identifier. The name of the topic. The `topic` segment is used when connecting directly to the cluster. Structured like: projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}.

type ProjectsLocationsGetCall

type ProjectsLocationsGetCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsGetCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsGetCall) Do

Do executes the "managedkafka.projects.locations.get" call. Any non-2xx status code is an error. Response headers are in either *Location.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsGetCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsGetCall) Header

func (c *ProjectsLocationsGetCall) Header() http.Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsGetCall) IfNoneMatch

func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

type ProjectsLocationsListCall

type ProjectsLocationsListCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsListCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsListCall) Do

Do executes the "managedkafka.projects.locations.list" call. Any non-2xx status code is an error. Response headers are in either *ListLocationsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsListCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsListCall) Filter

Filter sets the optional parameter "filter": A filter to narrow down results to a preferred subset. The filtering language accepts strings like "displayName=tokyo", and is documented in more detail in AIP-160 (https://google.aip.dev/160).

func (*ProjectsLocationsListCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsListCall) IfNoneMatch

func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

func (*ProjectsLocationsListCall) PageSize

PageSize sets the optional parameter "pageSize": The maximum number of results to return. If not set, the service selects a default.

func (*ProjectsLocationsListCall) PageToken

PageToken sets the optional parameter "pageToken": A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.

func (*ProjectsLocationsListCall) Pages

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type ProjectsLocationsOperationsCancelCall

type ProjectsLocationsOperationsCancelCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsOperationsCancelCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsOperationsCancelCall) Do

Do executes the "managedkafka.projects.locations.operations.cancel" call. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsOperationsCancelCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsOperationsCancelCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

type ProjectsLocationsOperationsDeleteCall

type ProjectsLocationsOperationsDeleteCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsOperationsDeleteCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsOperationsDeleteCall) Do

Do executes the "managedkafka.projects.locations.operations.delete" call. Any non-2xx status code is an error. Response headers are in either *Empty.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsOperationsDeleteCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsOperationsDeleteCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

type ProjectsLocationsOperationsGetCall

type ProjectsLocationsOperationsGetCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsOperationsGetCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsOperationsGetCall) Do

Do executes the "managedkafka.projects.locations.operations.get" call. Any non-2xx status code is an error. Response headers are in either *Operation.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsOperationsGetCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsOperationsGetCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsOperationsGetCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

type ProjectsLocationsOperationsListCall

type ProjectsLocationsOperationsListCall struct {
	// contains filtered or unexported fields
}

func (*ProjectsLocationsOperationsListCall) Context

Context sets the context to be used in this call's Do method.

func (*ProjectsLocationsOperationsListCall) Do

Do executes the "managedkafka.projects.locations.operations.list" call. Any non-2xx status code is an error. Response headers are in either *ListOperationsResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.

func (*ProjectsLocationsOperationsListCall) Fields

Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more details.

func (*ProjectsLocationsOperationsListCall) Filter

Filter sets the optional parameter "filter": The standard list filter.

func (*ProjectsLocationsOperationsListCall) Header

Header returns a http.Header that can be modified by the caller to add headers to the request.

func (*ProjectsLocationsOperationsListCall) IfNoneMatch

IfNoneMatch sets an optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request.

func (*ProjectsLocationsOperationsListCall) PageSize

PageSize sets the optional parameter "pageSize": The standard list page size.

func (*ProjectsLocationsOperationsListCall) PageToken

PageToken sets the optional parameter "pageToken": The standard list page token.

func (*ProjectsLocationsOperationsListCall) Pages

Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.

type ProjectsLocationsOperationsService

type ProjectsLocationsOperationsService struct {
	// contains filtered or unexported fields
}

func NewProjectsLocationsOperationsService

func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService

func (*ProjectsLocationsOperationsService) Cancel

Cancel: Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of `1`, corresponding to `Code.CANCELLED`.

- name: The name of the operation resource to be cancelled.

func (*ProjectsLocationsOperationsService) Delete

Delete: Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.

- name: The name of the operation resource to be deleted.

func (*ProjectsLocationsOperationsService) Get

Get: Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

- name: The name of the operation resource.

func (*ProjectsLocationsOperationsService) List

List: Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.

- name: The name of the operation's parent resource.

type ProjectsLocationsService

type ProjectsLocationsService struct {
	Clusters *ProjectsLocationsClustersService

	Operations *ProjectsLocationsOperationsService
	// contains filtered or unexported fields
}

func NewProjectsLocationsService

func NewProjectsLocationsService(s *Service) *ProjectsLocationsService

func (*ProjectsLocationsService) Get

Get: Gets information about a location.

- name: Resource name for the location.

func (*ProjectsLocationsService) List

List: Lists information about the supported locations for this service.

- name: The resource that owns the locations collection, if applicable.

type ProjectsService

type ProjectsService struct {
	Locations *ProjectsLocationsService
	// contains filtered or unexported fields
}

func NewProjectsService

func NewProjectsService(s *Service) *ProjectsService

type RebalanceConfig

type RebalanceConfig struct {
	// Mode: Optional. The rebalance behavior for the cluster. When not specified,
	// defaults to `NO_REBALANCE`.
	//
	// Possible values:
	//   "MODE_UNSPECIFIED" - A mode was not specified. Do not use.
	//   "NO_REBALANCE" - Do not rebalance automatically.
	//   "AUTO_REBALANCE_ON_SCALE_UP" - Automatically rebalance topic partitions
	// among brokers when the cluster is scaled up.
	Mode string `json:"mode,omitempty"`
	// ForceSendFields is a list of field names (e.g. "Mode") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Mode") to include in API requests
	// with the JSON null value. By default, fields with empty values are omitted
	// from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

RebalanceConfig: Defines rebalancing behavior of a Kafka cluster.

func (RebalanceConfig) MarshalJSON

func (s RebalanceConfig) MarshalJSON() ([]byte, error)

type Service

type Service struct {
	BasePath  string // API endpoint base URL
	UserAgent string // optional additional User-Agent fragment

	Projects *ProjectsService
	// contains filtered or unexported fields
}

func New deprecated

func New(client *http.Client) (*Service, error)

New creates a new Service. It uses the provided http.Client for requests.

Deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.

func NewService

func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error)

NewService creates a new Service.

type Status

type Status struct {
	// Code: The status code, which should be an enum value of google.rpc.Code.
	Code int64 `json:"code,omitempty"`
	// Details: A list of messages that carry the error details. There is a common
	// set of message types for APIs to use.
	Details []googleapi.RawMessage `json:"details,omitempty"`
	// Message: A developer-facing error message, which should be in English. Any
	// user-facing error message should be localized and sent in the
	// google.rpc.Status.details field, or localized by the client.
	Message string `json:"message,omitempty"`
	// ForceSendFields is a list of field names (e.g. "Code") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Code") to include in API requests
	// with the JSON null value. By default, fields with empty values are omitted
	// from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

Status: The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the API Design Guide (https://cloud.google.com/apis/design/errors).

func (Status) MarshalJSON

func (s Status) MarshalJSON() ([]byte, error)

type Topic

type Topic struct {
	// Configs: Optional. Configurations for the topic that are overridden from the
	// cluster defaults. The key of the map is a Kafka topic property name, for
	// example: `cleanup.policy`, `compression.type`.
	Configs map[string]string `json:"configs,omitempty"`
	// Name: Identifier. The name of the topic. The `topic` segment is used when
	// connecting directly to the cluster. Structured like:
	// projects/{project}/locations/{location}/clusters/{cluster}/topics/{topic}
	Name string `json:"name,omitempty"`
	// PartitionCount: Required. The number of partitions this topic has. The
	// partition count can only be increased, not decreased. Please note that if
	// partitions are increased for a topic that has a key, the partitioning logic
	// or the ordering of the messages will be affected.
	PartitionCount int64 `json:"partitionCount,omitempty"`
	// ReplicationFactor: Required. Immutable. The number of replicas of each
	// partition. A replication factor of 3 is recommended for high availability.
	ReplicationFactor int64 `json:"replicationFactor,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the server.
	googleapi.ServerResponse `json:"-"`
	// ForceSendFields is a list of field names (e.g. "Configs") to unconditionally
	// include in API requests. By default, fields with empty or default values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
	// details.
	ForceSendFields []string `json:"-"`
	// NullFields is a list of field names (e.g. "Configs") to include in API
	// requests with the JSON null value. By default, fields with empty values are
	// omitted from API requests. See
	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
	NullFields []string `json:"-"`
}

Topic: A Kafka topic in a given cluster.

func (Topic) MarshalJSON

func (s Topic) MarshalJSON() ([]byte, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL