diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/CHANGELOG.md b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/CHANGELOG.md index ec4e5490e279..b79dfb20fb90 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/CHANGELOG.md +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/CHANGELOG.md @@ -1,7 +1,7 @@ # Release History ## 1.0.0-preview.5 (Unreleased) - +- Supports List/Get Synapse resources through data plane APIs ## 1.0.0-preview.4 (2020-09-01) - Added test cases. diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/api/Azure.Analytics.Synapse.Artifacts.netstandard2.0.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/api/Azure.Analytics.Synapse.Artifacts.netstandard2.0.cs index 73cf2a7cbe53..37812d7ba033 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/api/Azure.Analytics.Synapse.Artifacts.netstandard2.0.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/api/Azure.Analytics.Synapse.Artifacts.netstandard2.0.cs @@ -8,6 +8,14 @@ public enum ServiceVersion V2019_06_01_preview = 1, } } + public partial class BigDataPoolsClient + { + protected BigDataPoolsClient() { } + public virtual Azure.Response Get(string bigDataPoolName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(string bigDataPoolName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response List(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ListAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } public partial class DataFlowClient { protected DataFlowClient() { } @@ -130,6 +138,14 @@ internal DatasetDeleteDatasetOperation() { } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } + public partial class IntegrationRuntimesClient + { + protected IntegrationRuntimesClient() { } + public virtual Azure.Response Get(string integrationRuntimeName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(string integrationRuntimeName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response List(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ListAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } public partial class LinkedServiceClient { protected LinkedServiceClient() { } @@ -329,6 +345,14 @@ internal SparkJobDefinitionExecuteSparkJobDefinitionOperation() { } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } + public partial class SqlPoolsClient + { + protected SqlPoolsClient() { } + public virtual Azure.Response Get(string sqlPoolName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(string sqlPoolName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response List(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ListAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } public partial class SqlScriptClient { protected SqlScriptClient() { } @@ -457,6 +481,12 @@ internal TriggerUnsubscribeTriggerFromEventsOperation() { } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } + public partial class WorkspaceClient + { + protected WorkspaceClient() { } + public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } } namespace Azure.Analytics.Synapse.Artifacts.Models { @@ -645,6 +675,19 @@ public AppendVariableActivity(string name) : base (default(string)) { } public object Value { get { throw null; } set { } } public string VariableName { get { throw null; } set { } } } + public partial class AutoPauseProperties + { + public AutoPauseProperties() { } + public int? DelayInMinutes { get { throw null; } set { } } + public bool? Enabled { get { throw null; } set { } } + } + public partial class AutoScaleProperties + { + public AutoScaleProperties() { } + public bool? Enabled { get { throw null; } set { } } + public int? MaxNodeCount { get { throw null; } set { } } + public int? MinNodeCount { get { throw null; } set { } } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct AvroCompressionCodec : System.IEquatable { @@ -881,6 +924,11 @@ public partial class AzureDataLakeStoreWriteSettings : Azure.Analytics.Synapse.A { public AzureDataLakeStoreWriteSettings() { } } + public partial class AzureEntityResource : Azure.Analytics.Synapse.Artifacts.Models.Resource + { + public AzureEntityResource() { } + public string Etag { get { throw null; } } + } public partial class AzureFileStorageLinkedService : Azure.Analytics.Synapse.Artifacts.Models.LinkedService { public AzureFileStorageLinkedService(object host) { } @@ -1236,6 +1284,29 @@ public BigDataPoolReference(Azure.Analytics.Synapse.Artifacts.Models.BigDataPool public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.BigDataPoolReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.BigDataPoolReferenceType right) { throw null; } public override string ToString() { throw null; } } + public partial class BigDataPoolResourceInfo : Azure.Analytics.Synapse.Artifacts.Models.TrackedResource + { + public BigDataPoolResourceInfo(string location) : base (default(string)) { } + public Azure.Analytics.Synapse.Artifacts.Models.AutoPauseProperties AutoPause { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.AutoScaleProperties AutoScale { get { throw null; } set { } } + public System.DateTimeOffset? CreationDate { get { throw null; } set { } } + public string DefaultSparkLogFolder { get { throw null; } set { } } + public bool? IsComputeIsolationEnabled { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.LibraryRequirements LibraryRequirements { get { throw null; } set { } } + public int? NodeCount { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.NodeSize? NodeSize { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily? NodeSizeFamily { get { throw null; } set { } } + public string ProvisioningState { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.LibraryRequirements SparkConfigProperties { get { throw null; } set { } } + public string SparkEventsFolder { get { throw null; } set { } } + public string SparkVersion { get { throw null; } set { } } + } + public partial class BigDataPoolResourceInfoListResult + { + internal BigDataPoolResourceInfoListResult() { } + public string NextLink { get { throw null; } } + public System.Collections.Generic.IReadOnlyList Value { get { throw null; } } + } public partial class BinaryDataset : Azure.Analytics.Synapse.Artifacts.Models.Dataset { public BinaryDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference linkedServiceName) : base (default(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference)) { } @@ -1612,6 +1683,10 @@ public partial class CustomDataSourceLinkedService : Azure.Analytics.Synapse.Art public CustomDataSourceLinkedService(object typeProperties) { } public object TypeProperties { get { throw null; } set { } } } + public partial class CustomSetupBase + { + public CustomSetupBase() { } + } public partial class DatabricksNotebookActivity : Azure.Analytics.Synapse.Artifacts.Models.ExecutionActivity { public DatabricksNotebookActivity(string name, object notebookPath) : base (default(string)) { } @@ -1783,7 +1858,7 @@ public void Add(string key, object value) { } public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.DataFlowReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.DataFlowReferenceType right) { throw null; } public override string ToString() { throw null; } } - public partial class DataFlowResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class DataFlowResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public DataFlowResource(Azure.Analytics.Synapse.Artifacts.Models.DataFlow properties) { } public Azure.Analytics.Synapse.Artifacts.Models.DataFlow Properties { get { throw null; } set { } } @@ -1837,6 +1912,12 @@ public DataLakeAnalyticsUsqlActivity(string name, object scriptPath, Azure.Analy public Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference ScriptLinkedService { get { throw null; } set { } } public object ScriptPath { get { throw null; } set { } } } + public partial class DataLakeStorageAccountDetails + { + public DataLakeStorageAccountDetails() { } + public string AccountUrl { get { throw null; } set { } } + public string Filesystem { get { throw null; } set { } } + } public partial class Dataset : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable { public Dataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference linkedServiceName) { } @@ -1978,7 +2059,7 @@ public DatasetReference(Azure.Analytics.Synapse.Artifacts.Models.DatasetReferenc public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.DatasetReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.DatasetReferenceType right) { throw null; } public override string ToString() { throw null; } } - public partial class DatasetResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class DatasetResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public DatasetResource(Azure.Analytics.Synapse.Artifacts.Models.Dataset properties) { } public Azure.Analytics.Synapse.Artifacts.Models.Dataset Properties { get { throw null; } set { } } @@ -1998,16 +2079,6 @@ public enum DayOfWeek Friday = 5, Saturday = 6, } - public enum DaysOfWeek - { - Sunday = 0, - Monday = 1, - Tuesday = 2, - Wednesday = 3, - Thursday = 4, - Friday = 5, - Saturday = 6, - } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct Db2AuthenticationType : System.IEquatable { @@ -2382,6 +2453,12 @@ public partial class EloquaSource : Azure.Analytics.Synapse.Artifacts.Models.Tab public EloquaSource() { } public object Query { get { throw null; } set { } } } + public partial class EntityReference + { + public EntityReference() { } + public string ReferenceName { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType? Type { get { throw null; } set { } } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct EventSubscriptionStatus : System.IEquatable { @@ -3204,6 +3281,149 @@ public partial class InformixTableDataset : Azure.Analytics.Synapse.Artifacts.Mo public InformixTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference linkedServiceName) : base (default(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference)) { } public object TableName { get { throw null; } set { } } } + public partial class IntegrationRuntime : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntime() { } + public string Description { get { throw null; } set { } } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } + public partial class IntegrationRuntimeComputeProperties : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntimeComputeProperties() { } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeDataFlowProperties DataFlowProperties { get { throw null; } set { } } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + public string Location { get { throw null; } set { } } + public int? MaxParallelExecutionsPerNode { get { throw null; } set { } } + public string NodeSize { get { throw null; } set { } } + public int? NumberOfNodes { get { throw null; } set { } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeVNetProperties VNetProperties { get { throw null; } set { } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } + public partial class IntegrationRuntimeCustomSetupScriptProperties + { + public IntegrationRuntimeCustomSetupScriptProperties() { } + public string BlobContainerUri { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.SecureString SasToken { get { throw null; } set { } } + } + public partial class IntegrationRuntimeDataFlowProperties : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntimeDataFlowProperties() { } + public Azure.Analytics.Synapse.Artifacts.Models.DataFlowComputeType? ComputeType { get { throw null; } set { } } + public int? CoreCount { get { throw null; } set { } } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public int? TimeToLive { get { throw null; } set { } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } + public partial class IntegrationRuntimeDataProxyProperties + { + public IntegrationRuntimeDataProxyProperties() { } + public Azure.Analytics.Synapse.Artifacts.Models.EntityReference ConnectVia { get { throw null; } set { } } + public string Path { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.EntityReference StagingLinkedService { get { throw null; } set { } } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeEdition : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeEdition(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition Enterprise { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition Standard { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition right) { throw null; } + public override string ToString() { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeEntityReferenceType : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeEntityReferenceType(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType IntegrationRuntimeReference { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType LinkedServiceReference { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEntityReferenceType right) { throw null; } + public override string ToString() { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeLicenseType : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeLicenseType(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType BasePrice { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType LicenseIncluded { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType right) { throw null; } + public override string ToString() { throw null; } + } + public partial class IntegrationRuntimeListResponse + { + internal IntegrationRuntimeListResponse() { } + public string NextLink { get { throw null; } } + public System.Collections.Generic.IReadOnlyList Value { get { throw null; } } + } public partial class IntegrationRuntimeReference { public IntegrationRuntimeReference(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeReferenceType type, string referenceName) { } @@ -3228,6 +3448,148 @@ public IntegrationRuntimeReference(Azure.Analytics.Synapse.Artifacts.Models.Inte public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeReferenceType right) { throw null; } public override string ToString() { throw null; } } + public partial class IntegrationRuntimeResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource + { + public IntegrationRuntimeResource(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntime properties) { } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntime Properties { get { throw null; } set { } } + } + public partial class IntegrationRuntimeSsisCatalogInfo : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntimeSsisCatalogInfo() { } + public Azure.Analytics.Synapse.Artifacts.Models.SecureString CatalogAdminPassword { get { throw null; } set { } } + public string CatalogAdminUserName { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier? CatalogPricingTier { get { throw null; } set { } } + public string CatalogServerEndpoint { get { throw null; } set { } } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeSsisCatalogPricingTier : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeSsisCatalogPricingTier(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier Basic { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier Premium { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier PremiumRS { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier Standard { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogPricingTier right) { throw null; } + public override string ToString() { throw null; } + } + public partial class IntegrationRuntimeSsisProperties : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntimeSsisProperties() { } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisCatalogInfo CatalogInfo { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeCustomSetupScriptProperties CustomSetupScriptProperties { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeDataProxyProperties DataProxyProperties { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeEdition? Edition { get { throw null; } set { } } + public System.Collections.Generic.IList ExpressCustomSetupProperties { get { throw null; } } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeLicenseType? LicenseType { get { throw null; } set { } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeState : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeState(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState AccessDenied { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Initial { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Limited { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState NeedRegistration { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Offline { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Online { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Started { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Starting { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Stopped { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState Stopping { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState right) { throw null; } + public override string ToString() { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct IntegrationRuntimeType : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public IntegrationRuntimeType(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType Managed { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType SelfHosted { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType left, Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeType right) { throw null; } + public override string ToString() { throw null; } + } + public partial class IntegrationRuntimeVNetProperties : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + { + public IntegrationRuntimeVNetProperties() { } + public object this[string key] { get { throw null; } set { } } + public System.Collections.Generic.ICollection Keys { get { throw null; } } + public System.Collections.Generic.IList PublicIPs { get { throw null; } } + public string Subnet { get { throw null; } set { } } + int System.Collections.Generic.ICollection>.Count { get { throw null; } } + bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } + public System.Collections.Generic.ICollection Values { get { throw null; } } + public string VNetId { get { throw null; } set { } } + public void Add(string key, object value) { } + public bool ContainsKey(string key) { throw null; } + public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } + public bool Remove(string key) { throw null; } + void System.Collections.Generic.ICollection>.Add(System.Collections.Generic.KeyValuePair value) { } + void System.Collections.Generic.ICollection>.Clear() { } + bool System.Collections.Generic.ICollection>.Contains(System.Collections.Generic.KeyValuePair value) { throw null; } + void System.Collections.Generic.ICollection>.CopyTo(System.Collections.Generic.KeyValuePair[] destination, int offset) { } + bool System.Collections.Generic.ICollection>.Remove(System.Collections.Generic.KeyValuePair value) { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + public bool TryGetValue(string key, out object value) { throw null; } + } public partial class JiraLinkedService : Azure.Analytics.Synapse.Artifacts.Models.LinkedService { public JiraLinkedService(object host, object username) { } @@ -3291,6 +3653,27 @@ public partial class JsonWriteSettings : Azure.Analytics.Synapse.Artifacts.Model public JsonWriteSettings() { } public Azure.Analytics.Synapse.Artifacts.Models.JsonWriteFilePattern? FilePattern { get { throw null; } set { } } } + public partial class LibraryRequirements + { + public LibraryRequirements() { } + public string Content { get { throw null; } set { } } + public string Filename { get { throw null; } set { } } + public System.DateTimeOffset? Time { get { throw null; } } + } + public partial class LinkedIntegrationRuntimeKeyAuthorization : Azure.Analytics.Synapse.Artifacts.Models.LinkedIntegrationRuntimeType + { + public LinkedIntegrationRuntimeKeyAuthorization(Azure.Analytics.Synapse.Artifacts.Models.SecureString key) { } + public Azure.Analytics.Synapse.Artifacts.Models.SecureString Key { get { throw null; } set { } } + } + public partial class LinkedIntegrationRuntimeRbacAuthorization : Azure.Analytics.Synapse.Artifacts.Models.LinkedIntegrationRuntimeType + { + public LinkedIntegrationRuntimeRbacAuthorization(string resourceId) { } + public string ResourceId { get { throw null; } set { } } + } + public partial class LinkedIntegrationRuntimeType + { + public LinkedIntegrationRuntimeType() { } + } public partial class LinkedService : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable { public LinkedService() { } @@ -3333,7 +3716,7 @@ public LinkedServiceReference(Azure.Analytics.Synapse.Artifacts.LinkedServiceRef public string ReferenceName { get { throw null; } set { } } public Azure.Analytics.Synapse.Artifacts.LinkedServiceReferenceType Type { get { throw null; } set { } } } - public partial class LinkedServiceResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class LinkedServiceResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public LinkedServiceResource(Azure.Analytics.Synapse.Artifacts.Models.LinkedService properties) { } public Azure.Analytics.Synapse.Artifacts.Models.LinkedService Properties { get { throw null; } set { } } @@ -3387,6 +3770,27 @@ public partial class MagentoSource : Azure.Analytics.Synapse.Artifacts.Models.Ta public MagentoSource() { } public object Query { get { throw null; } set { } } } + public partial class ManagedIdentity + { + public ManagedIdentity() { } + public string PrincipalId { get { throw null; } } + public string TenantId { get { throw null; } } + public Azure.Analytics.Synapse.Artifacts.Models.ResourceIdentityType? Type { get { throw null; } set { } } + } + public partial class ManagedIntegrationRuntime : Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntime + { + public ManagedIntegrationRuntime() { } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeComputeProperties ComputeProperties { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeSsisProperties SsisProperties { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntimeState? State { get { throw null; } } + } + public partial class ManagedVirtualNetworkSettings + { + public ManagedVirtualNetworkSettings() { } + public System.Collections.Generic.IList AllowedAadTenantIdsForLinking { get { throw null; } } + public bool? LinkedAccessCheckOnTargetResource { get { throw null; } set { } } + public bool? PreventDataExfiltration { get { throw null; } set { } } + } public partial class MappingDataFlow : Azure.Analytics.Synapse.Artifacts.Models.DataFlow { public MappingDataFlow() { } @@ -3612,6 +4016,46 @@ public NetezzaTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServic public object Table { get { throw null; } set { } } public object TableName { get { throw null; } set { } } } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct NodeSize : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public NodeSize(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize Large { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize Medium { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize None { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize Small { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize XLarge { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSize XXLarge { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.NodeSize other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.NodeSize left, Azure.Analytics.Synapse.Artifacts.Models.NodeSize right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.NodeSize (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.NodeSize left, Azure.Analytics.Synapse.Artifacts.Models.NodeSize right) { throw null; } + public override string ToString() { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct NodeSizeFamily : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public NodeSizeFamily(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily MemoryOptimized { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily None { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily left, Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily left, Azure.Analytics.Synapse.Artifacts.Models.NodeSizeFamily right) { throw null; } + public override string ToString() { throw null; } + } public partial class Notebook : System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable { public Notebook(Azure.Analytics.Synapse.Artifacts.Models.NotebookMetadata metadata, int nbformat, int nbformatMinor, System.Collections.Generic.IEnumerable cells) { } @@ -3763,7 +4207,7 @@ public void Add(string key, object value) { } public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.NotebookReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.NotebookReferenceType right) { throw null; } public override string ToString() { throw null; } } - public partial class NotebookResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class NotebookResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public NotebookResource(Azure.Analytics.Synapse.Artifacts.Models.Notebook properties) { } public Azure.Analytics.Synapse.Artifacts.Models.Notebook Properties { get { throw null; } set { } } @@ -4170,7 +4614,7 @@ public PipelineReference(Azure.Analytics.Synapse.Artifacts.Models.PipelineRefere public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.PipelineReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.PipelineReferenceType right) { throw null; } public override string ToString() { throw null; } } - public partial class PipelineResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource, System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable + public partial class PipelineResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource, System.Collections.Generic.ICollection>, System.Collections.Generic.IDictionary, System.Collections.Generic.IEnumerable>, System.Collections.IEnumerable { public PipelineResource() { } public System.Collections.Generic.IList Activities { get { throw null; } } @@ -4367,6 +4811,49 @@ public partial class PrestoSource : Azure.Analytics.Synapse.Artifacts.Models.Tab public PrestoSource() { } public object Query { get { throw null; } set { } } } + public partial class PrivateEndpoint + { + public PrivateEndpoint() { } + public string Id { get { throw null; } } + } + public partial class PrivateEndpointConnection : Azure.Analytics.Synapse.Artifacts.Models.Resource + { + public PrivateEndpointConnection() { } + public Azure.Analytics.Synapse.Artifacts.Models.PrivateEndpoint PrivateEndpoint { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionState PrivateLinkServiceConnectionState { get { throw null; } set { } } + public string ProvisioningState { get { throw null; } } + } + public partial class PrivateLinkServiceConnectionState + { + public PrivateLinkServiceConnectionState() { } + public string ActionsRequired { get { throw null; } } + public string Description { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus? Status { get { throw null; } set { } } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct PrivateLinkServiceConnectionStateStatus : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public PrivateLinkServiceConnectionStateStatus(string value) { throw null; } + public static Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus Approved { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus Disconnected { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus Pending { get { throw null; } } + public static Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus Rejected { get { throw null; } } + public bool Equals(Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus left, Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus right) { throw null; } + public static implicit operator Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus (string value) { throw null; } + public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus left, Azure.Analytics.Synapse.Artifacts.Models.PrivateLinkServiceConnectionStateStatus right) { throw null; } + public override string ToString() { throw null; } + } + public partial class ProxyResource : Azure.Analytics.Synapse.Artifacts.Models.Resource + { + public ProxyResource() { } + } public partial class QueryDataFlowDebugSessionsResponse { internal QueryDataFlowDebugSessionsResponse() { } @@ -4430,7 +4917,7 @@ public RecurrenceSchedule() { } int System.Collections.Generic.ICollection>.Count { get { throw null; } } bool System.Collections.Generic.ICollection>.IsReadOnly { get { throw null; } } public System.Collections.Generic.ICollection Values { get { throw null; } } - public System.Collections.Generic.IList WeekDays { get { throw null; } } + public System.Collections.Generic.IList WeekDays { get { throw null; } } public void Add(string key, object value) { } public bool ContainsKey(string key) { throw null; } public System.Collections.Generic.IEnumerator> GetEnumerator() { throw null; } @@ -4503,7 +4990,7 @@ public partial class RelationalTableDataset : Azure.Analytics.Synapse.Artifacts. public RelationalTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference linkedServiceName) : base (default(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceReference)) { } public object TableName { get { throw null; } set { } } } - public partial class RerunTriggerResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class RerunTriggerResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public RerunTriggerResource(Azure.Analytics.Synapse.Artifacts.Models.RerunTumblingWindowTrigger properties) { } public Azure.Analytics.Synapse.Artifacts.Models.RerunTumblingWindowTrigger Properties { get { throw null; } set { } } @@ -4516,6 +5003,18 @@ public RerunTumblingWindowTrigger(System.DateTimeOffset requestedStartTime, Syst public System.DateTimeOffset RequestedEndTime { get { throw null; } set { } } public System.DateTimeOffset RequestedStartTime { get { throw null; } set { } } } + public partial class Resource + { + public Resource() { } + public string Id { get { throw null; } } + public string Name { get { throw null; } } + public string Type { get { throw null; } } + } + public enum ResourceIdentityType + { + None = 0, + SystemAssigned = 1, + } public partial class ResponsysLinkedService : Azure.Analytics.Synapse.Artifacts.Models.LinkedService { public ResponsysLinkedService(object endpoint, object clientId) { } @@ -5128,6 +5627,11 @@ public SelfDependencyTumblingWindowTriggerReference(string offset) { } public string Offset { get { throw null; } set { } } public string Size { get { throw null; } set { } } } + public partial class SelfHostedIntegrationRuntime : Azure.Analytics.Synapse.Artifacts.Models.IntegrationRuntime + { + public SelfHostedIntegrationRuntime() { } + public Azure.Analytics.Synapse.Artifacts.Models.LinkedIntegrationRuntimeType LinkedInfo { get { throw null; } set { } } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct ServiceNowAuthenticationType : System.IEquatable { @@ -5247,6 +5751,13 @@ public partial class ShopifySource : Azure.Analytics.Synapse.Artifacts.Models.Ta public ShopifySource() { } public object Query { get { throw null; } set { } } } + public partial class Sku + { + public Sku() { } + public int? Capacity { get { throw null; } set { } } + public string Name { get { throw null; } set { } } + public string Tier { get { throw null; } set { } } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct SparkAuthenticationType : System.IEquatable { @@ -5367,7 +5878,7 @@ public void Add(string key, object value) { } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } public bool TryGetValue(string key, out object value) { throw null; } } - public partial class SparkJobDefinitionResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class SparkJobDefinitionResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public SparkJobDefinitionResource(Azure.Analytics.Synapse.Artifacts.Models.SparkJobDefinition properties) { } public Azure.Analytics.Synapse.Artifacts.Models.SparkJobDefinition Properties { get { throw null; } set { } } @@ -5633,6 +6144,26 @@ public SqlMISource() { } public object SqlReaderStoredProcedureName { get { throw null; } set { } } public System.Collections.Generic.IDictionary StoredProcedureParameters { get { throw null; } } } + public partial class SqlPool : Azure.Analytics.Synapse.Artifacts.Models.TrackedResource + { + public SqlPool(string location) : base (default(string)) { } + public string Collation { get { throw null; } set { } } + public string CreateMode { get { throw null; } set { } } + public System.DateTimeOffset? CreationDate { get { throw null; } set { } } + public long? MaxSizeBytes { get { throw null; } set { } } + public string ProvisioningState { get { throw null; } set { } } + public string RecoverableDatabaseId { get { throw null; } set { } } + public System.DateTimeOffset? RestorePointInTime { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.Sku Sku { get { throw null; } set { } } + public string SourceDatabaseId { get { throw null; } set { } } + public string Status { get { throw null; } set { } } + } + public partial class SqlPoolInfoListResult + { + internal SqlPoolInfoListResult() { } + public string NextLink { get { throw null; } } + public System.Collections.Generic.IReadOnlyList Value { get { throw null; } } + } public partial class SqlPoolReference { public SqlPoolReference(Azure.Analytics.Synapse.Artifacts.Models.SqlPoolReferenceType type, string referenceName) { } @@ -5730,7 +6261,7 @@ public void Add(string key, object value) { } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } public bool TryGetValue(string key, out object value) { throw null; } } - public partial class SqlScriptResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class SqlScriptResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public SqlScriptResource(Azure.Analytics.Synapse.Artifacts.Models.SqlScript properties) { } public Azure.Analytics.Synapse.Artifacts.Models.SqlScript Properties { get { throw null; } set { } } @@ -6021,13 +6552,9 @@ public void Add(string key, object value) { } System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } public bool TryGetValue(string key, out object value) { throw null; } } - public partial class SubResource + public partial class SubResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public SubResource() { } - public string Etag { get { throw null; } } - public string Id { get { throw null; } } - public string Name { get { throw null; } } - public string Type { get { throw null; } } } public partial class SubResourceDebugResource { @@ -6181,6 +6708,12 @@ public TeradataTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServi public object Database { get { throw null; } set { } } public object Table { get { throw null; } set { } } } + public partial class TrackedResource : Azure.Analytics.Synapse.Artifacts.Models.Resource + { + public TrackedResource(string location) { } + public string Location { get { throw null; } set { } } + public System.Collections.Generic.IDictionary Tags { get { throw null; } } + } public partial class Transformation { public Transformation(string name) { } @@ -6250,7 +6783,7 @@ public TriggerReference(Azure.Analytics.Synapse.Artifacts.Models.TriggerReferenc public static bool operator !=(Azure.Analytics.Synapse.Artifacts.Models.TriggerReferenceType left, Azure.Analytics.Synapse.Artifacts.Models.TriggerReferenceType right) { throw null; } public override string ToString() { throw null; } } - public partial class TriggerResource : Azure.Analytics.Synapse.Artifacts.Models.SubResource + public partial class TriggerResource : Azure.Analytics.Synapse.Artifacts.Models.AzureEntityResource { public TriggerResource(Azure.Analytics.Synapse.Artifacts.Models.Trigger properties) { } public Azure.Analytics.Synapse.Artifacts.Models.Trigger Properties { get { throw null; } set { } } @@ -6429,6 +6962,11 @@ public VerticaTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServic public object Table { get { throw null; } set { } } public object TableName { get { throw null; } set { } } } + public partial class VirtualNetworkProfile + { + public VirtualNetworkProfile() { } + public string ComputeSubnetId { get { throw null; } set { } } + } public partial class WaitActivity : Azure.Analytics.Synapse.Artifacts.Models.Activity { public WaitActivity(string name, int waitTimeInSeconds) : base (default(string)) { } @@ -6558,6 +7096,22 @@ public WebTableDataset(Azure.Analytics.Synapse.Artifacts.Models.LinkedServiceRef public object Index { get { throw null; } set { } } public object Path { get { throw null; } set { } } } + public partial class Workspace : Azure.Analytics.Synapse.Artifacts.Models.TrackedResource + { + public Workspace(string location) : base (default(string)) { } + public System.Collections.Generic.IDictionary ConnectivityEndpoints { get { throw null; } } + public Azure.Analytics.Synapse.Artifacts.Models.DataLakeStorageAccountDetails DefaultDataLakeStorage { get { throw null; } set { } } + public System.Collections.Generic.IReadOnlyDictionary ExtraProperties { get { throw null; } } + public Azure.Analytics.Synapse.Artifacts.Models.ManagedIdentity Identity { get { throw null; } set { } } + public string ManagedResourceGroupName { get { throw null; } set { } } + public string ManagedVirtualNetwork { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.ManagedVirtualNetworkSettings ManagedVirtualNetworkSettings { get { throw null; } set { } } + public System.Collections.Generic.IList PrivateEndpointConnections { get { throw null; } } + public string ProvisioningState { get { throw null; } } + public string SqlAdministratorLogin { get { throw null; } set { } } + public string SqlAdministratorLoginPassword { get { throw null; } set { } } + public Azure.Analytics.Synapse.Artifacts.Models.VirtualNetworkProfile VirtualNetworkProfile { get { throw null; } set { } } + } public partial class XeroLinkedService : Azure.Analytics.Synapse.Artifacts.Models.LinkedService { public XeroLinkedService(object host) { } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsClient.cs new file mode 100644 index 000000000000..637a19c0013f --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsClient.cs @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + /// The BigDataPools service client. + public partial class BigDataPoolsClient + { + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + internal BigDataPoolsRestClient RestClient { get; } + /// Initializes a new instance of BigDataPoolsClient for mocking. + protected BigDataPoolsClient() + { + } + /// Initializes a new instance of BigDataPoolsClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + internal BigDataPoolsClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + RestClient = new BigDataPoolsRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + /// List Big Data Pools. + /// The cancellation token to use. + public virtual async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("BigDataPoolsClient.List"); + scope.Start(); + try + { + return await RestClient.ListAsync(cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List Big Data Pools. + /// The cancellation token to use. + public virtual Response List(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("BigDataPoolsClient.List"); + scope.Start(); + try + { + return RestClient.List(cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Big Data Pool. + /// The Big Data Pool name. + /// The cancellation token to use. + public virtual async Task> GetAsync(string bigDataPoolName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("BigDataPoolsClient.Get"); + scope.Start(); + try + { + return await RestClient.GetAsync(bigDataPoolName, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Big Data Pool. + /// The Big Data Pool name. + /// The cancellation token to use. + public virtual Response Get(string bigDataPoolName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("BigDataPoolsClient.Get"); + scope.Start(); + try + { + return RestClient.Get(bigDataPoolName, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsRestClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsRestClient.cs new file mode 100644 index 000000000000..92d3fa171225 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/BigDataPoolsRestClient.cs @@ -0,0 +1,172 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + internal partial class BigDataPoolsRestClient + { + private string endpoint; + private string apiVersion; + private ClientDiagnostics _clientDiagnostics; + private HttpPipeline _pipeline; + + /// Initializes a new instance of BigDataPoolsRestClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + /// or is null. + public BigDataPoolsRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + if (endpoint == null) + { + throw new ArgumentNullException(nameof(endpoint)); + } + if (apiVersion == null) + { + throw new ArgumentNullException(nameof(apiVersion)); + } + + this.endpoint = endpoint; + this.apiVersion = apiVersion; + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + internal HttpMessage CreateListRequest() + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/bigDataPools", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// List Big Data Pools. + /// The cancellation token to use. + public async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + BigDataPoolResourceInfoListResult value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = BigDataPoolResourceInfoListResult.DeserializeBigDataPoolResourceInfoListResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// List Big Data Pools. + /// The cancellation token to use. + public Response List(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + BigDataPoolResourceInfoListResult value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = BigDataPoolResourceInfoListResult.DeserializeBigDataPoolResourceInfoListResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetRequest(string bigDataPoolName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/bigDataPools/", false); + uri.AppendPath(bigDataPoolName, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Get Big Data Pool. + /// The Big Data Pool name. + /// The cancellation token to use. + /// is null. + public async Task> GetAsync(string bigDataPoolName, CancellationToken cancellationToken = default) + { + if (bigDataPoolName == null) + { + throw new ArgumentNullException(nameof(bigDataPoolName)); + } + + using var message = CreateGetRequest(bigDataPoolName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + BigDataPoolResourceInfo value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = BigDataPoolResourceInfo.DeserializeBigDataPoolResourceInfo(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Get Big Data Pool. + /// The Big Data Pool name. + /// The cancellation token to use. + /// is null. + public Response Get(string bigDataPoolName, CancellationToken cancellationToken = default) + { + if (bigDataPoolName == null) + { + throw new ArgumentNullException(nameof(bigDataPoolName)); + } + + using var message = CreateGetRequest(bigDataPoolName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + BigDataPoolResourceInfo value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = BigDataPoolResourceInfo.DeserializeBigDataPoolResourceInfo(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesClient.cs new file mode 100644 index 000000000000..352fc4ec203c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesClient.cs @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + /// The IntegrationRuntimes service client. + public partial class IntegrationRuntimesClient + { + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + internal IntegrationRuntimesRestClient RestClient { get; } + /// Initializes a new instance of IntegrationRuntimesClient for mocking. + protected IntegrationRuntimesClient() + { + } + /// Initializes a new instance of IntegrationRuntimesClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + internal IntegrationRuntimesClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + RestClient = new IntegrationRuntimesRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + /// List Integration Runtimes. + /// The cancellation token to use. + public virtual async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("IntegrationRuntimesClient.List"); + scope.Start(); + try + { + return await RestClient.ListAsync(cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List Integration Runtimes. + /// The cancellation token to use. + public virtual Response List(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("IntegrationRuntimesClient.List"); + scope.Start(); + try + { + return RestClient.List(cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Integration Runtime. + /// The Integration Runtime name. + /// The cancellation token to use. + public virtual async Task> GetAsync(string integrationRuntimeName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("IntegrationRuntimesClient.Get"); + scope.Start(); + try + { + return await RestClient.GetAsync(integrationRuntimeName, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Integration Runtime. + /// The Integration Runtime name. + /// The cancellation token to use. + public virtual Response Get(string integrationRuntimeName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("IntegrationRuntimesClient.Get"); + scope.Start(); + try + { + return RestClient.Get(integrationRuntimeName, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesRestClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesRestClient.cs new file mode 100644 index 000000000000..111bce8c7c99 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/IntegrationRuntimesRestClient.cs @@ -0,0 +1,172 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + internal partial class IntegrationRuntimesRestClient + { + private string endpoint; + private string apiVersion; + private ClientDiagnostics _clientDiagnostics; + private HttpPipeline _pipeline; + + /// Initializes a new instance of IntegrationRuntimesRestClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + /// or is null. + public IntegrationRuntimesRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + if (endpoint == null) + { + throw new ArgumentNullException(nameof(endpoint)); + } + if (apiVersion == null) + { + throw new ArgumentNullException(nameof(apiVersion)); + } + + this.endpoint = endpoint; + this.apiVersion = apiVersion; + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + internal HttpMessage CreateListRequest() + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/integrationRuntimes", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// List Integration Runtimes. + /// The cancellation token to use. + public async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + IntegrationRuntimeListResponse value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = IntegrationRuntimeListResponse.DeserializeIntegrationRuntimeListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// List Integration Runtimes. + /// The cancellation token to use. + public Response List(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + IntegrationRuntimeListResponse value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = IntegrationRuntimeListResponse.DeserializeIntegrationRuntimeListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetRequest(string integrationRuntimeName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/integrationRuntimes/", false); + uri.AppendPath(integrationRuntimeName, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Get Integration Runtime. + /// The Integration Runtime name. + /// The cancellation token to use. + /// is null. + public async Task> GetAsync(string integrationRuntimeName, CancellationToken cancellationToken = default) + { + if (integrationRuntimeName == null) + { + throw new ArgumentNullException(nameof(integrationRuntimeName)); + } + + using var message = CreateGetRequest(integrationRuntimeName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + IntegrationRuntimeResource value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = IntegrationRuntimeResource.DeserializeIntegrationRuntimeResource(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Get Integration Runtime. + /// The Integration Runtime name. + /// The cancellation token to use. + /// is null. + public Response Get(string integrationRuntimeName, CancellationToken cancellationToken = default) + { + if (integrationRuntimeName == null) + { + throw new ArgumentNullException(nameof(integrationRuntimeName)); + } + + using var message = CreateGetRequest(integrationRuntimeName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + IntegrationRuntimeResource value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = IntegrationRuntimeResource.DeserializeIntegrationRuntimeResource(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.Serialization.cs new file mode 100644 index 000000000000..2214c2e0388a --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.Serialization.cs @@ -0,0 +1,61 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class AutoPauseProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(DelayInMinutes)) + { + writer.WritePropertyName("delayInMinutes"); + writer.WriteNumberValue(DelayInMinutes.Value); + } + if (Optional.IsDefined(Enabled)) + { + writer.WritePropertyName("enabled"); + writer.WriteBooleanValue(Enabled.Value); + } + writer.WriteEndObject(); + } + + internal static AutoPauseProperties DeserializeAutoPauseProperties(JsonElement element) + { + Optional delayInMinutes = default; + Optional enabled = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("delayInMinutes")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + delayInMinutes = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("enabled")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + enabled = property.Value.GetBoolean(); + continue; + } + } + return new AutoPauseProperties(Optional.ToNullable(delayInMinutes), Optional.ToNullable(enabled)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.cs new file mode 100644 index 000000000000..cd54124db83c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoPauseProperties.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Auto-pausing properties of a Big Data pool powered by Apache Spark. + public partial class AutoPauseProperties + { + /// Initializes a new instance of AutoPauseProperties. + public AutoPauseProperties() + { + } + + /// Initializes a new instance of AutoPauseProperties. + /// Number of minutes of idle time before the Big Data pool is automatically paused. + /// Whether auto-pausing is enabled for the Big Data pool. + internal AutoPauseProperties(int? delayInMinutes, bool? enabled) + { + DelayInMinutes = delayInMinutes; + Enabled = enabled; + } + + /// Number of minutes of idle time before the Big Data pool is automatically paused. + public int? DelayInMinutes { get; set; } + /// Whether auto-pausing is enabled for the Big Data pool. + public bool? Enabled { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.Serialization.cs new file mode 100644 index 000000000000..9923e4424c25 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.Serialization.cs @@ -0,0 +1,77 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class AutoScaleProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(MinNodeCount)) + { + writer.WritePropertyName("minNodeCount"); + writer.WriteNumberValue(MinNodeCount.Value); + } + if (Optional.IsDefined(Enabled)) + { + writer.WritePropertyName("enabled"); + writer.WriteBooleanValue(Enabled.Value); + } + if (Optional.IsDefined(MaxNodeCount)) + { + writer.WritePropertyName("maxNodeCount"); + writer.WriteNumberValue(MaxNodeCount.Value); + } + writer.WriteEndObject(); + } + + internal static AutoScaleProperties DeserializeAutoScaleProperties(JsonElement element) + { + Optional minNodeCount = default; + Optional enabled = default; + Optional maxNodeCount = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("minNodeCount")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + minNodeCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("enabled")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + enabled = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("maxNodeCount")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + maxNodeCount = property.Value.GetInt32(); + continue; + } + } + return new AutoScaleProperties(Optional.ToNullable(minNodeCount), Optional.ToNullable(enabled), Optional.ToNullable(maxNodeCount)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.cs new file mode 100644 index 000000000000..4470899fb5eb --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AutoScaleProperties.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Auto-scaling properties of a Big Data pool powered by Apache Spark. + public partial class AutoScaleProperties + { + /// Initializes a new instance of AutoScaleProperties. + public AutoScaleProperties() + { + } + + /// Initializes a new instance of AutoScaleProperties. + /// The minimum number of nodes the Big Data pool can support. + /// Whether automatic scaling is enabled for the Big Data pool. + /// The maximum number of nodes the Big Data pool can support. + internal AutoScaleProperties(int? minNodeCount, bool? enabled, int? maxNodeCount) + { + MinNodeCount = minNodeCount; + Enabled = enabled; + MaxNodeCount = maxNodeCount; + } + + /// The minimum number of nodes the Big Data pool can support. + public int? MinNodeCount { get; set; } + /// Whether automatic scaling is enabled for the Big Data pool. + public bool? Enabled { get; set; } + /// The maximum number of nodes the Big Data pool can support. + public int? MaxNodeCount { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.Serialization.cs new file mode 100644 index 000000000000..b2032cb1c389 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.Serialization.cs @@ -0,0 +1,53 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class AzureEntityResource : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WriteEndObject(); + } + + internal static AzureEntityResource DeserializeAzureEntityResource(JsonElement element) + { + Optional etag = default; + Optional id = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new AzureEntityResource(id.Value, name.Value, type.Value, etag.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.cs new file mode 100644 index 000000000000..b94cc916f2cb --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/AzureEntityResource.cs @@ -0,0 +1,31 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The resource model definition for a Azure Resource Manager resource with an etag. + public partial class AzureEntityResource : Resource + { + /// Initializes a new instance of AzureEntityResource. + public AzureEntityResource() + { + } + + /// Initializes a new instance of AzureEntityResource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. + internal AzureEntityResource(string id, string name, string type, string etag) : base(id, name, type) + { + Etag = etag; + } + + /// Resource Etag. + public string Etag { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.Serialization.cs new file mode 100644 index 000000000000..423c5a42338e --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.Serialization.cs @@ -0,0 +1,287 @@ +// 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.Analytics.Synapse.Artifacts.Models +{ + public partial class BigDataPoolResourceInfo : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Tags)) + { + writer.WritePropertyName("tags"); + writer.WriteStartObject(); + foreach (var item in Tags) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + writer.WritePropertyName("location"); + writer.WriteStringValue(Location); + writer.WritePropertyName("properties"); + writer.WriteStartObject(); + if (Optional.IsDefined(ProvisioningState)) + { + writer.WritePropertyName("provisioningState"); + writer.WriteStringValue(ProvisioningState); + } + if (Optional.IsDefined(AutoScale)) + { + writer.WritePropertyName("autoScale"); + writer.WriteObjectValue(AutoScale); + } + if (Optional.IsDefined(CreationDate)) + { + writer.WritePropertyName("creationDate"); + writer.WriteStringValue(CreationDate.Value, "O"); + } + if (Optional.IsDefined(AutoPause)) + { + writer.WritePropertyName("autoPause"); + writer.WriteObjectValue(AutoPause); + } + if (Optional.IsDefined(IsComputeIsolationEnabled)) + { + writer.WritePropertyName("isComputeIsolationEnabled"); + writer.WriteBooleanValue(IsComputeIsolationEnabled.Value); + } + if (Optional.IsDefined(SparkEventsFolder)) + { + writer.WritePropertyName("sparkEventsFolder"); + writer.WriteStringValue(SparkEventsFolder); + } + if (Optional.IsDefined(NodeCount)) + { + writer.WritePropertyName("nodeCount"); + writer.WriteNumberValue(NodeCount.Value); + } + if (Optional.IsDefined(LibraryRequirements)) + { + writer.WritePropertyName("libraryRequirements"); + writer.WriteObjectValue(LibraryRequirements); + } + if (Optional.IsDefined(SparkConfigProperties)) + { + writer.WritePropertyName("sparkConfigProperties"); + writer.WriteObjectValue(SparkConfigProperties); + } + if (Optional.IsDefined(SparkVersion)) + { + writer.WritePropertyName("sparkVersion"); + writer.WriteStringValue(SparkVersion); + } + if (Optional.IsDefined(DefaultSparkLogFolder)) + { + writer.WritePropertyName("defaultSparkLogFolder"); + writer.WriteStringValue(DefaultSparkLogFolder); + } + if (Optional.IsDefined(NodeSize)) + { + writer.WritePropertyName("nodeSize"); + writer.WriteStringValue(NodeSize.Value.ToString()); + } + if (Optional.IsDefined(NodeSizeFamily)) + { + writer.WritePropertyName("nodeSizeFamily"); + writer.WriteStringValue(NodeSizeFamily.Value.ToString()); + } + writer.WriteEndObject(); + writer.WriteEndObject(); + } + + internal static BigDataPoolResourceInfo DeserializeBigDataPoolResourceInfo(JsonElement element) + { + Optional> tags = default; + string location = default; + Optional id = default; + Optional name = default; + Optional type = default; + Optional provisioningState = default; + Optional autoScale = default; + Optional creationDate = default; + Optional autoPause = default; + Optional isComputeIsolationEnabled = default; + Optional sparkEventsFolder = default; + Optional nodeCount = default; + Optional libraryRequirements = default; + Optional sparkConfigProperties = default; + Optional sparkVersion = default; + Optional defaultSparkLogFolder = default; + Optional nodeSize = default; + Optional nodeSizeFamily = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("tags")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + tags = dictionary; + continue; + } + if (property.NameEquals("location")) + { + location = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + if (property.NameEquals("properties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("provisioningState")) + { + provisioningState = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("autoScale")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + autoScale = AutoScaleProperties.DeserializeAutoScaleProperties(property0.Value); + continue; + } + if (property0.NameEquals("creationDate")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + creationDate = property0.Value.GetDateTimeOffset("O"); + continue; + } + if (property0.NameEquals("autoPause")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + autoPause = AutoPauseProperties.DeserializeAutoPauseProperties(property0.Value); + continue; + } + if (property0.NameEquals("isComputeIsolationEnabled")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + isComputeIsolationEnabled = property0.Value.GetBoolean(); + continue; + } + if (property0.NameEquals("sparkEventsFolder")) + { + sparkEventsFolder = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("nodeCount")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + nodeCount = property0.Value.GetInt32(); + continue; + } + if (property0.NameEquals("libraryRequirements")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + libraryRequirements = LibraryRequirements.DeserializeLibraryRequirements(property0.Value); + continue; + } + if (property0.NameEquals("sparkConfigProperties")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + sparkConfigProperties = LibraryRequirements.DeserializeLibraryRequirements(property0.Value); + continue; + } + if (property0.NameEquals("sparkVersion")) + { + sparkVersion = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("defaultSparkLogFolder")) + { + defaultSparkLogFolder = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("nodeSize")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + nodeSize = new NodeSize(property0.Value.GetString()); + continue; + } + if (property0.NameEquals("nodeSizeFamily")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + nodeSizeFamily = new NodeSizeFamily(property0.Value.GetString()); + continue; + } + } + continue; + } + } + return new BigDataPoolResourceInfo(id.Value, name.Value, type.Value, Optional.ToDictionary(tags), location, provisioningState.Value, autoScale.Value, Optional.ToNullable(creationDate), autoPause.Value, Optional.ToNullable(isComputeIsolationEnabled), sparkEventsFolder.Value, Optional.ToNullable(nodeCount), libraryRequirements.Value, sparkConfigProperties.Value, sparkVersion.Value, defaultSparkLogFolder.Value, Optional.ToNullable(nodeSize), Optional.ToNullable(nodeSizeFamily)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.cs new file mode 100644 index 000000000000..d83054c4e43b --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfo.cs @@ -0,0 +1,90 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// A Big Data pool. + public partial class BigDataPoolResourceInfo : TrackedResource + { + /// Initializes a new instance of BigDataPoolResourceInfo. + /// The geo-location where the resource lives. + /// is null. + public BigDataPoolResourceInfo(string location) : base(location) + { + if (location == null) + { + throw new ArgumentNullException(nameof(location)); + } + } + + /// Initializes a new instance of BigDataPoolResourceInfo. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource tags. + /// The geo-location where the resource lives. + /// The state of the Big Data pool. + /// Auto-scaling properties. + /// The time when the Big Data pool was created. + /// Auto-pausing properties. + /// Whether compute isolation is required or not. + /// The Spark events folder. + /// The number of nodes in the Big Data pool. + /// Library version requirements. + /// Spark configuration file to specify additional properties. + /// The Apache Spark version. + /// The default folder where Spark logs will be written. + /// The level of compute power that each node in the Big Data pool has. + /// The kind of nodes that the Big Data pool provides. + internal BigDataPoolResourceInfo(string id, string name, string type, IDictionary tags, string location, string provisioningState, AutoScaleProperties autoScale, DateTimeOffset? creationDate, AutoPauseProperties autoPause, bool? isComputeIsolationEnabled, string sparkEventsFolder, int? nodeCount, LibraryRequirements libraryRequirements, LibraryRequirements sparkConfigProperties, string sparkVersion, string defaultSparkLogFolder, NodeSize? nodeSize, NodeSizeFamily? nodeSizeFamily) : base(id, name, type, tags, location) + { + ProvisioningState = provisioningState; + AutoScale = autoScale; + CreationDate = creationDate; + AutoPause = autoPause; + IsComputeIsolationEnabled = isComputeIsolationEnabled; + SparkEventsFolder = sparkEventsFolder; + NodeCount = nodeCount; + LibraryRequirements = libraryRequirements; + SparkConfigProperties = sparkConfigProperties; + SparkVersion = sparkVersion; + DefaultSparkLogFolder = defaultSparkLogFolder; + NodeSize = nodeSize; + NodeSizeFamily = nodeSizeFamily; + } + + /// The state of the Big Data pool. + public string ProvisioningState { get; set; } + /// Auto-scaling properties. + public AutoScaleProperties AutoScale { get; set; } + /// The time when the Big Data pool was created. + public DateTimeOffset? CreationDate { get; set; } + /// Auto-pausing properties. + public AutoPauseProperties AutoPause { get; set; } + /// Whether compute isolation is required or not. + public bool? IsComputeIsolationEnabled { get; set; } + /// The Spark events folder. + public string SparkEventsFolder { get; set; } + /// The number of nodes in the Big Data pool. + public int? NodeCount { get; set; } + /// Library version requirements. + public LibraryRequirements LibraryRequirements { get; set; } + /// Spark configuration file to specify additional properties. + public LibraryRequirements SparkConfigProperties { get; set; } + /// The Apache Spark version. + public string SparkVersion { get; set; } + /// The default folder where Spark logs will be written. + public string DefaultSparkLogFolder { get; set; } + /// The level of compute power that each node in the Big Data pool has. + public NodeSize? NodeSize { get; set; } + /// The kind of nodes that the Big Data pool provides. + public NodeSizeFamily? NodeSizeFamily { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.Serialization.cs new file mode 100644 index 000000000000..f7c86ca8fa3e --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.Serialization.cs @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class BigDataPoolResourceInfoListResult + { + internal static BigDataPoolResourceInfoListResult DeserializeBigDataPoolResourceInfoListResult(JsonElement element) + { + Optional nextLink = default; + Optional> value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("nextLink")) + { + nextLink = property.Value.GetString(); + continue; + } + if (property.NameEquals("value")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(BigDataPoolResourceInfo.DeserializeBigDataPoolResourceInfo(item)); + } + value = array; + continue; + } + } + return new BigDataPoolResourceInfoListResult(nextLink.Value, Optional.ToList(value)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.cs new file mode 100644 index 000000000000..31392e1d14bc --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/BigDataPoolResourceInfoListResult.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Collection of Big Data pool information. + public partial class BigDataPoolResourceInfoListResult + { + /// Initializes a new instance of BigDataPoolResourceInfoListResult. + internal BigDataPoolResourceInfoListResult() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of BigDataPoolResourceInfoListResult. + /// Link to the next page of results. + /// List of Big Data pools. + internal BigDataPoolResourceInfoListResult(string nextLink, IReadOnlyList value) + { + NextLink = nextLink; + Value = value; + } + + /// Link to the next page of results. + public string NextLink { get; } + /// List of Big Data pools. + public IReadOnlyList Value { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.Serialization.cs new file mode 100644 index 000000000000..53a4fb511fde --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.Serialization.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class CustomSetupBase : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("type"); + writer.WriteStringValue(Type); + writer.WriteEndObject(); + } + + internal static CustomSetupBase DeserializeCustomSetupBase(JsonElement element) + { + string type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new CustomSetupBase(type); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.cs new file mode 100644 index 000000000000..7e8a70aa283f --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/CustomSetupBase.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The base definition of the custom setup. + public partial class CustomSetupBase + { + /// Initializes a new instance of CustomSetupBase. + public CustomSetupBase() + { + } + + /// Initializes a new instance of CustomSetupBase. + /// The type of custom setup. + internal CustomSetupBase(string type) + { + Type = type; + } + + /// The type of custom setup. + internal string Type { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.Serialization.cs index 8454d844f185..40ca20d8e209 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static DataFlowResource DeserializeDataFlowResource(JsonElement element) { DataFlow properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static DataFlowResource DeserializeDataFlowResource(JsonElement element properties = DataFlow.DeserializeDataFlow(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static DataFlowResource DeserializeDataFlowResource(JsonElement element type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new DataFlowResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.cs index d6b55a01d1a0..b55f5dc482df 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataFlowResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Data flow resource type. - public partial class DataFlowResource : SubResource + public partial class DataFlowResource : AzureEntityResource { /// Initializes a new instance of DataFlowResource. /// Data flow properties. @@ -26,10 +26,10 @@ public DataFlowResource(DataFlow properties) } /// Initializes a new instance of DataFlowResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Data flow properties. internal DataFlowResource(string id, string name, string type, string etag, DataFlow properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.Serialization.cs new file mode 100644 index 000000000000..9733a65dfdc0 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.Serialization.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class DataLakeStorageAccountDetails : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(AccountUrl)) + { + writer.WritePropertyName("accountUrl"); + writer.WriteStringValue(AccountUrl); + } + if (Optional.IsDefined(Filesystem)) + { + writer.WritePropertyName("filesystem"); + writer.WriteStringValue(Filesystem); + } + writer.WriteEndObject(); + } + + internal static DataLakeStorageAccountDetails DeserializeDataLakeStorageAccountDetails(JsonElement element) + { + Optional accountUrl = default; + Optional filesystem = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("accountUrl")) + { + accountUrl = property.Value.GetString(); + continue; + } + if (property.NameEquals("filesystem")) + { + filesystem = property.Value.GetString(); + continue; + } + } + return new DataLakeStorageAccountDetails(accountUrl.Value, filesystem.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.cs new file mode 100644 index 000000000000..e14f35d67ce9 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DataLakeStorageAccountDetails.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Details of the data lake storage account associated with the workspace. + public partial class DataLakeStorageAccountDetails + { + /// Initializes a new instance of DataLakeStorageAccountDetails. + public DataLakeStorageAccountDetails() + { + } + + /// Initializes a new instance of DataLakeStorageAccountDetails. + /// Account URL. + /// Filesystem name. + internal DataLakeStorageAccountDetails(string accountUrl, string filesystem) + { + AccountUrl = accountUrl; + Filesystem = filesystem; + } + + /// Account URL. + public string AccountUrl { get; set; } + /// Filesystem name. + public string Filesystem { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.Serialization.cs index fb6d54a74dba..c84610976687 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static DatasetResource DeserializeDatasetResource(JsonElement element) { Dataset properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static DatasetResource DeserializeDatasetResource(JsonElement element) properties = Dataset.DeserializeDataset(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static DatasetResource DeserializeDatasetResource(JsonElement element) type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new DatasetResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.cs index 87d7886f8b80..bfe950be0b5b 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DatasetResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Dataset resource type. - public partial class DatasetResource : SubResource + public partial class DatasetResource : AzureEntityResource { /// Initializes a new instance of DatasetResource. /// Dataset properties. @@ -26,10 +26,10 @@ public DatasetResource(Dataset properties) } /// Initializes a new instance of DatasetResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Dataset properties. internal DatasetResource(string id, string name, string type, string etag, Dataset properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DayOfWeek.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DayOfWeek.cs index 4566266d6702..ef1730154e3b 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DayOfWeek.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DayOfWeek.cs @@ -7,7 +7,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { - /// The days of the week. + /// The DayOfWeek. public enum DayOfWeek { /// Sunday. diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.Serialization.cs deleted file mode 100644 index d8a71cb6b1e1..000000000000 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.Serialization.cs +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Analytics.Synapse.Artifacts.Models -{ - internal static class DaysOfWeekExtensions - { - public static string ToSerialString(this DaysOfWeek value) => value switch - { - DaysOfWeek.Sunday => "Sunday", - DaysOfWeek.Monday => "Monday", - DaysOfWeek.Tuesday => "Tuesday", - DaysOfWeek.Wednesday => "Wednesday", - DaysOfWeek.Thursday => "Thursday", - DaysOfWeek.Friday => "Friday", - DaysOfWeek.Saturday => "Saturday", - _ => throw new ArgumentOutOfRangeException(nameof(value), value, "Unknown DaysOfWeek value.") - }; - - public static DaysOfWeek ToDaysOfWeek(this string value) - { - if (string.Equals(value, "Sunday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Sunday; - if (string.Equals(value, "Monday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Monday; - if (string.Equals(value, "Tuesday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Tuesday; - if (string.Equals(value, "Wednesday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Wednesday; - if (string.Equals(value, "Thursday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Thursday; - if (string.Equals(value, "Friday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Friday; - if (string.Equals(value, "Saturday", StringComparison.InvariantCultureIgnoreCase)) return DaysOfWeek.Saturday; - throw new ArgumentOutOfRangeException(nameof(value), value, "Unknown DaysOfWeek value."); - } - } -} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.cs deleted file mode 100644 index 987a612608ba..000000000000 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/DaysOfWeek.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Analytics.Synapse.Artifacts.Models -{ - /// The DaysOfWeek. - public enum DaysOfWeek - { - /// Sunday. - Sunday, - /// Monday. - Monday, - /// Tuesday. - Tuesday, - /// Wednesday. - Wednesday, - /// Thursday. - Thursday, - /// Friday. - Friday, - /// Saturday. - Saturday - } -} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.Serialization.cs new file mode 100644 index 000000000000..ff70fd4161db --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.Serialization.cs @@ -0,0 +1,56 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class EntityReference : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Type)) + { + writer.WritePropertyName("type"); + writer.WriteStringValue(Type.Value.ToString()); + } + if (Optional.IsDefined(ReferenceName)) + { + writer.WritePropertyName("referenceName"); + writer.WriteStringValue(ReferenceName); + } + writer.WriteEndObject(); + } + + internal static EntityReference DeserializeEntityReference(JsonElement element) + { + Optional type = default; + Optional referenceName = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("type")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + type = new IntegrationRuntimeEntityReferenceType(property.Value.GetString()); + continue; + } + if (property.NameEquals("referenceName")) + { + referenceName = property.Value.GetString(); + continue; + } + } + return new EntityReference(Optional.ToNullable(type), referenceName.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.cs new file mode 100644 index 000000000000..dc28e54c0c2d --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/EntityReference.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The entity reference. + public partial class EntityReference + { + /// Initializes a new instance of EntityReference. + public EntityReference() + { + } + + /// Initializes a new instance of EntityReference. + /// The type of this referenced entity. + /// The name of this referenced entity. + internal EntityReference(IntegrationRuntimeEntityReferenceType? type, string referenceName) + { + Type = type; + ReferenceName = referenceName; + } + + /// The type of this referenced entity. + public IntegrationRuntimeEntityReferenceType? Type { get; set; } + /// The name of this referenced entity. + public string ReferenceName { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.Serialization.cs new file mode 100644 index 000000000000..3caca0ee1076 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.Serialization.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + internal partial class ErrorAdditionalInfo + { + internal static ErrorAdditionalInfo DeserializeErrorAdditionalInfo(JsonElement element) + { + Optional type = default; + Optional info = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + if (property.NameEquals("info")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + info = property.Value.GetObject(); + continue; + } + } + return new ErrorAdditionalInfo(type.Value, info.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.cs new file mode 100644 index 000000000000..95808ba77755 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorAdditionalInfo.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The resource management error additional info. + internal partial class ErrorAdditionalInfo + { + /// Initializes a new instance of ErrorAdditionalInfo. + internal ErrorAdditionalInfo() + { + } + + /// Initializes a new instance of ErrorAdditionalInfo. + /// The additional info type. + /// The additional info. + internal ErrorAdditionalInfo(string type, object info) + { + Type = type; + Info = info; + } + + /// The additional info type. + public string Type { get; } + /// The additional info. + public object Info { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.Serialization.cs new file mode 100644 index 000000000000..76fa100ebf4b --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.Serialization.cs @@ -0,0 +1,34 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + internal partial class ErrorContract + { + internal static ErrorContract DeserializeErrorContract(JsonElement element) + { + Optional error = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("error")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + error = ErrorResponse.DeserializeErrorResponse(property.Value); + continue; + } + } + return new ErrorContract(error.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.cs new file mode 100644 index 000000000000..f267c7ba0d30 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorContract.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Contains details when the response code indicates an error. + internal partial class ErrorContract + { + /// Initializes a new instance of ErrorContract. + internal ErrorContract() + { + } + + /// Initializes a new instance of ErrorContract. + /// The error details. + internal ErrorContract(ErrorResponse error) + { + Error = error; + } + + /// The error details. + public ErrorResponse Error { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.Serialization.cs new file mode 100644 index 000000000000..1a0a644a3789 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.Serialization.cs @@ -0,0 +1,74 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + internal partial class ErrorResponse + { + internal static ErrorResponse DeserializeErrorResponse(JsonElement element) + { + Optional code = default; + Optional message = default; + Optional target = default; + Optional> details = default; + Optional> additionalInfo = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("code")) + { + code = property.Value.GetString(); + continue; + } + if (property.NameEquals("message")) + { + message = property.Value.GetString(); + continue; + } + if (property.NameEquals("target")) + { + target = property.Value.GetString(); + continue; + } + if (property.NameEquals("details")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(DeserializeErrorResponse(item)); + } + details = array; + continue; + } + if (property.NameEquals("additionalInfo")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(ErrorAdditionalInfo.DeserializeErrorAdditionalInfo(item)); + } + additionalInfo = array; + continue; + } + } + return new ErrorResponse(code.Value, message.Value, target.Value, Optional.ToList(details), Optional.ToList(additionalInfo)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.cs new file mode 100644 index 000000000000..d5d27d468eb4 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ErrorResponse.cs @@ -0,0 +1,49 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The resource management error response. + internal partial class ErrorResponse + { + /// Initializes a new instance of ErrorResponse. + internal ErrorResponse() + { + Details = new ChangeTrackingList(); + AdditionalInfo = new ChangeTrackingList(); + } + + /// Initializes a new instance of ErrorResponse. + /// The error code. + /// The error message. + /// The error target. + /// The error details. + /// The error additional info. + internal ErrorResponse(string code, string message, string target, IReadOnlyList details, IReadOnlyList additionalInfo) + { + Code = code; + Message = message; + Target = target; + Details = details; + AdditionalInfo = additionalInfo; + } + + /// The error code. + public string Code { get; } + /// The error message. + public string Message { get; } + /// The error target. + public string Target { get; } + /// The error details. + public IReadOnlyList Details { get; } + /// The error additional info. + public IReadOnlyList AdditionalInfo { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.Serialization.cs new file mode 100644 index 000000000000..221f5b8bb7a3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.Serialization.cs @@ -0,0 +1,66 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntime : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("type"); + writer.WriteStringValue(Type.ToString()); + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"); + writer.WriteStringValue(Description); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntime DeserializeIntegrationRuntime(JsonElement element) + { + if (element.TryGetProperty("type", out JsonElement discriminator)) + { + switch (discriminator.GetString()) + { + case "Managed": return ManagedIntegrationRuntime.DeserializeManagedIntegrationRuntime(element); + case "SelfHosted": return SelfHostedIntegrationRuntime.DeserializeSelfHostedIntegrationRuntime(element); + } + } + IntegrationRuntimeType type = default; + Optional description = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("type")) + { + type = new IntegrationRuntimeType(property.Value.GetString()); + continue; + } + if (property.NameEquals("description")) + { + description = property.Value.GetString(); + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntime(type, description.Value, additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.cs new file mode 100644 index 000000000000..d1d96eadc245 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntime.cs @@ -0,0 +1,77 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Azure Synapse nested object which serves as a compute resource for activities. + public partial class IntegrationRuntime : IDictionary + { + /// Initializes a new instance of IntegrationRuntime. + public IntegrationRuntime() + { + AdditionalProperties = new ChangeTrackingDictionary(); + Type = new IntegrationRuntimeType("IntegrationRuntime"); + } + + /// Initializes a new instance of IntegrationRuntime. + /// Type of integration runtime. + /// Integration runtime description. + /// . + internal IntegrationRuntime(IntegrationRuntimeType type, string description, IDictionary additionalProperties) + { + Type = type; + Description = description; + AdditionalProperties = additionalProperties; + } + + /// Type of integration runtime. + internal IntegrationRuntimeType Type { get; set; } + /// Integration runtime description. + public string Description { get; set; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.Serialization.cs new file mode 100644 index 000000000000..84cc479ccba6 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.Serialization.cs @@ -0,0 +1,125 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeComputeProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Location)) + { + writer.WritePropertyName("location"); + writer.WriteStringValue(Location); + } + if (Optional.IsDefined(NodeSize)) + { + writer.WritePropertyName("nodeSize"); + writer.WriteStringValue(NodeSize); + } + if (Optional.IsDefined(NumberOfNodes)) + { + writer.WritePropertyName("numberOfNodes"); + writer.WriteNumberValue(NumberOfNodes.Value); + } + if (Optional.IsDefined(MaxParallelExecutionsPerNode)) + { + writer.WritePropertyName("maxParallelExecutionsPerNode"); + writer.WriteNumberValue(MaxParallelExecutionsPerNode.Value); + } + if (Optional.IsDefined(DataFlowProperties)) + { + writer.WritePropertyName("dataFlowProperties"); + writer.WriteObjectValue(DataFlowProperties); + } + if (Optional.IsDefined(VNetProperties)) + { + writer.WritePropertyName("vNetProperties"); + writer.WriteObjectValue(VNetProperties); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeComputeProperties DeserializeIntegrationRuntimeComputeProperties(JsonElement element) + { + Optional location = default; + Optional nodeSize = default; + Optional numberOfNodes = default; + Optional maxParallelExecutionsPerNode = default; + Optional dataFlowProperties = default; + Optional vNetProperties = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("location")) + { + location = property.Value.GetString(); + continue; + } + if (property.NameEquals("nodeSize")) + { + nodeSize = property.Value.GetString(); + continue; + } + if (property.NameEquals("numberOfNodes")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + numberOfNodes = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("maxParallelExecutionsPerNode")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + maxParallelExecutionsPerNode = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("dataFlowProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + dataFlowProperties = IntegrationRuntimeDataFlowProperties.DeserializeIntegrationRuntimeDataFlowProperties(property.Value); + continue; + } + if (property.NameEquals("vNetProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + vNetProperties = IntegrationRuntimeVNetProperties.DeserializeIntegrationRuntimeVNetProperties(property.Value); + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntimeComputeProperties(location.Value, nodeSize.Value, Optional.ToNullable(numberOfNodes), Optional.ToNullable(maxParallelExecutionsPerNode), dataFlowProperties.Value, vNetProperties.Value, additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.cs new file mode 100644 index 000000000000..57612afc2d09 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeComputeProperties.cs @@ -0,0 +1,92 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The compute resource properties for managed integration runtime. + public partial class IntegrationRuntimeComputeProperties : IDictionary + { + /// Initializes a new instance of IntegrationRuntimeComputeProperties. + public IntegrationRuntimeComputeProperties() + { + AdditionalProperties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of IntegrationRuntimeComputeProperties. + /// The location for managed integration runtime. The supported regions could be found on https://docs.microsoft.com/en-us/azure/data-factory/data-factory-data-movement-activities. + /// The node size requirement to managed integration runtime. + /// The required number of nodes for managed integration runtime. + /// Maximum parallel executions count per node for managed integration runtime. + /// Data flow properties for managed integration runtime. + /// VNet properties for managed integration runtime. + /// . + internal IntegrationRuntimeComputeProperties(string location, string nodeSize, int? numberOfNodes, int? maxParallelExecutionsPerNode, IntegrationRuntimeDataFlowProperties dataFlowProperties, IntegrationRuntimeVNetProperties vNetProperties, IDictionary additionalProperties) + { + Location = location; + NodeSize = nodeSize; + NumberOfNodes = numberOfNodes; + MaxParallelExecutionsPerNode = maxParallelExecutionsPerNode; + DataFlowProperties = dataFlowProperties; + VNetProperties = vNetProperties; + AdditionalProperties = additionalProperties; + } + + /// The location for managed integration runtime. The supported regions could be found on https://docs.microsoft.com/en-us/azure/data-factory/data-factory-data-movement-activities. + public string Location { get; set; } + /// The node size requirement to managed integration runtime. + public string NodeSize { get; set; } + /// The required number of nodes for managed integration runtime. + public int? NumberOfNodes { get; set; } + /// Maximum parallel executions count per node for managed integration runtime. + public int? MaxParallelExecutionsPerNode { get; set; } + /// Data flow properties for managed integration runtime. + public IntegrationRuntimeDataFlowProperties DataFlowProperties { get; set; } + /// VNet properties for managed integration runtime. + public IntegrationRuntimeVNetProperties VNetProperties { get; set; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.Serialization.cs new file mode 100644 index 000000000000..b187bbdcb84a --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.Serialization.cs @@ -0,0 +1,56 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeCustomSetupScriptProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(BlobContainerUri)) + { + writer.WritePropertyName("blobContainerUri"); + writer.WriteStringValue(BlobContainerUri); + } + if (Optional.IsDefined(SasToken)) + { + writer.WritePropertyName("sasToken"); + writer.WriteObjectValue(SasToken); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeCustomSetupScriptProperties DeserializeIntegrationRuntimeCustomSetupScriptProperties(JsonElement element) + { + Optional blobContainerUri = default; + Optional sasToken = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("blobContainerUri")) + { + blobContainerUri = property.Value.GetString(); + continue; + } + if (property.NameEquals("sasToken")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + sasToken = SecureString.DeserializeSecureString(property.Value); + continue; + } + } + return new IntegrationRuntimeCustomSetupScriptProperties(blobContainerUri.Value, sasToken.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.cs new file mode 100644 index 000000000000..8cb1ba8a6f5c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeCustomSetupScriptProperties.cs @@ -0,0 +1,32 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Custom setup script properties for a managed dedicated integration runtime. + public partial class IntegrationRuntimeCustomSetupScriptProperties + { + /// Initializes a new instance of IntegrationRuntimeCustomSetupScriptProperties. + public IntegrationRuntimeCustomSetupScriptProperties() + { + } + + /// Initializes a new instance of IntegrationRuntimeCustomSetupScriptProperties. + /// The URI of the Azure blob container that contains the custom setup script. + /// The SAS token of the Azure blob container. + internal IntegrationRuntimeCustomSetupScriptProperties(string blobContainerUri, SecureString sasToken) + { + BlobContainerUri = blobContainerUri; + SasToken = sasToken; + } + + /// The URI of the Azure blob container that contains the custom setup script. + public string BlobContainerUri { get; set; } + /// The SAS token of the Azure blob container. + public SecureString SasToken { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.Serialization.cs new file mode 100644 index 000000000000..a9861d8e42e4 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.Serialization.cs @@ -0,0 +1,87 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeDataFlowProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(ComputeType)) + { + writer.WritePropertyName("computeType"); + writer.WriteStringValue(ComputeType.Value.ToString()); + } + if (Optional.IsDefined(CoreCount)) + { + writer.WritePropertyName("coreCount"); + writer.WriteNumberValue(CoreCount.Value); + } + if (Optional.IsDefined(TimeToLive)) + { + writer.WritePropertyName("timeToLive"); + writer.WriteNumberValue(TimeToLive.Value); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeDataFlowProperties DeserializeIntegrationRuntimeDataFlowProperties(JsonElement element) + { + Optional computeType = default; + Optional coreCount = default; + Optional timeToLive = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("computeType")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + computeType = new DataFlowComputeType(property.Value.GetString()); + continue; + } + if (property.NameEquals("coreCount")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + coreCount = property.Value.GetInt32(); + continue; + } + if (property.NameEquals("timeToLive")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + timeToLive = property.Value.GetInt32(); + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntimeDataFlowProperties(Optional.ToNullable(computeType), Optional.ToNullable(coreCount), Optional.ToNullable(timeToLive), additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.cs new file mode 100644 index 000000000000..1c91d6585504 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataFlowProperties.cs @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Data flow properties for managed integration runtime. + public partial class IntegrationRuntimeDataFlowProperties : IDictionary + { + /// Initializes a new instance of IntegrationRuntimeDataFlowProperties. + public IntegrationRuntimeDataFlowProperties() + { + AdditionalProperties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of IntegrationRuntimeDataFlowProperties. + /// Compute type of the cluster which will execute data flow job. + /// Core count of the cluster which will execute data flow job. Supported values are: 8, 16, 32, 48, 80, 144 and 272. + /// Time to live (in minutes) setting of the cluster which will execute data flow job. + /// . + internal IntegrationRuntimeDataFlowProperties(DataFlowComputeType? computeType, int? coreCount, int? timeToLive, IDictionary additionalProperties) + { + ComputeType = computeType; + CoreCount = coreCount; + TimeToLive = timeToLive; + AdditionalProperties = additionalProperties; + } + + /// Compute type of the cluster which will execute data flow job. + public DataFlowComputeType? ComputeType { get; set; } + /// Core count of the cluster which will execute data flow job. Supported values are: 8, 16, 32, 48, 80, 144 and 272. + public int? CoreCount { get; set; } + /// Time to live (in minutes) setting of the cluster which will execute data flow job. + public int? TimeToLive { get; set; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.Serialization.cs new file mode 100644 index 000000000000..21268654c3d3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.Serialization.cs @@ -0,0 +1,72 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeDataProxyProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(ConnectVia)) + { + writer.WritePropertyName("connectVia"); + writer.WriteObjectValue(ConnectVia); + } + if (Optional.IsDefined(StagingLinkedService)) + { + writer.WritePropertyName("stagingLinkedService"); + writer.WriteObjectValue(StagingLinkedService); + } + if (Optional.IsDefined(Path)) + { + writer.WritePropertyName("path"); + writer.WriteStringValue(Path); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeDataProxyProperties DeserializeIntegrationRuntimeDataProxyProperties(JsonElement element) + { + Optional connectVia = default; + Optional stagingLinkedService = default; + Optional path = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("connectVia")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + connectVia = EntityReference.DeserializeEntityReference(property.Value); + continue; + } + if (property.NameEquals("stagingLinkedService")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + stagingLinkedService = EntityReference.DeserializeEntityReference(property.Value); + continue; + } + if (property.NameEquals("path")) + { + path = property.Value.GetString(); + continue; + } + } + return new IntegrationRuntimeDataProxyProperties(connectVia.Value, stagingLinkedService.Value, path.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.cs new file mode 100644 index 000000000000..733d75b486d5 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeDataProxyProperties.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Data proxy properties for a managed dedicated integration runtime. + public partial class IntegrationRuntimeDataProxyProperties + { + /// Initializes a new instance of IntegrationRuntimeDataProxyProperties. + public IntegrationRuntimeDataProxyProperties() + { + } + + /// Initializes a new instance of IntegrationRuntimeDataProxyProperties. + /// The self-hosted integration runtime reference. + /// The staging linked service reference. + /// The path to contain the staged data in the Blob storage. + internal IntegrationRuntimeDataProxyProperties(EntityReference connectVia, EntityReference stagingLinkedService, string path) + { + ConnectVia = connectVia; + StagingLinkedService = stagingLinkedService; + Path = path; + } + + /// The self-hosted integration runtime reference. + public EntityReference ConnectVia { get; set; } + /// The staging linked service reference. + public EntityReference StagingLinkedService { get; set; } + /// The path to contain the staged data in the Blob storage. + public string Path { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEdition.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEdition.cs new file mode 100644 index 000000000000..8361c4226b20 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEdition.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The edition for the SSIS Integration Runtime. + public readonly partial struct IntegrationRuntimeEdition : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeEdition(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string StandardValue = "Standard"; + private const string EnterpriseValue = "Enterprise"; + + /// Standard. + public static IntegrationRuntimeEdition Standard { get; } = new IntegrationRuntimeEdition(StandardValue); + /// Enterprise. + public static IntegrationRuntimeEdition Enterprise { get; } = new IntegrationRuntimeEdition(EnterpriseValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeEdition left, IntegrationRuntimeEdition right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeEdition left, IntegrationRuntimeEdition right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeEdition(string value) => new IntegrationRuntimeEdition(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeEdition other && Equals(other); + /// + public bool Equals(IntegrationRuntimeEdition other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEntityReferenceType.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEntityReferenceType.cs new file mode 100644 index 000000000000..dd3b9a2739a3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeEntityReferenceType.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The type of this referenced entity. + public readonly partial struct IntegrationRuntimeEntityReferenceType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeEntityReferenceType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string IntegrationRuntimeReferenceValue = "IntegrationRuntimeReference"; + private const string LinkedServiceReferenceValue = "LinkedServiceReference"; + + /// IntegrationRuntimeReference. + public static IntegrationRuntimeEntityReferenceType IntegrationRuntimeReference { get; } = new IntegrationRuntimeEntityReferenceType(IntegrationRuntimeReferenceValue); + /// LinkedServiceReference. + public static IntegrationRuntimeEntityReferenceType LinkedServiceReference { get; } = new IntegrationRuntimeEntityReferenceType(LinkedServiceReferenceValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeEntityReferenceType left, IntegrationRuntimeEntityReferenceType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeEntityReferenceType left, IntegrationRuntimeEntityReferenceType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeEntityReferenceType(string value) => new IntegrationRuntimeEntityReferenceType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeEntityReferenceType other && Equals(other); + /// + public bool Equals(IntegrationRuntimeEntityReferenceType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeLicenseType.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeLicenseType.cs new file mode 100644 index 000000000000..541443754e5b --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeLicenseType.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// License type for bringing your own license scenario. + public readonly partial struct IntegrationRuntimeLicenseType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeLicenseType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string BasePriceValue = "BasePrice"; + private const string LicenseIncludedValue = "LicenseIncluded"; + + /// BasePrice. + public static IntegrationRuntimeLicenseType BasePrice { get; } = new IntegrationRuntimeLicenseType(BasePriceValue); + /// LicenseIncluded. + public static IntegrationRuntimeLicenseType LicenseIncluded { get; } = new IntegrationRuntimeLicenseType(LicenseIncludedValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeLicenseType left, IntegrationRuntimeLicenseType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeLicenseType left, IntegrationRuntimeLicenseType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeLicenseType(string value) => new IntegrationRuntimeLicenseType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeLicenseType other && Equals(other); + /// + public bool Equals(IntegrationRuntimeLicenseType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.Serialization.cs new file mode 100644 index 000000000000..3eecb330b7d9 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.Serialization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeListResponse + { + internal static IntegrationRuntimeListResponse DeserializeIntegrationRuntimeListResponse(JsonElement element) + { + IReadOnlyList value = default; + Optional nextLink = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value")) + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(IntegrationRuntimeResource.DeserializeIntegrationRuntimeResource(item)); + } + value = array; + continue; + } + if (property.NameEquals("nextLink")) + { + nextLink = property.Value.GetString(); + continue; + } + } + return new IntegrationRuntimeListResponse(value, nextLink.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.cs new file mode 100644 index 000000000000..420ffb72699d --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeListResponse.cs @@ -0,0 +1,44 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// A list of integration runtime resources. + public partial class IntegrationRuntimeListResponse + { + /// Initializes a new instance of IntegrationRuntimeListResponse. + /// List of integration runtimes. + /// is null. + internal IntegrationRuntimeListResponse(IEnumerable value) + { + if (value == null) + { + throw new ArgumentNullException(nameof(value)); + } + + Value = value.ToList(); + } + + /// Initializes a new instance of IntegrationRuntimeListResponse. + /// List of integration runtimes. + /// The link to the next page of results, if any remaining results exist. + internal IntegrationRuntimeListResponse(IReadOnlyList value, string nextLink) + { + Value = value; + NextLink = nextLink; + } + + /// List of integration runtimes. + public IReadOnlyList Value { get; } + /// The link to the next page of results, if any remaining results exist. + public string NextLink { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.Serialization.cs new file mode 100644 index 000000000000..65d60022c065 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.Serialization.cs @@ -0,0 +1,61 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeResource : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("properties"); + writer.WriteObjectValue(Properties); + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeResource DeserializeIntegrationRuntimeResource(JsonElement element) + { + IntegrationRuntime properties = default; + Optional etag = default; + Optional id = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("properties")) + { + properties = IntegrationRuntime.DeserializeIntegrationRuntime(property.Value); + continue; + } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new IntegrationRuntimeResource(id.Value, name.Value, type.Value, etag.Value, properties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.cs new file mode 100644 index 000000000000..5a15b8de1924 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeResource.cs @@ -0,0 +1,42 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Integration runtime resource type. + public partial class IntegrationRuntimeResource : AzureEntityResource + { + /// Initializes a new instance of IntegrationRuntimeResource. + /// Integration runtime properties. + /// is null. + public IntegrationRuntimeResource(IntegrationRuntime properties) + { + if (properties == null) + { + throw new ArgumentNullException(nameof(properties)); + } + + Properties = properties; + } + + /// Initializes a new instance of IntegrationRuntimeResource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. + /// Integration runtime properties. + internal IntegrationRuntimeResource(string id, string name, string type, string etag, IntegrationRuntime properties) : base(id, name, type, etag) + { + Properties = properties; + } + + /// Integration runtime properties. + public IntegrationRuntime Properties { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.Serialization.cs new file mode 100644 index 000000000000..b337b7043703 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.Serialization.cs @@ -0,0 +1,93 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeSsisCatalogInfo : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(CatalogServerEndpoint)) + { + writer.WritePropertyName("catalogServerEndpoint"); + writer.WriteStringValue(CatalogServerEndpoint); + } + if (Optional.IsDefined(CatalogAdminUserName)) + { + writer.WritePropertyName("catalogAdminUserName"); + writer.WriteStringValue(CatalogAdminUserName); + } + if (Optional.IsDefined(CatalogAdminPassword)) + { + writer.WritePropertyName("catalogAdminPassword"); + writer.WriteObjectValue(CatalogAdminPassword); + } + if (Optional.IsDefined(CatalogPricingTier)) + { + writer.WritePropertyName("catalogPricingTier"); + writer.WriteStringValue(CatalogPricingTier.Value.ToString()); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeSsisCatalogInfo DeserializeIntegrationRuntimeSsisCatalogInfo(JsonElement element) + { + Optional catalogServerEndpoint = default; + Optional catalogAdminUserName = default; + Optional catalogAdminPassword = default; + Optional catalogPricingTier = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("catalogServerEndpoint")) + { + catalogServerEndpoint = property.Value.GetString(); + continue; + } + if (property.NameEquals("catalogAdminUserName")) + { + catalogAdminUserName = property.Value.GetString(); + continue; + } + if (property.NameEquals("catalogAdminPassword")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + catalogAdminPassword = SecureString.DeserializeSecureString(property.Value); + continue; + } + if (property.NameEquals("catalogPricingTier")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + catalogPricingTier = new IntegrationRuntimeSsisCatalogPricingTier(property.Value.GetString()); + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntimeSsisCatalogInfo(catalogServerEndpoint.Value, catalogAdminUserName.Value, catalogAdminPassword.Value, Optional.ToNullable(catalogPricingTier), additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.cs new file mode 100644 index 000000000000..dca1727de72c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogInfo.cs @@ -0,0 +1,84 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Catalog information for managed dedicated integration runtime. + public partial class IntegrationRuntimeSsisCatalogInfo : IDictionary + { + /// Initializes a new instance of IntegrationRuntimeSsisCatalogInfo. + public IntegrationRuntimeSsisCatalogInfo() + { + AdditionalProperties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of IntegrationRuntimeSsisCatalogInfo. + /// The catalog database server URL. + /// The administrator user name of catalog database. + /// The password of the administrator user account of the catalog database. + /// The pricing tier for the catalog database. The valid values could be found in https://azure.microsoft.com/en-us/pricing/details/sql-database/. + /// . + internal IntegrationRuntimeSsisCatalogInfo(string catalogServerEndpoint, string catalogAdminUserName, SecureString catalogAdminPassword, IntegrationRuntimeSsisCatalogPricingTier? catalogPricingTier, IDictionary additionalProperties) + { + CatalogServerEndpoint = catalogServerEndpoint; + CatalogAdminUserName = catalogAdminUserName; + CatalogAdminPassword = catalogAdminPassword; + CatalogPricingTier = catalogPricingTier; + AdditionalProperties = additionalProperties; + } + + /// The catalog database server URL. + public string CatalogServerEndpoint { get; set; } + /// The administrator user name of catalog database. + public string CatalogAdminUserName { get; set; } + /// The password of the administrator user account of the catalog database. + public SecureString CatalogAdminPassword { get; set; } + /// The pricing tier for the catalog database. The valid values could be found in https://azure.microsoft.com/en-us/pricing/details/sql-database/. + public IntegrationRuntimeSsisCatalogPricingTier? CatalogPricingTier { get; set; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogPricingTier.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogPricingTier.cs new file mode 100644 index 000000000000..747eebdddad5 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisCatalogPricingTier.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The pricing tier for the catalog database. The valid values could be found in https://azure.microsoft.com/en-us/pricing/details/sql-database/. + public readonly partial struct IntegrationRuntimeSsisCatalogPricingTier : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeSsisCatalogPricingTier(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string BasicValue = "Basic"; + private const string StandardValue = "Standard"; + private const string PremiumValue = "Premium"; + private const string PremiumRSValue = "PremiumRS"; + + /// Basic. + public static IntegrationRuntimeSsisCatalogPricingTier Basic { get; } = new IntegrationRuntimeSsisCatalogPricingTier(BasicValue); + /// Standard. + public static IntegrationRuntimeSsisCatalogPricingTier Standard { get; } = new IntegrationRuntimeSsisCatalogPricingTier(StandardValue); + /// Premium. + public static IntegrationRuntimeSsisCatalogPricingTier Premium { get; } = new IntegrationRuntimeSsisCatalogPricingTier(PremiumValue); + /// PremiumRS. + public static IntegrationRuntimeSsisCatalogPricingTier PremiumRS { get; } = new IntegrationRuntimeSsisCatalogPricingTier(PremiumRSValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeSsisCatalogPricingTier left, IntegrationRuntimeSsisCatalogPricingTier right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeSsisCatalogPricingTier left, IntegrationRuntimeSsisCatalogPricingTier right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeSsisCatalogPricingTier(string value) => new IntegrationRuntimeSsisCatalogPricingTier(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeSsisCatalogPricingTier other && Equals(other); + /// + public bool Equals(IntegrationRuntimeSsisCatalogPricingTier other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.Serialization.cs new file mode 100644 index 000000000000..017acca2dc03 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.Serialization.cs @@ -0,0 +1,145 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeSsisProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(CatalogInfo)) + { + writer.WritePropertyName("catalogInfo"); + writer.WriteObjectValue(CatalogInfo); + } + if (Optional.IsDefined(LicenseType)) + { + writer.WritePropertyName("licenseType"); + writer.WriteStringValue(LicenseType.Value.ToString()); + } + if (Optional.IsDefined(CustomSetupScriptProperties)) + { + writer.WritePropertyName("customSetupScriptProperties"); + writer.WriteObjectValue(CustomSetupScriptProperties); + } + if (Optional.IsDefined(DataProxyProperties)) + { + writer.WritePropertyName("dataProxyProperties"); + writer.WriteObjectValue(DataProxyProperties); + } + if (Optional.IsDefined(Edition)) + { + writer.WritePropertyName("edition"); + writer.WriteStringValue(Edition.Value.ToString()); + } + if (Optional.IsCollectionDefined(ExpressCustomSetupProperties)) + { + writer.WritePropertyName("expressCustomSetupProperties"); + writer.WriteStartArray(); + foreach (var item in ExpressCustomSetupProperties) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeSsisProperties DeserializeIntegrationRuntimeSsisProperties(JsonElement element) + { + Optional catalogInfo = default; + Optional licenseType = default; + Optional customSetupScriptProperties = default; + Optional dataProxyProperties = default; + Optional edition = default; + Optional> expressCustomSetupProperties = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("catalogInfo")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + catalogInfo = IntegrationRuntimeSsisCatalogInfo.DeserializeIntegrationRuntimeSsisCatalogInfo(property.Value); + continue; + } + if (property.NameEquals("licenseType")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + licenseType = new IntegrationRuntimeLicenseType(property.Value.GetString()); + continue; + } + if (property.NameEquals("customSetupScriptProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + customSetupScriptProperties = IntegrationRuntimeCustomSetupScriptProperties.DeserializeIntegrationRuntimeCustomSetupScriptProperties(property.Value); + continue; + } + if (property.NameEquals("dataProxyProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + dataProxyProperties = IntegrationRuntimeDataProxyProperties.DeserializeIntegrationRuntimeDataProxyProperties(property.Value); + continue; + } + if (property.NameEquals("edition")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + edition = new IntegrationRuntimeEdition(property.Value.GetString()); + continue; + } + if (property.NameEquals("expressCustomSetupProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(CustomSetupBase.DeserializeCustomSetupBase(item)); + } + expressCustomSetupProperties = array; + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntimeSsisProperties(catalogInfo.Value, Optional.ToNullable(licenseType), customSetupScriptProperties.Value, dataProxyProperties.Value, Optional.ToNullable(edition), Optional.ToList(expressCustomSetupProperties), additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.cs new file mode 100644 index 000000000000..c32a6b9237b4 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeSsisProperties.cs @@ -0,0 +1,93 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// SSIS properties for managed integration runtime. + public partial class IntegrationRuntimeSsisProperties : IDictionary + { + /// Initializes a new instance of IntegrationRuntimeSsisProperties. + public IntegrationRuntimeSsisProperties() + { + ExpressCustomSetupProperties = new ChangeTrackingList(); + AdditionalProperties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of IntegrationRuntimeSsisProperties. + /// Catalog information for managed dedicated integration runtime. + /// License type for bringing your own license scenario. + /// Custom setup script properties for a managed dedicated integration runtime. + /// Data proxy properties for a managed dedicated integration runtime. + /// The edition for the SSIS Integration Runtime. + /// Custom setup without script properties for a SSIS integration runtime. + /// . + internal IntegrationRuntimeSsisProperties(IntegrationRuntimeSsisCatalogInfo catalogInfo, IntegrationRuntimeLicenseType? licenseType, IntegrationRuntimeCustomSetupScriptProperties customSetupScriptProperties, IntegrationRuntimeDataProxyProperties dataProxyProperties, IntegrationRuntimeEdition? edition, IList expressCustomSetupProperties, IDictionary additionalProperties) + { + CatalogInfo = catalogInfo; + LicenseType = licenseType; + CustomSetupScriptProperties = customSetupScriptProperties; + DataProxyProperties = dataProxyProperties; + Edition = edition; + ExpressCustomSetupProperties = expressCustomSetupProperties; + AdditionalProperties = additionalProperties; + } + + /// Catalog information for managed dedicated integration runtime. + public IntegrationRuntimeSsisCatalogInfo CatalogInfo { get; set; } + /// License type for bringing your own license scenario. + public IntegrationRuntimeLicenseType? LicenseType { get; set; } + /// Custom setup script properties for a managed dedicated integration runtime. + public IntegrationRuntimeCustomSetupScriptProperties CustomSetupScriptProperties { get; set; } + /// Data proxy properties for a managed dedicated integration runtime. + public IntegrationRuntimeDataProxyProperties DataProxyProperties { get; set; } + /// The edition for the SSIS Integration Runtime. + public IntegrationRuntimeEdition? Edition { get; set; } + /// Custom setup without script properties for a SSIS integration runtime. + public IList ExpressCustomSetupProperties { get; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeState.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeState.cs new file mode 100644 index 000000000000..2925b110077f --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeState.cs @@ -0,0 +1,75 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The state of integration runtime. + public readonly partial struct IntegrationRuntimeState : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeState(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string InitialValue = "Initial"; + private const string StoppedValue = "Stopped"; + private const string StartedValue = "Started"; + private const string StartingValue = "Starting"; + private const string StoppingValue = "Stopping"; + private const string NeedRegistrationValue = "NeedRegistration"; + private const string OnlineValue = "Online"; + private const string LimitedValue = "Limited"; + private const string OfflineValue = "Offline"; + private const string AccessDeniedValue = "AccessDenied"; + + /// Initial. + public static IntegrationRuntimeState Initial { get; } = new IntegrationRuntimeState(InitialValue); + /// Stopped. + public static IntegrationRuntimeState Stopped { get; } = new IntegrationRuntimeState(StoppedValue); + /// Started. + public static IntegrationRuntimeState Started { get; } = new IntegrationRuntimeState(StartedValue); + /// Starting. + public static IntegrationRuntimeState Starting { get; } = new IntegrationRuntimeState(StartingValue); + /// Stopping. + public static IntegrationRuntimeState Stopping { get; } = new IntegrationRuntimeState(StoppingValue); + /// NeedRegistration. + public static IntegrationRuntimeState NeedRegistration { get; } = new IntegrationRuntimeState(NeedRegistrationValue); + /// Online. + public static IntegrationRuntimeState Online { get; } = new IntegrationRuntimeState(OnlineValue); + /// Limited. + public static IntegrationRuntimeState Limited { get; } = new IntegrationRuntimeState(LimitedValue); + /// Offline. + public static IntegrationRuntimeState Offline { get; } = new IntegrationRuntimeState(OfflineValue); + /// AccessDenied. + public static IntegrationRuntimeState AccessDenied { get; } = new IntegrationRuntimeState(AccessDeniedValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeState left, IntegrationRuntimeState right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeState left, IntegrationRuntimeState right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeState(string value) => new IntegrationRuntimeState(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeState other && Equals(other); + /// + public bool Equals(IntegrationRuntimeState other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeType.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeType.cs new file mode 100644 index 000000000000..040f10a82179 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeType.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The type of integration runtime. + public readonly partial struct IntegrationRuntimeType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public IntegrationRuntimeType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string ManagedValue = "Managed"; + private const string SelfHostedValue = "SelfHosted"; + + /// Managed. + public static IntegrationRuntimeType Managed { get; } = new IntegrationRuntimeType(ManagedValue); + /// SelfHosted. + public static IntegrationRuntimeType SelfHosted { get; } = new IntegrationRuntimeType(SelfHostedValue); + /// Determines if two values are the same. + public static bool operator ==(IntegrationRuntimeType left, IntegrationRuntimeType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(IntegrationRuntimeType left, IntegrationRuntimeType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator IntegrationRuntimeType(string value) => new IntegrationRuntimeType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is IntegrationRuntimeType other && Equals(other); + /// + public bool Equals(IntegrationRuntimeType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.Serialization.cs new file mode 100644 index 000000000000..1dac3301c0a4 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.Serialization.cs @@ -0,0 +1,87 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class IntegrationRuntimeVNetProperties : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(VNetId)) + { + writer.WritePropertyName("vNetId"); + writer.WriteStringValue(VNetId); + } + if (Optional.IsDefined(Subnet)) + { + writer.WritePropertyName("subnet"); + writer.WriteStringValue(Subnet); + } + if (Optional.IsCollectionDefined(PublicIPs)) + { + writer.WritePropertyName("publicIPs"); + writer.WriteStartArray(); + foreach (var item in PublicIPs) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static IntegrationRuntimeVNetProperties DeserializeIntegrationRuntimeVNetProperties(JsonElement element) + { + Optional vNetId = default; + Optional subnet = default; + Optional> publicIPs = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("vNetId")) + { + vNetId = property.Value.GetString(); + continue; + } + if (property.NameEquals("subnet")) + { + subnet = property.Value.GetString(); + continue; + } + if (property.NameEquals("publicIPs")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + publicIPs = array; + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new IntegrationRuntimeVNetProperties(vNetId.Value, subnet.Value, Optional.ToList(publicIPs), additionalProperties); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.cs new file mode 100644 index 000000000000..cd1d50ec3dd7 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/IntegrationRuntimeVNetProperties.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// VNet properties for managed integration runtime. + public partial class IntegrationRuntimeVNetProperties : IDictionary + { + /// Initializes a new instance of IntegrationRuntimeVNetProperties. + public IntegrationRuntimeVNetProperties() + { + PublicIPs = new ChangeTrackingList(); + AdditionalProperties = new ChangeTrackingDictionary(); + } + + /// Initializes a new instance of IntegrationRuntimeVNetProperties. + /// The ID of the VNet that this integration runtime will join. + /// The name of the subnet this integration runtime will join. + /// Resource IDs of the public IP addresses that this integration runtime will use. + /// . + internal IntegrationRuntimeVNetProperties(string vNetId, string subnet, IList publicIPs, IDictionary additionalProperties) + { + VNetId = vNetId; + Subnet = subnet; + PublicIPs = publicIPs; + AdditionalProperties = additionalProperties; + } + + /// The ID of the VNet that this integration runtime will join. + public string VNetId { get; set; } + /// The name of the subnet this integration runtime will join. + public string Subnet { get; set; } + /// Resource IDs of the public IP addresses that this integration runtime will use. + public IList PublicIPs { get; } + internal IDictionary AdditionalProperties { get; } + /// + public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); + /// + public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); + /// + public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); + /// + public ICollection Keys => AdditionalProperties.Keys; + /// + public ICollection Values => AdditionalProperties.Values; + /// + int ICollection>.Count => AdditionalProperties.Count; + /// + public void Add(string key, object value) => AdditionalProperties.Add(key, value); + /// + public bool Remove(string key) => AdditionalProperties.Remove(key); + /// + bool ICollection>.IsReadOnly => AdditionalProperties.IsReadOnly; + /// + void ICollection>.Add(KeyValuePair value) => AdditionalProperties.Add(value); + /// + bool ICollection>.Remove(KeyValuePair value) => AdditionalProperties.Remove(value); + /// + bool ICollection>.Contains(KeyValuePair value) => AdditionalProperties.Contains(value); + /// + void ICollection>.CopyTo(KeyValuePair[] destination, int offset) => AdditionalProperties.CopyTo(destination, offset); + /// + void ICollection>.Clear() => AdditionalProperties.Clear(); + /// + public object this[string key] + { + get => AdditionalProperties[key]; + set => AdditionalProperties[key] = value; + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.Serialization.cs new file mode 100644 index 000000000000..f4c3e911eef8 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.Serialization.cs @@ -0,0 +1,63 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class LibraryRequirements : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Content)) + { + writer.WritePropertyName("content"); + writer.WriteStringValue(Content); + } + if (Optional.IsDefined(Filename)) + { + writer.WritePropertyName("filename"); + writer.WriteStringValue(Filename); + } + writer.WriteEndObject(); + } + + internal static LibraryRequirements DeserializeLibraryRequirements(JsonElement element) + { + Optional time = default; + Optional content = default; + Optional filename = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("time")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + time = property.Value.GetDateTimeOffset("O"); + continue; + } + if (property.NameEquals("content")) + { + content = property.Value.GetString(); + continue; + } + if (property.NameEquals("filename")) + { + filename = property.Value.GetString(); + continue; + } + } + return new LibraryRequirements(Optional.ToNullable(time), content.Value, filename.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.cs new file mode 100644 index 000000000000..1723cbbb1c46 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LibraryRequirements.cs @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Library requirements for a Big Data pool powered by Apache Spark. + public partial class LibraryRequirements + { + /// Initializes a new instance of LibraryRequirements. + public LibraryRequirements() + { + } + + /// Initializes a new instance of LibraryRequirements. + /// The last update time of the library requirements file. + /// The library requirements. + /// The filename of the library requirements file. + internal LibraryRequirements(DateTimeOffset? time, string content, string filename) + { + Time = time; + Content = content; + Filename = filename; + } + + /// The last update time of the library requirements file. + public DateTimeOffset? Time { get; } + /// The library requirements. + public string Content { get; set; } + /// The filename of the library requirements file. + public string Filename { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.Serialization.cs new file mode 100644 index 000000000000..1315833f4b70 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.Serialization.cs @@ -0,0 +1,45 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class LinkedIntegrationRuntimeKeyAuthorization : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("key"); + writer.WriteObjectValue(Key); + writer.WritePropertyName("authorizationType"); + writer.WriteStringValue(AuthorizationType); + writer.WriteEndObject(); + } + + internal static LinkedIntegrationRuntimeKeyAuthorization DeserializeLinkedIntegrationRuntimeKeyAuthorization(JsonElement element) + { + SecureString key = default; + string authorizationType = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("key")) + { + key = SecureString.DeserializeSecureString(property.Value); + continue; + } + if (property.NameEquals("authorizationType")) + { + authorizationType = property.Value.GetString(); + continue; + } + } + return new LinkedIntegrationRuntimeKeyAuthorization(authorizationType, key); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.cs new file mode 100644 index 000000000000..22d87a2aee60 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeKeyAuthorization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The key authorization type integration runtime. + public partial class LinkedIntegrationRuntimeKeyAuthorization : LinkedIntegrationRuntimeType + { + /// Initializes a new instance of LinkedIntegrationRuntimeKeyAuthorization. + /// The key used for authorization. + /// is null. + public LinkedIntegrationRuntimeKeyAuthorization(SecureString key) + { + if (key == null) + { + throw new ArgumentNullException(nameof(key)); + } + + Key = key; + AuthorizationType = "Key"; + } + + /// Initializes a new instance of LinkedIntegrationRuntimeKeyAuthorization. + /// The authorization type for integration runtime sharing. + /// The key used for authorization. + internal LinkedIntegrationRuntimeKeyAuthorization(string authorizationType, SecureString key) : base(authorizationType) + { + Key = key; + AuthorizationType = authorizationType ?? "Key"; + } + + /// The key used for authorization. + public SecureString Key { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.Serialization.cs new file mode 100644 index 000000000000..8212998ab4ad --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.Serialization.cs @@ -0,0 +1,45 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class LinkedIntegrationRuntimeRbacAuthorization : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("resourceId"); + writer.WriteStringValue(ResourceId); + writer.WritePropertyName("authorizationType"); + writer.WriteStringValue(AuthorizationType); + writer.WriteEndObject(); + } + + internal static LinkedIntegrationRuntimeRbacAuthorization DeserializeLinkedIntegrationRuntimeRbacAuthorization(JsonElement element) + { + string resourceId = default; + string authorizationType = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("resourceId")) + { + resourceId = property.Value.GetString(); + continue; + } + if (property.NameEquals("authorizationType")) + { + authorizationType = property.Value.GetString(); + continue; + } + } + return new LinkedIntegrationRuntimeRbacAuthorization(authorizationType, resourceId); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.cs new file mode 100644 index 000000000000..2395be607b7e --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeRbacAuthorization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The role based access control (RBAC) authorization type integration runtime. + public partial class LinkedIntegrationRuntimeRbacAuthorization : LinkedIntegrationRuntimeType + { + /// Initializes a new instance of LinkedIntegrationRuntimeRbacAuthorization. + /// The resource identifier of the integration runtime to be shared. + /// is null. + public LinkedIntegrationRuntimeRbacAuthorization(string resourceId) + { + if (resourceId == null) + { + throw new ArgumentNullException(nameof(resourceId)); + } + + ResourceId = resourceId; + AuthorizationType = "RBAC"; + } + + /// Initializes a new instance of LinkedIntegrationRuntimeRbacAuthorization. + /// The authorization type for integration runtime sharing. + /// The resource identifier of the integration runtime to be shared. + internal LinkedIntegrationRuntimeRbacAuthorization(string authorizationType, string resourceId) : base(authorizationType) + { + ResourceId = resourceId; + AuthorizationType = authorizationType ?? "RBAC"; + } + + /// The resource identifier of the integration runtime to be shared. + public string ResourceId { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.Serialization.cs new file mode 100644 index 000000000000..640173a01deb --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.Serialization.cs @@ -0,0 +1,45 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class LinkedIntegrationRuntimeType : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("authorizationType"); + writer.WriteStringValue(AuthorizationType); + writer.WriteEndObject(); + } + + internal static LinkedIntegrationRuntimeType DeserializeLinkedIntegrationRuntimeType(JsonElement element) + { + if (element.TryGetProperty("authorizationType", out JsonElement discriminator)) + { + switch (discriminator.GetString()) + { + case "Key": return LinkedIntegrationRuntimeKeyAuthorization.DeserializeLinkedIntegrationRuntimeKeyAuthorization(element); + case "RBAC": return LinkedIntegrationRuntimeRbacAuthorization.DeserializeLinkedIntegrationRuntimeRbacAuthorization(element); + } + } + string authorizationType = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("authorizationType")) + { + authorizationType = property.Value.GetString(); + continue; + } + } + return new LinkedIntegrationRuntimeType(authorizationType); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.cs new file mode 100644 index 000000000000..648c0bc5d277 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedIntegrationRuntimeType.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The base definition of a linked integration runtime. + public partial class LinkedIntegrationRuntimeType + { + /// Initializes a new instance of LinkedIntegrationRuntimeType. + public LinkedIntegrationRuntimeType() + { + } + + /// Initializes a new instance of LinkedIntegrationRuntimeType. + /// The authorization type for integration runtime sharing. + internal LinkedIntegrationRuntimeType(string authorizationType) + { + AuthorizationType = authorizationType; + } + + /// The authorization type for integration runtime sharing. + internal string AuthorizationType { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.Serialization.cs index ad3ec5756cc8..daff68e9b6b1 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static LinkedServiceResource DeserializeLinkedServiceResource(JsonElement element) { LinkedService properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static LinkedServiceResource DeserializeLinkedServiceResource(JsonEleme properties = LinkedService.DeserializeLinkedService(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static LinkedServiceResource DeserializeLinkedServiceResource(JsonEleme type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new LinkedServiceResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.cs index 10115530c867..9d203b89818a 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/LinkedServiceResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Linked service resource type. - public partial class LinkedServiceResource : SubResource + public partial class LinkedServiceResource : AzureEntityResource { /// Initializes a new instance of LinkedServiceResource. /// Properties of linked service. @@ -26,10 +26,10 @@ public LinkedServiceResource(LinkedService properties) } /// Initializes a new instance of LinkedServiceResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of linked service. internal LinkedServiceResource(string id, string name, string type, string etag, LinkedService properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.Serialization.cs new file mode 100644 index 000000000000..e038afe46aaa --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.Serialization.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class ManagedIdentity : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Type)) + { + writer.WritePropertyName("type"); + writer.WriteStringValue(Type.Value.ToSerialString()); + } + writer.WriteEndObject(); + } + + internal static ManagedIdentity DeserializeManagedIdentity(JsonElement element) + { + Optional principalId = default; + Optional tenantId = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("principalId")) + { + principalId = property.Value.GetString(); + continue; + } + if (property.NameEquals("tenantId")) + { + tenantId = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + type = property.Value.GetString().ToResourceIdentityType(); + continue; + } + } + return new ManagedIdentity(principalId.Value, tenantId.Value, Optional.ToNullable(type)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.cs new file mode 100644 index 000000000000..9dd1bd1a194b --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIdentity.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The workspace managed identity. + public partial class ManagedIdentity + { + /// Initializes a new instance of ManagedIdentity. + public ManagedIdentity() + { + } + + /// Initializes a new instance of ManagedIdentity. + /// The principal ID of the workspace managed identity. + /// The tenant ID of the workspace managed identity. + /// The type of managed identity for the workspace. + internal ManagedIdentity(string principalId, string tenantId, ResourceIdentityType? type) + { + PrincipalId = principalId; + TenantId = tenantId; + Type = type; + } + + /// The principal ID of the workspace managed identity. + public string PrincipalId { get; } + /// The tenant ID of the workspace managed identity. + public string TenantId { get; } + /// The type of managed identity for the workspace. + public ResourceIdentityType? Type { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.Serialization.cs new file mode 100644 index 000000000000..bfa31cf7585d --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.Serialization.cs @@ -0,0 +1,116 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class ManagedIntegrationRuntime : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("type"); + writer.WriteStringValue(Type.ToString()); + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"); + writer.WriteStringValue(Description); + } + writer.WritePropertyName("typeProperties"); + writer.WriteStartObject(); + if (Optional.IsDefined(ComputeProperties)) + { + writer.WritePropertyName("computeProperties"); + writer.WriteObjectValue(ComputeProperties); + } + if (Optional.IsDefined(SsisProperties)) + { + writer.WritePropertyName("ssisProperties"); + writer.WriteObjectValue(SsisProperties); + } + writer.WriteEndObject(); + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static ManagedIntegrationRuntime DeserializeManagedIntegrationRuntime(JsonElement element) + { + Optional state = default; + IntegrationRuntimeType type = default; + Optional description = default; + Optional computeProperties = default; + Optional ssisProperties = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("state")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + state = new IntegrationRuntimeState(property.Value.GetString()); + continue; + } + if (property.NameEquals("type")) + { + type = new IntegrationRuntimeType(property.Value.GetString()); + continue; + } + if (property.NameEquals("description")) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("computeProperties")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + computeProperties = IntegrationRuntimeComputeProperties.DeserializeIntegrationRuntimeComputeProperties(property0.Value); + continue; + } + if (property0.NameEquals("ssisProperties")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + ssisProperties = IntegrationRuntimeSsisProperties.DeserializeIntegrationRuntimeSsisProperties(property0.Value); + continue; + } + } + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new ManagedIntegrationRuntime(type, description.Value, additionalProperties, Optional.ToNullable(state), computeProperties.Value, ssisProperties.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.cs new file mode 100644 index 000000000000..432881f72df3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedIntegrationRuntime.cs @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Managed integration runtime, including managed elastic and managed dedicated integration runtimes. + public partial class ManagedIntegrationRuntime : IntegrationRuntime + { + /// Initializes a new instance of ManagedIntegrationRuntime. + public ManagedIntegrationRuntime() + { + Type = IntegrationRuntimeType.Managed; + } + + /// Initializes a new instance of ManagedIntegrationRuntime. + /// Type of integration runtime. + /// Integration runtime description. + /// . + /// Integration runtime state, only valid for managed dedicated integration runtime. + /// The compute resource for managed integration runtime. + /// SSIS properties for managed integration runtime. + internal ManagedIntegrationRuntime(IntegrationRuntimeType type, string description, IDictionary additionalProperties, IntegrationRuntimeState? state, IntegrationRuntimeComputeProperties computeProperties, IntegrationRuntimeSsisProperties ssisProperties) : base(type, description, additionalProperties) + { + State = state; + ComputeProperties = computeProperties; + SsisProperties = ssisProperties; + Type = type; + } + + /// Integration runtime state, only valid for managed dedicated integration runtime. + public IntegrationRuntimeState? State { get; } + /// The compute resource for managed integration runtime. + public IntegrationRuntimeComputeProperties ComputeProperties { get; set; } + /// SSIS properties for managed integration runtime. + public IntegrationRuntimeSsisProperties SsisProperties { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.Serialization.cs new file mode 100644 index 000000000000..376c132f7bb9 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.Serialization.cs @@ -0,0 +1,88 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class ManagedVirtualNetworkSettings : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(PreventDataExfiltration)) + { + writer.WritePropertyName("preventDataExfiltration"); + writer.WriteBooleanValue(PreventDataExfiltration.Value); + } + if (Optional.IsDefined(LinkedAccessCheckOnTargetResource)) + { + writer.WritePropertyName("linkedAccessCheckOnTargetResource"); + writer.WriteBooleanValue(LinkedAccessCheckOnTargetResource.Value); + } + if (Optional.IsCollectionDefined(AllowedAadTenantIdsForLinking)) + { + writer.WritePropertyName("allowedAadTenantIdsForLinking"); + writer.WriteStartArray(); + foreach (var item in AllowedAadTenantIdsForLinking) + { + writer.WriteStringValue(item); + } + writer.WriteEndArray(); + } + writer.WriteEndObject(); + } + + internal static ManagedVirtualNetworkSettings DeserializeManagedVirtualNetworkSettings(JsonElement element) + { + Optional preventDataExfiltration = default; + Optional linkedAccessCheckOnTargetResource = default; + Optional> allowedAadTenantIdsForLinking = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("preventDataExfiltration")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + preventDataExfiltration = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("linkedAccessCheckOnTargetResource")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + linkedAccessCheckOnTargetResource = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("allowedAadTenantIdsForLinking")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + allowedAadTenantIdsForLinking = array; + continue; + } + } + return new ManagedVirtualNetworkSettings(Optional.ToNullable(preventDataExfiltration), Optional.ToNullable(linkedAccessCheckOnTargetResource), Optional.ToList(allowedAadTenantIdsForLinking)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.cs new file mode 100644 index 000000000000..ad1f9af3c5f5 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ManagedVirtualNetworkSettings.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Managed Virtual Network Settings. + public partial class ManagedVirtualNetworkSettings + { + /// Initializes a new instance of ManagedVirtualNetworkSettings. + public ManagedVirtualNetworkSettings() + { + AllowedAadTenantIdsForLinking = new ChangeTrackingList(); + } + + /// Initializes a new instance of ManagedVirtualNetworkSettings. + /// Prevent Data Exfiltration. + /// Linked Access Check On Target Resource. + /// Allowed Aad Tenant Ids For Linking. + internal ManagedVirtualNetworkSettings(bool? preventDataExfiltration, bool? linkedAccessCheckOnTargetResource, IList allowedAadTenantIdsForLinking) + { + PreventDataExfiltration = preventDataExfiltration; + LinkedAccessCheckOnTargetResource = linkedAccessCheckOnTargetResource; + AllowedAadTenantIdsForLinking = allowedAadTenantIdsForLinking; + } + + /// Prevent Data Exfiltration. + public bool? PreventDataExfiltration { get; set; } + /// Linked Access Check On Target Resource. + public bool? LinkedAccessCheckOnTargetResource { get; set; } + /// Allowed Aad Tenant Ids For Linking. + public IList AllowedAadTenantIdsForLinking { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSize.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSize.cs new file mode 100644 index 000000000000..f5cd2d8ef270 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSize.cs @@ -0,0 +1,63 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The level of compute power that each node in the Big Data pool has. + public readonly partial struct NodeSize : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public NodeSize(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string NoneValue = "None"; + private const string SmallValue = "Small"; + private const string MediumValue = "Medium"; + private const string LargeValue = "Large"; + private const string XLargeValue = "XLarge"; + private const string XXLargeValue = "XXLarge"; + + /// None. + public static NodeSize None { get; } = new NodeSize(NoneValue); + /// Small. + public static NodeSize Small { get; } = new NodeSize(SmallValue); + /// Medium. + public static NodeSize Medium { get; } = new NodeSize(MediumValue); + /// Large. + public static NodeSize Large { get; } = new NodeSize(LargeValue); + /// XLarge. + public static NodeSize XLarge { get; } = new NodeSize(XLargeValue); + /// XXLarge. + public static NodeSize XXLarge { get; } = new NodeSize(XXLargeValue); + /// Determines if two values are the same. + public static bool operator ==(NodeSize left, NodeSize right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(NodeSize left, NodeSize right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator NodeSize(string value) => new NodeSize(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is NodeSize other && Equals(other); + /// + public bool Equals(NodeSize other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSizeFamily.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSizeFamily.cs new file mode 100644 index 000000000000..cd7c382ad465 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NodeSizeFamily.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The kind of nodes that the Big Data pool provides. + public readonly partial struct NodeSizeFamily : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public NodeSizeFamily(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string NoneValue = "None"; + private const string MemoryOptimizedValue = "MemoryOptimized"; + + /// None. + public static NodeSizeFamily None { get; } = new NodeSizeFamily(NoneValue); + /// MemoryOptimized. + public static NodeSizeFamily MemoryOptimized { get; } = new NodeSizeFamily(MemoryOptimizedValue); + /// Determines if two values are the same. + public static bool operator ==(NodeSizeFamily left, NodeSizeFamily right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(NodeSizeFamily left, NodeSizeFamily right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator NodeSizeFamily(string value) => new NodeSizeFamily(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is NodeSizeFamily other && Equals(other); + /// + public bool Equals(NodeSizeFamily other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.Serialization.cs index ccaaa827c728..b38a54547aa7 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static NotebookResource DeserializeNotebookResource(JsonElement element) { Notebook properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static NotebookResource DeserializeNotebookResource(JsonElement element properties = Notebook.DeserializeNotebook(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static NotebookResource DeserializeNotebookResource(JsonElement element type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new NotebookResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.cs index 38e23812dede..9c405e9b439f 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/NotebookResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Notebook resource type. - public partial class NotebookResource : SubResource + public partial class NotebookResource : AzureEntityResource { /// Initializes a new instance of NotebookResource. /// Properties of Notebook. @@ -26,10 +26,10 @@ public NotebookResource(Notebook properties) } /// Initializes a new instance of NotebookResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of Notebook. internal NotebookResource(string id, string name, string type, string etag, Notebook properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.Serialization.cs index 0d7742e31912..5339f584766d 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.Serialization.cs @@ -97,10 +97,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static PipelineResource DeserializePipelineResource(JsonElement element) { + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; Optional description = default; Optional> activities = default; Optional> parameters = default; @@ -113,6 +113,11 @@ internal static PipelineResource DeserializePipelineResource(JsonElement element Dictionary additionalPropertiesDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -128,11 +133,6 @@ internal static PipelineResource DeserializePipelineResource(JsonElement element type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } if (property.NameEquals("properties")) { if (property.Value.ValueKind == JsonValueKind.Null) diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.cs index 228f72b85d27..747dbba85ee3 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PipelineResource.cs @@ -12,7 +12,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Pipeline resource type. - public partial class PipelineResource : SubResource, IDictionary + public partial class PipelineResource : AzureEntityResource, IDictionary { /// Initializes a new instance of PipelineResource. public PipelineResource() @@ -26,10 +26,10 @@ public PipelineResource() } /// Initializes a new instance of PipelineResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// The description of the pipeline. /// List of activities in pipeline. /// List of parameters for pipeline. diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.Serialization.cs new file mode 100644 index 000000000000..763d2e3c9bda --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.Serialization.cs @@ -0,0 +1,35 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class PrivateEndpoint : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WriteEndObject(); + } + + internal static PrivateEndpoint DeserializePrivateEndpoint(JsonElement element) + { + Optional id = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + } + return new PrivateEndpoint(id.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.cs new file mode 100644 index 000000000000..43a487fa5c17 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpoint.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Private endpoint details. + public partial class PrivateEndpoint + { + /// Initializes a new instance of PrivateEndpoint. + public PrivateEndpoint() + { + } + + /// Initializes a new instance of PrivateEndpoint. + /// Resource id of the private endpoint. + internal PrivateEndpoint(string id) + { + Id = id; + } + + /// Resource id of the private endpoint. + public string Id { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.Serialization.cs new file mode 100644 index 000000000000..f839a269c2c3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.Serialization.cs @@ -0,0 +1,100 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class PrivateEndpointConnection : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("properties"); + writer.WriteStartObject(); + if (Optional.IsDefined(PrivateEndpoint)) + { + writer.WritePropertyName("privateEndpoint"); + writer.WriteObjectValue(PrivateEndpoint); + } + if (Optional.IsDefined(PrivateLinkServiceConnectionState)) + { + writer.WritePropertyName("privateLinkServiceConnectionState"); + writer.WriteObjectValue(PrivateLinkServiceConnectionState); + } + writer.WriteEndObject(); + writer.WriteEndObject(); + } + + internal static PrivateEndpointConnection DeserializePrivateEndpointConnection(JsonElement element) + { + Optional id = default; + Optional name = default; + Optional type = default; + Optional privateEndpoint = default; + Optional privateLinkServiceConnectionState = default; + Optional provisioningState = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + if (property.NameEquals("properties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("privateEndpoint")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + privateEndpoint = PrivateEndpoint.DeserializePrivateEndpoint(property0.Value); + continue; + } + if (property0.NameEquals("privateLinkServiceConnectionState")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + privateLinkServiceConnectionState = PrivateLinkServiceConnectionState.DeserializePrivateLinkServiceConnectionState(property0.Value); + continue; + } + if (property0.NameEquals("provisioningState")) + { + provisioningState = property0.Value.GetString(); + continue; + } + } + continue; + } + } + return new PrivateEndpointConnection(id.Value, name.Value, type.Value, privateEndpoint.Value, privateLinkServiceConnectionState.Value, provisioningState.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.cs new file mode 100644 index 000000000000..ceab2954853c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateEndpointConnection.cs @@ -0,0 +1,39 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// A private endpoint connection. + public partial class PrivateEndpointConnection : Resource + { + /// Initializes a new instance of PrivateEndpointConnection. + public PrivateEndpointConnection() + { + } + + /// Initializes a new instance of PrivateEndpointConnection. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// The private endpoint which the connection belongs to. + /// Connection state of the private endpoint connection. + /// Provisioning state of the private endpoint connection. + internal PrivateEndpointConnection(string id, string name, string type, PrivateEndpoint privateEndpoint, PrivateLinkServiceConnectionState privateLinkServiceConnectionState, string provisioningState) : base(id, name, type) + { + PrivateEndpoint = privateEndpoint; + PrivateLinkServiceConnectionState = privateLinkServiceConnectionState; + ProvisioningState = provisioningState; + } + + /// The private endpoint which the connection belongs to. + public PrivateEndpoint PrivateEndpoint { get; set; } + /// Connection state of the private endpoint connection. + public PrivateLinkServiceConnectionState PrivateLinkServiceConnectionState { get; set; } + /// Provisioning state of the private endpoint connection. + public string ProvisioningState { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.Serialization.cs new file mode 100644 index 000000000000..1139a92cb44e --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.Serialization.cs @@ -0,0 +1,62 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class PrivateLinkServiceConnectionState : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"); + writer.WriteStringValue(Description); + } + writer.WriteEndObject(); + } + + internal static PrivateLinkServiceConnectionState DeserializePrivateLinkServiceConnectionState(JsonElement element) + { + Optional status = default; + Optional description = default; + Optional actionsRequired = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("status")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + status = new PrivateLinkServiceConnectionStateStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("description")) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("actionsRequired")) + { + actionsRequired = property.Value.GetString(); + continue; + } + } + return new PrivateLinkServiceConnectionState(Optional.ToNullable(status), description.Value, actionsRequired.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.cs new file mode 100644 index 000000000000..b001367e46f3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionState.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Connection state details of the private endpoint. + public partial class PrivateLinkServiceConnectionState + { + /// Initializes a new instance of PrivateLinkServiceConnectionState. + public PrivateLinkServiceConnectionState() + { + } + + /// Initializes a new instance of PrivateLinkServiceConnectionState. + /// The private link service connection status. + /// The private link service connection description. + /// The actions required for private link service connection. + internal PrivateLinkServiceConnectionState(PrivateLinkServiceConnectionStateStatus? status, string description, string actionsRequired) + { + Status = status; + Description = description; + ActionsRequired = actionsRequired; + } + + /// The private link service connection status. + public PrivateLinkServiceConnectionStateStatus? Status { get; set; } + /// The private link service connection description. + public string Description { get; set; } + /// The actions required for private link service connection. + public string ActionsRequired { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionStateStatus.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionStateStatus.cs new file mode 100644 index 000000000000..2dbf4f599f87 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/PrivateLinkServiceConnectionStateStatus.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The private link service connection status. + public readonly partial struct PrivateLinkServiceConnectionStateStatus : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public PrivateLinkServiceConnectionStateStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string ApprovedValue = "Approved"; + private const string PendingValue = "Pending"; + private const string RejectedValue = "Rejected"; + private const string DisconnectedValue = "Disconnected"; + + /// Approved. + public static PrivateLinkServiceConnectionStateStatus Approved { get; } = new PrivateLinkServiceConnectionStateStatus(ApprovedValue); + /// Pending. + public static PrivateLinkServiceConnectionStateStatus Pending { get; } = new PrivateLinkServiceConnectionStateStatus(PendingValue); + /// Rejected. + public static PrivateLinkServiceConnectionStateStatus Rejected { get; } = new PrivateLinkServiceConnectionStateStatus(RejectedValue); + /// Disconnected. + public static PrivateLinkServiceConnectionStateStatus Disconnected { get; } = new PrivateLinkServiceConnectionStateStatus(DisconnectedValue); + /// Determines if two values are the same. + public static bool operator ==(PrivateLinkServiceConnectionStateStatus left, PrivateLinkServiceConnectionStateStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(PrivateLinkServiceConnectionStateStatus left, PrivateLinkServiceConnectionStateStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator PrivateLinkServiceConnectionStateStatus(string value) => new PrivateLinkServiceConnectionStateStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is PrivateLinkServiceConnectionStateStatus other && Equals(other); + /// + public bool Equals(PrivateLinkServiceConnectionStateStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.Serialization.cs new file mode 100644 index 000000000000..6c2e933b9e74 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.Serialization.cs @@ -0,0 +1,47 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class ProxyResource : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WriteEndObject(); + } + + internal static ProxyResource DeserializeProxyResource(JsonElement element) + { + Optional id = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new ProxyResource(id.Value, name.Value, type.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.cs new file mode 100644 index 000000000000..5aa746e2e36f --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ProxyResource.cs @@ -0,0 +1,26 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The resource model definition for a ARM proxy resource. It will have everything other than required location and tags. + public partial class ProxyResource : Resource + { + /// Initializes a new instance of ProxyResource. + public ProxyResource() + { + } + + /// Initializes a new instance of ProxyResource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + internal ProxyResource(string id, string name, string type) : base(id, name, type) + { + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.Serialization.cs index b3027c985dfc..add0b78f87d7 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.Serialization.cs @@ -78,7 +78,7 @@ internal static RecurrenceSchedule DeserializeRecurrenceSchedule(JsonElement ele { Optional> minutes = default; Optional> hours = default; - Optional> weekDays = default; + Optional> weekDays = default; Optional> monthDays = default; Optional> monthlyOccurrences = default; IDictionary additionalProperties = default; @@ -122,10 +122,10 @@ internal static RecurrenceSchedule DeserializeRecurrenceSchedule(JsonElement ele property.ThrowNonNullablePropertyIsNull(); continue; } - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(item.GetString().ToDaysOfWeek()); + array.Add(item.GetString().ToDayOfWeek()); } weekDays = array; continue; diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.cs index f00cd060295c..33b624e70708 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RecurrenceSchedule.cs @@ -19,7 +19,7 @@ public RecurrenceSchedule() { Minutes = new ChangeTrackingList(); Hours = new ChangeTrackingList(); - WeekDays = new ChangeTrackingList(); + WeekDays = new ChangeTrackingList(); MonthDays = new ChangeTrackingList(); MonthlyOccurrences = new ChangeTrackingList(); AdditionalProperties = new ChangeTrackingDictionary(); @@ -32,7 +32,7 @@ public RecurrenceSchedule() /// The month days. /// The monthly occurrences. /// . - internal RecurrenceSchedule(IList minutes, IList hours, IList weekDays, IList monthDays, IList monthlyOccurrences, IDictionary additionalProperties) + internal RecurrenceSchedule(IList minutes, IList hours, IList weekDays, IList monthDays, IList monthlyOccurrences, IDictionary additionalProperties) { Minutes = minutes; Hours = hours; @@ -47,7 +47,7 @@ internal RecurrenceSchedule(IList minutes, IList hours, IList The hours. public IList Hours { get; } /// The days of the week. - public IList WeekDays { get; } + public IList WeekDays { get; } /// The month days. public IList MonthDays { get; } /// The monthly occurrences. diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.Serialization.cs index 6f014fceedf5..1ac5f0cf6883 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static RerunTriggerResource DeserializeRerunTriggerResource(JsonElement element) { RerunTumblingWindowTrigger properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static RerunTriggerResource DeserializeRerunTriggerResource(JsonElement properties = RerunTumblingWindowTrigger.DeserializeRerunTumblingWindowTrigger(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static RerunTriggerResource DeserializeRerunTriggerResource(JsonElement type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new RerunTriggerResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.cs index 3f1f1c30e975..ac3193dc62d2 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/RerunTriggerResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// RerunTrigger resource type. - public partial class RerunTriggerResource : SubResource + public partial class RerunTriggerResource : AzureEntityResource { /// Initializes a new instance of RerunTriggerResource. /// Properties of the rerun trigger. @@ -26,10 +26,10 @@ public RerunTriggerResource(RerunTumblingWindowTrigger properties) } /// Initializes a new instance of RerunTriggerResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of the rerun trigger. internal RerunTriggerResource(string id, string name, string type, string etag, RerunTumblingWindowTrigger properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.Serialization.cs new file mode 100644 index 000000000000..e7e168ba7dd8 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.Serialization.cs @@ -0,0 +1,47 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class Resource : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WriteEndObject(); + } + + internal static Resource DeserializeResource(JsonElement element) + { + Optional id = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new Resource(id.Value, name.Value, type.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.cs index 2259e0d0797a..e57e38b59710 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Resource.cs @@ -5,31 +5,32 @@ #nullable disable -using System.Collections.Generic; -using Azure.Core; - namespace Azure.Analytics.Synapse.Artifacts.Models { - /// Azure Synapse top-level resource. - internal partial class Resource + /// The Resource. + public partial class Resource { /// Initializes a new instance of Resource. - internal Resource() + public Resource() + { + } + + /// Initializes a new instance of Resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + internal Resource(string id, string name, string type) { - Tags = new ChangeTrackingDictionary(); + Id = id; + Name = name; + Type = type; } - /// The resource identifier. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. public string Id { get; } - /// The resource name. + /// The name of the resource. public string Name { get; } - /// The resource type. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. public string Type { get; } - /// The resource location. - public string Location { get; } - /// The resource tags. - public IReadOnlyDictionary Tags { get; } - /// Etag identifies change in the resource. - public string ETag { get; } } } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.Serialization.cs new file mode 100644 index 000000000000..ccc20c0aa333 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.Serialization.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + internal static class ResourceIdentityTypeExtensions + { + public static string ToSerialString(this ResourceIdentityType value) => value switch + { + ResourceIdentityType.None => "None", + ResourceIdentityType.SystemAssigned => "SystemAssigned", + _ => throw new ArgumentOutOfRangeException(nameof(value), value, "Unknown ResourceIdentityType value.") + }; + + public static ResourceIdentityType ToResourceIdentityType(this string value) + { + if (string.Equals(value, "None", StringComparison.InvariantCultureIgnoreCase)) return ResourceIdentityType.None; + if (string.Equals(value, "SystemAssigned", StringComparison.InvariantCultureIgnoreCase)) return ResourceIdentityType.SystemAssigned; + throw new ArgumentOutOfRangeException(nameof(value), value, "Unknown ResourceIdentityType value."); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.cs new file mode 100644 index 000000000000..c87bc7ecbc25 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/ResourceIdentityType.cs @@ -0,0 +1,18 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The type of managed identity for the workspace. + public enum ResourceIdentityType + { + /// None. + None, + /// SystemAssigned. + SystemAssigned + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.Serialization.cs new file mode 100644 index 000000000000..d8e4b452e2d8 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.Serialization.cs @@ -0,0 +1,89 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class SelfHostedIntegrationRuntime : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("type"); + writer.WriteStringValue(Type.ToString()); + if (Optional.IsDefined(Description)) + { + writer.WritePropertyName("description"); + writer.WriteStringValue(Description); + } + writer.WritePropertyName("typeProperties"); + writer.WriteStartObject(); + if (Optional.IsDefined(LinkedInfo)) + { + writer.WritePropertyName("linkedInfo"); + writer.WriteObjectValue(LinkedInfo); + } + writer.WriteEndObject(); + foreach (var item in AdditionalProperties) + { + writer.WritePropertyName(item.Key); + writer.WriteObjectValue(item.Value); + } + writer.WriteEndObject(); + } + + internal static SelfHostedIntegrationRuntime DeserializeSelfHostedIntegrationRuntime(JsonElement element) + { + IntegrationRuntimeType type = default; + Optional description = default; + Optional linkedInfo = default; + IDictionary additionalProperties = default; + Dictionary additionalPropertiesDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("type")) + { + type = new IntegrationRuntimeType(property.Value.GetString()); + continue; + } + if (property.NameEquals("description")) + { + description = property.Value.GetString(); + continue; + } + if (property.NameEquals("typeProperties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("linkedInfo")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + linkedInfo = LinkedIntegrationRuntimeType.DeserializeLinkedIntegrationRuntimeType(property0.Value); + continue; + } + } + continue; + } + additionalPropertiesDictionary.Add(property.Name, property.Value.GetObject()); + } + additionalProperties = additionalPropertiesDictionary; + return new SelfHostedIntegrationRuntime(type, description.Value, additionalProperties, linkedInfo.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.cs new file mode 100644 index 000000000000..254c88c5b108 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SelfHostedIntegrationRuntime.cs @@ -0,0 +1,35 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Self-hosted integration runtime. + public partial class SelfHostedIntegrationRuntime : IntegrationRuntime + { + /// Initializes a new instance of SelfHostedIntegrationRuntime. + public SelfHostedIntegrationRuntime() + { + Type = IntegrationRuntimeType.SelfHosted; + } + + /// Initializes a new instance of SelfHostedIntegrationRuntime. + /// Type of integration runtime. + /// Integration runtime description. + /// . + /// The base definition of a linked integration runtime. + internal SelfHostedIntegrationRuntime(IntegrationRuntimeType type, string description, IDictionary additionalProperties, LinkedIntegrationRuntimeType linkedInfo) : base(type, description, additionalProperties) + { + LinkedInfo = linkedInfo; + Type = type; + } + + /// The base definition of a linked integration runtime. + public LinkedIntegrationRuntimeType LinkedInfo { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.Serialization.cs new file mode 100644 index 000000000000..9cc85f4370b0 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.Serialization.cs @@ -0,0 +1,67 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class Sku : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Tier)) + { + writer.WritePropertyName("tier"); + writer.WriteStringValue(Tier); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(Capacity)) + { + writer.WritePropertyName("capacity"); + writer.WriteNumberValue(Capacity.Value); + } + writer.WriteEndObject(); + } + + internal static Sku DeserializeSku(JsonElement element) + { + Optional tier = default; + Optional name = default; + Optional capacity = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("tier")) + { + tier = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("capacity")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + capacity = property.Value.GetInt32(); + continue; + } + } + return new Sku(tier.Value, name.Value, Optional.ToNullable(capacity)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.cs new file mode 100644 index 000000000000..afadd09da08c --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Sku.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// SQL pool SKU. + public partial class Sku + { + /// Initializes a new instance of Sku. + public Sku() + { + } + + /// Initializes a new instance of Sku. + /// The service tier. + /// The SKU name. + /// If the SKU supports scale out/in then the capacity integer should be included. If scale out/in is not possible for the resource this may be omitted. + internal Sku(string tier, string name, int? capacity) + { + Tier = tier; + Name = name; + Capacity = capacity; + } + + /// The service tier. + public string Tier { get; set; } + /// The SKU name. + public string Name { get; set; } + /// If the SKU supports scale out/in then the capacity integer should be included. If scale out/in is not possible for the resource this may be omitted. + public int? Capacity { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.Serialization.cs index f1c7e542ff5b..45b802976f02 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static SparkJobDefinitionResource DeserializeSparkJobDefinitionResource(JsonElement element) { SparkJobDefinition properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static SparkJobDefinitionResource DeserializeSparkJobDefinitionResource properties = SparkJobDefinition.DeserializeSparkJobDefinition(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static SparkJobDefinitionResource DeserializeSparkJobDefinitionResource type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new SparkJobDefinitionResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.cs index 1c08e61f0462..b741115359cd 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SparkJobDefinitionResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Spark job definition resource type. - public partial class SparkJobDefinitionResource : SubResource + public partial class SparkJobDefinitionResource : AzureEntityResource { /// Initializes a new instance of SparkJobDefinitionResource. /// Properties of spark job definition. @@ -26,10 +26,10 @@ public SparkJobDefinitionResource(SparkJobDefinition properties) } /// Initializes a new instance of SparkJobDefinitionResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of spark job definition. internal SparkJobDefinitionResource(string id, string name, string type, string etag, SparkJobDefinition properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.Serialization.cs new file mode 100644 index 000000000000..665249e550d3 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.Serialization.cs @@ -0,0 +1,229 @@ +// 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.Analytics.Synapse.Artifacts.Models +{ + public partial class SqlPool : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Sku)) + { + writer.WritePropertyName("sku"); + writer.WriteObjectValue(Sku); + } + if (Optional.IsCollectionDefined(Tags)) + { + writer.WritePropertyName("tags"); + writer.WriteStartObject(); + foreach (var item in Tags) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + writer.WritePropertyName("location"); + writer.WriteStringValue(Location); + writer.WritePropertyName("properties"); + writer.WriteStartObject(); + if (Optional.IsDefined(MaxSizeBytes)) + { + writer.WritePropertyName("maxSizeBytes"); + writer.WriteNumberValue(MaxSizeBytes.Value); + } + if (Optional.IsDefined(Collation)) + { + writer.WritePropertyName("collation"); + writer.WriteStringValue(Collation); + } + if (Optional.IsDefined(SourceDatabaseId)) + { + writer.WritePropertyName("sourceDatabaseId"); + writer.WriteStringValue(SourceDatabaseId); + } + if (Optional.IsDefined(RecoverableDatabaseId)) + { + writer.WritePropertyName("recoverableDatabaseId"); + writer.WriteStringValue(RecoverableDatabaseId); + } + if (Optional.IsDefined(ProvisioningState)) + { + writer.WritePropertyName("provisioningState"); + writer.WriteStringValue(ProvisioningState); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"); + writer.WriteStringValue(Status); + } + if (Optional.IsDefined(RestorePointInTime)) + { + writer.WritePropertyName("restorePointInTime"); + writer.WriteStringValue(RestorePointInTime.Value, "O"); + } + if (Optional.IsDefined(CreateMode)) + { + writer.WritePropertyName("createMode"); + writer.WriteStringValue(CreateMode); + } + if (Optional.IsDefined(CreationDate)) + { + writer.WritePropertyName("creationDate"); + writer.WriteStringValue(CreationDate.Value, "O"); + } + writer.WriteEndObject(); + writer.WriteEndObject(); + } + + internal static SqlPool DeserializeSqlPool(JsonElement element) + { + Optional sku = default; + Optional> tags = default; + string location = default; + Optional id = default; + Optional name = default; + Optional type = default; + Optional maxSizeBytes = default; + Optional collation = default; + Optional sourceDatabaseId = default; + Optional recoverableDatabaseId = default; + Optional provisioningState = default; + Optional status = default; + Optional restorePointInTime = default; + Optional createMode = default; + Optional creationDate = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("sku")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + sku = Sku.DeserializeSku(property.Value); + continue; + } + if (property.NameEquals("tags")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + tags = dictionary; + continue; + } + if (property.NameEquals("location")) + { + location = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + if (property.NameEquals("properties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("maxSizeBytes")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + maxSizeBytes = property0.Value.GetInt64(); + continue; + } + if (property0.NameEquals("collation")) + { + collation = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("sourceDatabaseId")) + { + sourceDatabaseId = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("recoverableDatabaseId")) + { + recoverableDatabaseId = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("provisioningState")) + { + provisioningState = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("status")) + { + status = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("restorePointInTime")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + restorePointInTime = property0.Value.GetDateTimeOffset("O"); + continue; + } + if (property0.NameEquals("createMode")) + { + createMode = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("creationDate")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + creationDate = property0.Value.GetDateTimeOffset("O"); + continue; + } + } + continue; + } + } + return new SqlPool(id.Value, name.Value, type.Value, Optional.ToDictionary(tags), location, sku.Value, Optional.ToNullable(maxSizeBytes), collation.Value, sourceDatabaseId.Value, recoverableDatabaseId.Value, provisioningState.Value, status.Value, Optional.ToNullable(restorePointInTime), createMode.Value, Optional.ToNullable(creationDate)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.cs new file mode 100644 index 000000000000..ca2e0006796a --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPool.cs @@ -0,0 +1,78 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// A SQL Analytics pool. + public partial class SqlPool : TrackedResource + { + /// Initializes a new instance of SqlPool. + /// The geo-location where the resource lives. + /// is null. + public SqlPool(string location) : base(location) + { + if (location == null) + { + throw new ArgumentNullException(nameof(location)); + } + } + + /// Initializes a new instance of SqlPool. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource tags. + /// The geo-location where the resource lives. + /// SQL pool SKU. + /// Maximum size in bytes. + /// Collation mode. + /// Source database to create from. + /// Backup database to restore from. + /// Resource state. + /// Resource status. + /// Snapshot time to restore. + /// What is this?. + /// Date the SQL pool was created. + internal SqlPool(string id, string name, string type, IDictionary tags, string location, Sku sku, long? maxSizeBytes, string collation, string sourceDatabaseId, string recoverableDatabaseId, string provisioningState, string status, DateTimeOffset? restorePointInTime, string createMode, DateTimeOffset? creationDate) : base(id, name, type, tags, location) + { + Sku = sku; + MaxSizeBytes = maxSizeBytes; + Collation = collation; + SourceDatabaseId = sourceDatabaseId; + RecoverableDatabaseId = recoverableDatabaseId; + ProvisioningState = provisioningState; + Status = status; + RestorePointInTime = restorePointInTime; + CreateMode = createMode; + CreationDate = creationDate; + } + + /// SQL pool SKU. + public Sku Sku { get; set; } + /// Maximum size in bytes. + public long? MaxSizeBytes { get; set; } + /// Collation mode. + public string Collation { get; set; } + /// Source database to create from. + public string SourceDatabaseId { get; set; } + /// Backup database to restore from. + public string RecoverableDatabaseId { get; set; } + /// Resource state. + public string ProvisioningState { get; set; } + /// Resource status. + public string Status { get; set; } + /// Snapshot time to restore. + public DateTimeOffset? RestorePointInTime { get; set; } + /// What is this?. + public string CreateMode { get; set; } + /// Date the SQL pool was created. + public DateTimeOffset? CreationDate { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.Serialization.cs new file mode 100644 index 000000000000..32150e6f2b1e --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.Serialization.cs @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class SqlPoolInfoListResult + { + internal static SqlPoolInfoListResult DeserializeSqlPoolInfoListResult(JsonElement element) + { + Optional nextLink = default; + Optional> value = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("nextLink")) + { + nextLink = property.Value.GetString(); + continue; + } + if (property.NameEquals("value")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(SqlPool.DeserializeSqlPool(item)); + } + value = array; + continue; + } + } + return new SqlPoolInfoListResult(nextLink.Value, Optional.ToList(value)); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.cs new file mode 100644 index 000000000000..187808661c63 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlPoolInfoListResult.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// List of SQL pools. + public partial class SqlPoolInfoListResult + { + /// Initializes a new instance of SqlPoolInfoListResult. + internal SqlPoolInfoListResult() + { + Value = new ChangeTrackingList(); + } + + /// Initializes a new instance of SqlPoolInfoListResult. + /// Link to the next page of results. + /// List of SQL pools. + internal SqlPoolInfoListResult(string nextLink, IReadOnlyList value) + { + NextLink = nextLink; + Value = value; + } + + /// Link to the next page of results. + public string NextLink { get; } + /// List of SQL pools. + public IReadOnlyList Value { get; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.Serialization.cs index c124eec6982e..2541841b7fd7 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static SqlScriptResource DeserializeSqlScriptResource(JsonElement element) { SqlScript properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static SqlScriptResource DeserializeSqlScriptResource(JsonElement eleme properties = SqlScript.DeserializeSqlScript(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static SqlScriptResource DeserializeSqlScriptResource(JsonElement eleme type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new SqlScriptResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.cs index 8a4095336317..4399a5209b1e 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SqlScriptResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Sql Script resource type. - public partial class SqlScriptResource : SubResource + public partial class SqlScriptResource : AzureEntityResource { /// Initializes a new instance of SqlScriptResource. /// Properties of sql script. @@ -26,10 +26,10 @@ public SqlScriptResource(SqlScript properties) } /// Initializes a new instance of SqlScriptResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of sql script. internal SqlScriptResource(string id, string name, string type, string etag, SqlScript properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.Serialization.cs index 248ab9f8a973..33e72bf0a103 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.Serialization.cs @@ -20,12 +20,17 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static SubResource DeserializeSubResource(JsonElement element) { + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -41,11 +46,6 @@ internal static SubResource DeserializeSubResource(JsonElement element) type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new SubResource(id.Value, name.Value, type.Value, etag.Value); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.cs index 7a1a7f69b14b..3f67f373261b 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/SubResource.cs @@ -8,7 +8,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Azure Synapse nested resource, which belongs to a workspace. - public partial class SubResource + public partial class SubResource : AzureEntityResource { /// Initializes a new instance of SubResource. public SubResource() @@ -16,25 +16,12 @@ public SubResource() } /// Initializes a new instance of SubResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. - internal SubResource(string id, string name, string type, string etag) + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. + internal SubResource(string id, string name, string type, string etag) : base(id, name, type, etag) { - Id = id; - Name = name; - Type = type; - Etag = etag; } - - /// The resource identifier. - public string Id { get; } - /// The resource name. - public string Name { get; } - /// The resource type. - public string Type { get; } - /// Etag identifies change in the resource. - public string Etag { get; } } } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.Serialization.cs new file mode 100644 index 000000000000..03a04a6431c4 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.Serialization.cs @@ -0,0 +1,83 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class TrackedResource : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsCollectionDefined(Tags)) + { + writer.WritePropertyName("tags"); + writer.WriteStartObject(); + foreach (var item in Tags) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + writer.WritePropertyName("location"); + writer.WriteStringValue(Location); + writer.WriteEndObject(); + } + + internal static TrackedResource DeserializeTrackedResource(JsonElement element) + { + Optional> tags = default; + string location = default; + Optional id = default; + Optional name = default; + Optional type = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("tags")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + tags = dictionary; + continue; + } + if (property.NameEquals("location")) + { + location = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + } + return new TrackedResource(id.Value, name.Value, type.Value, Optional.ToDictionary(tags), location); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.cs new file mode 100644 index 000000000000..3aabb5f5b594 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TrackedResource.cs @@ -0,0 +1,48 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// The resource model definition for a ARM tracked top level resource. + public partial class TrackedResource : Resource + { + /// Initializes a new instance of TrackedResource. + /// The geo-location where the resource lives. + /// is null. + public TrackedResource(string location) + { + if (location == null) + { + throw new ArgumentNullException(nameof(location)); + } + + Tags = new ChangeTrackingDictionary(); + Location = location; + } + + /// Initializes a new instance of TrackedResource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource tags. + /// The geo-location where the resource lives. + internal TrackedResource(string id, string name, string type, IDictionary tags, string location) : base(id, name, type) + { + Tags = tags; + Location = location; + } + + /// Resource tags. + public IDictionary Tags { get; } + /// The geo-location where the resource lives. + public string Location { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.Serialization.cs index a379da912c1b..118aab8d27c0 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.Serialization.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.Serialization.cs @@ -23,10 +23,10 @@ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) internal static TriggerResource DeserializeTriggerResource(JsonElement element) { Trigger properties = default; + Optional etag = default; Optional id = default; Optional name = default; Optional type = default; - Optional etag = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("properties")) @@ -34,6 +34,11 @@ internal static TriggerResource DeserializeTriggerResource(JsonElement element) properties = Trigger.DeserializeTrigger(property.Value); continue; } + if (property.NameEquals("etag")) + { + etag = property.Value.GetString(); + continue; + } if (property.NameEquals("id")) { id = property.Value.GetString(); @@ -49,11 +54,6 @@ internal static TriggerResource DeserializeTriggerResource(JsonElement element) type = property.Value.GetString(); continue; } - if (property.NameEquals("etag")) - { - etag = property.Value.GetString(); - continue; - } } return new TriggerResource(id.Value, name.Value, type.Value, etag.Value, properties); } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.cs index b38b252264dc..07eaa46e2e49 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/TriggerResource.cs @@ -10,7 +10,7 @@ namespace Azure.Analytics.Synapse.Artifacts.Models { /// Trigger resource type. - public partial class TriggerResource : SubResource + public partial class TriggerResource : AzureEntityResource { /// Initializes a new instance of TriggerResource. /// Properties of the trigger. @@ -26,10 +26,10 @@ public TriggerResource(Trigger properties) } /// Initializes a new instance of TriggerResource. - /// The resource identifier. - /// The resource name. - /// The resource type. - /// Etag identifies change in the resource. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource Etag. /// Properties of the trigger. internal TriggerResource(string id, string name, string type, string etag, Trigger properties) : base(id, name, type, etag) { diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.Serialization.cs new file mode 100644 index 000000000000..d7fbb5005625 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.Serialization.cs @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class VirtualNetworkProfile : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(ComputeSubnetId)) + { + writer.WritePropertyName("computeSubnetId"); + writer.WriteStringValue(ComputeSubnetId); + } + writer.WriteEndObject(); + } + + internal static VirtualNetworkProfile DeserializeVirtualNetworkProfile(JsonElement element) + { + Optional computeSubnetId = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("computeSubnetId")) + { + computeSubnetId = property.Value.GetString(); + continue; + } + } + return new VirtualNetworkProfile(computeSubnetId.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.cs new file mode 100644 index 000000000000..592b7b2510ce --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/VirtualNetworkProfile.cs @@ -0,0 +1,28 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + /// Virtual Network Profile. + public partial class VirtualNetworkProfile + { + /// Initializes a new instance of VirtualNetworkProfile. + public VirtualNetworkProfile() + { + } + + /// Initializes a new instance of VirtualNetworkProfile. + /// Subnet ID used for computes in workspace. + internal VirtualNetworkProfile(string computeSubnetId) + { + ComputeSubnetId = computeSubnetId; + } + + /// Subnet ID used for computes in workspace. + public string ComputeSubnetId { get; set; } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.Serialization.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.Serialization.cs new file mode 100644 index 000000000000..af301082c1af --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.Serialization.cs @@ -0,0 +1,281 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Analytics.Synapse.Artifacts.Models +{ + public partial class Workspace : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + if (Optional.IsDefined(Identity)) + { + writer.WritePropertyName("identity"); + writer.WriteObjectValue(Identity); + } + if (Optional.IsCollectionDefined(Tags)) + { + writer.WritePropertyName("tags"); + writer.WriteStartObject(); + foreach (var item in Tags) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + writer.WritePropertyName("location"); + writer.WriteStringValue(Location); + writer.WritePropertyName("properties"); + writer.WriteStartObject(); + if (Optional.IsDefined(DefaultDataLakeStorage)) + { + writer.WritePropertyName("defaultDataLakeStorage"); + writer.WriteObjectValue(DefaultDataLakeStorage); + } + if (Optional.IsDefined(SqlAdministratorLoginPassword)) + { + writer.WritePropertyName("sqlAdministratorLoginPassword"); + writer.WriteStringValue(SqlAdministratorLoginPassword); + } + if (Optional.IsDefined(ManagedResourceGroupName)) + { + writer.WritePropertyName("managedResourceGroupName"); + writer.WriteStringValue(ManagedResourceGroupName); + } + if (Optional.IsDefined(SqlAdministratorLogin)) + { + writer.WritePropertyName("sqlAdministratorLogin"); + writer.WriteStringValue(SqlAdministratorLogin); + } + if (Optional.IsDefined(VirtualNetworkProfile)) + { + writer.WritePropertyName("virtualNetworkProfile"); + writer.WriteObjectValue(VirtualNetworkProfile); + } + if (Optional.IsCollectionDefined(ConnectivityEndpoints)) + { + writer.WritePropertyName("connectivityEndpoints"); + writer.WriteStartObject(); + foreach (var item in ConnectivityEndpoints) + { + writer.WritePropertyName(item.Key); + writer.WriteStringValue(item.Value); + } + writer.WriteEndObject(); + } + if (Optional.IsDefined(ManagedVirtualNetwork)) + { + writer.WritePropertyName("managedVirtualNetwork"); + writer.WriteStringValue(ManagedVirtualNetwork); + } + if (Optional.IsCollectionDefined(PrivateEndpointConnections)) + { + writer.WritePropertyName("privateEndpointConnections"); + writer.WriteStartArray(); + foreach (var item in PrivateEndpointConnections) + { + writer.WriteObjectValue(item); + } + writer.WriteEndArray(); + } + if (Optional.IsDefined(ManagedVirtualNetworkSettings)) + { + writer.WritePropertyName("managedVirtualNetworkSettings"); + writer.WriteObjectValue(ManagedVirtualNetworkSettings); + } + writer.WriteEndObject(); + writer.WriteEndObject(); + } + + internal static Workspace DeserializeWorkspace(JsonElement element) + { + Optional identity = default; + Optional> tags = default; + string location = default; + Optional id = default; + Optional name = default; + Optional type = default; + Optional defaultDataLakeStorage = default; + Optional sqlAdministratorLoginPassword = default; + Optional managedResourceGroupName = default; + Optional provisioningState = default; + Optional sqlAdministratorLogin = default; + Optional virtualNetworkProfile = default; + Optional> connectivityEndpoints = default; + Optional managedVirtualNetwork = default; + Optional> privateEndpointConnections = default; + Optional> extraProperties = default; + Optional managedVirtualNetworkSettings = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("identity")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + identity = ManagedIdentity.DeserializeManagedIdentity(property.Value); + continue; + } + if (property.NameEquals("tags")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property0 in property.Value.EnumerateObject()) + { + dictionary.Add(property0.Name, property0.Value.GetString()); + } + tags = dictionary; + continue; + } + if (property.NameEquals("location")) + { + location = property.Value.GetString(); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name")) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type")) + { + type = property.Value.GetString(); + continue; + } + if (property.NameEquals("properties")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + foreach (var property0 in property.Value.EnumerateObject()) + { + if (property0.NameEquals("defaultDataLakeStorage")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + defaultDataLakeStorage = DataLakeStorageAccountDetails.DeserializeDataLakeStorageAccountDetails(property0.Value); + continue; + } + if (property0.NameEquals("sqlAdministratorLoginPassword")) + { + sqlAdministratorLoginPassword = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("managedResourceGroupName")) + { + managedResourceGroupName = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("provisioningState")) + { + provisioningState = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("sqlAdministratorLogin")) + { + sqlAdministratorLogin = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("virtualNetworkProfile")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + virtualNetworkProfile = VirtualNetworkProfile.DeserializeVirtualNetworkProfile(property0.Value); + continue; + } + if (property0.NameEquals("connectivityEndpoints")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property1 in property0.Value.EnumerateObject()) + { + dictionary.Add(property1.Name, property1.Value.GetString()); + } + connectivityEndpoints = dictionary; + continue; + } + if (property0.NameEquals("managedVirtualNetwork")) + { + managedVirtualNetwork = property0.Value.GetString(); + continue; + } + if (property0.NameEquals("privateEndpointConnections")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property0.Value.EnumerateArray()) + { + array.Add(PrivateEndpointConnection.DeserializePrivateEndpointConnection(item)); + } + privateEndpointConnections = array; + continue; + } + if (property0.NameEquals("extraProperties")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + Dictionary dictionary = new Dictionary(); + foreach (var property1 in property0.Value.EnumerateObject()) + { + dictionary.Add(property1.Name, property1.Value.GetObject()); + } + extraProperties = dictionary; + continue; + } + if (property0.NameEquals("managedVirtualNetworkSettings")) + { + if (property0.Value.ValueKind == JsonValueKind.Null) + { + property0.ThrowNonNullablePropertyIsNull(); + continue; + } + managedVirtualNetworkSettings = ManagedVirtualNetworkSettings.DeserializeManagedVirtualNetworkSettings(property0.Value); + continue; + } + } + continue; + } + } + return new Workspace(id.Value, name.Value, type.Value, Optional.ToDictionary(tags), location, identity.Value, defaultDataLakeStorage.Value, sqlAdministratorLoginPassword.Value, managedResourceGroupName.Value, provisioningState.Value, sqlAdministratorLogin.Value, virtualNetworkProfile.Value, Optional.ToDictionary(connectivityEndpoints), managedVirtualNetwork.Value, Optional.ToList(privateEndpointConnections), Optional.ToDictionary(extraProperties), managedVirtualNetworkSettings.Value); + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.cs index e9d5b5ec1ee5..614f4703596f 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/Models/Workspace.cs @@ -6,52 +6,86 @@ #nullable disable using System; -using System.Collections; using System.Collections.Generic; using Azure.Core; namespace Azure.Analytics.Synapse.Artifacts.Models { - /// Workspace resource type. - internal partial class Workspace : Resource, IReadOnlyDictionary + /// A workspace. + public partial class Workspace : TrackedResource { /// Initializes a new instance of Workspace. - internal Workspace() + /// The geo-location where the resource lives. + /// is null. + public Workspace(string location) : base(location) { - AdditionalProperties = new ChangeTrackingDictionary(); + if (location == null) + { + throw new ArgumentNullException(nameof(location)); + } + + ConnectivityEndpoints = new ChangeTrackingDictionary(); + PrivateEndpointConnections = new ChangeTrackingList(); + ExtraProperties = new ChangeTrackingDictionary(); } - /// Managed service identity of the workspace. - public WorkspaceIdentity Identity { get; } - /// Workspace provisioning state, example Succeeded. - public string ProvisioningState { get; } - /// Time the workspace was created in ISO8601 format. - public DateTimeOffset? CreateTime { get; } - /// Version of the workspace. - public string Version { get; } - /// Linked service reference. - public LinkedServiceReference DefaultStorage { get; } - /// Linked service reference. - public LinkedServiceReference DefaultSqlServer { get; } - internal IReadOnlyDictionary AdditionalProperties { get; } - /// - public IEnumerator> GetEnumerator() => AdditionalProperties.GetEnumerator(); - /// - IEnumerator IEnumerable.GetEnumerator() => AdditionalProperties.GetEnumerator(); - /// - public bool TryGetValue(string key, out object value) => AdditionalProperties.TryGetValue(key, out value); - /// - public bool ContainsKey(string key) => AdditionalProperties.ContainsKey(key); - /// - public IEnumerable Keys => AdditionalProperties.Keys; - /// - public IEnumerable Values => AdditionalProperties.Values; - /// - int IReadOnlyCollection>.Count => AdditionalProperties.Count; - /// - public object this[string key] + /// Initializes a new instance of Workspace. + /// Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. + /// The name of the resource. + /// The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + /// Resource tags. + /// The geo-location where the resource lives. + /// Identity of the workspace. + /// Workspace default data lake storage account details. + /// SQL administrator login password. + /// Workspace managed resource group. The resource group name uniquely identifies the resource group within the user subscriptionId. The resource group name must be no longer than 90 characters long, and must be alphanumeric characters (Char.IsLetterOrDigit()) and '-', '_', '(', ')' and'.'. Note that the name cannot end with '.'. + /// Resource provisioning state. + /// Login for workspace SQL active directory administrator. + /// Virtual Network profile. + /// Connectivity endpoints. + /// Setting this to 'default' will ensure that all compute for this workspace is in a virtual network managed on behalf of the user. + /// Private endpoint connections to the workspace. + /// Workspace level configs and feature flags. + /// Managed Virtual Network Settings. + internal Workspace(string id, string name, string type, IDictionary tags, string location, ManagedIdentity identity, DataLakeStorageAccountDetails defaultDataLakeStorage, string sqlAdministratorLoginPassword, string managedResourceGroupName, string provisioningState, string sqlAdministratorLogin, VirtualNetworkProfile virtualNetworkProfile, IDictionary connectivityEndpoints, string managedVirtualNetwork, IList privateEndpointConnections, IReadOnlyDictionary extraProperties, ManagedVirtualNetworkSettings managedVirtualNetworkSettings) : base(id, name, type, tags, location) { - get => AdditionalProperties[key]; + Identity = identity; + DefaultDataLakeStorage = defaultDataLakeStorage; + SqlAdministratorLoginPassword = sqlAdministratorLoginPassword; + ManagedResourceGroupName = managedResourceGroupName; + ProvisioningState = provisioningState; + SqlAdministratorLogin = sqlAdministratorLogin; + VirtualNetworkProfile = virtualNetworkProfile; + ConnectivityEndpoints = connectivityEndpoints; + ManagedVirtualNetwork = managedVirtualNetwork; + PrivateEndpointConnections = privateEndpointConnections; + ExtraProperties = extraProperties; + ManagedVirtualNetworkSettings = managedVirtualNetworkSettings; } + + /// Identity of the workspace. + public ManagedIdentity Identity { get; set; } + /// Workspace default data lake storage account details. + public DataLakeStorageAccountDetails DefaultDataLakeStorage { get; set; } + /// SQL administrator login password. + public string SqlAdministratorLoginPassword { get; set; } + /// Workspace managed resource group. The resource group name uniquely identifies the resource group within the user subscriptionId. The resource group name must be no longer than 90 characters long, and must be alphanumeric characters (Char.IsLetterOrDigit()) and '-', '_', '(', ')' and'.'. Note that the name cannot end with '.'. + public string ManagedResourceGroupName { get; set; } + /// Resource provisioning state. + public string ProvisioningState { get; } + /// Login for workspace SQL active directory administrator. + public string SqlAdministratorLogin { get; set; } + /// Virtual Network profile. + public VirtualNetworkProfile VirtualNetworkProfile { get; set; } + /// Connectivity endpoints. + public IDictionary ConnectivityEndpoints { get; } + /// Setting this to 'default' will ensure that all compute for this workspace is in a virtual network managed on behalf of the user. + public string ManagedVirtualNetwork { get; set; } + /// Private endpoint connections to the workspace. + public IList PrivateEndpointConnections { get; } + /// Workspace level configs and feature flags. + public IReadOnlyDictionary ExtraProperties { get; } + /// Managed Virtual Network Settings. + public ManagedVirtualNetworkSettings ManagedVirtualNetworkSettings { get; set; } } } diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsClient.cs new file mode 100644 index 000000000000..4ff371e3f054 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsClient.cs @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + /// The SqlPools service client. + public partial class SqlPoolsClient + { + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + internal SqlPoolsRestClient RestClient { get; } + /// Initializes a new instance of SqlPoolsClient for mocking. + protected SqlPoolsClient() + { + } + /// Initializes a new instance of SqlPoolsClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + internal SqlPoolsClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + RestClient = new SqlPoolsRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + /// List Sql Pools. + /// The cancellation token to use. + public virtual async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("SqlPoolsClient.List"); + scope.Start(); + try + { + return await RestClient.ListAsync(cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// List Sql Pools. + /// The cancellation token to use. + public virtual Response List(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("SqlPoolsClient.List"); + scope.Start(); + try + { + return RestClient.List(cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Sql Pool. + /// The Sql Pool name. + /// The cancellation token to use. + public virtual async Task> GetAsync(string sqlPoolName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("SqlPoolsClient.Get"); + scope.Start(); + try + { + return await RestClient.GetAsync(sqlPoolName, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Sql Pool. + /// The Sql Pool name. + /// The cancellation token to use. + public virtual Response Get(string sqlPoolName, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("SqlPoolsClient.Get"); + scope.Start(); + try + { + return RestClient.Get(sqlPoolName, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsRestClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsRestClient.cs new file mode 100644 index 000000000000..39ebbdb44d41 --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/SqlPoolsRestClient.cs @@ -0,0 +1,172 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + internal partial class SqlPoolsRestClient + { + private string endpoint; + private string apiVersion; + private ClientDiagnostics _clientDiagnostics; + private HttpPipeline _pipeline; + + /// Initializes a new instance of SqlPoolsRestClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + /// or is null. + public SqlPoolsRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + if (endpoint == null) + { + throw new ArgumentNullException(nameof(endpoint)); + } + if (apiVersion == null) + { + throw new ArgumentNullException(nameof(apiVersion)); + } + + this.endpoint = endpoint; + this.apiVersion = apiVersion; + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + internal HttpMessage CreateListRequest() + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/sqlPools", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// List Sql Pools. + /// The cancellation token to use. + public async Task> ListAsync(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + SqlPoolInfoListResult value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = SqlPoolInfoListResult.DeserializeSqlPoolInfoListResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// List Sql Pools. + /// The cancellation token to use. + public Response List(CancellationToken cancellationToken = default) + { + using var message = CreateListRequest(); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + SqlPoolInfoListResult value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = SqlPoolInfoListResult.DeserializeSqlPoolInfoListResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetRequest(string sqlPoolName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/sqlPools/", false); + uri.AppendPath(sqlPoolName, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Get Sql Pool. + /// The Sql Pool name. + /// The cancellation token to use. + /// is null. + public async Task> GetAsync(string sqlPoolName, CancellationToken cancellationToken = default) + { + if (sqlPoolName == null) + { + throw new ArgumentNullException(nameof(sqlPoolName)); + } + + using var message = CreateGetRequest(sqlPoolName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + SqlPool value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = SqlPool.DeserializeSqlPool(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Get Sql Pool. + /// The Sql Pool name. + /// The cancellation token to use. + /// is null. + public Response Get(string sqlPoolName, CancellationToken cancellationToken = default) + { + if (sqlPoolName == null) + { + throw new ArgumentNullException(nameof(sqlPoolName)); + } + + using var message = CreateGetRequest(sqlPoolName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + SqlPool value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = SqlPool.DeserializeSqlPool(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceClient.cs new file mode 100644 index 000000000000..05e50fbc4b8f --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceClient.cs @@ -0,0 +1,73 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + /// The Workspace service client. + public partial class WorkspaceClient + { + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + internal WorkspaceRestClient RestClient { get; } + /// Initializes a new instance of WorkspaceClient for mocking. + protected WorkspaceClient() + { + } + /// Initializes a new instance of WorkspaceClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + internal WorkspaceClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + RestClient = new WorkspaceRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + /// Get Workspace. + /// The cancellation token to use. + public virtual async Task> GetAsync(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("WorkspaceClient.Get"); + scope.Start(); + try + { + return await RestClient.GetAsync(cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Get Workspace. + /// The cancellation token to use. + public virtual Response Get(CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("WorkspaceClient.Get"); + scope.Start(); + try + { + return RestClient.Get(cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceRestClient.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceRestClient.cs new file mode 100644 index 000000000000..ceb0be43510d --- /dev/null +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Generated/WorkspaceRestClient.cs @@ -0,0 +1,103 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Analytics.Synapse.Artifacts.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Analytics.Synapse.Artifacts +{ + internal partial class WorkspaceRestClient + { + private string endpoint; + private string apiVersion; + private ClientDiagnostics _clientDiagnostics; + private HttpPipeline _pipeline; + + /// Initializes a new instance of WorkspaceRestClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The workspace development endpoint, for example https://myworkspace.dev.azuresynapse.net. + /// Api Version. + /// or is null. + public WorkspaceRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2019-06-01-preview") + { + if (endpoint == null) + { + throw new ArgumentNullException(nameof(endpoint)); + } + if (apiVersion == null) + { + throw new ArgumentNullException(nameof(apiVersion)); + } + + this.endpoint = endpoint; + this.apiVersion = apiVersion; + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + internal HttpMessage CreateGetRequest() + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/workspace", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Get Workspace. + /// The cancellation token to use. + public async Task> GetAsync(CancellationToken cancellationToken = default) + { + using var message = CreateGetRequest(); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + Workspace value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = Workspace.DeserializeWorkspace(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Get Workspace. + /// The cancellation token to use. + public Response Get(CancellationToken cancellationToken = default) + { + using var message = CreateGetRequest(); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + Workspace value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = Workspace.DeserializeWorkspace(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Properties/AssemblyInfo.cs b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Properties/AssemblyInfo.cs index f752319a6530..7a8a7ab2008c 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Properties/AssemblyInfo.cs +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/Properties/AssemblyInfo.cs @@ -12,3 +12,6 @@ [assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Activity")] [assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Dataset")] [assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Notebook")] +[assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Workspace")] +[assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Resource")] +[assembly: SuppressMessage("Usage", "AZC0012:Avoid single word type names", Justification = "", Scope = "type", Target = "~T:Azure.Analytics.Synapse.Artifacts.Models.Sku")] diff --git a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/autorest.md b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/autorest.md index 4b485e474f8f..1302835d3303 100644 --- a/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/autorest.md +++ b/sdk/synapse/Azure.Analytics.Synapse.Artifacts/src/autorest.md @@ -6,7 +6,7 @@ Run `dotnet build /t:GenerateCode` to generate code. > see https://aka.ms/autorest ```yaml -repo: https://github.com/Azure/azure-rest-api-specs/blob/036a9bba574b092c83a5d1b2fd9482d87e8fdc9d +repo: https://github.com/Azure/azure-rest-api-specs/blob/6dbb686b279234e608aba00309e6b8564c291c97 ``` ``` yaml @@ -23,4 +23,8 @@ input-file: - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/entityTypes/SparkJobDefinition.json - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/entityTypes/SqlScript.json - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/entityTypes/Trigger.json + - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/bigDataPools.json + - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/integrationRuntimes.json + - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/sqlPools.json + - $(repo)/specification/synapse/data-plane/Microsoft.Synapse/preview/2019-06-01-preview/workspace.json ```