workspaces

package
v0.20240118.1115711 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: MPL-2.0 Imports: 14 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/operationalinsights/2023-09-01/workspaces Documentation

The workspaces SDK allows for interaction with the Azure Resource Manager Service operationalinsights (API Version 2023-09-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/operationalinsights/2023-09-01/workspaces"

Client Initialization

client := workspaces.NewWorkspacesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: WorkspacesClient.CreateOrUpdate

ctx := context.TODO()
id := workspaces.NewWorkspaceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue")

payload := workspaces.Workspace{
	// ...
}


if err := client.CreateOrUpdateThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Example Usage: WorkspacesClient.Delete

ctx := context.TODO()
id := workspaces.NewWorkspaceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue")

if err := client.DeleteThenPoll(ctx, id, workspaces.DefaultDeleteOperationOptions()); err != nil {
	// handle the error
}

Example Usage: WorkspacesClient.Get

ctx := context.TODO()
id := workspaces.NewWorkspaceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: WorkspacesClient.List

ctx := context.TODO()
id := workspaces.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

read, err := client.List(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: WorkspacesClient.ListByResourceGroup

ctx := context.TODO()
id := workspaces.NewResourceGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group")

read, err := client.ListByResourceGroup(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: WorkspacesClient.Update

ctx := context.TODO()
id := workspaces.NewWorkspaceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue")

payload := workspaces.WorkspacePatch{
	// ...
}


read, err := client.Update(ctx, id, payload)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForCapacityReservationLevel

func PossibleValuesForCapacityReservationLevel() []int64

func PossibleValuesForDataIngestionStatus

func PossibleValuesForDataIngestionStatus() []string

func PossibleValuesForPublicNetworkAccessType

func PossibleValuesForPublicNetworkAccessType() []string

func PossibleValuesForWorkspaceEntityStatus

func PossibleValuesForWorkspaceEntityStatus() []string

func PossibleValuesForWorkspaceSkuNameEnum

func PossibleValuesForWorkspaceSkuNameEnum() []string

func ValidateWorkspaceID

func ValidateWorkspaceID(input interface{}, key string) (warnings []string, errors []error)

ValidateWorkspaceID checks that 'input' can be parsed as a Workspace ID

Types

type CapacityReservationLevel

type CapacityReservationLevel int64
const (
	CapacityReservationLevelFiveHundred      CapacityReservationLevel = 500
	CapacityReservationLevelFiveThousand     CapacityReservationLevel = 5000
	CapacityReservationLevelFiveZeroThousand CapacityReservationLevel = 50000
	CapacityReservationLevelFourHundred      CapacityReservationLevel = 400
	CapacityReservationLevelOneHundred       CapacityReservationLevel = 100
	CapacityReservationLevelOneThousand      CapacityReservationLevel = 1000
	CapacityReservationLevelOneZeroThousand  CapacityReservationLevel = 10000
	CapacityReservationLevelThreeHundred     CapacityReservationLevel = 300
	CapacityReservationLevelTwoFiveThousand  CapacityReservationLevel = 25000
	CapacityReservationLevelTwoHundred       CapacityReservationLevel = 200
	CapacityReservationLevelTwoThousand      CapacityReservationLevel = 2000
)

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type DataIngestionStatus

type DataIngestionStatus string
const (
	DataIngestionStatusApproachingQuota      DataIngestionStatus = "ApproachingQuota"
	DataIngestionStatusForceOff              DataIngestionStatus = "ForceOff"
	DataIngestionStatusForceOn               DataIngestionStatus = "ForceOn"
	DataIngestionStatusOverQuota             DataIngestionStatus = "OverQuota"
	DataIngestionStatusRespectQuota          DataIngestionStatus = "RespectQuota"
	DataIngestionStatusSubscriptionSuspended DataIngestionStatus = "SubscriptionSuspended"
)

func (*DataIngestionStatus) UnmarshalJSON

func (s *DataIngestionStatus) UnmarshalJSON(bytes []byte) error

type DeleteOperationOptions

type DeleteOperationOptions struct {
	Force *bool
}

func DefaultDeleteOperationOptions

func DefaultDeleteOperationOptions() DeleteOperationOptions

func (DeleteOperationOptions) ToHeaders

func (o DeleteOperationOptions) ToHeaders() *client.Headers

func (DeleteOperationOptions) ToOData

func (o DeleteOperationOptions) ToOData() *odata.Query

func (DeleteOperationOptions) ToQuery

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workspace
}

type ListByResourceGroupOperationResponse

type ListByResourceGroupOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *WorkspaceListResult
}

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *WorkspaceListResult
}

type PrivateLinkScopedResource

type PrivateLinkScopedResource struct {
	ResourceId *string `json:"resourceId,omitempty"`
	ScopeId    *string `json:"scopeId,omitempty"`
}

type PublicNetworkAccessType

type PublicNetworkAccessType string
const (
	PublicNetworkAccessTypeDisabled PublicNetworkAccessType = "Disabled"
	PublicNetworkAccessTypeEnabled  PublicNetworkAccessType = "Enabled"
)

func (*PublicNetworkAccessType) UnmarshalJSON

func (s *PublicNetworkAccessType) UnmarshalJSON(bytes []byte) error

type UpdateOperationResponse

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *Workspace
}

type Workspace

type Workspace struct {
	Etag       *string                           `json:"etag,omitempty"`
	Id         *string                           `json:"id,omitempty"`
	Identity   *identity.SystemOrUserAssignedMap `json:"identity,omitempty"`
	Location   string                            `json:"location"`
	Name       *string                           `json:"name,omitempty"`
	Properties *WorkspaceProperties              `json:"properties,omitempty"`
	SystemData *systemdata.SystemData            `json:"systemData,omitempty"`
	Tags       *map[string]string                `json:"tags,omitempty"`
	Type       *string                           `json:"type,omitempty"`
}

type WorkspaceCapping

type WorkspaceCapping struct {
	DailyQuotaGb        *float64             `json:"dailyQuotaGb,omitempty"`
	DataIngestionStatus *DataIngestionStatus `json:"dataIngestionStatus,omitempty"`
	QuotaNextResetTime  *string              `json:"quotaNextResetTime,omitempty"`
}

type WorkspaceEntityStatus

type WorkspaceEntityStatus string
const (
	WorkspaceEntityStatusCanceled            WorkspaceEntityStatus = "Canceled"
	WorkspaceEntityStatusCreating            WorkspaceEntityStatus = "Creating"
	WorkspaceEntityStatusDeleting            WorkspaceEntityStatus = "Deleting"
	WorkspaceEntityStatusFailed              WorkspaceEntityStatus = "Failed"
	WorkspaceEntityStatusProvisioningAccount WorkspaceEntityStatus = "ProvisioningAccount"
	WorkspaceEntityStatusSucceeded           WorkspaceEntityStatus = "Succeeded"
	WorkspaceEntityStatusUpdating            WorkspaceEntityStatus = "Updating"
)

func (*WorkspaceEntityStatus) UnmarshalJSON

func (s *WorkspaceEntityStatus) UnmarshalJSON(bytes []byte) error

type WorkspaceFeatures

type WorkspaceFeatures struct {
	ClusterResourceId                           *string `json:"clusterResourceId,omitempty"`
	DisableLocalAuth                            *bool   `json:"disableLocalAuth,omitempty"`
	EnableDataExport                            *bool   `json:"enableDataExport,omitempty"`
	EnableLogAccessUsingOnlyResourcePermissions *bool   `json:"enableLogAccessUsingOnlyResourcePermissions,omitempty"`
	ImmediatePurgeDataOn30Days                  *bool   `json:"immediatePurgeDataOn30Days,omitempty"`
	UnifiedSentinelBillingOnly                  *bool   `json:"unifiedSentinelBillingOnly,omitempty"`
}

type WorkspaceId

type WorkspaceId struct {
	SubscriptionId    string
	ResourceGroupName string
	WorkspaceName     string
}

WorkspaceId is a struct representing the Resource ID for a Workspace

func NewWorkspaceID

func NewWorkspaceID(subscriptionId string, resourceGroupName string, workspaceName string) WorkspaceId

NewWorkspaceID returns a new WorkspaceId struct

func ParseWorkspaceID

func ParseWorkspaceID(input string) (*WorkspaceId, error)

ParseWorkspaceID parses 'input' into a WorkspaceId

func ParseWorkspaceIDInsensitively

func ParseWorkspaceIDInsensitively(input string) (*WorkspaceId, error)

ParseWorkspaceIDInsensitively parses 'input' case-insensitively into a WorkspaceId note: this method should only be used for API response data and not user input

func (*WorkspaceId) FromParseResult

func (id *WorkspaceId) FromParseResult(input resourceids.ParseResult) error

func (WorkspaceId) ID

func (id WorkspaceId) ID() string

ID returns the formatted Workspace ID

func (WorkspaceId) Segments

func (id WorkspaceId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Workspace ID

func (WorkspaceId) String

func (id WorkspaceId) String() string

String returns a human-readable description of this Workspace ID

type WorkspaceListResult

type WorkspaceListResult struct {
	Value *[]Workspace `json:"value,omitempty"`
}

type WorkspacePatch

type WorkspacePatch struct {
	Etag       *string                           `json:"etag,omitempty"`
	Id         *string                           `json:"id,omitempty"`
	Identity   *identity.SystemOrUserAssignedMap `json:"identity,omitempty"`
	Name       *string                           `json:"name,omitempty"`
	Properties *WorkspaceProperties              `json:"properties,omitempty"`
	Tags       *map[string]string                `json:"tags,omitempty"`
	Type       *string                           `json:"type,omitempty"`
}

type WorkspaceProperties

type WorkspaceProperties struct {
	CreatedDate                         *string                      `json:"createdDate,omitempty"`
	CustomerId                          *string                      `json:"customerId,omitempty"`
	DefaultDataCollectionRuleResourceId *string                      `json:"defaultDataCollectionRuleResourceId,omitempty"`
	Features                            *WorkspaceFeatures           `json:"features,omitempty"`
	ForceCmkForQuery                    *bool                        `json:"forceCmkForQuery,omitempty"`
	ModifiedDate                        *string                      `json:"modifiedDate,omitempty"`
	PrivateLinkScopedResources          *[]PrivateLinkScopedResource `json:"privateLinkScopedResources,omitempty"`
	ProvisioningState                   *WorkspaceEntityStatus       `json:"provisioningState,omitempty"`
	PublicNetworkAccessForIngestion     *PublicNetworkAccessType     `json:"publicNetworkAccessForIngestion,omitempty"`
	PublicNetworkAccessForQuery         *PublicNetworkAccessType     `json:"publicNetworkAccessForQuery,omitempty"`
	RetentionInDays                     *int64                       `json:"retentionInDays,omitempty"`
	Sku                                 *WorkspaceSku                `json:"sku,omitempty"`
	WorkspaceCapping                    *WorkspaceCapping            `json:"workspaceCapping,omitempty"`
}

type WorkspaceSku

type WorkspaceSku struct {
	CapacityReservationLevel *CapacityReservationLevel `json:"capacityReservationLevel,omitempty"`
	LastSkuUpdate            *string                   `json:"lastSkuUpdate,omitempty"`
	Name                     WorkspaceSkuNameEnum      `json:"name"`
}

type WorkspaceSkuNameEnum

type WorkspaceSkuNameEnum string
const (
	WorkspaceSkuNameEnumCapacityReservation  WorkspaceSkuNameEnum = "CapacityReservation"
	WorkspaceSkuNameEnumFree                 WorkspaceSkuNameEnum = "Free"
	WorkspaceSkuNameEnumLACluster            WorkspaceSkuNameEnum = "LACluster"
	WorkspaceSkuNameEnumPerGBTwoZeroOneEight WorkspaceSkuNameEnum = "PerGB2018"
	WorkspaceSkuNameEnumPerNode              WorkspaceSkuNameEnum = "PerNode"
	WorkspaceSkuNameEnumPremium              WorkspaceSkuNameEnum = "Premium"
	WorkspaceSkuNameEnumStandalone           WorkspaceSkuNameEnum = "Standalone"
	WorkspaceSkuNameEnumStandard             WorkspaceSkuNameEnum = "Standard"
)

func (*WorkspaceSkuNameEnum) UnmarshalJSON

func (s *WorkspaceSkuNameEnum) UnmarshalJSON(bytes []byte) error

type WorkspacesClient

type WorkspacesClient struct {
	Client *resourcemanager.Client
}

func NewWorkspacesClientWithBaseURI

func NewWorkspacesClientWithBaseURI(sdkApi sdkEnv.Api) (*WorkspacesClient, error)

func (WorkspacesClient) CreateOrUpdate

func (c WorkspacesClient) CreateOrUpdate(ctx context.Context, id WorkspaceId, input Workspace) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (WorkspacesClient) CreateOrUpdateThenPoll

func (c WorkspacesClient) CreateOrUpdateThenPoll(ctx context.Context, id WorkspaceId, input Workspace) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (WorkspacesClient) Delete

Delete ...

func (WorkspacesClient) DeleteThenPoll

func (c WorkspacesClient) DeleteThenPoll(ctx context.Context, id WorkspaceId, options DeleteOperationOptions) error

DeleteThenPoll performs Delete then polls until it's completed

func (WorkspacesClient) Get

Get ...

func (WorkspacesClient) List

List ...

func (WorkspacesClient) ListByResourceGroup

ListByResourceGroup ...

func (WorkspacesClient) Update

Update ...

Jump to

Keyboard shortcuts

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