lakehouse

package
v0.1.0-beta.9 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BackgroundJobsClient

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

BackgroundJobsClient contains the methods for the BackgroundJobs group. Don't use this type directly, use a constructor function instead.

func (*BackgroundJobsClient) RunOnDemandTableMaintenance

func (client *BackgroundJobsClient) RunOnDemandTableMaintenance(ctx context.Context, workspaceID string, lakehouseID string, jobType string, runOnDemandTableMaintenanceRequest RunOnDemandTableMaintenanceRequest, options *BackgroundJobsClientRunOnDemandTableMaintenanceOptions) (BackgroundJobsClientRunOnDemandTableMaintenanceResponse, error)

RunOnDemandTableMaintenance - REQUIRED DELEGATED SCOPES Lakehouse.Execute.All or Item.Execute.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | No | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The Lakehouse item ID.
  • jobType - TableMaintenance job type.
  • runOnDemandTableMaintenanceRequest - Run on-demand table maintenance request payload.
  • options - BackgroundJobsClientRunOnDemandTableMaintenanceOptions contains the optional parameters for the BackgroundJobsClient.RunOnDemandTableMaintenance method.
Example (RunTableMaintenanceWithOptimizeEnabledAndVacuumDisabled)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewBackgroundJobsClient().RunOnDemandTableMaintenance(ctx, "4b218778-e7a5-4d73-8187-f10824047715", "431e8d7b-4a95-4c02-8ccd-6faef5ba1bd7", "TableMaintenance", lakehouse.RunOnDemandTableMaintenanceRequest{
		ExecutionData: &lakehouse.TableMaintenanceExecutionData{
			OptimizeSettings: &lakehouse.OptimizeSettings{},
			TableName:        to.Ptr("table1"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

Example (RunTableMaintenanceWithOptimizeZOrderAndVacuumEnabled)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewBackgroundJobsClient().RunOnDemandTableMaintenance(ctx, "4b218778-e7a5-4d73-8187-f10824047715", "431e8d7b-4a95-4c02-8ccd-6faef5ba1bd7", "TableMaintenance", lakehouse.RunOnDemandTableMaintenanceRequest{
		ExecutionData: &lakehouse.TableMaintenanceExecutionData{
			OptimizeSettings: &lakehouse.OptimizeSettings{
				VOrder: to.Ptr(true),
				ZOrderBy: []string{
					"tipAmount"},
			},
			TableName: to.Ptr("table1"),
			VacuumSettings: &lakehouse.VacuumSettings{
				RetentionPeriod: to.Ptr("7:01:00:00"),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

Example (RunTableMaintenanceWithOptimizeZOrderAndVacuumEnabledForSchemaEnabledLakehouse)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewBackgroundJobsClient().RunOnDemandTableMaintenance(ctx, "4b218778-e7a5-4d73-8187-f10824047715", "431e8d7b-4a95-4c02-8ccd-6faef5ba1bd7", "TableMaintenance", lakehouse.RunOnDemandTableMaintenanceRequest{
		ExecutionData: &lakehouse.TableMaintenanceExecutionData{
			OptimizeSettings: &lakehouse.OptimizeSettings{
				VOrder: to.Ptr(true),
				ZOrderBy: []string{
					"tipAmount"},
			},
			SchemaName: to.Ptr("dbo"),
			TableName:  to.Ptr("table1"),
			VacuumSettings: &lakehouse.VacuumSettings{
				RetentionPeriod: to.Ptr("7:01:00:00"),
			},
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

type BackgroundJobsClientRunOnDemandTableMaintenanceOptions

type BackgroundJobsClientRunOnDemandTableMaintenanceOptions struct {
}

BackgroundJobsClientRunOnDemandTableMaintenanceOptions contains the optional parameters for the BackgroundJobsClient.RunOnDemandTableMaintenance method.

type BackgroundJobsClientRunOnDemandTableMaintenanceResponse

type BackgroundJobsClientRunOnDemandTableMaintenanceResponse struct {
	// Location contains the information returned from the Location header response.
	Location *string

	// RetryAfter contains the information returned from the Retry-After header response.
	RetryAfter *int32
}

BackgroundJobsClientRunOnDemandTableMaintenanceResponse contains the response from method BackgroundJobsClient.RunOnDemandTableMaintenance.

type CSV

type CSV struct {
	// REQUIRED; Data file format name. Additional file format types may be added over time.
	Format *FileFormat

	// The delimiter of CSV file.
	Delimiter *string

	// This property indicates whether the CSV data file contains a header line or not.
	Header *bool
}

CSV format options for CSV files.

func (*CSV) GetFileFormatOptions

func (c *CSV) GetFileFormatOptions() *FileFormatOptions

GetFileFormatOptions implements the FileFormatOptionsClassification interface for type CSV.

func (CSV) MarshalJSON

func (c CSV) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CSV.

func (*CSV) UnmarshalJSON

func (c *CSV) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CSV.

type ClientFactory

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

ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.

func NewClientFactory

func NewClientFactory(credential azcore.TokenCredential, endpoint *string, options *azcore.ClientOptions) (*ClientFactory, error)

NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.

  • credential - used to authorize requests. Usually a credential from azidentity.
  • endpoint - pass nil to accept the default values.
  • options - pass nil to accept the default values.

func NewClientFactoryWithClient

func NewClientFactoryWithClient(client fabric.Client) *ClientFactory

NewClientFactoryWithClient creates a new instance of ClientFactory with sharable Client. The Client will be propagated to any client created from this factory.

  • client - Client created in the containing module: github.com/microsoft/fabric-sdk-go/fabric

func (*ClientFactory) NewBackgroundJobsClient

func (c *ClientFactory) NewBackgroundJobsClient() *BackgroundJobsClient

NewBackgroundJobsClient creates a new instance of BackgroundJobsClient.

func (*ClientFactory) NewItemsClient

func (c *ClientFactory) NewItemsClient() *ItemsClient

NewItemsClient creates a new instance of ItemsClient.

func (*ClientFactory) NewTablesClient

func (c *ClientFactory) NewTablesClient() *TablesClient

NewTablesClient creates a new instance of TablesClient.

type CreateLakehouseRequest

type CreateLakehouseRequest struct {
	// REQUIRED; The lakehouse display name. The display name must follow naming rules according to item type.
	DisplayName *string

	// The lakehouse creation payload.
	CreationPayload *CreationPayload

	// The lakehouse description. Maximum length is 256 characters.
	Description *string
}

CreateLakehouseRequest - Create lakehouse request payload.

func (CreateLakehouseRequest) MarshalJSON

func (c CreateLakehouseRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CreateLakehouseRequest.

func (*CreateLakehouseRequest) UnmarshalJSON

func (c *CreateLakehouseRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CreateLakehouseRequest.

type CreationPayload

type CreationPayload struct {
	// REQUIRED; Create a schema enabled lakehouse when set to true. Only 'true' is allowed.
	EnableSchemas *bool
}

CreationPayload - (Preview) Lakehouse item payload. This property is currently required due to the schema enabled lakehouse being in preview. It might become redundant upon General Availability (GA).

func (CreationPayload) MarshalJSON

func (c CreationPayload) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CreationPayload.

func (*CreationPayload) UnmarshalJSON

func (c *CreationPayload) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CreationPayload.

type FileFormat

type FileFormat string

FileFormat - Data file format name. Additional file format types may be added over time.

const (
	// FileFormatCSV - CSV format name.
	FileFormatCSV FileFormat = "Csv"
	// FileFormatParquet - Parquet format name.
	FileFormatParquet FileFormat = "Parquet"
)

func PossibleFileFormatValues

func PossibleFileFormatValues() []FileFormat

PossibleFileFormatValues returns the possible values for the FileFormat const type.

type FileFormatOptions

type FileFormatOptions struct {
	// REQUIRED; Data file format name. Additional file format types may be added over time.
	Format *FileFormat
}

FileFormatOptions - Abstract type of data file format options.

func (*FileFormatOptions) GetFileFormatOptions

func (f *FileFormatOptions) GetFileFormatOptions() *FileFormatOptions

GetFileFormatOptions implements the FileFormatOptionsClassification interface for type FileFormatOptions.

func (FileFormatOptions) MarshalJSON

func (f FileFormatOptions) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type FileFormatOptions.

func (*FileFormatOptions) UnmarshalJSON

func (f *FileFormatOptions) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type FileFormatOptions.

type FileFormatOptionsClassification

type FileFormatOptionsClassification interface {
	// GetFileFormatOptions returns the FileFormatOptions content of the underlying type.
	GetFileFormatOptions() *FileFormatOptions
}

FileFormatOptionsClassification provides polymorphic access to related types. Call the interface's GetFileFormatOptions() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *CSV, *FileFormatOptions, *Parquet

type ItemType

type ItemType string

ItemType - The type of the item. Additional item types may be added over time.

const (
	// ItemTypeDashboard - PowerBI dashboard.
	ItemTypeDashboard ItemType = "Dashboard"
	// ItemTypeDataPipeline - A data pipeline.
	ItemTypeDataPipeline ItemType = "DataPipeline"
	// ItemTypeDatamart - PowerBI datamart.
	ItemTypeDatamart ItemType = "Datamart"
	// ItemTypeEnvironment - An environment.
	ItemTypeEnvironment ItemType = "Environment"
	// ItemTypeEventhouse - An eventhouse.
	ItemTypeEventhouse ItemType = "Eventhouse"
	// ItemTypeEventstream - An eventstream.
	ItemTypeEventstream ItemType = "Eventstream"
	// ItemTypeKQLDashboard - A KQL dashboard.
	ItemTypeKQLDashboard ItemType = "KQLDashboard"
	// ItemTypeKQLDatabase - A KQL database.
	ItemTypeKQLDatabase ItemType = "KQLDatabase"
	// ItemTypeKQLQueryset - A KQL queryset.
	ItemTypeKQLQueryset ItemType = "KQLQueryset"
	// ItemTypeLakehouse - A lakehouse.
	ItemTypeLakehouse ItemType = "Lakehouse"
	// ItemTypeMLExperiment - A machine learning experiment.
	ItemTypeMLExperiment ItemType = "MLExperiment"
	// ItemTypeMLModel - A machine learning model.
	ItemTypeMLModel ItemType = "MLModel"
	// ItemTypeMirroredDatabase - A mirrored database.
	ItemTypeMirroredDatabase ItemType = "MirroredDatabase"
	// ItemTypeMirroredWarehouse - A mirrored warehouse.
	ItemTypeMirroredWarehouse ItemType = "MirroredWarehouse"
	// ItemTypeNotebook - A notebook.
	ItemTypeNotebook ItemType = "Notebook"
	// ItemTypePaginatedReport - PowerBI paginated report.
	ItemTypePaginatedReport ItemType = "PaginatedReport"
	// ItemTypeReflex - A Reflex.
	ItemTypeReflex ItemType = "Reflex"
	// ItemTypeReport - PowerBI report.
	ItemTypeReport ItemType = "Report"
	// ItemTypeSQLEndpoint - An SQL endpoint.
	ItemTypeSQLEndpoint ItemType = "SQLEndpoint"
	// ItemTypeSemanticModel - PowerBI semantic model.
	ItemTypeSemanticModel ItemType = "SemanticModel"
	// ItemTypeSparkJobDefinition - A spark job definition.
	ItemTypeSparkJobDefinition ItemType = "SparkJobDefinition"
	// ItemTypeWarehouse - A warehouse.
	ItemTypeWarehouse ItemType = "Warehouse"
)

func PossibleItemTypeValues

func PossibleItemTypeValues() []ItemType

PossibleItemTypeValues returns the possible values for the ItemType const type.

type ItemsClient

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

ItemsClient contains the methods for the Items group. Don't use this type directly, use a constructor function instead.

func (*ItemsClient) BeginCreateLakehouse

func (client *ItemsClient) BeginCreateLakehouse(ctx context.Context, workspaceID string, createLakehouseRequest CreateLakehouseRequest, options *ItemsClientBeginCreateLakehouseOptions) (*runtime.Poller[ItemsClientCreateLakehouseResponse], error)

BeginCreateLakehouse - This API supports long running operations (LRO) [/rest/api/fabric/articles/long-running-operation]. This API does not support create a lakehouse with definition. PERMISSIONS The caller must have contributor or higher workspace role. REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All or Item.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • createLakehouseRequest - Create item request payload.
  • options - ItemsClientBeginCreateLakehouseOptions contains the optional parameters for the ItemsClient.BeginCreateLakehouse method.
Example (CreateALakehouseExample)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewItemsClient().BeginCreateLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", lakehouse.CreateLakehouseRequest{
		Description: to.Ptr("A lakehouse description"),
		DisplayName: to.Ptr("Lakehouse_1"),
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}
Output:

Example (CreateALakehouseWithSchemaExample)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewItemsClient().BeginCreateLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", lakehouse.CreateLakehouseRequest{
		Description: to.Ptr("A schema enabled lakehouse."),
		CreationPayload: &lakehouse.CreationPayload{
			EnableSchemas: to.Ptr(true),
		},
		DisplayName: to.Ptr("Lakehouse_created_with_schema"),
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}
Output:

func (*ItemsClient) CreateLakehouse

func (client *ItemsClient) CreateLakehouse(ctx context.Context, workspaceID string, createLakehouseRequest CreateLakehouseRequest, options *ItemsClientBeginCreateLakehouseOptions) (ItemsClientCreateLakehouseResponse, error)

CreateLakehouse - returns ItemsClientCreateLakehouseResponse in sync mode. This API supports long running operations (LRO) [/rest/api/fabric/articles/long-running-operation].

This API does not support create a lakehouse with definition.

PERMISSIONS The caller must have contributor or higher workspace role.

REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All or Item.ReadWrite.All

MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section.

| Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes |

INTERFACE Generated from API version v1

  • workspaceID - The workspace ID.
  • createLakehouseRequest - Create item request payload.
  • options - ItemsClientBeginCreateLakehouseOptions contains the optional parameters for the ItemsClient.BeginCreateLakehouse method.

func (*ItemsClient) DeleteLakehouse

func (client *ItemsClient) DeleteLakehouse(ctx context.Context, workspaceID string, lakehouseID string, options *ItemsClientDeleteLakehouseOptions) (ItemsClientDeleteLakehouseResponse, error)

DeleteLakehouse - PERMISSIONS The caller must have contributor or higher workspace role. REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All or Item.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse ID.
  • options - ItemsClientDeleteLakehouseOptions contains the optional parameters for the ItemsClient.DeleteLakehouse method.
Example

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewItemsClient().DeleteLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", "5b218778-e7a5-4d73-8187-f10824047715", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ItemsClient) GetLakehouse

func (client *ItemsClient) GetLakehouse(ctx context.Context, workspaceID string, lakehouseID string, options *ItemsClientGetLakehouseOptions) (ItemsClientGetLakehouseResponse, error)

GetLakehouse - PERMISSIONS The caller must have viewer or higher workspace role. REQUIRED DELEGATED SCOPES Lakehouse.Read.All or Lakehouse.ReadWrite.All or Item.Read.All or Item.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse ID.
  • options - ItemsClientGetLakehouseOptions contains the optional parameters for the ItemsClient.GetLakehouse method.
Example (GetALakehouseExample)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewItemsClient().GetLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", "5b218778-e7a5-4d73-8187-f10824047715", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Lakehouse = lakehouse.Lakehouse{
	// 	Type: to.Ptr(lakehouse.ItemTypeLakehouse),
	// 	Description: to.Ptr("A lakehouse description."),
	// 	DisplayName: to.Ptr("Lakehouse_1"),
	// 	ID: to.Ptr("5b218778-e7a5-4d73-8187-f10824047715"),
	// 	WorkspaceID: to.Ptr("cfafbeb1-8037-4d0c-896e-a46fb27ff229"),
	// 	Properties: &lakehouse.Properties{
	// 		OneLakeFilesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Files"),
	// 		OneLakeTablesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Tables"),
	// 		SQLEndpointProperties: &lakehouse.SQLEndpointProperties{
	// 			ConnectionString: to.Ptr("qvrmbuxie7we7glrekxgy6npqu-6xgyei3x2xiejip4iime6knh5m.datawarehouse.fabric.microsoft.com"),
	// 			ID: to.Ptr("37dc8a41-dea9-465d-b528-3e95043b2356"),
	// 			ProvisioningStatus: to.Ptr(lakehouse.SQLEndpointProvisioningStatusSuccess),
	// 		},
	// 	},
	// }
}
Output:

Example (GetALakehouseWithSchemaExample)

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewItemsClient().GetLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", "5b218778-e7a5-4d73-8187-f10824047715", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Lakehouse = lakehouse.Lakehouse{
	// 	Type: to.Ptr(lakehouse.ItemTypeLakehouse),
	// 	Description: to.Ptr("A schema enabled lakehouse."),
	// 	DisplayName: to.Ptr("Lakehouse_created_with_schema"),
	// 	ID: to.Ptr("5b218778-e7a5-4d73-8187-f10824047715"),
	// 	WorkspaceID: to.Ptr("cfafbeb1-8037-4d0c-896e-a46fb27ff229"),
	// 	Properties: &lakehouse.Properties{
	// 		DefaultSchema: to.Ptr("dbo"),
	// 		OneLakeFilesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Files"),
	// 		OneLakeTablesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Tables"),
	// 		SQLEndpointProperties: &lakehouse.SQLEndpointProperties{
	// 			ConnectionString: to.Ptr("qvrmbuxie7we7glrekxgy6npqu-6xgyei3x2xiejip4iime6knh5m.datawarehouse.fabric.microsoft.com"),
	// 			ID: to.Ptr("37dc8a41-dea9-465d-b528-3e95043b2356"),
	// 			ProvisioningStatus: to.Ptr(lakehouse.SQLEndpointProvisioningStatusSuccess),
	// 		},
	// 	},
	// }
}
Output:

func (*ItemsClient) ListLakehouses

func (client *ItemsClient) ListLakehouses(ctx context.Context, workspaceID string, options *ItemsClientListLakehousesOptions) ([]Lakehouse, error)

ListLakehouses - returns array of Lakehouse from all pages. This API supports pagination [/rest/api/fabric/articles/pagination].

PERMISSIONS The caller must have viewer or higher workspace role.

REQUIRED DELEGATED SCOPES Workspace.Read.All or Workspace.ReadWrite.All

MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section.

| Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes |

INTERFACE Generated from API version v1

  • workspaceID - The workspace ID.
  • options - ItemsClientListLakehousesOptions contains the optional parameters for the ItemsClient.NewListLakehousesPager method.

func (*ItemsClient) NewListLakehousesPager

func (client *ItemsClient) NewListLakehousesPager(workspaceID string, options *ItemsClientListLakehousesOptions) *runtime.Pager[ItemsClientListLakehousesResponse]

NewListLakehousesPager - This API supports pagination [/rest/api/fabric/articles/pagination]. PERMISSIONS The caller must have viewer or higher workspace role. REQUIRED DELEGATED SCOPES Workspace.Read.All or Workspace.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE

Generated from API version v1

  • workspaceID - The workspace ID.
  • options - ItemsClientListLakehousesOptions contains the optional parameters for the ItemsClient.NewListLakehousesPager method.
Example

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewItemsClient().NewListLakehousesPager("cfafbeb1-8037-4d0c-896e-a46fb27ff229", &lakehouse.ItemsClientListLakehousesOptions{ContinuationToken: nil})
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Value {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.Lakehouses = lakehouse.Lakehouses{
		// 	Value: []lakehouse.Lakehouse{
		// 		{
		// 			Type: to.Ptr(lakehouse.ItemTypeLakehouse),
		// 			Description: to.Ptr("A lakehouse description."),
		// 			DisplayName: to.Ptr("Lakehouse_1"),
		// 			ID: to.Ptr("3546052c-ae64-4526-b1a8-52af7761426f"),
		// 			WorkspaceID: to.Ptr("cfafbeb1-8037-4d0c-896e-a46fb27ff229"),
		// 			Properties: &lakehouse.Properties{
		// 				OneLakeFilesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Files"),
		// 				OneLakeTablesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/2382cdf5-d577-44d0-a1fc-42184f29a7eb/e5fb215b-1934-413e-b33a-debaf844afde/Tables"),
		// 				SQLEndpointProperties: &lakehouse.SQLEndpointProperties{
		// 					ConnectionString: to.Ptr("qvrmbuxie7we7glrekxgy6npqu-6xgyei3x2xiejip4iime6knh5m.datawarehouse.fabric.microsoft.com"),
		// 					ID: to.Ptr("37dc8a41-dea9-465d-b528-3e95043b2356"),
		// 					ProvisioningStatus: to.Ptr(lakehouse.SQLEndpointProvisioningStatusSuccess),
		// 				},
		// 			},
		// 		},
		// 		{
		// 			Type: to.Ptr(lakehouse.ItemTypeLakehouse),
		// 			Description: to.Ptr("A lakehouse description."),
		// 			DisplayName: to.Ptr("Lakehouse_2"),
		// 			ID: to.Ptr("a8a1bffa-7eea-49dc-a1d2-6281c1d031f1"),
		// 			WorkspaceID: to.Ptr("cfafbeb1-8037-4d0c-896e-a46fb27ff229"),
		// 			Properties: &lakehouse.Properties{
		// 				OneLakeFilesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/fc5d0537-1b22-4de1-a5e9-9b8bb58ed1e1/6dc325f6-46f6-4a2a-930b-10b96a463566/Files"),
		// 				OneLakeTablesPath: to.Ptr("https://onelake.dfs.fabric.microsoft.com/fc5d0537-1b22-4de1-a5e9-9b8bb58ed1e1/6dc325f6-46f6-4a2a-930b-10b96a463566/Tables"),
		// 				SQLEndpointProperties: &lakehouse.SQLEndpointProperties{
		// 					ConnectionString: to.Ptr("qvrmbuxie7we7glrekxgy6npqu-6xgyei3x2xiejip4iime6knh5m.datawarehouse.fabric.microsoft.com"),
		// 					ID: to.Ptr("37dc8a41-dea9-465d-b528-3e95043b2356"),
		// 					ProvisioningStatus: to.Ptr(lakehouse.SQLEndpointProvisioningStatusSuccess),
		// 				},
		// 			},
		// 	}},
		// }
	}
}
Output:

func (*ItemsClient) UpdateLakehouse

func (client *ItemsClient) UpdateLakehouse(ctx context.Context, workspaceID string, lakehouseID string, updateLakehouseRequest UpdateLakehouseRequest, options *ItemsClientUpdateLakehouseOptions) (ItemsClientUpdateLakehouseResponse, error)

UpdateLakehouse - PERMISSIONS The caller must have contributor or higher workspace role. REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All or Item.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse ID.
  • updateLakehouseRequest - Update lakehouse request payload.
  • options - ItemsClientUpdateLakehouseOptions contains the optional parameters for the ItemsClient.UpdateLakehouse method.
Example

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewItemsClient().UpdateLakehouse(ctx, "cfafbeb1-8037-4d0c-896e-a46fb27ff229", "5b218778-e7a5-4d73-8187-f10824047715", lakehouse.UpdateLakehouseRequest{
		Description: to.Ptr("A new description for lakehouse."),
		DisplayName: to.Ptr("Lakehouse_New_Name"),
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Lakehouse = lakehouse.Lakehouse{
	// 	Type: to.Ptr(lakehouse.ItemTypeLakehouse),
	// 	Description: to.Ptr("A new description for lakehouse."),
	// 	DisplayName: to.Ptr("Lakehouse_New_Name"),
	// 	ID: to.Ptr("5b218778-e7a5-4d73-8187-f10824047715"),
	// 	WorkspaceID: to.Ptr("cfafbeb1-8037-4d0c-896e-a46fb27ff229"),
	// }
}
Output:

type ItemsClientBeginCreateLakehouseOptions

type ItemsClientBeginCreateLakehouseOptions struct {
	// Resumes the long-running operation from the provided token.
	ResumeToken string
}

ItemsClientBeginCreateLakehouseOptions contains the optional parameters for the ItemsClient.BeginCreateLakehouse method.

type ItemsClientCreateLakehouseResponse

type ItemsClientCreateLakehouseResponse struct {
	// A lakehouse item.
	Lakehouse
}

ItemsClientCreateLakehouseResponse contains the response from method ItemsClient.BeginCreateLakehouse.

type ItemsClientDeleteLakehouseOptions

type ItemsClientDeleteLakehouseOptions struct {
}

ItemsClientDeleteLakehouseOptions contains the optional parameters for the ItemsClient.DeleteLakehouse method.

type ItemsClientDeleteLakehouseResponse

type ItemsClientDeleteLakehouseResponse struct {
}

ItemsClientDeleteLakehouseResponse contains the response from method ItemsClient.DeleteLakehouse.

type ItemsClientGetLakehouseOptions

type ItemsClientGetLakehouseOptions struct {
}

ItemsClientGetLakehouseOptions contains the optional parameters for the ItemsClient.GetLakehouse method.

type ItemsClientGetLakehouseResponse

type ItemsClientGetLakehouseResponse struct {
	// A lakehouse item.
	Lakehouse
}

ItemsClientGetLakehouseResponse contains the response from method ItemsClient.GetLakehouse.

type ItemsClientListLakehousesOptions

type ItemsClientListLakehousesOptions struct {
	// A token for retrieving the next page of results.
	ContinuationToken *string
}

ItemsClientListLakehousesOptions contains the optional parameters for the ItemsClient.NewListLakehousesPager method.

type ItemsClientListLakehousesResponse

type ItemsClientListLakehousesResponse struct {
	// A list of lakehouses.
	Lakehouses
}

ItemsClientListLakehousesResponse contains the response from method ItemsClient.NewListLakehousesPager.

type ItemsClientUpdateLakehouseOptions

type ItemsClientUpdateLakehouseOptions struct {
}

ItemsClientUpdateLakehouseOptions contains the optional parameters for the ItemsClient.UpdateLakehouse method.

type ItemsClientUpdateLakehouseResponse

type ItemsClientUpdateLakehouseResponse struct {
	// A lakehouse item.
	Lakehouse
}

ItemsClientUpdateLakehouseResponse contains the response from method ItemsClient.UpdateLakehouse.

type Lakehouse

type Lakehouse struct {
	// REQUIRED; The item type.
	Type *ItemType

	// The item description.
	Description *string

	// The item display name.
	DisplayName *string

	// The lakehouse properties.
	Properties *Properties

	// READ-ONLY; The item ID.
	ID *string

	// READ-ONLY; The workspace ID.
	WorkspaceID *string
}

Lakehouse - A lakehouse item.

func (Lakehouse) MarshalJSON

func (l Lakehouse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Lakehouse.

func (*Lakehouse) UnmarshalJSON

func (l *Lakehouse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Lakehouse.

type Lakehouses

type Lakehouses struct {
	// REQUIRED; A list of lakehouses.
	Value []Lakehouse

	// The token for the next result set batch. If there are no more records, it's removed from the response.
	ContinuationToken *string

	// The URI of the next result set batch. If there are no more records, it's removed from the response.
	ContinuationURI *string
}

Lakehouses - A list of lakehouses.

func (Lakehouses) MarshalJSON

func (l Lakehouses) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Lakehouses.

func (*Lakehouses) UnmarshalJSON

func (l *Lakehouses) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Lakehouses.

type LoadTableRequest

type LoadTableRequest struct {
	// REQUIRED; The type of relativePath, either file or folder. Additional PathType types may be added over time.
	PathType *PathType

	// REQUIRED; The relative path of the data file or folder.
	RelativePath *string

	// The file extension of the data file.
	FileExtension *string

	// Abstract type of data file format options.
	FormatOptions FileFormatOptionsClassification

	// The load table operation mode, overwrite or append. Additional mode types may be added over time.
	Mode *ModeType

	// Indicates whether to search data files recursively or not, when loading a table from a folder.
	Recursive *bool
}

LoadTableRequest - Represents a load table operation request.

func (LoadTableRequest) MarshalJSON

func (l LoadTableRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type LoadTableRequest.

func (*LoadTableRequest) UnmarshalJSON

func (l *LoadTableRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type LoadTableRequest.

type ModeType

type ModeType string

ModeType - The load table operation mode, overwrite or append. Additional mode types may be added over time.

const (
	// ModeTypeAppend - load table in append mode.
	ModeTypeAppend ModeType = "Append"
	// ModeTypeOverwrite - load table in overwrite mode.
	ModeTypeOverwrite ModeType = "Overwrite"
)

func PossibleModeTypeValues

func PossibleModeTypeValues() []ModeType

PossibleModeTypeValues returns the possible values for the ModeType const type.

type OptimizeSettings

type OptimizeSettings struct {
	// The V-Order [/fabric/data-engineering/delta-optimization-and-v-order#what-is-v-order] settings. True - Enabled, False -
	// Disabled.
	VOrder *bool

	// A list of column names to Z-Order the data by. If not provided, Z-Ordering isn't applied.
	ZOrderBy []string
}

OptimizeSettings - Table maintenance optimization settings.

func (OptimizeSettings) MarshalJSON

func (o OptimizeSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OptimizeSettings.

func (*OptimizeSettings) UnmarshalJSON

func (o *OptimizeSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OptimizeSettings.

type Parquet

type Parquet struct {
	// REQUIRED; Data file format name. Additional file format types may be added over time.
	Format *FileFormat
}

Parquet - Format options for Parquet files.

func (*Parquet) GetFileFormatOptions

func (p *Parquet) GetFileFormatOptions() *FileFormatOptions

GetFileFormatOptions implements the FileFormatOptionsClassification interface for type Parquet.

func (Parquet) MarshalJSON

func (p Parquet) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Parquet.

func (*Parquet) UnmarshalJSON

func (p *Parquet) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Parquet.

type PathType

type PathType string

PathType - The type of relativePath, either file or folder. Additional PathType types may be added over time.

const (
	// PathTypeFile - load table from file.
	PathTypeFile PathType = "File"
	// PathTypeFolder - load table from folder.
	PathTypeFolder PathType = "Folder"
)

func PossiblePathTypeValues

func PossiblePathTypeValues() []PathType

PossiblePathTypeValues returns the possible values for the PathType const type.

type Properties

type Properties struct {
	// REQUIRED; OneLake path to the Lakehouse files directory.
	OneLakeFilesPath *string

	// REQUIRED; OneLake path to the Lakehouse tables directory.
	OneLakeTablesPath *string

	// Default schema of the lakehouse. This property is returned only for schema enabled lakehouse.
	DefaultSchema *string

	// An object containing the properties of the SQL endpoint.
	SQLEndpointProperties *SQLEndpointProperties
}

Properties - The lakehouse properties.

func (Properties) MarshalJSON

func (p Properties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Properties.

func (*Properties) UnmarshalJSON

func (p *Properties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Properties.

type RunOnDemandTableMaintenanceRequest

type RunOnDemandTableMaintenanceRequest struct {
	// REQUIRED; Execution data to configure the table maintenance [/fabric/data-engineering/lakehouse-table-maintenance] job.
	ExecutionData *TableMaintenanceExecutionData
}

RunOnDemandTableMaintenanceRequest - Run on demand lakehouse table maintenance instance payload

func (RunOnDemandTableMaintenanceRequest) MarshalJSON

func (r RunOnDemandTableMaintenanceRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RunOnDemandTableMaintenanceRequest.

func (*RunOnDemandTableMaintenanceRequest) UnmarshalJSON

func (r *RunOnDemandTableMaintenanceRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RunOnDemandTableMaintenanceRequest.

type SQLEndpointProperties

type SQLEndpointProperties struct {
	// REQUIRED; The SQL endpoint provisioning status.
	ProvisioningStatus *SQLEndpointProvisioningStatus

	// SQL endpoint connection string.
	ConnectionString *string

	// SQL endpoint ID.
	ID *string
}

SQLEndpointProperties - An object containing the properties of the SQL endpoint.

func (SQLEndpointProperties) MarshalJSON

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

MarshalJSON implements the json.Marshaller interface for type SQLEndpointProperties.

func (*SQLEndpointProperties) UnmarshalJSON

func (s *SQLEndpointProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SQLEndpointProperties.

type SQLEndpointProvisioningStatus

type SQLEndpointProvisioningStatus string

SQLEndpointProvisioningStatus - The SQL endpoint provisioning status type. Additional SqlEndpointProvisioningStatus types may be added over time.

const (
	// SQLEndpointProvisioningStatusFailed - SQL endpoint provisioning failed.
	SQLEndpointProvisioningStatusFailed SQLEndpointProvisioningStatus = "Failed"
	// SQLEndpointProvisioningStatusInProgress - SQL endpoint provisioning is in progress.
	SQLEndpointProvisioningStatusInProgress SQLEndpointProvisioningStatus = "InProgress"
	// SQLEndpointProvisioningStatusSuccess - SQL endpoint provisioning succeeded.
	SQLEndpointProvisioningStatusSuccess SQLEndpointProvisioningStatus = "Success"
)

func PossibleSQLEndpointProvisioningStatusValues

func PossibleSQLEndpointProvisioningStatusValues() []SQLEndpointProvisioningStatus

PossibleSQLEndpointProvisioningStatusValues returns the possible values for the SQLEndpointProvisioningStatus const type.

type Table

type Table struct {
	// REQUIRED; Table format.
	Format *string

	// REQUIRED; Table location.
	Location *string

	// REQUIRED; Table name.
	Name *string

	// REQUIRED; Table type.
	Type *TableType
}

Table information.

func (Table) MarshalJSON

func (t Table) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Table.

func (*Table) UnmarshalJSON

func (t *Table) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Table.

type TableMaintenanceExecutionData

type TableMaintenanceExecutionData struct {
	// REQUIRED; Name of the table to run maintenance on. Max length of 256 character alphanumeric string with underscores.
	TableName *string

	// Configures the optimization settings of the maintenance job. To skip table optimization, leave this parameter empty.
	OptimizeSettings *OptimizeSettings

	// Name of the schema under which the table is created. This property is applicable only for a schema enabled Lakehouse. Max
	// length of 128 character alphanumeric string with underscores.
	SchemaName *string

	// Configures the vacuum [https://docs.delta.io/latest/delta-utility.html#-delta-vacuum] settings of the maintenance job.
	// To skip table vacuum, leave this parameter empty.
	VacuumSettings *VacuumSettings
}

TableMaintenanceExecutionData - Run on demand lakehouse table maintenance instance payload

func (TableMaintenanceExecutionData) MarshalJSON

func (t TableMaintenanceExecutionData) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type TableMaintenanceExecutionData.

func (*TableMaintenanceExecutionData) UnmarshalJSON

func (t *TableMaintenanceExecutionData) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type TableMaintenanceExecutionData.

type TableType

type TableType string

TableType - The table type. Additional TableType types may be added over time.

const (
	// TableTypeExternal - External table.
	TableTypeExternal TableType = "External"
	// TableTypeManaged - Managed table.
	TableTypeManaged TableType = "Managed"
)

func PossibleTableTypeValues

func PossibleTableTypeValues() []TableType

PossibleTableTypeValues returns the possible values for the TableType const type.

type Tables

type Tables struct {
	// REQUIRED; List of tables.
	Data []Table

	// Token to get the next page of results.
	ContinuationToken *string

	// The URI of the next chunk in the result set.
	ContinuationURI *string
}

Tables - A paginated list of tables.

func (Tables) MarshalJSON

func (t Tables) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Tables.

func (*Tables) UnmarshalJSON

func (t *Tables) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Tables.

type TablesClient

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

TablesClient contains the methods for the Tables group. Don't use this type directly, use a constructor function instead.

func (*TablesClient) BeginLoadTable

func (client *TablesClient) BeginLoadTable(ctx context.Context, workspaceID string, lakehouseID string, tableName string, loadTableRequest LoadTableRequest, options *TablesClientBeginLoadTableOptions) (*runtime.Poller[TablesClientLoadTableResponse], error)

BeginLoadTable - This API supports long running operations (LRO) [/rest/api/fabric/articles/long-running-operation]. PERMISSIONS Write permission to the lakehouse item. REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE If the operation fails it returns an *core.ResponseError type.

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse item ID.
  • tableName - The table name.
  • loadTableRequest - The load table request payload.
  • options - TablesClientBeginLoadTableOptions contains the optional parameters for the TablesClient.BeginLoadTable method.

func (*TablesClient) ListTables

func (client *TablesClient) ListTables(ctx context.Context, workspaceID string, lakehouseID string, options *TablesClientListTablesOptions) ([]Table, error)

ListTables - returns array of Table from all pages. This API supports pagination [/rest/api/fabric/articles/pagination]. A maximum of 100 records can be returned per request. With the URI provided in the response, you can get the next page of records.

REQUIRED DELEGATED SCOPES Lakehouse.Read.All or Lakehouse.ReadWrite.All

MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section.

| Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes |

INTERFACE Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse ID.
  • options - TablesClientListTablesOptions contains the optional parameters for the TablesClient.NewListTablesPager method.

func (*TablesClient) LoadTable

func (client *TablesClient) LoadTable(ctx context.Context, workspaceID string, lakehouseID string, tableName string, loadTableRequest LoadTableRequest, options *TablesClientBeginLoadTableOptions) (TablesClientLoadTableResponse, error)

LoadTable - returns TablesClientLoadTableResponse in sync mode. This API supports long running operations (LRO) [/rest/api/fabric/articles/long-running-operation].

PERMISSIONS Write permission to the lakehouse item.

REQUIRED DELEGATED SCOPES Lakehouse.ReadWrite.All

MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section.

| Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes |

INTERFACE Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse item ID.
  • tableName - The table name.
  • loadTableRequest - The load table request payload.
  • options - TablesClientBeginLoadTableOptions contains the optional parameters for the TablesClient.BeginLoadTable method.

func (*TablesClient) NewListTablesPager

func (client *TablesClient) NewListTablesPager(workspaceID string, lakehouseID string, options *TablesClientListTablesOptions) *runtime.Pager[TablesClientListTablesResponse]

NewListTablesPager - This API supports pagination [/rest/api/fabric/articles/pagination]. A maximum of 100 records can be returned per request. With the URI provided in the response, you can get the next page of records. REQUIRED DELEGATED SCOPES Lakehouse.Read.All or Lakehouse.ReadWrite.All MICROSOFT ENTRA SUPPORTED IDENTITIES This API supports the Microsoft identities [/rest/api/fabric/articles/identity-support] listed in this section. | Identity | Support | |-|-| | User | Yes | | Service principal [/entra/identity-platform/app-objects-and-service-principals#service-principal-object] and Managed identities [/entra/identity/managed-identities-azure-resources/overview] | Yes | INTERFACE

Generated from API version v1

  • workspaceID - The workspace ID.
  • lakehouseID - The lakehouse ID.
  • options - TablesClientListTablesOptions contains the optional parameters for the TablesClient.NewListTablesPager method.
Example

Generated from example definition

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"

	"github.com/microsoft/fabric-sdk-go/fabric/lakehouse"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := lakehouse.NewClientFactory(cred, nil, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	pager := clientFactory.NewTablesClient().NewListTablesPager("f089354e-8366-4e18-aea3-4cb4a3a50b48", "41ce06d1-d81b-4ea0-bc6d-2ce3dd2f8e87", &lakehouse.TablesClientListTablesOptions{MaxResults: to.Ptr[int32](10),
		ContinuationToken: to.Ptr(""),
	})
	for pager.More() {
		page, err := pager.NextPage(ctx)
		if err != nil {
			log.Fatalf("failed to advance page: %v", err)
		}
		for _, v := range page.Data {
			// You could use page here. We use blank identifier for just demo purposes.
			_ = v
		}
		// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
		// page.Tables = lakehouse.Tables{
		// 	ContinuationToken: to.Ptr("+RID:~HTsuAOseYicH-GcAAAAAAA==#RT:1#TRC:1#ISV:2#IEO:65567#QCF:8#FPC:AgKfAZ8BnwEEAAe8eoA="),
		// 	ContinuationURI: to.Ptr("https://api.fabric.microsoft.com/v1/workspaces/f089354e-8366-4e18-aea3-4cb4a3a50b48/lakehouses/41ce06d1-d81b-4ea0-bc6d-2ce3dd2f8e87/tables?continuationToken=%2BRID%3A~HTsuAOseYicH-GcAAAAAAA%3D%3D%23RT%3A1%23TRC%3A1%23ISV%3A2%23IEO%3A65567%23QCF%3A8%23FPC%3AAgKfAZ8BnwEEAAe8eoA%3D"),
		// 	Data: []lakehouse.Table{
		// 		{
		// 			Name: to.Ptr("Table1"),
		// 			Type: to.Ptr(lakehouse.TableTypeManaged),
		// 			Format: to.Ptr("Delta"),
		// 			Location: to.Ptr("abfss://f089354e-8366-4e18-aea3-4cb4a3a50b48@onelake.dfs.fabric.microsoft.com/41ce06d1-d81b-4ea0-bc6d-2ce3dd2f8e87/Tables/Table1"),
		// 	}},
		// }
	}
}
Output:

type TablesClientBeginLoadTableOptions

type TablesClientBeginLoadTableOptions struct {
	// Resumes the long-running operation from the provided token.
	ResumeToken string
}

TablesClientBeginLoadTableOptions contains the optional parameters for the TablesClient.BeginLoadTable method.

type TablesClientListTablesOptions

type TablesClientListTablesOptions struct {
	// Token to retrieve the next page of results, if available.
	ContinuationToken *string

	// The maximum number of results per page to return.
	MaxResults *int32
}

TablesClientListTablesOptions contains the optional parameters for the TablesClient.NewListTablesPager method.

type TablesClientListTablesResponse

type TablesClientListTablesResponse struct {
	// A paginated list of tables.
	Tables
}

TablesClientListTablesResponse contains the response from method TablesClient.NewListTablesPager.

type TablesClientLoadTableResponse

type TablesClientLoadTableResponse struct {
}

TablesClientLoadTableResponse contains the response from method TablesClient.BeginLoadTable.

type UpdateLakehouseRequest

type UpdateLakehouseRequest struct {
	// The lakehouse description. Maximum length is 256 characters.
	Description *string

	// The lakehouse display name. The display name must follow naming rules according to item type.
	DisplayName *string
}

UpdateLakehouseRequest - Update lakehouse request.

func (UpdateLakehouseRequest) MarshalJSON

func (u UpdateLakehouseRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type UpdateLakehouseRequest.

func (*UpdateLakehouseRequest) UnmarshalJSON

func (u *UpdateLakehouseRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type UpdateLakehouseRequest.

type VacuumSettings

type VacuumSettings struct {
	// Overrides the default retention period. Unreferenced files or data files associated with delta table versions older than
	// the specified retention period are removed. This value should follow the
	// pattern of d:hh:mm:ss where d is the number of days, hh is the number of hours between 00 and 23, mm is the number of minutes
	// between 00 and 59, and ss is the number of seconds between 00 and 59.
	RetentionPeriod *string
}

VacuumSettings - Table maintenance vacuum [/fabric/data-engineering/lakehouse-table-maintenance#table-maintenance-operations] settings.

func (VacuumSettings) MarshalJSON

func (v VacuumSettings) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type VacuumSettings.

func (*VacuumSettings) UnmarshalJSON

func (v *VacuumSettings) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type VacuumSettings.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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