From 565b2bebd47ef8fc6b4eba421fe5cc863d15e062 Mon Sep 17 00:00:00 2001 From: Andre Pinto <31374863+anpint@users.noreply.github.com> Date: Sun, 15 Sep 2019 08:04:26 -0700 Subject: [PATCH] Update StorageSync 2019-06-01 protocol with cloud tiering and recall status (#7161) * introduce cloud tiering and recall status * fix validation errors * Additional validation fixes --- .../examples/CloudEndpoints_Create.json | 3 +- .../examples/RegisteredServers_Create.json | 4 +- .../examples/ServerEndpoints_Create.json | 7 +- .../examples/ServerEndpoints_Get.json | 28 +++- .../ServerEndpoints_ListBySyncGroup.json | 26 ++- .../examples/SyncGroups_Create.json | 2 +- .../stable/2019-06-01/storagesync.json | 154 +++++++++++++++--- 7 files changed, 188 insertions(+), 36 deletions(-) diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/CloudEndpoints_Create.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/CloudEndpoints_Create.json index 2242d1fcca03..27065cf111ee 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/CloudEndpoints_Create.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/CloudEndpoints_Create.json @@ -12,8 +12,7 @@ "azureFileShareName": "cvcloud-afscv-0719-058-a94a1354-a1fd-4e9a-9a50-919fad8c4ba4", "storageAccountTenantId": "\"72f988bf-86f1-41af-91ab-2d7cd011db47\"", "friendlyName": "ankushbsubscriptionmgmtmab" - }, - "type": "Microsoft.StorageSync/storageSyncServices/syncGroups/cloudEndpoints" + } } }, "responses": { diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/RegisteredServers_Create.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/RegisteredServers_Create.json index 5bea94fbacdd..48e98fd334b4 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/RegisteredServers_Create.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/RegisteredServers_Create.json @@ -5,15 +5,13 @@ "storageSyncServiceName": "SampleStorageSyncService_1", "serverId": "\"080d4133-bdb5-40a0-96a0-71a6057bfe9a\"", "parameters": { - "name": "SampleServer-prod3.redmond.corp.microsoft.com", "properties": { "serverRole": "Standalone", "serverCertificate": "\"MIIDFjCCAf6gAwIBAgIQQS+DS8uhc4VNzUkTw7wbRjANBgkqhkiG9w0BAQ0FADAzMTEwLwYDVQQDEyhhbmt1c2hiLXByb2QzLnJlZG1vbmQuY29ycC5taWNyb3NvZnQuY29tMB4XDTE3MDgwMzE3MDQyNFoXDTE4MDgwNDE3MDQyNFowMzExMC8GA1UEAxMoYW5rdXNoYi1wcm9kMy5yZWRtb25kLmNvcnAubWljcm9zb2Z0LmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALDRvV4gmsIy6jGDPiHsXmvgVP749NNP7DopdlbHaNhjFmYINHl0uWylyaZmgJrROt2mnxN/zEyJtGnqYHlzUr4xvGq/qV5pqgdB9tag/sw9i22gfe9PRZ0FmSOZnXMbLYgLiDFqLtut5gHcOuWMj03YnkfoBEKlFBxWbagvW2yxz/Sxi9OVSJOKCaXra0RpcIHrO/KFl6ho2eE1/7Ykmfa8hZvSdoPd5gHdLiQcMB/pxq+mWp1fI6c8vFZoDu7Atn+NXTzYPKUxKzaisF12TsaKpohUsJpbB3Wocb0F5frn614D2pg14ERB5otjAMWw1m65csQWPI6dP8KIYe0+QPkCAwEAAaMmMCQwIgYDVR0lAQH/BBgwFgYIKwYBBQUHAwIGCisGAQQBgjcKAwwwDQYJKoZIhvcNAQENBQADggEBAA4RhVIBkw34M1RwakJgHvtjsOFxF1tVQA941NtLokx1l2Z8+GFQkcG4xpZSt+UN6wLerdCbnNhtkCErWUDeaT0jxk4g71Ofex7iM04crT4iHJr8mi96/XnhnkTUs+GDk12VgdeeNEczMZz+8Mxw9dJ5NCnYgTwO0SzGlclRsDvjzkLo8rh2ZG6n/jKrEyNXXo+hOqhupij0QbRP2Tvexdfw201kgN1jdZify8XzJ8Oi0bTS0KpJf2pNPOlooK2bjMUei9ANtEdXwwfVZGWvVh6tJjdv6k14wWWJ1L7zhA1IIVb1J+sQUzJji5iX0DrezjTz1Fg+gAzITaA/WsuujlM=\"", "lastHeartBeat": "\"2017-08-08T18:29:06.470652Z\"", "serverOSVersion": "10.0.14393.0", "agentVersion": "1.0.277.0" - }, - "type": "Microsoft.StorageSync/storageSyncServices/registeredServers" + } }, "api-version": "2019-06-01" }, diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Create.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Create.json index 39c48aee0438..6c17beab14c0 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Create.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Create.json @@ -14,8 +14,7 @@ "tierFilesOlderThanDays": 0, "offlineDataTransfer": "on", "offlineDataTransferShareName": "myfileshare" - }, - "type": "Microsoft.StorageSync/storageSyncServices/syncGroups/serverEndpoints" + } }, "api-version": "2019-06-01" }, @@ -41,7 +40,9 @@ "offlineDataTransfer": "on", "offlineDataTransferStorageAccountResourceId": "/subscriptions/744f4d70-6d17-4921-8970-a765d14f763f/resourceGroups/myRG/providers/Microsoft.Storage/storageAccounts/mysa", "offlineDataTransferStorageAccountTenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47", - "offlineDataTransferShareName": "myfileshare" + "offlineDataTransferShareName": "myfileshare", + "cloudTieringStatus": null, + "recallStatus": null }, "id": "/subscriptions/52b8da2f-61e0-4a1f-8dde-336911f367fb/resourceGroups/SampleResourceGroup_1/providers/Microsoft.StorageSync/storageSyncServices/SampleStorageSyncService_1/syncGroups/SampleSyncGroup_1/serverEndpoints/SampleServerEndpoint_1", "type": "Microsoft.StorageSync/storageSyncServices/syncGroups/serverEndpoints" diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Get.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Get.json index 8158f62ac507..d652320cf157 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Get.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_Get.json @@ -17,7 +17,7 @@ "name": "SampleServerEndpoint_1", "properties": { "serverLocalPath": "D:\\SampleServerEndpoint_1", - "cloudTiering": "off", + "cloudTiering": "on", "volumeFreeSpacePercent": 100, "friendlyName": "somemachine.redmond.corp.microsoft.com", "serverResourceId": "/subscriptions/52b8da2f-61e0-4a1f-8dde-336911f367fb/resourceGroups/SampleResourceGroup_1/providers/Microsoft.StorageSync/storageSyncServices/SampleStorageSyncService_1/registeredServers/080d4133-bdb5-40a0-96a0-71a6057bfe9a", @@ -71,7 +71,31 @@ "offlineDataTransfer": "on", "offlineDataTransferStorageAccountResourceId": "/subscriptions/744f4d70-6d17-4921-8970-a765d14f763f/resourceGroups/myRG/providers/Microsoft.Storage/storageAccounts/mysa", "offlineDataTransferStorageAccountTenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47", - "offlineDataTransferShareName": "myfileshare" + "offlineDataTransferShareName": "myfileshare", + "cloudTieringStatus": { + "lastUpdatedTimestamp": "2018-06-11T23:32:51.1057915Z", + "health": "Error", + "lastCloudTieringResult": -2134347771, + "lastSuccessTimestamp": "2018-06-11T23:32:51.1057915Z" + }, + "recallStatus": { + "lastUpdatedTimestamp": "2018-06-11T23:32:51.1057915Z", + "totalRecallErrorsCount": 30, + "recallErrors": [ + { + "errorCode": -2134347775, + "count": 5 + }, + { + "errorCode": -2134347774, + "count": 10 + }, + { + "errorCode": -2134347773, + "count": 15 + } + ] + } }, "id": "/subscriptions/52b8da2f-61e0-4a1f-8dde-336911f367fb/resourceGroups/SampleResourceGroup_1/providers/Microsoft.StorageSync/storageSyncServices/SampleStorageSyncService_1/syncGroups/SampleSyncGroup_1/serverEndpoints/SampleServerEndpoint_1", "type": "Microsoft.StorageSync/storageSyncServices/syncGroups/serverEndpoints" diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_ListBySyncGroup.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_ListBySyncGroup.json index c3fcb72e5094..9d7b3f5485f4 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_ListBySyncGroup.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/ServerEndpoints_ListBySyncGroup.json @@ -111,7 +111,31 @@ "downloadActivity": null, "offlineDataTransferStatus": "NotRunning" }, - "offlineDataTransfer": "off" + "offlineDataTransfer": "off", + "cloudTieringStatus": { + "lastUpdatedTimestamp": "2018-06-11T23:32:51.1057915Z", + "health": "Error", + "lastCloudTieringResult": -2134347771, + "lastSuccessTimestamp": "2018-06-11T23:32:51.1057915Z" + }, + "recallStatus": { + "lastUpdatedTimestamp": "2018-06-11T23:32:51.1057915Z", + "totalRecallErrorsCount": 30, + "recallErrors": [ + { + "errorCode": -2134347775, + "count": 5 + }, + { + "errorCode": -2134347774, + "count": 10 + }, + { + "errorCode": -2134347773, + "count": 15 + } + ] + } }, "id": "/subscriptions/52b8da2f-61e0-4a1f-8dde-336911f367fb/resourceGroups/SampleResourceGroup_1/providers/Microsoft.StorageSync/storageSyncServices/SampleStorageSyncService_1/syncGroups/SampleSyncGroup_1/serverEndpoints/SampleServerEndpoint_2", "type": "Microsoft.StorageSync/storageSyncServices/syncGroups/serverEndpoints" diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/SyncGroups_Create.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/SyncGroups_Create.json index 8f4f003696a7..602b8323c6f9 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/SyncGroups_Create.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/examples/SyncGroups_Create.json @@ -6,7 +6,7 @@ "syncGroupName": "SampleSyncGroup_1", "api-version": "2019-06-01", "parameters": { - "type": "Microsoft.StorageSync/storageSyncServices/syncGroups" + "properties": {} } }, "responses": { diff --git a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/storagesync.json b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/storagesync.json index 76c3ada61848..43043fe5ba8a 100644 --- a/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/storagesync.json +++ b/specification/storagesync/resource-manager/Microsoft.StorageSync/stable/2019-06-01/storagesync.json @@ -3409,8 +3409,7 @@ }, "isdir": { "type": "boolean", - "description": "Restore file spec isdir", - "readOnly": true + "description": "Restore file spec isdir" } } }, @@ -3577,7 +3576,8 @@ "properties": { "uniqueId": { "type": "string", - "description": "Unique Id" + "description": "Unique Id", + "readOnly": true }, "syncGroupStatus": { "type": "string", @@ -3811,6 +3811,18 @@ "offlineDataTransferShareName": { "type": "string", "description": "Offline data transfer share name" + }, + "cloudTieringStatus": { + "type": "object", + "$ref": "#/definitions/ServerEndpointCloudTieringStatus", + "description": "Cloud tiering status. Only populated if cloud tiering is enabled.", + "readOnly": true + }, + "recallStatus": { + "type": "object", + "$ref": "#/definitions/ServerEndpointRecallStatus", + "description": "Recall status. Only populated if cloud tiering is enabled.", + "readOnly": true } } }, @@ -3819,29 +3831,30 @@ "description": "Server Endpoint sync status", "properties": { "downloadHealth": { - "$ref": "#/definitions/HealthState", + "$ref": "#/definitions/ServerEndpointSyncHealthState", "description": "Download Health Status.", "readOnly": true }, "uploadHealth": { - "$ref": "#/definitions/HealthState", + "$ref": "#/definitions/ServerEndpointSyncHealthState", "description": "Upload Health Status.", "readOnly": true }, "combinedHealth": { - "$ref": "#/definitions/HealthState", + "$ref": "#/definitions/ServerEndpointSyncHealthState", "description": "Combined Health Status.", "readOnly": true }, "syncActivity": { - "$ref": "#/definitions/SyncActivityState", + "$ref": "#/definitions/ServerEndpointSyncActivityState", "description": "Sync activity", "readOnly": true }, "totalPersistentFilesNotSyncingCount": { "type": "integer", "format": "int64", - "description": "Total count of persistent files not syncing (combined upload + download). Reserved for future use.", + "minimum": 0, + "description": "Total count of persistent files not syncing (combined upload + download).", "readOnly": true }, "lastUpdatedTimestamp": { @@ -3851,33 +3864,33 @@ "readOnly": true }, "uploadStatus": { - "$ref": "#/definitions/SyncSessionStatus", + "$ref": "#/definitions/ServerEndpointSyncSessionStatus", "description": "Upload Status", "readOnly": true }, "downloadStatus": { - "$ref": "#/definitions/SyncSessionStatus", + "$ref": "#/definitions/ServerEndpointSyncSessionStatus", "description": "Download Status", "readOnly": true }, "uploadActivity": { - "$ref": "#/definitions/SyncActivityStatus", + "$ref": "#/definitions/ServerEndpointSyncActivityStatus", "description": "Upload sync activity", "readOnly": true }, "downloadActivity": { - "$ref": "#/definitions/SyncActivityStatus", + "$ref": "#/definitions/ServerEndpointSyncActivityStatus", "description": "Download sync activity", "readOnly": true }, "offlineDataTransferStatus": { - "$ref": "#/definitions/OfflineDataTransferState", + "$ref": "#/definitions/ServerEndpointOfflineDataTransferState", "description": "Offline Data Transfer State", "readOnly": true } } }, - "SyncSessionStatus": { + "ServerEndpointSyncSessionStatus": { "type": "object", "description": "Sync Session status object.", "properties": { @@ -3902,32 +3915,35 @@ "lastSyncPerItemErrorCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Last sync per item error count.", "readOnly": true }, "persistentFilesNotSyncingCount": { "type": "integer", "format": "int64", - "description": "Count of persistent files not syncing. Reserved for future use.", + "minimum": 0, + "description": "Count of persistent files not syncing.", "readOnly": true }, "transientFilesNotSyncingCount": { "type": "integer", "format": "int64", - "description": "Count of transient files not syncing. Reserved for future use.", + "minimum": 0, + "description": "Count of transient files not syncing.", "readOnly": true }, "filesNotSyncingErrors": { "type": "array", "items": { - "$ref": "#/definitions/FilesNotSyncingError" + "$ref": "#/definitions/ServerEndpointFilesNotSyncingError" }, - "description": "Array of per-item errors coming from the last sync session. Reserved for future use.", + "description": "Array of per-item errors coming from the last sync session.", "readOnly": true } } }, - "SyncActivityStatus": { + "ServerEndpointSyncActivityStatus": { "type": "object", "description": "Sync Session status object.", "properties": { @@ -3940,36 +3956,41 @@ "perItemErrorCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Per item error count", "readOnly": true }, "appliedItemCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Applied item count.", "readOnly": true }, "totalItemCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Total item count (if available)", "readOnly": true }, "appliedBytes": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Applied bytes", "readOnly": true }, "totalBytes": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Total bytes (if available)", "readOnly": true } } }, - "FilesNotSyncingError": { + "ServerEndpointFilesNotSyncingError": { "type": "object", "description": "Files not syncing error object", "properties": { @@ -3982,12 +4003,14 @@ "persistentCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Count of persistent files not syncing with the specified error code", "readOnly": true }, "transientCount": { "type": "integer", "format": "int64", + "minimum": 0, "description": "Count of transient files not syncing with the specified error code", "readOnly": true } @@ -4013,9 +4036,9 @@ "off" ] }, - "HealthState": { + "ServerEndpointSyncHealthState": { "type": "string", - "description": "Type of the Health state", + "description": "Type of the sync health state", "enum": [ "Healthy", "Error", @@ -4024,7 +4047,7 @@ "NoActivity" ] }, - "SyncActivityState": { + "ServerEndpointSyncActivityState": { "type": "string", "description": "Type of the sync activity state", "enum": [ @@ -4033,7 +4056,7 @@ "UploadAndDownload" ] }, - "OfflineDataTransferState": { + "ServerEndpointOfflineDataTransferState": { "type": "string", "description": "Type of the Health state", "enum": [ @@ -4106,6 +4129,89 @@ } }, "description": "Operation status object" + }, + "ServerEndpointCloudTieringStatus": { + "type": "object", + "description": "Server endpoint cloud tiering status object.", + "properties": { + "health": { + "$ref": "#/definitions/ServerEndpointCloudTieringHealthState", + "description": "Cloud tiering health state.", + "readOnly": true + }, + "lastUpdatedTimestamp": { + "type": "string", + "format": "date-time", + "description": "Last updated timestamp", + "readOnly": true + }, + "lastCloudTieringResult": { + "type": "integer", + "format": "int32", + "description": "Last cloud tiering result (HResult)", + "readOnly": true + }, + "lastSuccessTimestamp": { + "type": "string", + "format": "date-time", + "description": "Last cloud tiering success timestamp", + "readOnly": true + } + } + }, + "ServerEndpointCloudTieringHealthState": { + "type": "string", + "description": "Type of the cloud tiering health state", + "enum": [ + "Healthy", + "Error" + ] + }, + "ServerEndpointRecallStatus": { + "type": "object", + "description": "Server endpoint recall status object.", + "properties": { + "lastUpdatedTimestamp": { + "type": "string", + "format": "date-time", + "description": "Last updated timestamp", + "readOnly": true + }, + "totalRecallErrorsCount": { + "type": "integer", + "format": "int64", + "minimum": 0, + "description": "Total count of recall errors.", + "readOnly": true + }, + "recallErrors": { + "type": "array", + "items": { + "$ref": "#/definitions/ServerEndpointRecallError" + }, + "description": "Array of recall errors", + "readOnly": true + } + } + }, + "ServerEndpointRecallError": { + "type": "object", + "description": "Server endpoint recall error object", + "properties": { + "errorCode": { + "type": "integer", + "format": "int32", + "description": "Error code (HResult)", + "readOnly": true + }, + "count": { + "type": "integer", + "format": "int64", + "minimum": 0, + "description": "Count of occurences of the error", + "readOnly": true + } + } } }, "securityDefinitions": {