Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

PostgreSQL Flexible server added support for new api version 2023-03-01-preview which includes some new features and bug fixes #36788

Merged
Merged
Show file tree
Hide file tree
Changes from 41 commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
01e28ea
PostgreSQL Flexible server added support for new api version 2023-03-…
ambrahma Jun 1, 2023
f1ee677
Update changelog to add accidentally removed history for previous rel…
ambrahma Jun 1, 2023
59dfe2f
Remove changelog entry for latest version
ambrahma Jun 1, 2023
8c46532
Update changelog for latest version
ambrahma Jun 1, 2023
db1cedb
Update code to point to latest swagger release and add test coverage
ambrahma Jul 5, 2023
8003c04
Merge changes with main branch and resolve conflits
ambrahma Jul 5, 2023
2cc81d4
Merge branch 'main' of https://github.com/ambrahma/azure-sdk-for-net …
ambrahma Jul 6, 2023
91fa3d8
Fix some of the errors related to backward compatibility
ambrahma Jul 6, 2023
235ed6d
Remove unwanted file
ambrahma Jul 6, 2023
3307b12
Add StorageSizeInGB back
ambrahma Jul 6, 2023
442dae2
Fix backward cmpatibility for few CapabilityProperties and add new re…
ambrahma Jul 6, 2023
9be6ff0
Update some of the properties for backward compatibility
ambrahma Jul 6, 2023
adedd0a
Rename a model
ambrahma Jul 6, 2023
23a1563
Revert renaming
ambrahma Jul 6, 2023
bacfcb5
Rerecord tests for replica
ambrahma Jul 6, 2023
ad577d4
Fix backward compatibility around fastProvisioningSupported
ambrahma Jul 7, 2023
16ae4bb
Add new recording for GeoRestore
ambrahma Jul 7, 2023
f1f5db2
Merge changes with main branch to remove the test recordings
ambrahma Jul 7, 2023
26b72ba
Fix couple of backward compatibility issues
ambrahma Jul 7, 2023
d3fcc9d
Fix review comments
ambrahma Jul 10, 2023
4ab5ecf
Fix errors for zone and supportedHAModes
ambrahma Jul 10, 2023
0a687de
Fix errors around updated enum values
ambrahma Jul 10, 2023
2adb69c
Fix PostgreSqlFlexibleServerStorageTierCapability errors and revert c…
ambrahma Jul 10, 2023
96dfda7
Fix errors for PostgreSqlFlexibleServerStorageCapability
ambrahma Jul 10, 2023
fa583a1
Add older unwanted models and mark them explicitly as EditorBrowsable…
ambrahma Jul 10, 2023
1c2d698
Fix suggestion around naming of enum
ambrahma Jul 10, 2023
d822cf2
Update tag for assets
ambrahma Jul 10, 2023
a3f870e
Reverted commented code and updated tag for assets.json
ambrahma Jul 11, 2023
ff52d75
Mark ReviveDropped as Live only test and update tests and assets.json
ambrahma Jul 11, 2023
09f3037
Merge with master
ambrahma Jul 11, 2023
af21ef4
Update tests
ambrahma Jul 11, 2023
eff0292
Update assets.json
dvbb Jul 12, 2023
a22d15e
Merge branch 'Azure:main' into postgresql-flexibleserver-20230301preview
ambrahma Jul 12, 2023
fd0674e
Merge branch 'main' into postgresql-flexibleserver-20230301preview
live1206 Jul 13, 2023
3f75692
Merge branch 'Azure:main' into postgresql-flexibleserver-20230301preview
ambrahma Jul 13, 2023
b8dfe39
Fix review comments and few test recordings
ambrahma Jul 13, 2023
2b8c3ce
Fix review comments
ambrahma Jul 13, 2023
6dcee83
Rename CheckMigrationNameAvailability
ambrahma Jul 13, 2023
2f74176
Export API changes
ambrahma Jul 13, 2023
293c407
Rename GetLogFiles
ambrahma Jul 13, 2023
2c3ca79
Update the tag for tests
ambrahma Jul 13, 2023
6ddf5cc
Update test tag which contains all desired test recordings
ambrahma Jul 14, 2023
35121f2
Fix review comments
ambrahma Jul 14, 2023
9f8aa8f
Merge branch 'main' of https://github.com/ambrahma/azure-sdk-for-net …
ambrahma Jul 18, 2023
a1cfa85
Fix pending breaking changes as per recommendation
ambrahma Jul 18, 2023
23f11d5
Export api for changes
ambrahma Jul 18, 2023
97b15cb
Update CHANGELOG.md
ArcturusZhang Jul 18, 2023
fa1f72f
Update CHANGELOG.md
ArcturusZhang Jul 18, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions sdk/postgresql/Azure.ResourceManager.PostgreSql/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,30 @@

## 1.2.0-beta.2 (Unreleased)

This release uses api version 2023-03-01-preview for PostgreSQL flexible server.

### Features Added

- Data Encryption support for Geo-backup enabled servers.
- ReviveDropped. This allows you to revive the dropped servers.
- Migration
- Performance tier scaling for Storage
- Long Term Retention Backup
- LogFiles

### Breaking Changes

- Updated response object for ExecuteLocationBasedCapabilities.
- New properties added for Storage object under PostgreSqlFlexibleServerData to support features like IOPS scaling and Storage AutoGrow. StorageSizeInGB property available under Storage.

### Bugs Fixed

- ReplicaCapacity under PostgreSqlFlexibleServerData is now marked as read-only as this cannot be updated.
- Removed unsupported IdentityType "SystemAssigned".
- Renamed KeyType for Data encryption feature from unsupported SystemAssigned to supported SystemManaged.
- Support Network object to be updated as part of PostgreSqlFlexibleServerPatch call.
- Remove unsupported ReplicationRoles GeoSyncReplica, Secondary, SyncReplica, WalReplica.

### Other Changes

## 1.2.0-beta.1 (2023-05-31)
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "net",
"TagPrefix": "net/postgresql/Azure.ResourceManager.PostgreSql",
"Tag": "net/postgresql/Azure.ResourceManager.PostgreSql_fe6acfa75b"
"Tag": "net/postgresql/Azure.ResourceManager.PostgreSql_d63febae65"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable enable
ambrahma marked this conversation as resolved.
Show resolved Hide resolved

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Base object for representing capability. </summary>
public partial class PostgreSqlBaseCapability
{
/// <summary> Readonly status of the capability. </summary>
public string? Status
ambrahma marked this conversation as resolved.
Show resolved Hide resolved
{
get => CapabilityStatus?.ToString();
}
}
}
ambrahma marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System.Collections.Generic;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Capability for the PostgreSQL server. </summary>
public partial class PostgreSqlFlexibleServerCapabilityProperties : PostgreSqlBaseCapability
{
/// <summary> List of supported flexible server editions. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerEditionCapability> SupportedFlexibleServerEditions
{
get => SupportedServerEditions;
}
ambrahma marked this conversation as resolved.
Show resolved Hide resolved
/// <summary> Gets the supported hyperscale node editions. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerHyperscaleNodeEditionCapability> SupportedHyperscaleNodeEditions { get; }
/// <summary> A value indicating whether fast provisioning is supported in this region. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public bool? FastProvisioningSupported
{
get => SupportFastProvisioning is null ? false : SupportFastProvisioning == PostgreSqlFlexibleServerFastProvisioningSupported.Enabled;
}
/// <summary> A value indicating whether a new server in this region can have geo-backups to paired region. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public bool? IsGeoBackupSupported
{
get => GeoBackupSupported is null ? false : GeoBackupSupported == PostgreSqlFlexibleServerGeoBackupSupported.Enabled;
}
/// <summary> A value indicating whether a new server in this region can be zone redundant HA enabled. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public bool? IsZoneRedundantHASupported
{
get => ZoneRedundantHaSupported is null ? false : ZoneRedundantHaSupported == PostgreSqlFlexibleServerZoneRedundantHaSupported.Enabled;
}
/// <summary> A value indicating whether a new server in this region can have geo-backups to paired region and have zone redundant HA enabled. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public bool? IsZoneRedundantHAAndGeoBackupSupported
{
get => ZoneRedundantHaAndGeoBackupSupported is null ? false : ZoneRedundantHaAndGeoBackupSupported == PostgreSqlFlexibleServerZoneRedundantHaAndGeoBackupSupported.Enabled;
}

/// <summary> zone name. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string Zone { get; }
/// <summary> Supported high availability mode. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<string> SupportedHAModes { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System.Collections.Generic;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Flexible server edition capabilities. </summary>
public partial class PostgreSqlFlexibleServerEditionCapability : PostgreSqlBaseCapability
{
/// <summary> The list of server versions supported by this server edition. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerServerVersionCapability> SupportedServerVersions { get; }
}
}
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

// <auto-generated/>

#nullable disable

using System.Collections.Generic;
using System.ComponentModel;
using Azure.Core;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Hyperscale node edition capabilities. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public partial class PostgreSqlFlexibleServerHyperscaleNodeEditionCapability
{
/// <summary> Initializes a new instance of PostgreSqlFlexibleServerHyperscaleNodeEditionCapability. </summary>
Expand All @@ -37,12 +37,16 @@ internal PostgreSqlFlexibleServerHyperscaleNodeEditionCapability(string name, IR
}

/// <summary> Server edition name. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string Name { get; }
/// <summary> The list of editions supported by this server edition. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerStorageEditionCapability> SupportedStorageEditions { get; }
/// <summary> The list of server versions supported by this server edition. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerServerVersionCapability> SupportedServerVersions { get; }
/// <summary> The list of Node Types supported by this server edition. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerNodeTypeCapability> SupportedNodeTypes { get; }
/// <summary> The status. </summary>
public string Status { get; }
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> the types of identities associated with this resource; currently restricted to 'None and UserAssigned'. </summary>
public readonly partial struct PostgreSqlFlexibleServerIdentityType : IEquatable<PostgreSqlFlexibleServerIdentityType>
{
private const string SystemAssignedValue = "SystemAssigned";

/// <summary> SystemAssigned. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerIdentityType SystemAssigned { get; } = new PostgreSqlFlexibleServerIdentityType(SystemAssignedValue);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Data encryption type to depict if it is System Managed vs Azure Key vault. </summary>
public readonly partial struct PostgreSqlFlexibleServerKeyType : IEquatable<PostgreSqlFlexibleServerKeyType>
{
private const string SystemAssignedValue = "SystemAssigned";

/// <summary> SystemAssigned. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerKeyType SystemAssigned { get; } = new PostgreSqlFlexibleServerKeyType(SystemAssignedValue);
}
}
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

// <auto-generated/>

#nullable disable

using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> node type capability. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public partial class PostgreSqlFlexibleServerNodeTypeCapability
{
/// <summary> Initializes a new instance of PostgreSqlFlexibleServerNodeTypeCapability. </summary>
Expand All @@ -27,10 +28,13 @@ internal PostgreSqlFlexibleServerNodeTypeCapability(string name, string nodeType
}

/// <summary> note type name. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string Name { get; }
/// <summary> note type. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string NodeType { get; }
/// <summary> The status. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string Status { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

// <auto-generated/>

#nullable disable

using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Represents a server to be updated. </summary>
public partial class PostgreSqlFlexibleServerPatch
{
/// <summary> Max storage allowed for a server. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public int? StorageSizeInGB
{
get => Storage is null ? default : Storage.StorageSizeInGB;
set
{
if (Storage is null)
Storage = new PostgreSqlFlexibleServerStorage();
Storage.StorageSizeInGB = value;
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Used to indicate role of the server in replication set. </summary>
public readonly partial struct PostgreSqlFlexibleServerReplicationRole : IEquatable<PostgreSqlFlexibleServerReplicationRole>
{
private const string SecondaryValue = "Secondary";
private const string WalReplicaValue = "WalReplica";
private const string SyncReplicaValue = "SyncReplica";
private const string GeoSyncReplicaValue = "GeoSyncReplica";
/// <summary> Secondary. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerReplicationRole Secondary { get; } = new PostgreSqlFlexibleServerReplicationRole(SecondaryValue);
/// <summary> WalReplica. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerReplicationRole WalReplica { get; } = new PostgreSqlFlexibleServerReplicationRole(WalReplicaValue);
/// <summary> SyncReplica. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerReplicationRole SyncReplica { get; } = new PostgreSqlFlexibleServerReplicationRole(SyncReplicaValue);
/// <summary> AsyncReplica. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static PostgreSqlFlexibleServerReplicationRole GeoSyncReplica { get; } = new PostgreSqlFlexibleServerReplicationRole(GeoSyncReplicaValue);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System.Collections.Generic;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Server version capabilities. </summary>
public partial class PostgreSqlFlexibleServerServerVersionCapability : PostgreSqlBaseCapability
{
/// <summary> Gets the supported v cores. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerVCoreCapability> SupportedVCores { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System.Collections.Generic;
using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> storage size in MB capability. </summary>
public partial class PostgreSqlFlexibleServerStorageCapability : PostgreSqlBaseCapability
{
/// <summary> storage MB name. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string Name { get; }
/// <summary> Gets the supported upgradable tier list. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public IReadOnlyList<PostgreSqlFlexibleServerStorageTierCapability> SupportedUpgradableTierList { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System.ComponentModel;

namespace Azure.ResourceManager.PostgreSql.FlexibleServers.Models
{
/// <summary> Represents capability of a storage tier. </summary>
public partial class PostgreSqlFlexibleServerStorageTierCapability : PostgreSqlBaseCapability
{
/// <summary> Storage tier name. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string TierName { get; }
/// <summary> Indicates if this is a baseline storage tier or not. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public bool? IsBaseline { get; }
}
}
Loading