Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Stream Analytics API version from 2020-03-01-preview to 2020-03-01 #16270

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion internal/services/streamanalytics/client/client.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/internal/common"
)

Expand Down
6 changes: 3 additions & 3 deletions internal/services/streamanalytics/helpers_input.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package streamanalytics
import (
"fmt"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/validation"
"github.com/hashicorp/terraform-provider-azurerm/utils"
Expand Down Expand Up @@ -42,7 +42,7 @@ func schemaStreamAnalyticsStreamInputSerialization() *pluginsdk.Schema {
Type: pluginsdk.TypeString,
Optional: true,
ValidateFunc: validation.StringInSlice([]string{
string(streamanalytics.UTF8),
string(streamanalytics.EncodingUTF8),
}, false),
},
},
Expand All @@ -53,7 +53,7 @@ func schemaStreamAnalyticsStreamInputSerialization() *pluginsdk.Schema {
func expandStreamAnalyticsStreamInputSerialization(input []interface{}) (streamanalytics.BasicSerialization, error) {
v := input[0].(map[string]interface{})

inputType := streamanalytics.TypeBasicSerialization(v["type"].(string))
inputType := streamanalytics.Type(v["type"].(string))
encoding := v["encoding"].(string)
fieldDelimiter := v["field_delimiter"].(string)

Expand Down
10 changes: 5 additions & 5 deletions internal/services/streamanalytics/helpers_output.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package streamanalytics
import (
"fmt"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/validation"
"github.com/hashicorp/terraform-provider-azurerm/utils"
Expand Down Expand Up @@ -43,16 +43,16 @@ func schemaStreamAnalyticsOutputSerialization() *pluginsdk.Schema {
Type: pluginsdk.TypeString,
Optional: true,
ValidateFunc: validation.StringInSlice([]string{
string(streamanalytics.UTF8),
string(streamanalytics.EncodingUTF8),
}, false),
},

"format": {
Type: pluginsdk.TypeString,
Optional: true,
ValidateFunc: validation.StringInSlice([]string{
string(streamanalytics.Array),
string(streamanalytics.LineSeparated),
string(streamanalytics.JSONOutputSerializationFormatArray),
string(streamanalytics.JSONOutputSerializationFormatLineSeparated),
}, false),
},
},
Expand All @@ -63,7 +63,7 @@ func schemaStreamAnalyticsOutputSerialization() *pluginsdk.Schema {
func expandStreamAnalyticsOutputSerialization(input []interface{}) (streamanalytics.BasicSerialization, error) {
v := input[0].(map[string]interface{})

outputType := streamanalytics.TypeBasicSerialization(v["type"].(string))
outputType := streamanalytics.Type(v["type"].(string))
encoding := v["encoding"].(string)
fieldDelimiter := v["field_delimiter"].(string)
format := v["format"].(string)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/internal/sdk"
Expand Down Expand Up @@ -97,7 +97,7 @@ func (r ClusterResource) Create() sdk.ResourceFunc {
Name: utils.String(model.Name),
Location: utils.String(model.Location),
Sku: &streamanalytics.ClusterSku{
Name: streamanalytics.Default,
Name: streamanalytics.ClusterSkuNameDefault,
Capacity: utils.Int32(model.StreamingCapacity),
},
Tags: tags.Expand(model.Tags),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
"github.com/hashicorp/terraform-provider-azurerm/internal/clients"
Expand Down Expand Up @@ -132,10 +132,10 @@ func resourceStreamAnalyticsFunctionUDACreate(d *pluginsdk.ResourceData, meta in

props := streamanalytics.Function{
Properties: &streamanalytics.AggregateFunctionProperties{
Type: streamanalytics.TypeAggregate,
Type: streamanalytics.TypeBasicFunctionPropertiesTypeAggregate,
FunctionConfiguration: &streamanalytics.FunctionConfiguration{
Binding: &streamanalytics.JavaScriptFunctionBinding{
Type: streamanalytics.TypeMicrosoftStreamAnalyticsJavascriptUdf,
Type: streamanalytics.TypeBasicFunctionBindingTypeMicrosoftStreamAnalyticsJavascriptUdf,
JavaScriptFunctionBindingProperties: &streamanalytics.JavaScriptFunctionBindingProperties{
Script: utils.String(d.Get("script").(string)),
},
Expand Down Expand Up @@ -220,10 +220,10 @@ func resourceStreamAnalyticsFunctionUDAUpdate(d *pluginsdk.ResourceData, meta in

props := streamanalytics.Function{
Properties: &streamanalytics.AggregateFunctionProperties{
Type: streamanalytics.TypeAggregate,
Type: streamanalytics.TypeBasicFunctionPropertiesTypeAggregate,
FunctionConfiguration: &streamanalytics.FunctionConfiguration{
Binding: &streamanalytics.JavaScriptFunctionBinding{
Type: streamanalytics.TypeMicrosoftStreamAnalyticsJavascriptUdf,
Type: streamanalytics.TypeBasicFunctionBindingTypeMicrosoftStreamAnalyticsJavascriptUdf,
JavaScriptFunctionBindingProperties: &streamanalytics.JavaScriptFunctionBindingProperties{
Script: utils.String(d.Get("script").(string)),
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
Expand Down Expand Up @@ -137,10 +137,10 @@ func resourceStreamAnalyticsFunctionUDFCreateUpdate(d *pluginsdk.ResourceData, m

function := streamanalytics.Function{
Properties: &streamanalytics.ScalarFunctionProperties{
Type: streamanalytics.TypeScalar,
Type: streamanalytics.TypeBasicFunctionPropertiesTypeScalar,
FunctionConfiguration: &streamanalytics.FunctionConfiguration{
Binding: &streamanalytics.JavaScriptFunctionBinding{
Type: streamanalytics.TypeMicrosoftStreamAnalyticsJavascriptUdf,
Type: streamanalytics.TypeBasicFunctionBindingTypeMicrosoftStreamAnalyticsJavascriptUdf,
JavaScriptFunctionBindingProperties: &streamanalytics.JavaScriptFunctionBindingProperties{
Script: utils.String(script),
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/resourcemanager/commonschema"
"github.com/hashicorp/go-azure-helpers/resourcemanager/identity"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
Expand Down Expand Up @@ -62,7 +62,7 @@ func resourceStreamAnalyticsJob() *pluginsdk.Resource {
Computed: true,
ValidateFunc: validation.StringInSlice([]string{
// values found in the other API the portal uses
string(streamanalytics.OneFullStopZero),
string(streamanalytics.CompatibilityLevelOneFullStopZero),
"1.1",
"1.2",
}, false),
Expand Down Expand Up @@ -95,10 +95,10 @@ func resourceStreamAnalyticsJob() *pluginsdk.Resource {
Type: pluginsdk.TypeString,
Optional: true,
ValidateFunc: validation.StringInSlice([]string{
string(streamanalytics.Adjust),
string(streamanalytics.Drop),
string(streamanalytics.EventsOutOfOrderPolicyAdjust),
string(streamanalytics.EventsOutOfOrderPolicyDrop),
}, false),
Default: string(streamanalytics.Adjust),
Default: string(streamanalytics.EventsOutOfOrderPolicyAdjust),
},

"output_error_policy": {
Expand Down Expand Up @@ -187,8 +187,8 @@ func resourceStreamAnalyticsJobCreateUpdate(d *pluginsdk.ResourceData, meta inte
Name: utils.String(id.Name),
Location: utils.String(location),
StreamingJobProperties: &streamanalytics.StreamingJobProperties{
Sku: &streamanalytics.StreamingJobSku{
Name: streamanalytics.Standard,
Sku: &streamanalytics.Sku{
Name: streamanalytics.SkuNameStandard,
},
CompatibilityLevel: streamanalytics.CompatibilityLevel(compatibilityLevel),
EventsLateArrivalMaxDelayInSeconds: utils.Int32(int32(eventsLateArrivalMaxDelayInSeconds)),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/internal/sdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/services/streamanalytics/parse"
Expand Down Expand Up @@ -99,7 +99,7 @@ func (r ManagedPrivateEndpointResource) Create() sdk.ResourceFunc {
}

props := streamanalytics.PrivateEndpoint{
Properties: &streamanalytics.PrivateEndpointProperties{
PrivateEndpointProperties: &streamanalytics.PrivateEndpointProperties{
ManualPrivateLinkServiceConnections: &[]streamanalytics.PrivateLinkServiceConnection{
{
PrivateLinkServiceConnectionProperties: &streamanalytics.PrivateLinkServiceConnectionProperties{
Expand Down Expand Up @@ -140,7 +140,7 @@ func (r ManagedPrivateEndpointResource) Read() sdk.ResourceFunc {
return fmt.Errorf("reading %s: %+v", *id, err)
}

if resp.Properties.ManualPrivateLinkServiceConnections == nil {
if resp.PrivateEndpointProperties.ManualPrivateLinkServiceConnections == nil {
return fmt.Errorf("TODO")
}

Expand All @@ -150,7 +150,7 @@ func (r ManagedPrivateEndpointResource) Read() sdk.ResourceFunc {
StreamAnalyticsCluster: id.ClusterName,
}

for _, mplsc := range *resp.Properties.ManualPrivateLinkServiceConnections {
for _, mplsc := range *resp.PrivateEndpointProperties.ManualPrivateLinkServiceConnections {
state.TargetResourceId = *mplsc.PrivateLinkServiceID
state.SubResourceName = strings.Join(*mplsc.GroupIds, "")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"context"
"fmt"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/internal/clients"
"github.com/hashicorp/terraform-provider-azurerm/internal/services/streamanalytics/parse"
"github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
Expand Down Expand Up @@ -142,7 +142,7 @@ func resourceStreamAnalyticsOutputBlobCreateUpdate(d *pluginsdk.ResourceData, me
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.BlobOutputDataSource{
Type: streamanalytics.TypeMicrosoftStorageBlob,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftStorageBlob,
BlobOutputDataSourceProperties: &streamanalytics.BlobOutputDataSourceProperties{
StorageAccounts: &[]streamanalytics.StorageAccount{
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
Expand Down Expand Up @@ -133,7 +133,7 @@ func resourceStreamAnalyticsOutputEventHubCreateUpdate(d *pluginsdk.ResourceData
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.EventHubOutputDataSource{
Type: streamanalytics.TypeMicrosoftServiceBusEventHub,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftServiceBusEventHub,
EventHubOutputDataSourceProperties: &streamanalytics.EventHubOutputDataSourceProperties{
EventHubName: utils.String(eventHubName),
ServiceBusNamespace: utils.String(serviceBusNamespace),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/internal/sdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/services/streamanalytics/parse"
Expand Down Expand Up @@ -125,7 +125,7 @@ func (r OutputFunctionResource) Create() sdk.ResourceFunc {
Name: utils.String(model.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.AzureFunctionOutputDataSource{
Type: streamanalytics.TypeMicrosoftAzureFunction,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftAzureFunction,
AzureFunctionOutputDataSourceProperties: &streamanalytics.AzureFunctionOutputDataSourceProperties{
FunctionAppName: utils.String(model.FunctionApp),
FunctionName: utils.String(model.FunctionName),
Expand Down Expand Up @@ -212,7 +212,7 @@ func (r OutputFunctionResource) Update() sdk.ResourceFunc {
Name: utils.String(state.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.AzureFunctionOutputDataSource{
Type: streamanalytics.TypeMicrosoftStorageTable,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftStorageTable,
AzureFunctionOutputDataSourceProperties: &streamanalytics.AzureFunctionOutputDataSourceProperties{
FunctionAppName: utils.String(state.FunctionApp),
FunctionName: utils.String(state.FunctionName),
Expand Down Expand Up @@ -268,7 +268,7 @@ func (r OutputFunctionResource) CustomImporter() sdk.ResourceRunFunc {

props := resp.OutputProperties
if _, ok := props.Datasource.AsAzureFunctionOutputDataSource(); !ok {
return fmt.Errorf("specified output is not of type %s", streamanalytics.TypeMicrosoftAzureFunction)
return fmt.Errorf("specified output is not of type %s", streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftAzureFunction)
}
return nil
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
"github.com/hashicorp/terraform-provider-azurerm/internal/clients"
Expand Down Expand Up @@ -122,7 +122,7 @@ func resourceStreamAnalyticsOutputSqlCreateUpdate(d *pluginsdk.ResourceData, met
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.AzureSQLDatabaseOutputDataSource{
Type: streamanalytics.TypeMicrosoftSQLServerDatabase,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftSQLServerDatabase,
AzureSQLDatabaseOutputDataSourceProperties: &streamanalytics.AzureSQLDatabaseOutputDataSourceProperties{
Server: utils.String(server),
Database: utils.String(databaseName),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
Expand Down Expand Up @@ -117,7 +117,7 @@ func resourceStreamAnalyticsOutputServiceBusQueueCreateUpdate(d *pluginsdk.Resou
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.ServiceBusQueueOutputDataSource{
Type: streamanalytics.TypeMicrosoftServiceBusQueue,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftServiceBusQueue,
ServiceBusQueueOutputDataSourceProperties: &streamanalytics.ServiceBusQueueOutputDataSourceProperties{
QueueName: utils.String(queueName),
ServiceBusNamespace: utils.String(serviceBusNamespace),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/azure"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
Expand Down Expand Up @@ -123,7 +123,7 @@ func resourceStreamAnalyticsOutputServiceBusTopicCreateUpdate(d *pluginsdk.Resou
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.ServiceBusTopicOutputDataSource{
Type: streamanalytics.TypeMicrosoftServiceBusTopic,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftServiceBusTopic,
ServiceBusTopicOutputDataSourceProperties: &streamanalytics.ServiceBusTopicOutputDataSourceProperties{
TopicName: utils.String(d.Get("topic_name").(string)),
ServiceBusNamespace: utils.String(d.Get("servicebus_namespace").(string)),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"time"

"github.com/Azure/azure-sdk-for-go/services/preview/streamanalytics/mgmt/2020-03-01-preview/streamanalytics"
"github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2020-03-01/streamanalytics"
"github.com/hashicorp/go-azure-helpers/lang/response"
"github.com/hashicorp/terraform-provider-azurerm/helpers/tf"
"github.com/hashicorp/terraform-provider-azurerm/internal/clients"
Expand All @@ -25,7 +25,7 @@ func resourceStreamAnalyticsOutputSynapse() *pluginsdk.Resource {
Importer: pluginsdk.ImporterValidatingResourceIdThen(func(id string) error {
_, err := parse.OutputID(id)
return err
}, importStreamAnalyticsOutput(streamanalytics.TypeMicrosoftSQLServerDataWarehouse)),
}, importStreamAnalyticsOutput(streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftSQLServerDataWarehouse)),

Timeouts: &pluginsdk.ResourceTimeout{
Create: pluginsdk.DefaultTimeout(30 * time.Minute),
Expand Down Expand Up @@ -117,7 +117,7 @@ func resourceStreamAnalyticsOutputSynapseCreateUpdate(d *pluginsdk.ResourceData,
Name: utils.String(id.Name),
OutputProperties: &streamanalytics.OutputProperties{
Datasource: &streamanalytics.AzureSynapseOutputDataSource{
Type: streamanalytics.TypeMicrosoftSQLServerDataWarehouse,
Type: streamanalytics.TypeBasicOutputDataSourceTypeMicrosoftSQLServerDataWarehouse,
AzureSynapseOutputDataSourceProperties: &streamanalytics.AzureSynapseOutputDataSourceProperties{
Server: utils.String(d.Get("server").(string)),
Database: utils.String(d.Get("database").(string)),
Expand Down
Loading