Skip to content

Commit 458e486

Browse files
afedyashovAndrey Fedyashovramoka178ravimedaankushbindlish2
authored
Introduce Microsoft.FileShares API version "2025-09 01-preview" (#39144)
* Introduce 2025-09-01-preview in typespec * Introduce 2025-09-01-preview swagger * Introduce 2025-09-01-preview examples * Update readme.md for 2025-09-01-preview configuration * Fileshares Private Endpoint connection changes over 2025-09-01 (#40096) * Add private endpoint & private link resources Add TypeSpec ARM definitions for PrivateEndpointConnection and PrivateLinkResource (v2025_09_01_preview). Introduces resource operation interfaces (get/create/delete/list), models for PrivateLinkResource properties and list result, and registers the new files in fileshares.tsp. Includes example request/response JSON for the 2025-06-01-preview APIs (create/get/delete/list and private link resource get/list) and necessary LRO/response annotations and suppressions. * Add PrivateEndpoint & PrivateLink resources APIs Expose PrivateEndpointConnections and PrivateLinkResources for FileShares: add REST paths for list/get/create/update/delete private endpoint connections and list/get private link resources, including pageable responses and long-running operation metadata. Add related JSON schema definitions (PrivateEndpointConnectionListResult, PrivateLinkResource, PrivateLinkResourceListResult, PrivateLinkResourceProperties) and surface a privateEndpointConnections property on FileShareProperties with @added(Versions.v2025_06_01_preview). Also remove a redundant @added annotation from the PrivateEndpointConnection model file. * Bump FileShares examples to 2025-09-01-preview (#40103) Rename example files from 2025-06-01-preview to 2025-09-01-preview and update their api-version values. Also update embedded response header URLs (Azure-AsyncOperation and Location) to use ?api-version=2025-09-01-preview. Affects PrivateEndpointConnections_Create/Delete/Get/ListByFileShare and PrivateLinkResources_Get/ListByFileShare example JSON files under specification/fileshares/resource-manager/Microsoft.FileShares/FileShares/examples. * update with example restructuring * Update readme.md * Include generated files after tsp compile * update files * update example * Update fileshares.tsp --------- Co-authored-by: Andrey Fedyashov <anfedyas@microsoft.com> Co-authored-by: ramoka178 <57157576+ramoka178@users.noreply.github.com> Co-authored-by: Ravi Eda <raeda@microsoft.com> Co-authored-by: Ankush Bindlish <34896519+ankushbindlish2@users.noreply.github.com> Co-authored-by: Ankush <ankushb@microsoft.com>
1 parent b84dedf commit 458e486

65 files changed

Lines changed: 5047 additions & 47 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
import "@azure-tools/typespec-azure-core";
2+
import "@azure-tools/typespec-azure-resource-manager";
3+
import "@typespec/openapi";
4+
import "@typespec/rest";
5+
import "@typespec/versioning";
6+
import "./fileshares.tsp";
7+
8+
using TypeSpec.Rest;
9+
using Azure.ResourceManager;
10+
using TypeSpec.Http;
11+
using TypeSpec.OpenAPI;
12+
using Azure.ResourceManager.Legacy;
13+
using TypeSpec.Versioning;
14+
15+
namespace Microsoft.FileShares;
16+
17+
/**
18+
* The private endpoint connection resource.
19+
*/
20+
@parentResource(FileShare)
21+
model PrivateEndpointConnection is PrivateEndpointConnectionResource;
22+
23+
alias PrivateEndpointOperations = Azure.ResourceManager.PrivateEndpoints<PrivateEndpointConnection>;
24+
25+
@added(Versions.v2025_09_01_preview)
26+
@armResourceOperations
27+
interface PrivateEndpointConnections {
28+
/**
29+
* Gets the specified private endpoint connection associated with the file share.
30+
*/
31+
get is PrivateEndpointOperations.Read<FileShare>;
32+
33+
/**
34+
* Update the state of specified private endpoint connection associated with the file share.
35+
*/
36+
#suppress "@azure-tools/typespec-azure-resource-manager/arm-put-operation-response-codes" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
37+
@Azure.Core.useFinalStateVia("location")
38+
create is PrivateEndpointOperations.CreateOrUpdateAsync<
39+
FileShare,
40+
Response = ArmResourceUpdatedResponse<PrivateEndpointConnection> | ArmAcceptedLroResponse<LroHeaders = ArmCombinedLroHeaders<FinalResult = PrivateEndpointConnection> &
41+
Azure.Core.Foundations.RetryAfterHeader>
42+
>;
43+
44+
/**
45+
* Deletes the specified private endpoint connection associated with the file share.
46+
*/
47+
#suppress "@azure-tools/typespec-azure-resource-manager/arm-delete-operation-response-codes" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
48+
@Azure.Core.useFinalStateVia("location")
49+
delete is PrivateEndpointOperations.DeleteAsync<
50+
FileShare,
51+
Response = ArmDeletedResponse | ArmDeleteAcceptedLroResponse<LroHeaders = ArmCombinedLroHeaders<FinalResult = void> &
52+
Azure.Core.Foundations.RetryAfterHeader> | ArmDeletedNoContentResponse
53+
>;
54+
55+
/**
56+
* Get a PrivateEndpointConnection List.
57+
*/
58+
@list
59+
listByFileShare is Azure.ResourceManager.Legacy.PrivateEndpoints.ListSinglePageByParent<
60+
FileShare,
61+
PrivateEndpointConnection
62+
>;
63+
}
64+
65+
@@doc(PrivateEndpointConnection.properties, "Resource properties.");
66+
@@doc(PrivateEndpointConnections.create::parameters.resource,
67+
"The private endpoint connection properties."
68+
);
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
import "@azure-tools/typespec-azure-core";
2+
import "@azure-tools/typespec-azure-resource-manager";
3+
import "@typespec/openapi";
4+
import "@typespec/rest";
5+
import "@typespec/versioning";
6+
import "./fileshares.tsp";
7+
8+
using TypeSpec.Rest;
9+
using Azure.ResourceManager;
10+
using TypeSpec.Http;
11+
using TypeSpec.OpenAPI;
12+
using TypeSpec.Versioning;
13+
14+
namespace Microsoft.FileShares;
15+
16+
/**
17+
* A private link resource.
18+
*/
19+
@added(Versions.v2025_09_01_preview)
20+
@parentResource(FileShare)
21+
model PrivateLinkResource
22+
is Azure.ResourceManager.ProxyResource<PrivateLinkResourceProperties> {
23+
...ResourceNameParameter<
24+
Resource = PrivateLinkResource,
25+
KeyName = "privateLinkResourceName",
26+
SegmentName = "privateLinkResources",
27+
NamePattern = "^[a-z][a-z0-9]*$"
28+
>;
29+
}
30+
31+
@added(Versions.v2025_09_01_preview)
32+
@armResourceOperations
33+
interface PrivateLinkResources {
34+
/**
35+
* Gets the private link resources that need to be created for a file share.
36+
*/
37+
get is ArmResourceRead<PrivateLinkResource>;
38+
39+
/**
40+
* Gets the private link resources that need to be created for a file share.
41+
*/
42+
list is ArmResourceListByParent<
43+
PrivateLinkResource,
44+
Response = ArmResponse<PrivateLinkResourceListResult>
45+
>;
46+
}
47+
48+
@@doc(PrivateLinkResource.name, "The name of the private link resource.");
49+
@@doc(PrivateLinkResource.properties, "Resource properties.");
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"title": "FileShareSnapshot_CreateOrUpdate_MaximumSet",
3+
"operationId": "FileShareSnapshot_CreateOrUpdate",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "fileshare",
9+
"name": "testfilesharesnapshot",
10+
"resource": {
11+
"properties": {
12+
"metadata": {
13+
"key9372": "jtc"
14+
}
15+
}
16+
}
17+
},
18+
"responses": {
19+
"202": {
20+
"headers": {
21+
"location": "https://contoso.com/operationstatus"
22+
}
23+
}
24+
}
25+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"title": "FileShareSnapshot_Delete_MaximumSet",
3+
"operationId": "FileShareSnapshot_Delete",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "fileshare",
9+
"name": "testfilesharesnapshot"
10+
},
11+
"responses": {
12+
"202": {
13+
"headers": {
14+
"location": "https://contoso.com/operationstatus"
15+
}
16+
},
17+
"204": {}
18+
}
19+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
"title": "FileShareSnapshot_Get_MaximumSet",
3+
"operationId": "FileShareSnapshot_Get",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "fileshare",
9+
"name": "testfilesharesnapshot"
10+
},
11+
"responses": {
12+
"200": {
13+
"body": {
14+
"properties": {
15+
"snapshotTime": "wgujspthevkfo",
16+
"initiatorId": "ghublxbeifhvhwokvhppbw",
17+
"metadata": {
18+
"key9372": "jtc"
19+
}
20+
},
21+
"id": "/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg1Network/providers/Microsoft.FileShares/fileShares/testfileshare/fileShareSnapshots/testfilesharesnapshot",
22+
"name": "testfilesharesnapshot",
23+
"type": "Microsoft.FileShares/fileShares/fileShareSnapshots",
24+
"systemData": {
25+
"createdBy": "moat",
26+
"createdByType": "User",
27+
"createdAt": "2025-07-23T12:37:53.955Z",
28+
"lastModifiedBy": "dxukcadzapywjcgnxsqchaa",
29+
"lastModifiedByType": "User",
30+
"lastModifiedAt": "2025-07-23T12:37:53.955Z"
31+
}
32+
}
33+
}
34+
}
35+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
"title": "FileShareSnapshot_List_MaximumSet",
3+
"operationId": "FileShareSnapshot_List",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "fileshare"
9+
},
10+
"responses": {
11+
"200": {
12+
"body": {
13+
"value": [
14+
{
15+
"properties": {
16+
"snapshotTime": "wgujspthevkfo",
17+
"initiatorId": "ghublxbeifhvhwokvhppbw",
18+
"metadata": {
19+
"key9372": "jtc"
20+
}
21+
},
22+
"id": "/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg1Network/providers/Microsoft.FileShares/fileShares/testfileshare/fileShareSnapshots/testfilesharesnapshot",
23+
"name": "testfilesharesnapshot",
24+
"type": "Microsoft.FileShares/fileShares/fileShareSnapshots",
25+
"systemData": {
26+
"createdBy": "moat",
27+
"createdByType": "User",
28+
"createdAt": "2025-07-23T12:37:53.955Z",
29+
"lastModifiedBy": "dxukcadzapywjcgnxsqchaa",
30+
"lastModifiedByType": "User",
31+
"lastModifiedAt": "2025-07-23T12:37:53.955Z"
32+
}
33+
}
34+
],
35+
"nextLink": "https://microsoft.com/a"
36+
}
37+
}
38+
}
39+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"title": "FileShareSnapshot_List_MinimumSet",
3+
"operationId": "FileShareSnapshot_List",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "testfileshare"
9+
},
10+
"responses": {
11+
"200": {
12+
"body": {
13+
"value": []
14+
}
15+
}
16+
}
17+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
{
2+
"title": "FileShareSnapshot_Update_MaximumSet",
3+
"operationId": "FileShareSnapshot_Update",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"resourceGroupName": "rgfileshares",
8+
"resourceName": "fileshare",
9+
"name": "testfilesharesnapshot",
10+
"properties": {
11+
"properties": {
12+
"metadata": {
13+
"key491": "dalhvhxqhjszelfuueetvxmgkbukwa"
14+
}
15+
}
16+
}
17+
},
18+
"responses": {
19+
"200": {
20+
"body": {
21+
"properties": {
22+
"snapshotTime": "wgujspthevkfo",
23+
"initiatorId": "ghublxbeifhvhwokvhppbw",
24+
"metadata": {
25+
"key9372": "jtc"
26+
}
27+
},
28+
"id": "/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg1Network/providers/Microsoft.FileShares/fileShares/testfileshare/fileShareSnapshots/testfilesharesnapshot",
29+
"name": "testfilesharesnapshot",
30+
"type": "Microsoft.FileShares/fileShares/fileShareSnapshots",
31+
"systemData": {
32+
"createdBy": "moat",
33+
"createdByType": "User",
34+
"createdAt": "2025-07-23T12:37:53.955Z",
35+
"lastModifiedBy": "dxukcadzapywjcgnxsqchaa",
36+
"lastModifiedByType": "User",
37+
"lastModifiedAt": "2025-07-23T12:37:53.955Z"
38+
}
39+
}
40+
},
41+
"202": {
42+
"headers": {
43+
"location": "https://contoso.com/operationstatus"
44+
}
45+
}
46+
}
47+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"title": "FileShare_GetLimits_MaximumSet",
3+
"operationId": "FileShare_GetLimits",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"location": "dpplbglogsvzrbbeo"
8+
},
9+
"responses": {
10+
"200": {
11+
"body": {
12+
"properties": {
13+
"limits": {
14+
"maxFileShares": 21,
15+
"maxFileShareSnapshots": 5,
16+
"maxFileShareSubnets": 11,
17+
"maxFileSharePrivateEndpointConnections": 17,
18+
"minProvisionedStorageGiB": 15,
19+
"maxProvisionedStorageGiB": 18,
20+
"minProvisionedIOPerSec": 21,
21+
"maxProvisionedIOPerSec": 2,
22+
"minProvisionedThroughputMiBPerSec": 30,
23+
"maxProvisionedThroughputMiBPerSec": 14
24+
},
25+
"provisioningConstants": {
26+
"baseIOPerSec": 9,
27+
"scalarIOPerSec": 17,
28+
"baseThroughputMiBPerSec": 17,
29+
"scalarThroughputMiBPerSec": 12,
30+
"guardrailIOPerSecScalar": 5,
31+
"guardrailThroughputScalar": 5
32+
}
33+
}
34+
}
35+
}
36+
}
37+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"title": "FileShare_GetLimits_MinimumSet",
3+
"operationId": "FileShare_GetLimits",
4+
"parameters": {
5+
"api-version": "2025-09-01-preview",
6+
"subscriptionId": "0681745E-3F9F-4966-80E6-69624A3B29F2",
7+
"location": "dpplbglogsvzrbbeo"
8+
},
9+
"responses": {
10+
"200": {
11+
"body": {
12+
"properties": {
13+
"limits": {
14+
"maxFileShares": 21,
15+
"maxFileShareSnapshots": 5,
16+
"maxFileShareSubnets": 11,
17+
"maxFileSharePrivateEndpointConnections": 17,
18+
"minProvisionedStorageGiB": 15,
19+
"maxProvisionedStorageGiB": 18,
20+
"minProvisionedIOPerSec": 21,
21+
"maxProvisionedIOPerSec": 2,
22+
"minProvisionedThroughputMiBPerSec": 30,
23+
"maxProvisionedThroughputMiBPerSec": 14
24+
},
25+
"provisioningConstants": {
26+
"baseIOPerSec": 9,
27+
"scalarIOPerSec": 17,
28+
"baseThroughputMiBPerSec": 17,
29+
"scalarThroughputMiBPerSec": 12,
30+
"guardrailIOPerSecScalar": 5,
31+
"guardrailThroughputScalar": 5
32+
}
33+
}
34+
}
35+
}
36+
}
37+
}

0 commit comments

Comments
 (0)