Cloud Dataplex API v1 - Package cloud.google.com/go/dataplex/apiv1 (v0.4.0)

Package dataplex is an auto-generated package for the Cloud Dataplex API.

Dataplex API is used to manage the lifecycle of data lakes.

NOTE: This package is in beta. It is not stable, and may be subject to changes.

Example usage

To get started with this package, create a client.

ctx := context.Background()
c, err := dataplex.NewContentClient(ctx)
if err != nil {
    // TODO: Handle error.
}
defer c.Close()

The client will use your default application credentials. Clients should be reused instead of created as needed. The methods of Client are safe for concurrent use by multiple goroutines. The returned client must be Closed when it is done being used.

Using the Client

The following is an example of making an API call with the newly created client.

ctx := context.Background()
c, err := dataplex.NewContentClient(ctx)
if err != nil {
    // TODO: Handle error.
}
defer c.Close()

req := &dataplexpb.CreateContentRequest{
    // TODO: Fill request struct fields.
    // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateContentRequest.
}
resp, err := c.CreateContent(ctx, req)
if err != nil {
    // TODO: Handle error.
}
// TODO: Use resp.
_ = resp

Use of Context

The ctx passed to NewClient is used for authentication requests and for creating the underlying connection, but is not used for subsequent calls. Individual methods on the client use the ctx given to them.

To close the open connection, use the Close() method.

For information about setting deadlines, reusing contexts, and more please visit https://pkg.go.dev/cloud.google.com/go.

Functions

func DefaultAuthScopes

func DefaultAuthScopes() []string

DefaultAuthScopes reports the default set of authentication scopes to use with this package.

ActionIterator

type ActionIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Action, nextPageToken string, err error)
	// contains filtered or unexported fields
}

ActionIterator manages a stream of *dataplexpb.Action.

func (*ActionIterator) Next

func (it *ActionIterator) Next() (*dataplexpb.Action, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*ActionIterator) PageInfo

func (it *ActionIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

AssetIterator

type AssetIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Asset, nextPageToken string, err error)
	// contains filtered or unexported fields
}

AssetIterator manages a stream of *dataplexpb.Asset.

func (*AssetIterator) Next

func (it *AssetIterator) Next() (*dataplexpb.Asset, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*AssetIterator) PageInfo

func (it *AssetIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

CallOptions

type CallOptions struct {
	CreateLake        []gax.CallOption
	UpdateLake        []gax.CallOption
	DeleteLake        []gax.CallOption
	ListLakes         []gax.CallOption
	GetLake           []gax.CallOption
	ListLakeActions   []gax.CallOption
	CreateZone        []gax.CallOption
	UpdateZone        []gax.CallOption
	DeleteZone        []gax.CallOption
	ListZones         []gax.CallOption
	GetZone           []gax.CallOption
	ListZoneActions   []gax.CallOption
	CreateAsset       []gax.CallOption
	UpdateAsset       []gax.CallOption
	DeleteAsset       []gax.CallOption
	ListAssets        []gax.CallOption
	GetAsset          []gax.CallOption
	ListAssetActions  []gax.CallOption
	CreateTask        []gax.CallOption
	UpdateTask        []gax.CallOption
	DeleteTask        []gax.CallOption
	ListTasks         []gax.CallOption
	GetTask           []gax.CallOption
	ListJobs          []gax.CallOption
	GetJob            []gax.CallOption
	CancelJob         []gax.CallOption
	CreateEnvironment []gax.CallOption
	UpdateEnvironment []gax.CallOption
	DeleteEnvironment []gax.CallOption
	ListEnvironments  []gax.CallOption
	GetEnvironment    []gax.CallOption
	ListSessions      []gax.CallOption
}

CallOptions contains the retry settings for each method of Client.

Client

type Client struct {

	// The call options for this service.
	CallOptions *CallOptions

	// LROClient is used internally to handle long-running operations.
	// It is exposed so that its CallOptions can be modified if required.
	// Users should not Close this client.
	LROClient *lroauto.OperationsClient
	// contains filtered or unexported fields
}

Client is a client for interacting with Cloud Dataplex API. Methods, except Close, may be called concurrently. However, fields must not be modified concurrently with method calls.

Dataplex service provides data lakes as a service. The primary resources offered by this service are Lakes, Zones and Assets which collectively allow a data adminstrator to organize, manage, secure and catalog data across their organization located across cloud projects in a variety of storage systems including Cloud Storage and BigQuery.

func NewClient

func NewClient(ctx context.Context, opts ...option.ClientOption) (*Client, error)

NewClient creates a new dataplex service client based on gRPC. The returned client must be Closed when it is done being used to clean up its underlying connections.

Dataplex service provides data lakes as a service. The primary resources offered by this service are Lakes, Zones and Assets which collectively allow a data adminstrator to organize, manage, secure and catalog data across their organization located across cloud projects in a variety of storage systems including Cloud Storage and BigQuery.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	// TODO: Use client.
	_ = c
}

func (*Client) CancelJob

func (c *Client) CancelJob(ctx context.Context, req *dataplexpb.CancelJobRequest, opts ...gax.CallOption) error

CancelJob cancel jobs running for the task resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CancelJobRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CancelJobRequest.
	}
	err = c.CancelJob(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) Close

func (c *Client) Close() error

Close closes the connection to the API service. The user should invoke this when the client is no longer required.

func (*Client) Connection

func (c *Client) Connection() *grpc.ClientConn

Connection returns a connection to the API service.

Deprecated.

func (*Client) CreateAsset

CreateAsset creates an asset resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateAssetRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateAssetRequest.
	}
	op, err := c.CreateAsset(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateAssetOperation

func (c *Client) CreateAssetOperation(name string) *CreateAssetOperation

CreateAssetOperation returns a new CreateAssetOperation from a given name. The name must be that of a previously created CreateAssetOperation, possibly from a different process.

func (*Client) CreateEnvironment

CreateEnvironment create an environment resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateEnvironmentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateEnvironmentRequest.
	}
	op, err := c.CreateEnvironment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateEnvironmentOperation

func (c *Client) CreateEnvironmentOperation(name string) *CreateEnvironmentOperation

CreateEnvironmentOperation returns a new CreateEnvironmentOperation from a given name. The name must be that of a previously created CreateEnvironmentOperation, possibly from a different process.

func (*Client) CreateLake

CreateLake creates a lake resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateLakeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateLakeRequest.
	}
	op, err := c.CreateLake(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateLakeOperation

func (c *Client) CreateLakeOperation(name string) *CreateLakeOperation

CreateLakeOperation returns a new CreateLakeOperation from a given name. The name must be that of a previously created CreateLakeOperation, possibly from a different process.

func (*Client) CreateTask

CreateTask creates a task resource within a lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateTaskRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateTaskRequest.
	}
	op, err := c.CreateTask(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateTaskOperation

func (c *Client) CreateTaskOperation(name string) *CreateTaskOperation

CreateTaskOperation returns a new CreateTaskOperation from a given name. The name must be that of a previously created CreateTaskOperation, possibly from a different process.

func (*Client) CreateZone

CreateZone creates a zone resource within a lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateZoneRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateZoneRequest.
	}
	op, err := c.CreateZone(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateZoneOperation

func (c *Client) CreateZoneOperation(name string) *CreateZoneOperation

CreateZoneOperation returns a new CreateZoneOperation from a given name. The name must be that of a previously created CreateZoneOperation, possibly from a different process.

func (*Client) DeleteAsset

DeleteAsset deletes an asset resource. The referenced storage resource is detached (default) or deleted based on the associated Lifecycle policy.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteAssetRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteAssetRequest.
	}
	op, err := c.DeleteAsset(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteAssetOperation

func (c *Client) DeleteAssetOperation(name string) *DeleteAssetOperation

DeleteAssetOperation returns a new DeleteAssetOperation from a given name. The name must be that of a previously created DeleteAssetOperation, possibly from a different process.

func (*Client) DeleteEnvironment

DeleteEnvironment delete the environment resource. All the child resources must have been deleted before environment deletion can be initiated.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteEnvironmentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteEnvironmentRequest.
	}
	op, err := c.DeleteEnvironment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteEnvironmentOperation

func (c *Client) DeleteEnvironmentOperation(name string) *DeleteEnvironmentOperation

DeleteEnvironmentOperation returns a new DeleteEnvironmentOperation from a given name. The name must be that of a previously created DeleteEnvironmentOperation, possibly from a different process.

func (*Client) DeleteLake

DeleteLake deletes a lake resource. All zones within the lake must be deleted before the lake can be deleted.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteLakeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteLakeRequest.
	}
	op, err := c.DeleteLake(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteLakeOperation

func (c *Client) DeleteLakeOperation(name string) *DeleteLakeOperation

DeleteLakeOperation returns a new DeleteLakeOperation from a given name. The name must be that of a previously created DeleteLakeOperation, possibly from a different process.

func (*Client) DeleteTask

DeleteTask delete the task resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteTaskRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteTaskRequest.
	}
	op, err := c.DeleteTask(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteTaskOperation

func (c *Client) DeleteTaskOperation(name string) *DeleteTaskOperation

DeleteTaskOperation returns a new DeleteTaskOperation from a given name. The name must be that of a previously created DeleteTaskOperation, possibly from a different process.

func (*Client) DeleteZone

DeleteZone deletes a zone resource. All assets within a zone must be deleted before the zone can be deleted.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteZoneRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteZoneRequest.
	}
	op, err := c.DeleteZone(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteZoneOperation

func (c *Client) DeleteZoneOperation(name string) *DeleteZoneOperation

DeleteZoneOperation returns a new DeleteZoneOperation from a given name. The name must be that of a previously created DeleteZoneOperation, possibly from a different process.

func (*Client) GetAsset

func (c *Client) GetAsset(ctx context.Context, req *dataplexpb.GetAssetRequest, opts ...gax.CallOption) (*dataplexpb.Asset, error)

GetAsset retrieves an asset resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetAssetRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetAssetRequest.
	}
	resp, err := c.GetAsset(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetEnvironment

func (c *Client) GetEnvironment(ctx context.Context, req *dataplexpb.GetEnvironmentRequest, opts ...gax.CallOption) (*dataplexpb.Environment, error)

GetEnvironment get environment resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetEnvironmentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetEnvironmentRequest.
	}
	resp, err := c.GetEnvironment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetJob

func (c *Client) GetJob(ctx context.Context, req *dataplexpb.GetJobRequest, opts ...gax.CallOption) (*dataplexpb.Job, error)

GetJob get job resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetJobRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetJobRequest.
	}
	resp, err := c.GetJob(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetLake

func (c *Client) GetLake(ctx context.Context, req *dataplexpb.GetLakeRequest, opts ...gax.CallOption) (*dataplexpb.Lake, error)

GetLake retrieves a lake resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetLakeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetLakeRequest.
	}
	resp, err := c.GetLake(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetTask

func (c *Client) GetTask(ctx context.Context, req *dataplexpb.GetTaskRequest, opts ...gax.CallOption) (*dataplexpb.Task, error)

GetTask get task resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetTaskRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetTaskRequest.
	}
	resp, err := c.GetTask(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetZone

func (c *Client) GetZone(ctx context.Context, req *dataplexpb.GetZoneRequest, opts ...gax.CallOption) (*dataplexpb.Zone, error)

GetZone retrieves a zone resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetZoneRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetZoneRequest.
	}
	resp, err := c.GetZone(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) ListAssetActions

func (c *Client) ListAssetActions(ctx context.Context, req *dataplexpb.ListAssetActionsRequest, opts ...gax.CallOption) *ActionIterator

ListAssetActions lists action resources in an asset.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListAssetActionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListAssetActionsRequest.
	}
	it := c.ListAssetActions(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListAssets

func (c *Client) ListAssets(ctx context.Context, req *dataplexpb.ListAssetsRequest, opts ...gax.CallOption) *AssetIterator

ListAssets lists asset resources in a zone.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListAssetsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListAssetsRequest.
	}
	it := c.ListAssets(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListEnvironments

func (c *Client) ListEnvironments(ctx context.Context, req *dataplexpb.ListEnvironmentsRequest, opts ...gax.CallOption) *EnvironmentIterator

ListEnvironments lists environments under the given lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListEnvironmentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListEnvironmentsRequest.
	}
	it := c.ListEnvironments(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListJobs

func (c *Client) ListJobs(ctx context.Context, req *dataplexpb.ListJobsRequest, opts ...gax.CallOption) *JobIterator

ListJobs lists Jobs under the given task.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListJobsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListJobsRequest.
	}
	it := c.ListJobs(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListLakeActions

func (c *Client) ListLakeActions(ctx context.Context, req *dataplexpb.ListLakeActionsRequest, opts ...gax.CallOption) *ActionIterator

ListLakeActions lists action resources in a lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListLakeActionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListLakeActionsRequest.
	}
	it := c.ListLakeActions(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListLakes

func (c *Client) ListLakes(ctx context.Context, req *dataplexpb.ListLakesRequest, opts ...gax.CallOption) *LakeIterator

ListLakes lists lake resources in a project and location.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListLakesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListLakesRequest.
	}
	it := c.ListLakes(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListSessions

func (c *Client) ListSessions(ctx context.Context, req *dataplexpb.ListSessionsRequest, opts ...gax.CallOption) *SessionIterator

ListSessions lists session resources in an environment.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListSessionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListSessionsRequest.
	}
	it := c.ListSessions(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListTasks

func (c *Client) ListTasks(ctx context.Context, req *dataplexpb.ListTasksRequest, opts ...gax.CallOption) *TaskIterator

ListTasks lists tasks under the given lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListTasksRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListTasksRequest.
	}
	it := c.ListTasks(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListZoneActions

func (c *Client) ListZoneActions(ctx context.Context, req *dataplexpb.ListZoneActionsRequest, opts ...gax.CallOption) *ActionIterator

ListZoneActions lists action resources in a zone.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListZoneActionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListZoneActionsRequest.
	}
	it := c.ListZoneActions(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListZones

func (c *Client) ListZones(ctx context.Context, req *dataplexpb.ListZonesRequest, opts ...gax.CallOption) *ZoneIterator

ListZones lists zone resources in a lake.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListZonesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListZonesRequest.
	}
	it := c.ListZones(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) UpdateAsset

UpdateAsset updates an asset resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateAssetRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateAssetRequest.
	}
	op, err := c.UpdateAsset(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateAssetOperation

func (c *Client) UpdateAssetOperation(name string) *UpdateAssetOperation

UpdateAssetOperation returns a new UpdateAssetOperation from a given name. The name must be that of a previously created UpdateAssetOperation, possibly from a different process.

func (*Client) UpdateEnvironment

UpdateEnvironment update the environment resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateEnvironmentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateEnvironmentRequest.
	}
	op, err := c.UpdateEnvironment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateEnvironmentOperation

func (c *Client) UpdateEnvironmentOperation(name string) *UpdateEnvironmentOperation

UpdateEnvironmentOperation returns a new UpdateEnvironmentOperation from a given name. The name must be that of a previously created UpdateEnvironmentOperation, possibly from a different process.

func (*Client) UpdateLake

UpdateLake updates a lake resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateLakeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateLakeRequest.
	}
	op, err := c.UpdateLake(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateLakeOperation

func (c *Client) UpdateLakeOperation(name string) *UpdateLakeOperation

UpdateLakeOperation returns a new UpdateLakeOperation from a given name. The name must be that of a previously created UpdateLakeOperation, possibly from a different process.

func (*Client) UpdateTask

UpdateTask update the task resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateTaskRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateTaskRequest.
	}
	op, err := c.UpdateTask(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateTaskOperation

func (c *Client) UpdateTaskOperation(name string) *UpdateTaskOperation

UpdateTaskOperation returns a new UpdateTaskOperation from a given name. The name must be that of a previously created UpdateTaskOperation, possibly from a different process.

func (*Client) UpdateZone

UpdateZone updates a zone resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateZoneRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateZoneRequest.
	}
	op, err := c.UpdateZone(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateZoneOperation

func (c *Client) UpdateZoneOperation(name string) *UpdateZoneOperation

UpdateZoneOperation returns a new UpdateZoneOperation from a given name. The name must be that of a previously created UpdateZoneOperation, possibly from a different process.

ContentCallOptions

type ContentCallOptions struct {
	CreateContent []gax.CallOption
	UpdateContent []gax.CallOption
	DeleteContent []gax.CallOption
	GetContent    []gax.CallOption
	ListContent   []gax.CallOption
}

ContentCallOptions contains the retry settings for each method of ContentClient.

ContentClient

type ContentClient struct {

	// The call options for this service.
	CallOptions *ContentCallOptions
	// contains filtered or unexported fields
}

ContentClient is a client for interacting with Cloud Dataplex API. Methods, except Close, may be called concurrently. However, fields must not be modified concurrently with method calls.

ContentService manages Notebook and SQL Scripts for Dataplex.

func NewContentClient

func NewContentClient(ctx context.Context, opts ...option.ClientOption) (*ContentClient, error)

NewContentClient creates a new content service client based on gRPC. The returned client must be Closed when it is done being used to clean up its underlying connections.

ContentService manages Notebook and SQL Scripts for Dataplex.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	// TODO: Use client.
	_ = c
}

func (*ContentClient) Close

func (c *ContentClient) Close() error

Close closes the connection to the API service. The user should invoke this when the client is no longer required.

func (*ContentClient) Connection

func (c *ContentClient) Connection() *grpc.ClientConn

Connection returns a connection to the API service.

Deprecated.

func (*ContentClient) CreateContent

CreateContent create a content.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateContentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateContentRequest.
	}
	resp, err := c.CreateContent(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*ContentClient) DeleteContent

func (c *ContentClient) DeleteContent(ctx context.Context, req *dataplexpb.DeleteContentRequest, opts ...gax.CallOption) error

DeleteContent delete a content.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteContentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteContentRequest.
	}
	err = c.DeleteContent(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*ContentClient) GetContent

GetContent get a content resource.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetContentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetContentRequest.
	}
	resp, err := c.GetContent(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*ContentClient) ListContent

ListContent list content.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListContentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListContentRequest.
	}
	it := c.ListContent(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*ContentClient) UpdateContent

UpdateContent update a content. Only supports full resource update.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewContentClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateContentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateContentRequest.
	}
	resp, err := c.UpdateContent(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

ContentIterator

type ContentIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Content, nextPageToken string, err error)
	// contains filtered or unexported fields
}

ContentIterator manages a stream of *dataplexpb.Content.

func (*ContentIterator) Next

func (it *ContentIterator) Next() (*dataplexpb.Content, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*ContentIterator) PageInfo

func (it *ContentIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

CreateAssetOperation

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

CreateAssetOperation manages a long-running operation from CreateAsset.

func (*CreateAssetOperation) Done

func (op *CreateAssetOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateAssetOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateAssetOperation) Name

func (op *CreateAssetOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateAssetOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateAssetOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateEnvironmentOperation

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

CreateEnvironmentOperation manages a long-running operation from CreateEnvironment.

func (*CreateEnvironmentOperation) Done

func (op *CreateEnvironmentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateEnvironmentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateEnvironmentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateEnvironmentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateEnvironmentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateLakeOperation

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

CreateLakeOperation manages a long-running operation from CreateLake.

func (*CreateLakeOperation) Done

func (op *CreateLakeOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateLakeOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateLakeOperation) Name

func (op *CreateLakeOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateLakeOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateLakeOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateTaskOperation

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

CreateTaskOperation manages a long-running operation from CreateTask.

func (*CreateTaskOperation) Done

func (op *CreateTaskOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateTaskOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateTaskOperation) Name

func (op *CreateTaskOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateTaskOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateTaskOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateZoneOperation

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

CreateZoneOperation manages a long-running operation from CreateZone.

func (*CreateZoneOperation) Done

func (op *CreateZoneOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateZoneOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateZoneOperation) Name

func (op *CreateZoneOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateZoneOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateZoneOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteAssetOperation

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

DeleteAssetOperation manages a long-running operation from DeleteAsset.

func (*DeleteAssetOperation) Done

func (op *DeleteAssetOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteAssetOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteAssetOperation) Name

func (op *DeleteAssetOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteAssetOperation) Poll

func (op *DeleteAssetOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteAssetOperation) Wait

func (op *DeleteAssetOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteEnvironmentOperation

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

DeleteEnvironmentOperation manages a long-running operation from DeleteEnvironment.

func (*DeleteEnvironmentOperation) Done

func (op *DeleteEnvironmentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteEnvironmentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteEnvironmentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteEnvironmentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteEnvironmentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteLakeOperation

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

DeleteLakeOperation manages a long-running operation from DeleteLake.

func (*DeleteLakeOperation) Done

func (op *DeleteLakeOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteLakeOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteLakeOperation) Name

func (op *DeleteLakeOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteLakeOperation) Poll

func (op *DeleteLakeOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteLakeOperation) Wait

func (op *DeleteLakeOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteTaskOperation

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

DeleteTaskOperation manages a long-running operation from DeleteTask.

func (*DeleteTaskOperation) Done

func (op *DeleteTaskOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteTaskOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteTaskOperation) Name

func (op *DeleteTaskOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteTaskOperation) Poll

func (op *DeleteTaskOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteTaskOperation) Wait

func (op *DeleteTaskOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteZoneOperation

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

DeleteZoneOperation manages a long-running operation from DeleteZone.

func (*DeleteZoneOperation) Done

func (op *DeleteZoneOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteZoneOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteZoneOperation) Name

func (op *DeleteZoneOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteZoneOperation) Poll

func (op *DeleteZoneOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteZoneOperation) Wait

func (op *DeleteZoneOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

EntityIterator

type EntityIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Entity, nextPageToken string, err error)
	// contains filtered or unexported fields
}

EntityIterator manages a stream of *dataplexpb.Entity.

func (*EntityIterator) Next

func (it *EntityIterator) Next() (*dataplexpb.Entity, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*EntityIterator) PageInfo

func (it *EntityIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

EnvironmentIterator

type EnvironmentIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Environment, nextPageToken string, err error)
	// contains filtered or unexported fields
}

EnvironmentIterator manages a stream of *dataplexpb.Environment.

func (*EnvironmentIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*EnvironmentIterator) PageInfo

func (it *EnvironmentIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

JobIterator

type JobIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Job, nextPageToken string, err error)
	// contains filtered or unexported fields
}

JobIterator manages a stream of *dataplexpb.Job.

func (*JobIterator) Next

func (it *JobIterator) Next() (*dataplexpb.Job, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*JobIterator) PageInfo

func (it *JobIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

LakeIterator

type LakeIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Lake, nextPageToken string, err error)
	// contains filtered or unexported fields
}

LakeIterator manages a stream of *dataplexpb.Lake.

func (*LakeIterator) Next

func (it *LakeIterator) Next() (*dataplexpb.Lake, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*LakeIterator) PageInfo

func (it *LakeIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

MetadataCallOptions

type MetadataCallOptions struct {
	CreateEntity    []gax.CallOption
	UpdateEntity    []gax.CallOption
	DeleteEntity    []gax.CallOption
	GetEntity       []gax.CallOption
	ListEntities    []gax.CallOption
	CreatePartition []gax.CallOption
	DeletePartition []gax.CallOption
	GetPartition    []gax.CallOption
	ListPartitions  []gax.CallOption
}

MetadataCallOptions contains the retry settings for each method of MetadataClient.

MetadataClient

type MetadataClient struct {

	// The call options for this service.
	CallOptions *MetadataCallOptions
	// contains filtered or unexported fields
}

MetadataClient is a client for interacting with Cloud Dataplex API. Methods, except Close, may be called concurrently. However, fields must not be modified concurrently with method calls.

Metadata service manages metadata resources such as tables, filesets and partitions.

func NewMetadataClient

func NewMetadataClient(ctx context.Context, opts ...option.ClientOption) (*MetadataClient, error)

NewMetadataClient creates a new metadata service client based on gRPC. The returned client must be Closed when it is done being used to clean up its underlying connections.

Metadata service manages metadata resources such as tables, filesets and partitions.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	// TODO: Use client.
	_ = c
}

func (*MetadataClient) Close

func (c *MetadataClient) Close() error

Close closes the connection to the API service. The user should invoke this when the client is no longer required.

func (*MetadataClient) Connection

func (c *MetadataClient) Connection() *grpc.ClientConn

Connection returns a connection to the API service.

Deprecated.

func (*MetadataClient) CreateEntity

CreateEntity create a metadata entity.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreateEntityRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreateEntityRequest.
	}
	resp, err := c.CreateEntity(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*MetadataClient) CreatePartition

CreatePartition create a metadata partition.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.CreatePartitionRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#CreatePartitionRequest.
	}
	resp, err := c.CreatePartition(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*MetadataClient) DeleteEntity

func (c *MetadataClient) DeleteEntity(ctx context.Context, req *dataplexpb.DeleteEntityRequest, opts ...gax.CallOption) error

DeleteEntity delete a metadata entity.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeleteEntityRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeleteEntityRequest.
	}
	err = c.DeleteEntity(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*MetadataClient) DeletePartition

func (c *MetadataClient) DeletePartition(ctx context.Context, req *dataplexpb.DeletePartitionRequest, opts ...gax.CallOption) error

DeletePartition delete a metadata partition.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.DeletePartitionRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#DeletePartitionRequest.
	}
	err = c.DeletePartition(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*MetadataClient) GetEntity

GetEntity get a metadata entity.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetEntityRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetEntityRequest.
	}
	resp, err := c.GetEntity(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*MetadataClient) GetPartition

GetPartition get a metadata partition of an entity.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.GetPartitionRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#GetPartitionRequest.
	}
	resp, err := c.GetPartition(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*MetadataClient) ListEntities

ListEntities list metadata entities in a zone.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListEntitiesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListEntitiesRequest.
	}
	it := c.ListEntities(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*MetadataClient) ListPartitions

ListPartitions list metadata partitions of an entity.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"
	"google.golang.org/api/iterator"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.ListPartitionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#ListPartitionsRequest.
	}
	it := c.ListPartitions(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*MetadataClient) UpdateEntity

UpdateEntity update a metadata entity. Only supports full resource update.

Example

package main

import (
	"context"

	dataplex "cloud.google.com/go/dataplex/apiv1"

	dataplexpb "google.golang.org/genproto/googleapis/cloud/dataplex/v1"
)

func main() {
	ctx := context.Background()
	c, err := dataplex.NewMetadataClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &dataplexpb.UpdateEntityRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/dataplex/v1#UpdateEntityRequest.
	}
	resp, err := c.UpdateEntity(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

PartitionIterator

type PartitionIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Partition, nextPageToken string, err error)
	// contains filtered or unexported fields
}

PartitionIterator manages a stream of *dataplexpb.Partition.

func (*PartitionIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*PartitionIterator) PageInfo

func (it *PartitionIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

SessionIterator

type SessionIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Session, nextPageToken string, err error)
	// contains filtered or unexported fields
}

SessionIterator manages a stream of *dataplexpb.Session.

func (*SessionIterator) Next

func (it *SessionIterator) Next() (*dataplexpb.Session, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*SessionIterator) PageInfo

func (it *SessionIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

TaskIterator

type TaskIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Task, nextPageToken string, err error)
	// contains filtered or unexported fields
}

TaskIterator manages a stream of *dataplexpb.Task.

func (*TaskIterator) Next

func (it *TaskIterator) Next() (*dataplexpb.Task, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*TaskIterator) PageInfo

func (it *TaskIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.

UpdateAssetOperation

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

UpdateAssetOperation manages a long-running operation from UpdateAsset.

func (*UpdateAssetOperation) Done

func (op *UpdateAssetOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateAssetOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateAssetOperation) Name

func (op *UpdateAssetOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateAssetOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateAssetOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateEnvironmentOperation

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

UpdateEnvironmentOperation manages a long-running operation from UpdateEnvironment.

func (*UpdateEnvironmentOperation) Done

func (op *UpdateEnvironmentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateEnvironmentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateEnvironmentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateEnvironmentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateEnvironmentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateLakeOperation

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

UpdateLakeOperation manages a long-running operation from UpdateLake.

func (*UpdateLakeOperation) Done

func (op *UpdateLakeOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateLakeOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateLakeOperation) Name

func (op *UpdateLakeOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateLakeOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateLakeOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateTaskOperation

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

UpdateTaskOperation manages a long-running operation from UpdateTask.

func (*UpdateTaskOperation) Done

func (op *UpdateTaskOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateTaskOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateTaskOperation) Name

func (op *UpdateTaskOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateTaskOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateTaskOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateZoneOperation

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

UpdateZoneOperation manages a long-running operation from UpdateZone.

func (*UpdateZoneOperation) Done

func (op *UpdateZoneOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateZoneOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateZoneOperation) Name

func (op *UpdateZoneOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateZoneOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateZoneOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

ZoneIterator

type ZoneIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*dataplexpb.Zone, nextPageToken string, err error)
	// contains filtered or unexported fields
}

ZoneIterator manages a stream of *dataplexpb.Zone.

func (*ZoneIterator) Next

func (it *ZoneIterator) Next() (*dataplexpb.Zone, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*ZoneIterator) PageInfo

func (it *ZoneIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the google.golang.org/api/iterator package for details.