From 869855c6b5edb46a5006a9e607417373cae8a74e Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Mon, 6 Nov 2023 02:31:44 +0000 Subject: [PATCH] CodeGen from PR 26480 in Azure/azure-rest-api-specs Merge 2c37e900164aa457e440b99bc41d81270455fcc3 into b13bd252f5a0ae3e870dcd5fb4dc5c1389a7a734 --- ...ourceManager.DataFactory.netstandard2.0.cs | 11 +++ .../FormatReadSettings.Serialization.cs | 3 +- .../Generated/Models/FormatReadSettings.cs | 2 +- .../Models/GetDatasetMetadataActivity.cs | 4 +- ...oogleAdWordsLinkedService.Serialization.cs | 62 +++++++++++++++- .../Models/GoogleAdWordsLinkedService.cs | 34 ++++++--- .../ParquetReadSettings.Serialization.cs | 74 +++++++++++++++++++ .../Generated/Models/ParquetReadSettings.cs | 43 +++++++++++ .../Models/ParquetSource.Serialization.cs | 17 ++++- .../src/Generated/Models/ParquetSource.cs | 6 +- .../Models/WebHookActivity.Serialization.cs | 17 ++++- .../src/Generated/Models/WebHookActivity.cs | 6 +- .../src/autorest.md | 2 +- 13 files changed, 262 insertions(+), 19 deletions(-) create mode 100644 sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.Serialization.cs create mode 100644 sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.cs diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/api/Azure.ResourceManager.DataFactory.netstandard2.0.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/api/Azure.ResourceManager.DataFactory.netstandard2.0.cs index 2aaa00445ead5..3c50fd0375533 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/api/Azure.ResourceManager.DataFactory.netstandard2.0.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/api/Azure.ResourceManager.DataFactory.netstandard2.0.cs @@ -3627,8 +3627,12 @@ public GoogleAdWordsLinkedService() { } public Azure.Core.Expressions.DataFactory.DataFactorySecretBaseDefinition DeveloperToken { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement Email { get { throw null; } set { } } public string EncryptedCredential { get { throw null; } set { } } + public Azure.Core.Expressions.DataFactory.DataFactoryElement GoogleAdsApiVersion { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement KeyFilePath { get { throw null; } set { } } + public Azure.Core.Expressions.DataFactory.DataFactoryElement LoginCustomerId { get { throw null; } set { } } + public Azure.Core.Expressions.DataFactory.DataFactorySecretBaseDefinition PrivateKey { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactorySecretBaseDefinition RefreshToken { get { throw null; } set { } } + public Azure.Core.Expressions.DataFactory.DataFactoryElement SupportLegacyDataTypes { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement TrustedCertPath { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement UseSystemTrustStore { get { throw null; } set { } } } @@ -5376,6 +5380,11 @@ public ParquetDataset(Azure.Core.Expressions.DataFactory.DataFactoryLinkedServic public Azure.Core.Expressions.DataFactory.DataFactoryElement CompressionCodec { get { throw null; } set { } } public Azure.ResourceManager.DataFactory.Models.DatasetLocation DataLocation { get { throw null; } set { } } } + public partial class ParquetReadSettings : Azure.ResourceManager.DataFactory.Models.FormatReadSettings + { + public ParquetReadSettings() { } + public Azure.ResourceManager.DataFactory.Models.CompressionReadSettings CompressionProperties { get { throw null; } set { } } + } public partial class ParquetSink : Azure.ResourceManager.DataFactory.Models.CopySink { public ParquetSink() { } @@ -5386,6 +5395,7 @@ public partial class ParquetSource : Azure.ResourceManager.DataFactory.Models.Co { public ParquetSource() { } public System.BinaryData AdditionalColumns { get { throw null; } set { } } + public Azure.ResourceManager.DataFactory.Models.ParquetReadSettings FormatSettings { get { throw null; } set { } } public Azure.ResourceManager.DataFactory.Models.StoreReadSettings StoreSettings { get { throw null; } set { } } } public partial class ParquetWriteSettings : Azure.ResourceManager.DataFactory.Models.FormatWriteSettings @@ -7554,6 +7564,7 @@ public WebHookActivity(string name, Azure.ResourceManager.DataFactory.Models.Web public Azure.Core.Expressions.DataFactory.DataFactoryElement Body { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement Headers { get { throw null; } set { } } public Azure.ResourceManager.DataFactory.Models.WebHookActivityMethod Method { get { throw null; } set { } } + public Azure.ResourceManager.DataFactory.Models.SecureInputOutputPolicy Policy { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement ReportStatusOnCallBack { get { throw null; } set { } } public string Timeout { get { throw null; } set { } } public Azure.Core.Expressions.DataFactory.DataFactoryElement Uri { get { throw null; } set { } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.Serialization.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.Serialization.cs index 380e0390a2102..d4e6f4ed74b7b 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.Serialization.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.Serialization.cs @@ -43,9 +43,10 @@ internal static FormatReadSettings DeserializeFormatReadSettings(JsonElement ele switch (discriminator.GetString()) { case "BinaryReadSettings": return BinaryReadSettings.DeserializeBinaryReadSettings(element); + case "DelimitedTextReadSettings": return DelimitedTextReadSettings.DeserializeDelimitedTextReadSettings(element); case "JsonReadSettings": return JsonReadSettings.DeserializeJsonReadSettings(element); case "XmlReadSettings": return XmlReadSettings.DeserializeXmlReadSettings(element); - case "DelimitedTextReadSettings": return DelimitedTextReadSettings.DeserializeDelimitedTextReadSettings(element); + case "ParquetReadSettings": return ParquetReadSettings.DeserializeParquetReadSettings(element); } } return UnknownFormatReadSettings.DeserializeUnknownFormatReadSettings(element); diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.cs index 338d55a3c0a2b..f06092aa383db 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/FormatReadSettings.cs @@ -14,7 +14,7 @@ namespace Azure.ResourceManager.DataFactory.Models /// /// Format read settings. /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. - /// The available derived classes include , , and . + /// The available derived classes include , , , and . /// public partial class FormatReadSettings { diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GetDatasetMetadataActivity.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GetDatasetMetadataActivity.cs index 45bacba96c6da..e249d9edb4124 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GetDatasetMetadataActivity.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GetDatasetMetadataActivity.cs @@ -50,7 +50,7 @@ public GetDatasetMetadataActivity(string name, DatasetReference dataset) : base( /// /// GetMetadata activity format settings. /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. - /// The available derived classes include , , and . + /// The available derived classes include , , , and . /// internal GetDatasetMetadataActivity(string name, string activityType, string description, PipelineActivityState? state, ActivityOnInactiveMarkAs? onInactiveMarkAs, IList dependsOn, IList userProperties, IDictionary additionalProperties, DataFactoryLinkedServiceReference linkedServiceName, PipelineActivityPolicy policy, DatasetReference dataset, IList fieldList, StoreReadSettings storeSettings, FormatReadSettings formatSettings) : base(name, activityType, description, state, onInactiveMarkAs, dependsOn, userProperties, additionalProperties, linkedServiceName, policy) { @@ -103,7 +103,7 @@ internal GetDatasetMetadataActivity(string name, string activityType, string des /// /// GetMetadata activity format settings. /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. - /// The available derived classes include , , and . + /// The available derived classes include , , , and . /// public FormatReadSettings FormatSettings { get; set; } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.Serialization.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.Serialization.cs index 7e655f605033e..69eb2b5baf658 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.Serialization.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.Serialization.cs @@ -127,6 +127,26 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) writer.WritePropertyName("useSystemTrustStore"u8); JsonSerializer.Serialize(writer, UseSystemTrustStore); } + if (Optional.IsDefined(PrivateKey)) + { + writer.WritePropertyName("privateKey"u8); + JsonSerializer.Serialize(writer, PrivateKey); + } + if (Optional.IsDefined(LoginCustomerId)) + { + writer.WritePropertyName("loginCustomerID"u8); + JsonSerializer.Serialize(writer, LoginCustomerId); + } + if (Optional.IsDefined(GoogleAdsApiVersion)) + { + writer.WritePropertyName("googleAdsApiVersion"u8); + JsonSerializer.Serialize(writer, GoogleAdsApiVersion); + } + if (Optional.IsDefined(SupportLegacyDataTypes)) + { + writer.WritePropertyName("supportLegacyDataTypes"u8); + JsonSerializer.Serialize(writer, SupportLegacyDataTypes); + } if (Optional.IsDefined(EncryptedCredential)) { writer.WritePropertyName("encryptedCredential"u8); @@ -170,6 +190,10 @@ internal static GoogleAdWordsLinkedService DeserializeGoogleAdWordsLinkedService Optional> keyFilePath = default; Optional> trustedCertPath = default; Optional> useSystemTrustStore = default; + Optional privateKey = default; + Optional> loginCustomerId = default; + Optional> googleAdsApiVersion = default; + Optional> supportLegacyDataTypes = default; Optional encryptedCredential = default; IDictionary additionalProperties = default; Dictionary additionalPropertiesDictionary = new Dictionary(); @@ -337,6 +361,42 @@ internal static GoogleAdWordsLinkedService DeserializeGoogleAdWordsLinkedService useSystemTrustStore = JsonSerializer.Deserialize>(property0.Value.GetRawText()); continue; } + if (property0.NameEquals("privateKey"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + privateKey = JsonSerializer.Deserialize(property0.Value.GetRawText()); + continue; + } + if (property0.NameEquals("loginCustomerID"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + loginCustomerId = JsonSerializer.Deserialize>(property0.Value.GetRawText()); + continue; + } + if (property0.NameEquals("googleAdsApiVersion"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + googleAdsApiVersion = JsonSerializer.Deserialize>(property0.Value.GetRawText()); + continue; + } + if (property0.NameEquals("supportLegacyDataTypes"u8)) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + supportLegacyDataTypes = JsonSerializer.Deserialize>(property0.Value.GetRawText()); + continue; + } if (property0.NameEquals("encryptedCredential"u8)) { encryptedCredential = property0.Value.GetString(); @@ -348,7 +408,7 @@ internal static GoogleAdWordsLinkedService DeserializeGoogleAdWordsLinkedService additionalPropertiesDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } additionalProperties = additionalPropertiesDictionary; - return new GoogleAdWordsLinkedService(type, connectVia.Value, description.Value, Optional.ToDictionary(parameters), Optional.ToList(annotations), additionalProperties, connectionProperties.Value, clientCustomerId.Value, developerToken, Optional.ToNullable(authenticationType), refreshToken, clientId.Value, clientSecret, email.Value, keyFilePath.Value, trustedCertPath.Value, useSystemTrustStore.Value, encryptedCredential.Value); + return new GoogleAdWordsLinkedService(type, connectVia.Value, description.Value, Optional.ToDictionary(parameters), Optional.ToList(annotations), additionalProperties, connectionProperties.Value, clientCustomerId.Value, developerToken, Optional.ToNullable(authenticationType), refreshToken, clientId.Value, clientSecret, email.Value, keyFilePath.Value, trustedCertPath.Value, useSystemTrustStore.Value, privateKey, loginCustomerId.Value, googleAdsApiVersion.Value, supportLegacyDataTypes.Value, encryptedCredential.Value); } } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.cs index b26bc13f6abaa..60c6a3157513d 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/GoogleAdWordsLinkedService.cs @@ -27,7 +27,7 @@ public GoogleAdWordsLinkedService() /// Parameters for linked service. /// List of tags that can be used for describing the linked service. /// Additional Properties. - /// Properties used to connect to GoogleAds. It is mutually exclusive with any other properties in the linked service. Type: object. + /// (Deprecated) Properties used to connect to GoogleAds. It is mutually exclusive with any other properties in the linked service. Type: object. /// The Client customer ID of the AdWords account that you want to fetch report data for. Type: string (or Expression with resultType string). /// The developer token associated with the manager account that you use to grant access to the AdWords API. /// The OAuth 2.0 authentication mechanism used for authentication. ServiceAuthentication can only be used on self-hosted IR. @@ -35,11 +35,15 @@ public GoogleAdWordsLinkedService() /// The client id of the google application used to acquire the refresh token. Type: string (or Expression with resultType string). /// The client secret of the google application used to acquire the refresh token. /// The service account email ID that is used for ServiceAuthentication and can only be used on self-hosted IR. Type: string (or Expression with resultType string). - /// The full path to the .p12 key file that is used to authenticate the service account email address and can only be used on self-hosted IR. Type: string (or Expression with resultType string). - /// The full path of the .pem file containing trusted CA certificates for verifying the server when connecting over SSL. This property can only be set when using SSL on self-hosted IR. The default value is the cacerts.pem file installed with the IR. Type: string (or Expression with resultType string). - /// Specifies whether to use a CA certificate from the system trust store or from a specified PEM file. The default value is false. Type: boolean (or Expression with resultType boolean). + /// (Deprecated) The full path to the .p12 key file that is used to authenticate the service account email address and can only be used on self-hosted IR. Type: string (or Expression with resultType string). + /// (Deprecated) The full path of the .pem file containing trusted CA certificates for verifying the server when connecting over SSL. This property can only be set when using SSL on self-hosted IR. The default value is the cacerts.pem file installed with the IR. Type: string (or Expression with resultType string). + /// (Deprecated) Specifies whether to use a CA certificate from the system trust store or from a specified PEM file. The default value is false. Type: boolean (or Expression with resultType boolean). + /// The private key that is used to authenticate the service account email address and can only be used on self-hosted IR. + /// The customer ID of the Google Ads Manager account through which you want to fetch report data of specific Customer. Type: string (or Expression with resultType string). + /// The Google Ads API major version such as v14. The supported major versions could be found on https://developers.google.com/google-ads/api/docs/release-notes. Type: string (or Expression with resultType string). + /// Specifies whether to use the legacy data type mappings, which maps float, int32 and int64 from Google to string. Do not set this to true unless you want to keep backward compatibility with legacy driver's data type mappings. Type: boolean (or Expression with resultType boolean). /// The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string. - internal GoogleAdWordsLinkedService(string linkedServiceType, IntegrationRuntimeReference connectVia, string description, IDictionary parameters, IList annotations, IDictionary additionalProperties, BinaryData connectionProperties, DataFactoryElement clientCustomerId, DataFactorySecretBaseDefinition developerToken, GoogleAdWordsAuthenticationType? authenticationType, DataFactorySecretBaseDefinition refreshToken, DataFactoryElement clientId, DataFactorySecretBaseDefinition clientSecret, DataFactoryElement email, DataFactoryElement keyFilePath, DataFactoryElement trustedCertPath, DataFactoryElement useSystemTrustStore, string encryptedCredential) : base(linkedServiceType, connectVia, description, parameters, annotations, additionalProperties) + internal GoogleAdWordsLinkedService(string linkedServiceType, IntegrationRuntimeReference connectVia, string description, IDictionary parameters, IList annotations, IDictionary additionalProperties, BinaryData connectionProperties, DataFactoryElement clientCustomerId, DataFactorySecretBaseDefinition developerToken, GoogleAdWordsAuthenticationType? authenticationType, DataFactorySecretBaseDefinition refreshToken, DataFactoryElement clientId, DataFactorySecretBaseDefinition clientSecret, DataFactoryElement email, DataFactoryElement keyFilePath, DataFactoryElement trustedCertPath, DataFactoryElement useSystemTrustStore, DataFactorySecretBaseDefinition privateKey, DataFactoryElement loginCustomerId, DataFactoryElement googleAdsApiVersion, DataFactoryElement supportLegacyDataTypes, string encryptedCredential) : base(linkedServiceType, connectVia, description, parameters, annotations, additionalProperties) { ConnectionProperties = connectionProperties; ClientCustomerId = clientCustomerId; @@ -52,12 +56,16 @@ internal GoogleAdWordsLinkedService(string linkedServiceType, IntegrationRuntime KeyFilePath = keyFilePath; TrustedCertPath = trustedCertPath; UseSystemTrustStore = useSystemTrustStore; + PrivateKey = privateKey; + LoginCustomerId = loginCustomerId; + GoogleAdsApiVersion = googleAdsApiVersion; + SupportLegacyDataTypes = supportLegacyDataTypes; EncryptedCredential = encryptedCredential; LinkedServiceType = linkedServiceType ?? "GoogleAdWords"; } /// - /// Properties used to connect to GoogleAds. It is mutually exclusive with any other properties in the linked service. Type: object. + /// (Deprecated) Properties used to connect to GoogleAds. It is mutually exclusive with any other properties in the linked service. Type: object. /// /// To assign an object to this property use . /// @@ -101,12 +109,20 @@ internal GoogleAdWordsLinkedService(string linkedServiceType, IntegrationRuntime public DataFactorySecretBaseDefinition ClientSecret { get; set; } /// The service account email ID that is used for ServiceAuthentication and can only be used on self-hosted IR. Type: string (or Expression with resultType string). public DataFactoryElement Email { get; set; } - /// The full path to the .p12 key file that is used to authenticate the service account email address and can only be used on self-hosted IR. Type: string (or Expression with resultType string). + /// (Deprecated) The full path to the .p12 key file that is used to authenticate the service account email address and can only be used on self-hosted IR. Type: string (or Expression with resultType string). public DataFactoryElement KeyFilePath { get; set; } - /// The full path of the .pem file containing trusted CA certificates for verifying the server when connecting over SSL. This property can only be set when using SSL on self-hosted IR. The default value is the cacerts.pem file installed with the IR. Type: string (or Expression with resultType string). + /// (Deprecated) The full path of the .pem file containing trusted CA certificates for verifying the server when connecting over SSL. This property can only be set when using SSL on self-hosted IR. The default value is the cacerts.pem file installed with the IR. Type: string (or Expression with resultType string). public DataFactoryElement TrustedCertPath { get; set; } - /// Specifies whether to use a CA certificate from the system trust store or from a specified PEM file. The default value is false. Type: boolean (or Expression with resultType boolean). + /// (Deprecated) Specifies whether to use a CA certificate from the system trust store or from a specified PEM file. The default value is false. Type: boolean (or Expression with resultType boolean). public DataFactoryElement UseSystemTrustStore { get; set; } + /// The private key that is used to authenticate the service account email address and can only be used on self-hosted IR. + public DataFactorySecretBaseDefinition PrivateKey { get; set; } + /// The customer ID of the Google Ads Manager account through which you want to fetch report data of specific Customer. Type: string (or Expression with resultType string). + public DataFactoryElement LoginCustomerId { get; set; } + /// The Google Ads API major version such as v14. The supported major versions could be found on https://developers.google.com/google-ads/api/docs/release-notes. Type: string (or Expression with resultType string). + public DataFactoryElement GoogleAdsApiVersion { get; set; } + /// Specifies whether to use the legacy data type mappings, which maps float, int32 and int64 from Google to string. Do not set this to true unless you want to keep backward compatibility with legacy driver's data type mappings. Type: boolean (or Expression with resultType boolean). + public DataFactoryElement SupportLegacyDataTypes { get; set; } /// The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string. public string EncryptedCredential { get; set; } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.Serialization.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.Serialization.cs new file mode 100644 index 0000000000000..6bd86225e8fff --- /dev/null +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.Serialization.cs @@ -0,0 +1,74 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.DataFactory.Models +{ + public partial class ParquetReadSettings : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(CompressionProperties)) + { + writer.WritePropertyName("compressionProperties"u8); + writer.WriteObjectValue(CompressionProperties); + } + writer.WritePropertyName("type"u8); + writer.WriteStringValue(FormatReadSettingsType); + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); +#if NET6_0_OR_GREATER + writer.WriteRawValue(item.Value); +#else + using (JsonDocument document = JsonDocument.Parse(item.Value)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + writer.WriteEndObject(); + } + + internal static ParquetReadSettings DeserializeParquetReadSettings(JsonElement element) + { + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Optional compressionProperties = default; + string type = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("compressionProperties"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + compressionProperties = CompressionReadSettings.DeserializeCompressionReadSettings(property.Value); + continue; + } + if (property.NameEquals("type"u8)) + { + type = property.Value.GetString(); + continue; + } + additionalPropertiesDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + additionalProperties = additionalPropertiesDictionary; + return new ParquetReadSettings(type, additionalProperties, compressionProperties.Value); + } + } +} diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.cs new file mode 100644 index 0000000000000..211be7e3b343b --- /dev/null +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetReadSettings.cs @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.DataFactory.Models +{ + /// Parquet read settings. + public partial class ParquetReadSettings : FormatReadSettings + { + /// Initializes a new instance of ParquetReadSettings. + public ParquetReadSettings() + { + FormatReadSettingsType = "ParquetReadSettings"; + } + + /// Initializes a new instance of ParquetReadSettings. + /// The read setting type. + /// Additional Properties. + /// + /// Compression settings. + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , and . + /// + internal ParquetReadSettings(string formatReadSettingsType, IDictionary additionalProperties, CompressionReadSettings compressionProperties) : base(formatReadSettingsType, additionalProperties) + { + CompressionProperties = compressionProperties; + FormatReadSettingsType = formatReadSettingsType ?? "ParquetReadSettings"; + } + + /// + /// Compression settings. + /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. + /// The available derived classes include , and . + /// + public CompressionReadSettings CompressionProperties { get; set; } + } +} diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.Serialization.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.Serialization.cs index e332c23b17fd5..da2fdcdf918a1 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.Serialization.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.Serialization.cs @@ -23,6 +23,11 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) writer.WritePropertyName("storeSettings"u8); writer.WriteObjectValue(StoreSettings); } + if (Optional.IsDefined(FormatSettings)) + { + writer.WritePropertyName("formatSettings"u8); + writer.WriteObjectValue(FormatSettings); + } if (Optional.IsDefined(AdditionalColumns)) { writer.WritePropertyName("additionalColumns"u8); @@ -79,6 +84,7 @@ internal static ParquetSource DeserializeParquetSource(JsonElement element) return null; } Optional storeSettings = default; + Optional formatSettings = default; Optional additionalColumns = default; string type = default; Optional> sourceRetryCount = default; @@ -98,6 +104,15 @@ internal static ParquetSource DeserializeParquetSource(JsonElement element) storeSettings = StoreReadSettings.DeserializeStoreReadSettings(property.Value); continue; } + if (property.NameEquals("formatSettings"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + formatSettings = ParquetReadSettings.DeserializeParquetReadSettings(property.Value); + continue; + } if (property.NameEquals("additionalColumns"u8)) { if (property.Value.ValueKind == JsonValueKind.Null) @@ -151,7 +166,7 @@ internal static ParquetSource DeserializeParquetSource(JsonElement element) additionalPropertiesDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } additionalProperties = additionalPropertiesDictionary; - return new ParquetSource(type, sourceRetryCount.Value, sourceRetryWait.Value, maxConcurrentConnections.Value, disableMetricsCollection.Value, additionalProperties, storeSettings.Value, additionalColumns.Value); + return new ParquetSource(type, sourceRetryCount.Value, sourceRetryWait.Value, maxConcurrentConnections.Value, disableMetricsCollection.Value, additionalProperties, storeSettings.Value, formatSettings.Value, additionalColumns.Value); } } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.cs index 16a22699a665b..50ee2c74efb6d 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/ParquetSource.cs @@ -32,10 +32,12 @@ public ParquetSource() /// Please note is the base class. According to the scenario, a derived class of the base class might need to be assigned here, or this property needs to be casted to one of the possible derived classes. /// The available derived classes include , , , , , , , , , , , and . /// + /// Parquet format settings. /// Specifies the additional columns to be added to source data. Type: array of objects(AdditionalColumns) (or Expression with resultType array of objects). - internal ParquetSource(string copySourceType, DataFactoryElement sourceRetryCount, DataFactoryElement sourceRetryWait, DataFactoryElement maxConcurrentConnections, DataFactoryElement disableMetricsCollection, IDictionary additionalProperties, StoreReadSettings storeSettings, BinaryData additionalColumns) : base(copySourceType, sourceRetryCount, sourceRetryWait, maxConcurrentConnections, disableMetricsCollection, additionalProperties) + internal ParquetSource(string copySourceType, DataFactoryElement sourceRetryCount, DataFactoryElement sourceRetryWait, DataFactoryElement maxConcurrentConnections, DataFactoryElement disableMetricsCollection, IDictionary additionalProperties, StoreReadSettings storeSettings, ParquetReadSettings formatSettings, BinaryData additionalColumns) : base(copySourceType, sourceRetryCount, sourceRetryWait, maxConcurrentConnections, disableMetricsCollection, additionalProperties) { StoreSettings = storeSettings; + FormatSettings = formatSettings; AdditionalColumns = additionalColumns; CopySourceType = copySourceType ?? "ParquetSource"; } @@ -46,6 +48,8 @@ internal ParquetSource(string copySourceType, DataFactoryElement sourceRetr /// The available derived classes include , , , , , , , , , , , and . /// public StoreReadSettings StoreSettings { get; set; } + /// Parquet format settings. + public ParquetReadSettings FormatSettings { get; set; } /// /// Specifies the additional columns to be added to source data. Type: array of objects(AdditionalColumns) (or Expression with resultType array of objects). /// diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.Serialization.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.Serialization.cs index 3baf20bfa3c29..561bd5789be6c 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.Serialization.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.Serialization.cs @@ -18,6 +18,11 @@ public partial class WebHookActivity : IUtf8JsonSerializable void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) { writer.WriteStartObject(); + if (Optional.IsDefined(Policy)) + { + writer.WritePropertyName("policy"u8); + writer.WriteObjectValue(Policy); + } writer.WritePropertyName("name"u8); writer.WriteStringValue(Name); writer.WritePropertyName("type"u8); @@ -110,6 +115,7 @@ internal static WebHookActivity DeserializeWebHookActivity(JsonElement element) { return null; } + Optional policy = default; string name = default; string type = default; Optional description = default; @@ -128,6 +134,15 @@ internal static WebHookActivity DeserializeWebHookActivity(JsonElement element) Dictionary additionalPropertiesDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { + if (property.NameEquals("policy"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + policy = SecureInputOutputPolicy.DeserializeSecureInputOutputPolicy(property.Value); + continue; + } if (property.NameEquals("name"u8)) { name = property.Value.GetString(); @@ -255,7 +270,7 @@ internal static WebHookActivity DeserializeWebHookActivity(JsonElement element) additionalPropertiesDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } additionalProperties = additionalPropertiesDictionary; - return new WebHookActivity(name, type, description.Value, Optional.ToNullable(state), Optional.ToNullable(onInactiveMarkAs), Optional.ToList(dependsOn), Optional.ToList(userProperties), additionalProperties, method, url, timeout.Value, headers.Value, body.Value, authentication.Value, reportStatusOnCallBack.Value); + return new WebHookActivity(name, type, description.Value, Optional.ToNullable(state), Optional.ToNullable(onInactiveMarkAs), Optional.ToList(dependsOn), Optional.ToList(userProperties), additionalProperties, policy.Value, method, url, timeout.Value, headers.Value, body.Value, authentication.Value, reportStatusOnCallBack.Value); } } } diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.cs b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.cs index 96156ed7c3e6e..20c394328f3a7 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.cs +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/Generated/Models/WebHookActivity.cs @@ -39,6 +39,7 @@ public WebHookActivity(string name, WebHookActivityMethod method, DataFactoryEle /// Activity depends on condition. /// Activity user properties. /// Additional Properties. + /// Activity policy. /// Rest API method for target endpoint. /// WebHook activity target endpoint and path. Type: string (or Expression with resultType string). /// The timeout within which the webhook should be called back. If there is no value specified, it defaults to 10 minutes. Type: string. Pattern: ((\d+)\.)?(\d\d):(60|([0-5][0-9])):(60|([0-5][0-9])). @@ -46,8 +47,9 @@ public WebHookActivity(string name, WebHookActivityMethod method, DataFactoryEle /// Represents the payload that will be sent to the endpoint. Required for POST/PUT method, not allowed for GET method Type: string (or Expression with resultType string). /// Authentication method used for calling the endpoint. /// When set to true, statusCode, output and error in callback request body will be consumed by activity. The activity can be marked as failed by setting statusCode >= 400 in callback request. Default is false. Type: boolean (or Expression with resultType boolean). - internal WebHookActivity(string name, string activityType, string description, PipelineActivityState? state, ActivityOnInactiveMarkAs? onInactiveMarkAs, IList dependsOn, IList userProperties, IDictionary additionalProperties, WebHookActivityMethod method, DataFactoryElement uri, string timeout, DataFactoryElement headers, DataFactoryElement body, WebActivityAuthentication authentication, DataFactoryElement reportStatusOnCallBack) : base(name, activityType, description, state, onInactiveMarkAs, dependsOn, userProperties, additionalProperties) + internal WebHookActivity(string name, string activityType, string description, PipelineActivityState? state, ActivityOnInactiveMarkAs? onInactiveMarkAs, IList dependsOn, IList userProperties, IDictionary additionalProperties, SecureInputOutputPolicy policy, WebHookActivityMethod method, DataFactoryElement uri, string timeout, DataFactoryElement headers, DataFactoryElement body, WebActivityAuthentication authentication, DataFactoryElement reportStatusOnCallBack) : base(name, activityType, description, state, onInactiveMarkAs, dependsOn, userProperties, additionalProperties) { + Policy = policy; Method = method; Uri = uri; Timeout = timeout; @@ -58,6 +60,8 @@ internal WebHookActivity(string name, string activityType, string description, P ActivityType = activityType ?? "WebHook"; } + /// Activity policy. + public SecureInputOutputPolicy Policy { get; set; } /// Rest API method for target endpoint. public WebHookActivityMethod Method { get; set; } /// WebHook activity target endpoint and path. Type: string (or Expression with resultType string). diff --git a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/autorest.md b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/autorest.md index 31a52edce5339..7988a199eebbf 100644 --- a/sdk/datafactory/Azure.ResourceManager.DataFactory/src/autorest.md +++ b/sdk/datafactory/Azure.ResourceManager.DataFactory/src/autorest.md @@ -9,7 +9,7 @@ generate-model-factory: false csharp: true library-name: DataFactory namespace: Azure.ResourceManager.DataFactory -require: https://github.com/Azure/azure-rest-api-specs/blob/24c9b5a8982cb081662b27ef8ab93da3389b0160/specification/datafactory/resource-manager/readme.md +require: /mnt/vss/_work/1/s/azure-rest-api-specs/specification/datafactory/resource-manager/readme.md output-folder: $(this-folder)/Generated clear-output-folder: true sample-gen: