Skip to content

Commit 09f3658

Browse files
Import client.tsp from main.tsp for deploymentStacks, policy, and search (@scope support) (#44027)
1 parent dddc9b4 commit 09f3658

4 files changed

Lines changed: 27 additions & 10 deletions

File tree

  • specification
    • resources/resource-manager
      • Microsoft.Authorization/policy
      • Microsoft.Resources/deploymentStacks
    • search/resource-manager/Microsoft.Search/Search

specification/resources/resource-manager/Microsoft.Authorization/policy/main.tsp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import "./PolicySetDefinitionVersion.tsp";
2424
import "./routes.tsp";
2525
import "./Variable.tsp";
2626
import "./VariableValue.tsp";
27+
import "./client.tsp";
2728

2829
using Azure.Core;
2930
using Azure.ResourceManager;

specification/resources/resource-manager/Microsoft.Resources/deploymentStacks/main.tsp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import "@azure-tools/typespec-azure-resource-manager";
1414
import "./models.tsp";
1515
import "./models-whatIf.tsp";
1616
import "./back-compat.tsp";
17+
import "./client.tsp";
1718

1819
using Azure.ResourceManager;
1920
using TypeSpec.Versioning;

specification/search/resource-manager/Microsoft.Search/Search/client.tsp

Lines changed: 24 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,9 @@ using Azure.Core;
1515
using Azure.ResourceManager;
1616
using Azure.ClientGenerator.Core;
1717
using TypeSpec.OpenAPI;
18+
using Microsoft.Search;
1819

19-
namespace Microsoft.Search;
20+
namespace Customizations;
2021

2122
#suppress "@azure-tools/typespec-azure-core/documentation-required" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
2223
#suppress "@azure-tools/typespec-azure-core/casing-style" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
@@ -414,7 +415,7 @@ op privateEndpointConnectionsGetCustomization(
414415

415416
#suppress "@azure-tools/typespec-azure-core/documentation-required" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
416417
params?: `search-management-request-options`,
417-
): ArmResponse<PrivateEndpointConnection> | CloudError;
418+
): ArmResponse<Microsoft.Search.PrivateEndpointConnection> | CloudError;
418419

419420
/**
420421
* Updates a private endpoint connection to the search service in the given resource group.
@@ -448,7 +449,9 @@ op privateEndpointConnectionsUpdateCustomization(
448449

449450
#suppress "@azure-tools/typespec-azure-core/documentation-required" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
450451
params?: `search-management-request-options`,
451-
): ArmResourceUpdatedResponse<PrivateEndpointConnection> | CloudError;
452+
):
453+
| ArmResourceUpdatedResponse<Microsoft.Search.PrivateEndpointConnection>
454+
| CloudError;
452455

453456
/**
454457
* Disconnects the private endpoint connection and deletes it from the search service.
@@ -477,7 +480,10 @@ op privateEndpointConnectionsDeleteCustomization(
477480

478481
#suppress "@azure-tools/typespec-azure-core/documentation-required" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
479482
params?: `search-management-request-options`,
480-
): ArmResponse<PrivateEndpointConnection> | NotFoundResponse | CloudError;
483+
):
484+
| ArmResponse<Microsoft.Search.PrivateEndpointConnection>
485+
| NotFoundResponse
486+
| CloudError;
481487

482488
/**
483489
* Gets a list of all supported private link resource types for the given service.
@@ -967,9 +973,17 @@ model AccessRulePropertiesSubscriptionsItem {
967973

968974
@@clientName(SearchServiceProperties.eTag, "etag", "java");
969975

970-
@@clientName(SearchResourceEncryptionKey.keyVaultKeyName, "keyName");
971-
@@clientName(SearchResourceEncryptionKey.keyVaultKeyVersion, "keyVersion");
972-
@@clientName(SearchResourceEncryptionKey.keyVaultUri, "vaultUri");
976+
@@clientName(
977+
SearchResourceEncryptionKey.keyVaultKeyName,
978+
"keyName",
979+
"!autorest"
980+
);
981+
@@clientName(
982+
SearchResourceEncryptionKey.keyVaultKeyVersion,
983+
"keyVersion",
984+
"!autorest"
985+
);
986+
@@clientName(SearchResourceEncryptionKey.keyVaultUri, "vaultUri", "!autorest");
973987

974988
// C# settings
975989
#suppress "@azure-tools/typespec-azure-core/no-legacy-usage" "flatten sku for backward compat with C# SDK"
@@ -1068,12 +1082,12 @@ model AccessRulePropertiesSubscriptionsItem {
10681082
"csharp"
10691083
);
10701084
@@clientName(
1071-
PrivateEndpointConnectionProperties,
1085+
Microsoft.Search.PrivateEndpointConnectionProperties,
10721086
"SearchServicePrivateEndpointConnectionProperties",
10731087
"csharp"
10741088
);
10751089
@@clientName(
1076-
PrivateEndpointConnectionProperties.privateLinkServiceConnectionState,
1090+
Microsoft.Search.PrivateEndpointConnectionProperties.privateLinkServiceConnectionState,
10771091
"ConnectionState",
10781092
"csharp"
10791093
);
@@ -1151,7 +1165,7 @@ model AccessRulePropertiesSubscriptionsItem {
11511165
"csharp"
11521166
);
11531167
@@clientName(
1154-
PrivateEndpointConnection,
1168+
Microsoft.Search.PrivateEndpointConnection,
11551169
"SearchPrivateEndpointConnection",
11561170
"csharp"
11571171
);

specification/search/resource-manager/Microsoft.Search/Search/main.tsp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import "./PrivateEndpointConnection.tsp";
1818
import "./SharedPrivateLinkResource.tsp";
1919
import "./NetworkSecurityPerimeterConfiguration.tsp";
2020
import "./routes.tsp";
21+
import "./client.tsp";
2122

2223
using TypeSpec.Rest;
2324
using TypeSpec.Http;

0 commit comments

Comments
 (0)