@azure/arm-postgresql-flexible 8.1.0-alpha.20250718.1 → 8.1.0-alpha.20250721.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/lroImpl.js +7 -3
- package/dist/browser/lroImpl.js.map +1 -1
- package/dist/browser/models/mappers.js +395 -183
- package/dist/browser/models/mappers.js.map +1 -1
- package/dist/browser/operations/administrators.js +45 -52
- package/dist/browser/operations/administrators.js.map +1 -1
- package/dist/browser/operations/backups.js +45 -52
- package/dist/browser/operations/backups.js.map +1 -1
- package/dist/browser/operations/checkNameAvailability.js +1 -0
- package/dist/browser/operations/checkNameAvailability.js.map +1 -1
- package/dist/browser/operations/checkNameAvailabilityWithLocation.js +1 -0
- package/dist/browser/operations/checkNameAvailabilityWithLocation.js.map +1 -1
- package/dist/browser/operations/configurations.js +45 -52
- package/dist/browser/operations/configurations.js.map +1 -1
- package/dist/browser/operations/databases.js +45 -52
- package/dist/browser/operations/databases.js.map +1 -1
- package/dist/browser/operations/firewallRules.js +45 -52
- package/dist/browser/operations/firewallRules.js.map +1 -1
- package/dist/browser/operations/flexibleServer.js +12 -6
- package/dist/browser/operations/flexibleServer.js.map +1 -1
- package/dist/browser/operations/getPrivateDnsZoneSuffix.js +1 -0
- package/dist/browser/operations/getPrivateDnsZoneSuffix.js.map +1 -1
- package/dist/browser/operations/locationBasedCapabilities.js +23 -40
- package/dist/browser/operations/locationBasedCapabilities.js.map +1 -1
- package/dist/browser/operations/logFiles.js +23 -40
- package/dist/browser/operations/logFiles.js.map +1 -1
- package/dist/browser/operations/ltrBackupOperations.js +23 -40
- package/dist/browser/operations/ltrBackupOperations.js.map +1 -1
- package/dist/browser/operations/migrations.js +23 -40
- package/dist/browser/operations/migrations.js.map +1 -1
- package/dist/browser/operations/operations.js +23 -40
- package/dist/browser/operations/operations.js.map +1 -1
- package/dist/browser/operations/privateEndpointConnectionOperations.js +23 -12
- package/dist/browser/operations/privateEndpointConnectionOperations.js.map +1 -1
- package/dist/browser/operations/privateEndpointConnections.js +23 -40
- package/dist/browser/operations/privateEndpointConnections.js.map +1 -1
- package/dist/browser/operations/privateLinkResources.js +23 -40
- package/dist/browser/operations/privateLinkResources.js.map +1 -1
- package/dist/browser/operations/quotaUsages.js +23 -40
- package/dist/browser/operations/quotaUsages.js.map +1 -1
- package/dist/browser/operations/replicas.js +10 -27
- package/dist/browser/operations/replicas.js.map +1 -1
- package/dist/browser/operations/serverCapabilities.js +23 -40
- package/dist/browser/operations/serverCapabilities.js.map +1 -1
- package/dist/browser/operations/serverThreatProtectionSettings.js +34 -46
- package/dist/browser/operations/serverThreatProtectionSettings.js.map +1 -1
- package/dist/browser/operations/servers.js +111 -115
- package/dist/browser/operations/servers.js.map +1 -1
- package/dist/browser/operations/tuningConfiguration.js +89 -103
- package/dist/browser/operations/tuningConfiguration.js.map +1 -1
- package/dist/browser/operations/tuningIndex.js +23 -40
- package/dist/browser/operations/tuningIndex.js.map +1 -1
- package/dist/browser/operations/tuningOptions.js +23 -40
- package/dist/browser/operations/tuningOptions.js.map +1 -1
- package/dist/browser/operations/virtualEndpoints.js +56 -58
- package/dist/browser/operations/virtualEndpoints.js.map +1 -1
- package/dist/browser/operations/virtualNetworkSubnetUsage.js +1 -0
- package/dist/browser/operations/virtualNetworkSubnetUsage.js.map +1 -1
- package/dist/browser/pagingHelper.js +2 -4
- package/dist/browser/pagingHelper.js.map +1 -1
- package/dist/browser/postgreSQLManagementFlexibleServerClient.js +39 -5
- package/dist/browser/postgreSQLManagementFlexibleServerClient.js.map +1 -1
- package/dist/commonjs/lroImpl.js +7 -3
- package/dist/commonjs/lroImpl.js.map +1 -1
- package/dist/commonjs/models/mappers.js +395 -183
- package/dist/commonjs/models/mappers.js.map +1 -1
- package/dist/commonjs/operations/administrators.js +45 -51
- package/dist/commonjs/operations/administrators.js.map +1 -1
- package/dist/commonjs/operations/backups.js +45 -51
- package/dist/commonjs/operations/backups.js.map +1 -1
- package/dist/commonjs/operations/checkNameAvailability.js +1 -0
- package/dist/commonjs/operations/checkNameAvailability.js.map +1 -1
- package/dist/commonjs/operations/checkNameAvailabilityWithLocation.js +1 -0
- package/dist/commonjs/operations/checkNameAvailabilityWithLocation.js.map +1 -1
- package/dist/commonjs/operations/configurations.js +45 -51
- package/dist/commonjs/operations/configurations.js.map +1 -1
- package/dist/commonjs/operations/databases.js +45 -51
- package/dist/commonjs/operations/databases.js.map +1 -1
- package/dist/commonjs/operations/firewallRules.js +45 -51
- package/dist/commonjs/operations/firewallRules.js.map +1 -1
- package/dist/commonjs/operations/flexibleServer.js +12 -6
- package/dist/commonjs/operations/flexibleServer.js.map +1 -1
- package/dist/commonjs/operations/getPrivateDnsZoneSuffix.js +1 -0
- package/dist/commonjs/operations/getPrivateDnsZoneSuffix.js.map +1 -1
- package/dist/commonjs/operations/locationBasedCapabilities.js +23 -39
- package/dist/commonjs/operations/locationBasedCapabilities.js.map +1 -1
- package/dist/commonjs/operations/logFiles.js +23 -39
- package/dist/commonjs/operations/logFiles.js.map +1 -1
- package/dist/commonjs/operations/ltrBackupOperations.js +23 -39
- package/dist/commonjs/operations/ltrBackupOperations.js.map +1 -1
- package/dist/commonjs/operations/migrations.js +23 -39
- package/dist/commonjs/operations/migrations.js.map +1 -1
- package/dist/commonjs/operations/operations.js +23 -39
- package/dist/commonjs/operations/operations.js.map +1 -1
- package/dist/commonjs/operations/privateEndpointConnectionOperations.js +23 -12
- package/dist/commonjs/operations/privateEndpointConnectionOperations.js.map +1 -1
- package/dist/commonjs/operations/privateEndpointConnections.js +23 -39
- package/dist/commonjs/operations/privateEndpointConnections.js.map +1 -1
- package/dist/commonjs/operations/privateLinkResources.js +23 -39
- package/dist/commonjs/operations/privateLinkResources.js.map +1 -1
- package/dist/commonjs/operations/quotaUsages.js +23 -39
- package/dist/commonjs/operations/quotaUsages.js.map +1 -1
- package/dist/commonjs/operations/replicas.js +10 -26
- package/dist/commonjs/operations/replicas.js.map +1 -1
- package/dist/commonjs/operations/serverCapabilities.js +23 -39
- package/dist/commonjs/operations/serverCapabilities.js.map +1 -1
- package/dist/commonjs/operations/serverThreatProtectionSettings.js +34 -45
- package/dist/commonjs/operations/serverThreatProtectionSettings.js.map +1 -1
- package/dist/commonjs/operations/servers.js +111 -114
- package/dist/commonjs/operations/servers.js.map +1 -1
- package/dist/commonjs/operations/tuningConfiguration.js +89 -102
- package/dist/commonjs/operations/tuningConfiguration.js.map +1 -1
- package/dist/commonjs/operations/tuningIndex.js +23 -39
- package/dist/commonjs/operations/tuningIndex.js.map +1 -1
- package/dist/commonjs/operations/tuningOptions.js +23 -39
- package/dist/commonjs/operations/tuningOptions.js.map +1 -1
- package/dist/commonjs/operations/virtualEndpoints.js +56 -57
- package/dist/commonjs/operations/virtualEndpoints.js.map +1 -1
- package/dist/commonjs/operations/virtualNetworkSubnetUsage.js +1 -0
- package/dist/commonjs/operations/virtualNetworkSubnetUsage.js.map +1 -1
- package/dist/commonjs/pagingHelper.js +2 -4
- package/dist/commonjs/pagingHelper.js.map +1 -1
- package/dist/commonjs/postgreSQLManagementFlexibleServerClient.js +39 -5
- package/dist/commonjs/postgreSQLManagementFlexibleServerClient.js.map +1 -1
- package/dist/commonjs/tsdoc-metadata.json +11 -11
- package/dist/esm/lroImpl.js +7 -3
- package/dist/esm/lroImpl.js.map +1 -1
- package/dist/esm/models/mappers.js +395 -183
- package/dist/esm/models/mappers.js.map +1 -1
- package/dist/esm/operations/administrators.js +45 -52
- package/dist/esm/operations/administrators.js.map +1 -1
- package/dist/esm/operations/backups.js +45 -52
- package/dist/esm/operations/backups.js.map +1 -1
- package/dist/esm/operations/checkNameAvailability.js +1 -0
- package/dist/esm/operations/checkNameAvailability.js.map +1 -1
- package/dist/esm/operations/checkNameAvailabilityWithLocation.js +1 -0
- package/dist/esm/operations/checkNameAvailabilityWithLocation.js.map +1 -1
- package/dist/esm/operations/configurations.js +45 -52
- package/dist/esm/operations/configurations.js.map +1 -1
- package/dist/esm/operations/databases.js +45 -52
- package/dist/esm/operations/databases.js.map +1 -1
- package/dist/esm/operations/firewallRules.js +45 -52
- package/dist/esm/operations/firewallRules.js.map +1 -1
- package/dist/esm/operations/flexibleServer.js +12 -6
- package/dist/esm/operations/flexibleServer.js.map +1 -1
- package/dist/esm/operations/getPrivateDnsZoneSuffix.js +1 -0
- package/dist/esm/operations/getPrivateDnsZoneSuffix.js.map +1 -1
- package/dist/esm/operations/locationBasedCapabilities.js +23 -40
- package/dist/esm/operations/locationBasedCapabilities.js.map +1 -1
- package/dist/esm/operations/logFiles.js +23 -40
- package/dist/esm/operations/logFiles.js.map +1 -1
- package/dist/esm/operations/ltrBackupOperations.js +23 -40
- package/dist/esm/operations/ltrBackupOperations.js.map +1 -1
- package/dist/esm/operations/migrations.js +23 -40
- package/dist/esm/operations/migrations.js.map +1 -1
- package/dist/esm/operations/operations.js +23 -40
- package/dist/esm/operations/operations.js.map +1 -1
- package/dist/esm/operations/privateEndpointConnectionOperations.js +23 -12
- package/dist/esm/operations/privateEndpointConnectionOperations.js.map +1 -1
- package/dist/esm/operations/privateEndpointConnections.js +23 -40
- package/dist/esm/operations/privateEndpointConnections.js.map +1 -1
- package/dist/esm/operations/privateLinkResources.js +23 -40
- package/dist/esm/operations/privateLinkResources.js.map +1 -1
- package/dist/esm/operations/quotaUsages.js +23 -40
- package/dist/esm/operations/quotaUsages.js.map +1 -1
- package/dist/esm/operations/replicas.js +10 -27
- package/dist/esm/operations/replicas.js.map +1 -1
- package/dist/esm/operations/serverCapabilities.js +23 -40
- package/dist/esm/operations/serverCapabilities.js.map +1 -1
- package/dist/esm/operations/serverThreatProtectionSettings.js +34 -46
- package/dist/esm/operations/serverThreatProtectionSettings.js.map +1 -1
- package/dist/esm/operations/servers.js +111 -115
- package/dist/esm/operations/servers.js.map +1 -1
- package/dist/esm/operations/tuningConfiguration.js +89 -103
- package/dist/esm/operations/tuningConfiguration.js.map +1 -1
- package/dist/esm/operations/tuningIndex.js +23 -40
- package/dist/esm/operations/tuningIndex.js.map +1 -1
- package/dist/esm/operations/tuningOptions.js +23 -40
- package/dist/esm/operations/tuningOptions.js.map +1 -1
- package/dist/esm/operations/virtualEndpoints.js +56 -58
- package/dist/esm/operations/virtualEndpoints.js.map +1 -1
- package/dist/esm/operations/virtualNetworkSubnetUsage.js +1 -0
- package/dist/esm/operations/virtualNetworkSubnetUsage.js.map +1 -1
- package/dist/esm/pagingHelper.js +2 -4
- package/dist/esm/pagingHelper.js.map +1 -1
- package/dist/esm/postgreSQLManagementFlexibleServerClient.js +39 -5
- package/dist/esm/postgreSQLManagementFlexibleServerClient.js.map +1 -1
- package/dist/react-native/lroImpl.js +7 -3
- package/dist/react-native/lroImpl.js.map +1 -1
- package/dist/react-native/models/mappers.js +395 -183
- package/dist/react-native/models/mappers.js.map +1 -1
- package/dist/react-native/operations/administrators.js +45 -52
- package/dist/react-native/operations/administrators.js.map +1 -1
- package/dist/react-native/operations/backups.js +45 -52
- package/dist/react-native/operations/backups.js.map +1 -1
- package/dist/react-native/operations/checkNameAvailability.js +1 -0
- package/dist/react-native/operations/checkNameAvailability.js.map +1 -1
- package/dist/react-native/operations/checkNameAvailabilityWithLocation.js +1 -0
- package/dist/react-native/operations/checkNameAvailabilityWithLocation.js.map +1 -1
- package/dist/react-native/operations/configurations.js +45 -52
- package/dist/react-native/operations/configurations.js.map +1 -1
- package/dist/react-native/operations/databases.js +45 -52
- package/dist/react-native/operations/databases.js.map +1 -1
- package/dist/react-native/operations/firewallRules.js +45 -52
- package/dist/react-native/operations/firewallRules.js.map +1 -1
- package/dist/react-native/operations/flexibleServer.js +12 -6
- package/dist/react-native/operations/flexibleServer.js.map +1 -1
- package/dist/react-native/operations/getPrivateDnsZoneSuffix.js +1 -0
- package/dist/react-native/operations/getPrivateDnsZoneSuffix.js.map +1 -1
- package/dist/react-native/operations/locationBasedCapabilities.js +23 -40
- package/dist/react-native/operations/locationBasedCapabilities.js.map +1 -1
- package/dist/react-native/operations/logFiles.js +23 -40
- package/dist/react-native/operations/logFiles.js.map +1 -1
- package/dist/react-native/operations/ltrBackupOperations.js +23 -40
- package/dist/react-native/operations/ltrBackupOperations.js.map +1 -1
- package/dist/react-native/operations/migrations.js +23 -40
- package/dist/react-native/operations/migrations.js.map +1 -1
- package/dist/react-native/operations/operations.js +23 -40
- package/dist/react-native/operations/operations.js.map +1 -1
- package/dist/react-native/operations/privateEndpointConnectionOperations.js +23 -12
- package/dist/react-native/operations/privateEndpointConnectionOperations.js.map +1 -1
- package/dist/react-native/operations/privateEndpointConnections.js +23 -40
- package/dist/react-native/operations/privateEndpointConnections.js.map +1 -1
- package/dist/react-native/operations/privateLinkResources.js +23 -40
- package/dist/react-native/operations/privateLinkResources.js.map +1 -1
- package/dist/react-native/operations/quotaUsages.js +23 -40
- package/dist/react-native/operations/quotaUsages.js.map +1 -1
- package/dist/react-native/operations/replicas.js +10 -27
- package/dist/react-native/operations/replicas.js.map +1 -1
- package/dist/react-native/operations/serverCapabilities.js +23 -40
- package/dist/react-native/operations/serverCapabilities.js.map +1 -1
- package/dist/react-native/operations/serverThreatProtectionSettings.js +34 -46
- package/dist/react-native/operations/serverThreatProtectionSettings.js.map +1 -1
- package/dist/react-native/operations/servers.js +111 -115
- package/dist/react-native/operations/servers.js.map +1 -1
- package/dist/react-native/operations/tuningConfiguration.js +89 -103
- package/dist/react-native/operations/tuningConfiguration.js.map +1 -1
- package/dist/react-native/operations/tuningIndex.js +23 -40
- package/dist/react-native/operations/tuningIndex.js.map +1 -1
- package/dist/react-native/operations/tuningOptions.js +23 -40
- package/dist/react-native/operations/tuningOptions.js.map +1 -1
- package/dist/react-native/operations/virtualEndpoints.js +56 -58
- package/dist/react-native/operations/virtualEndpoints.js.map +1 -1
- package/dist/react-native/operations/virtualNetworkSubnetUsage.js +1 -0
- package/dist/react-native/operations/virtualNetworkSubnetUsage.js.map +1 -1
- package/dist/react-native/pagingHelper.js +2 -4
- package/dist/react-native/pagingHelper.js.map +1 -1
- package/dist/react-native/postgreSQLManagementFlexibleServerClient.js +39 -5
- package/dist/react-native/postgreSQLManagementFlexibleServerClient.js.map +1 -1
- package/package.json +2 -2
- package/review/arm-postgresql-flexible-node.api.md +2723 -2723
|
@@ -15,8 +15,10 @@ const index_js_1 = require("./operations/index.js");
|
|
|
15
15
|
const Parameters = tslib_1.__importStar(require("./models/parameters.js"));
|
|
16
16
|
const Mappers = tslib_1.__importStar(require("./models/mappers.js"));
|
|
17
17
|
class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient {
|
|
18
|
+
$host;
|
|
19
|
+
subscriptionId;
|
|
20
|
+
apiVersion;
|
|
18
21
|
constructor(credentials, subscriptionIdOrOptions, options) {
|
|
19
|
-
var _a, _b, _c;
|
|
20
22
|
if (credentials === undefined) {
|
|
21
23
|
throw new Error("'credentials' cannot be null");
|
|
22
24
|
}
|
|
@@ -39,12 +41,17 @@ class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient
|
|
|
39
41
|
const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
|
40
42
|
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
|
41
43
|
: `${packageDetails}`;
|
|
42
|
-
const optionsWithDefaults =
|
|
44
|
+
const optionsWithDefaults = {
|
|
45
|
+
...defaults,
|
|
46
|
+
...options,
|
|
47
|
+
userAgentOptions: {
|
|
43
48
|
userAgentPrefix,
|
|
44
|
-
},
|
|
49
|
+
},
|
|
50
|
+
endpoint: options.endpoint ?? options.baseUri ?? "https://management.azure.com",
|
|
51
|
+
};
|
|
45
52
|
super(optionsWithDefaults);
|
|
46
53
|
let bearerTokenAuthenticationPolicyFound = false;
|
|
47
|
-
if (
|
|
54
|
+
if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
|
|
48
55
|
const pipelinePolicies = options.pipeline.getOrderedPolicies();
|
|
49
56
|
bearerTokenAuthenticationPolicyFound = pipelinePolicies.some((pipelinePolicy) => pipelinePolicy.name === coreRestPipeline.bearerTokenAuthenticationPolicyName);
|
|
50
57
|
}
|
|
@@ -57,7 +64,7 @@ class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient
|
|
|
57
64
|
});
|
|
58
65
|
this.pipeline.addPolicy(coreRestPipeline.bearerTokenAuthenticationPolicy({
|
|
59
66
|
credential: credentials,
|
|
60
|
-
scopes:
|
|
67
|
+
scopes: optionsWithDefaults.credentialScopes ?? `${optionsWithDefaults.endpoint}/.default`,
|
|
61
68
|
challengeCallbacks: {
|
|
62
69
|
authorizeRequestOnChallenge: coreClient.authorizeRequestOnClaimChallenge,
|
|
63
70
|
},
|
|
@@ -139,6 +146,33 @@ class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient
|
|
|
139
146
|
options,
|
|
140
147
|
}, checkMigrationNameAvailabilityOperationSpec);
|
|
141
148
|
}
|
|
149
|
+
administrators;
|
|
150
|
+
backups;
|
|
151
|
+
locationBasedCapabilities;
|
|
152
|
+
serverCapabilities;
|
|
153
|
+
checkNameAvailability;
|
|
154
|
+
checkNameAvailabilityWithLocation;
|
|
155
|
+
configurations;
|
|
156
|
+
databases;
|
|
157
|
+
firewallRules;
|
|
158
|
+
servers;
|
|
159
|
+
flexibleServer;
|
|
160
|
+
ltrBackupOperations;
|
|
161
|
+
migrations;
|
|
162
|
+
operations;
|
|
163
|
+
getPrivateDnsZoneSuffix;
|
|
164
|
+
privateEndpointConnections;
|
|
165
|
+
privateEndpointConnectionOperations;
|
|
166
|
+
privateLinkResources;
|
|
167
|
+
quotaUsages;
|
|
168
|
+
replicas;
|
|
169
|
+
logFiles;
|
|
170
|
+
serverThreatProtectionSettings;
|
|
171
|
+
tuningOptions;
|
|
172
|
+
tuningIndex;
|
|
173
|
+
tuningConfiguration;
|
|
174
|
+
virtualEndpoints;
|
|
175
|
+
virtualNetworkSubnetUsage;
|
|
142
176
|
}
|
|
143
177
|
exports.PostgreSQLManagementFlexibleServerClient = PostgreSQLManagementFlexibleServerClient;
|
|
144
178
|
// Operation Specifications
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"postgreSQLManagementFlexibleServerClient.js","sourceRoot":"","sources":["../../src/postgreSQLManagementFlexibleServerClient.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAEH,uEAAiD;AACjD,oFAA8D;AAG9D,oDA4B+B;AA8B/B,2EAAqD;AACrD,qEAA+C;AAQ/C,MAAa,wCAAyC,SAAQ,UAAU,CAAC,aAAa;IAoBpF,YACE,WAAqC,EACrC,uBAAyF,EACzF,OAAgE;;QAEhE,IAAI,WAAW,KAAK,SAAS,EAAE,CAAC;YAC9B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;QAClD,CAAC;QAED,IAAI,cAAkC,CAAC;QAEvC,IAAI,OAAO,uBAAuB,KAAK,QAAQ,EAAE,CAAC;YAChD,cAAc,GAAG,uBAAuB,CAAC;QAC3C,CAAC;aAAM,IAAI,OAAO,uBAAuB,KAAK,QAAQ,EAAE,CAAC;YACvD,OAAO,GAAG,uBAAuB,CAAC;QACpC,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAA2D;YACvE,kBAAkB,EAAE,iCAAiC;YACrD,UAAU,EAAE,WAAW;SACxB,CAAC;QAEF,MAAM,cAAc,GAAG,+CAA+C,CAAC;QACvE,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,iDACpB,QAAQ,GACR,OAAO,KACV,gBAAgB,EAAE;gBAChB,eAAe;aAChB,EACD,QAAQ,EAAE,MAAA,MAAA,OAAO,CAAC,QAAQ,mCAAI,OAAO,CAAC,OAAO,mCAAI,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B;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,MAAM,CAAC;IAC7D,SAAS,EAAE,MAAM;IACjB,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport * as coreRestPipeline from \"@azure/core-rest-pipeline\";\nimport type { PipelineRequest, PipelineResponse, SendRequest } from \"@azure/core-rest-pipeline\";\nimport type * as coreAuth from \"@azure/core-auth\";\nimport {\n AdministratorsImpl,\n BackupsImpl,\n LocationBasedCapabilitiesImpl,\n ServerCapabilitiesImpl,\n CheckNameAvailabilityImpl,\n CheckNameAvailabilityWithLocationImpl,\n ConfigurationsImpl,\n DatabasesImpl,\n FirewallRulesImpl,\n ServersImpl,\n FlexibleServerImpl,\n LtrBackupOperationsImpl,\n MigrationsImpl,\n OperationsImpl,\n GetPrivateDnsZoneSuffixImpl,\n PrivateEndpointConnectionsImpl,\n PrivateEndpointConnectionOperationsImpl,\n PrivateLinkResourcesImpl,\n QuotaUsagesImpl,\n ReplicasImpl,\n LogFilesImpl,\n ServerThreatProtectionSettingsImpl,\n TuningOptionsImpl,\n TuningIndexImpl,\n TuningConfigurationImpl,\n VirtualEndpointsImpl,\n VirtualNetworkSubnetUsageImpl,\n} from \"./operations/index.js\";\nimport type {\n Administrators,\n Backups,\n LocationBasedCapabilities,\n ServerCapabilities,\n CheckNameAvailability,\n CheckNameAvailabilityWithLocation,\n Configurations,\n Databases,\n FirewallRules,\n Servers,\n FlexibleServer,\n LtrBackupOperations,\n Migrations,\n Operations,\n GetPrivateDnsZoneSuffix,\n PrivateEndpointConnections,\n PrivateEndpointConnectionOperations,\n PrivateLinkResources,\n QuotaUsages,\n Replicas,\n LogFiles,\n ServerThreatProtectionSettings,\n TuningOptions,\n TuningIndex,\n TuningConfiguration,\n VirtualEndpoints,\n VirtualNetworkSubnetUsage,\n} from \"./operationsInterfaces/index.js\";\nimport * as Parameters from \"./models/parameters.js\";\nimport * as Mappers from \"./models/mappers.js\";\nimport type {\n PostgreSQLManagementFlexibleServerClientOptionalParams,\n MigrationNameAvailabilityResource,\n CheckMigrationNameAvailabilityOptionalParams,\n CheckMigrationNameAvailabilityResponse,\n} from \"./models/index.js\";\n\nexport class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient {\n $host: string;\n subscriptionId?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the PostgreSQLManagementFlexibleServerClient class.\n * @param credentials Subscription credentials which uniquely identify client subscription.\n * @param subscriptionId The ID of the target subscription. The value must be an UUID.\n * @param options The parameter options\n */\n constructor(\n credentials: coreAuth.TokenCredential,\n subscriptionId: string,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n );\n constructor(\n credentials: coreAuth.TokenCredential,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n );\n constructor(\n credentials: coreAuth.TokenCredential,\n subscriptionIdOrOptions?: PostgreSQLManagementFlexibleServerClientOptionalParams | string,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n ) {\n if (credentials === undefined) {\n throw new Error(\"'credentials' cannot be null\");\n }\n\n let subscriptionId: string | undefined;\n\n if (typeof subscriptionIdOrOptions === \"string\") {\n subscriptionId = subscriptionIdOrOptions;\n } else if (typeof subscriptionIdOrOptions === \"object\") {\n options = subscriptionIdOrOptions;\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: PostgreSQLManagementFlexibleServerClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n credential: credentials,\n };\n\n const packageDetails = `azsdk-js-arm-postgresql-flexible/8.1.0-beta.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix,\n },\n endpoint: options.endpoint ?? options.baseUri ?? \"https://management.azure.com\",\n };\n super(optionsWithDefaults);\n\n let bearerTokenAuthenticationPolicyFound: boolean = false;\n if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {\n const pipelinePolicies: coreRestPipeline.PipelinePolicy[] =\n options.pipeline.getOrderedPolicies();\n bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(\n (pipelinePolicy) =>\n pipelinePolicy.name === coreRestPipeline.bearerTokenAuthenticationPolicyName,\n );\n }\n if (\n !options ||\n !options.pipeline ||\n options.pipeline.getOrderedPolicies().length == 0 ||\n !bearerTokenAuthenticationPolicyFound\n ) {\n this.pipeline.removePolicy({\n name: coreRestPipeline.bearerTokenAuthenticationPolicyName,\n });\n this.pipeline.addPolicy(\n coreRestPipeline.bearerTokenAuthenticationPolicy({\n credential: credentials,\n scopes:\n optionsWithDefaults.credentialScopes ?? `${optionsWithDefaults.endpoint}/.default`,\n challengeCallbacks: {\n authorizeRequestOnChallenge: coreClient.authorizeRequestOnClaimChallenge,\n },\n }),\n );\n }\n // Parameter assignments\n this.subscriptionId = subscriptionId;\n\n // Assigning values to Constant parameters\n this.$host = options.$host || \"https://management.azure.com\";\n this.apiVersion = options.apiVersion || \"2025-01-01-preview\";\n this.administrators = new AdministratorsImpl(this);\n this.backups = new BackupsImpl(this);\n this.locationBasedCapabilities = new LocationBasedCapabilitiesImpl(this);\n this.serverCapabilities = new ServerCapabilitiesImpl(this);\n this.checkNameAvailability = new CheckNameAvailabilityImpl(this);\n this.checkNameAvailabilityWithLocation = new CheckNameAvailabilityWithLocationImpl(this);\n this.configurations = new ConfigurationsImpl(this);\n this.databases = new DatabasesImpl(this);\n this.firewallRules = new FirewallRulesImpl(this);\n this.servers = new ServersImpl(this);\n this.flexibleServer = new FlexibleServerImpl(this);\n this.ltrBackupOperations = new LtrBackupOperationsImpl(this);\n this.migrations = new MigrationsImpl(this);\n this.operations = new OperationsImpl(this);\n this.getPrivateDnsZoneSuffix = new GetPrivateDnsZoneSuffixImpl(this);\n this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this);\n this.privateEndpointConnectionOperations = new PrivateEndpointConnectionOperationsImpl(this);\n this.privateLinkResources = new PrivateLinkResourcesImpl(this);\n this.quotaUsages = new QuotaUsagesImpl(this);\n this.replicas = new ReplicasImpl(this);\n this.logFiles = new LogFilesImpl(this);\n this.serverThreatProtectionSettings = new ServerThreatProtectionSettingsImpl(this);\n this.tuningOptions = new TuningOptionsImpl(this);\n this.tuningIndex = new TuningIndexImpl(this);\n this.tuningConfiguration = new TuningConfigurationImpl(this);\n this.virtualEndpoints = new VirtualEndpointsImpl(this);\n this.virtualNetworkSubnetUsage = new VirtualNetworkSubnetUsageImpl(this);\n this.addCustomApiVersionPolicy(options.apiVersion);\n }\n\n /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */\n private addCustomApiVersionPolicy(apiVersion?: string) {\n if (!apiVersion) {\n return;\n }\n const apiVersionPolicy = {\n name: \"CustomApiVersionPolicy\",\n async sendRequest(request: PipelineRequest, next: SendRequest): Promise<PipelineResponse> {\n const param = request.url.split(\"?\");\n if (param.length > 1) {\n const newParams = param[1].split(\"&\").map((item) => {\n if (item.indexOf(\"api-version\") > -1) {\n return \"api-version=\" + apiVersion;\n } else {\n return item;\n }\n });\n request.url = param[0] + \"?\" + newParams.join(\"&\");\n }\n return next(request);\n },\n };\n this.pipeline.addPolicy(apiVersionPolicy);\n }\n\n /**\n * This method checks whether a proposed migration name is valid and available.\n * @param subscriptionId The subscription ID of the target database server.\n * @param resourceGroupName The resource group name of the target database server.\n * @param targetDbServerName The name of the target database server.\n * @param parameters The required parameters for checking if a migration name is available.\n * @param options The options parameters.\n */\n checkMigrationNameAvailability(\n subscriptionId: string,\n resourceGroupName: string,\n targetDbServerName: string,\n parameters: MigrationNameAvailabilityResource,\n options?: CheckMigrationNameAvailabilityOptionalParams,\n ): Promise<CheckMigrationNameAvailabilityResponse> {\n return this.sendOperationRequest(\n {\n subscriptionId,\n resourceGroupName,\n targetDbServerName,\n parameters,\n options,\n },\n checkMigrationNameAvailabilityOperationSpec,\n );\n }\n\n administrators: Administrators;\n backups: Backups;\n locationBasedCapabilities: LocationBasedCapabilities;\n serverCapabilities: ServerCapabilities;\n checkNameAvailability: CheckNameAvailability;\n checkNameAvailabilityWithLocation: CheckNameAvailabilityWithLocation;\n configurations: Configurations;\n databases: Databases;\n firewallRules: FirewallRules;\n servers: Servers;\n flexibleServer: FlexibleServer;\n ltrBackupOperations: LtrBackupOperations;\n migrations: Migrations;\n operations: Operations;\n getPrivateDnsZoneSuffix: GetPrivateDnsZoneSuffix;\n privateEndpointConnections: PrivateEndpointConnections;\n privateEndpointConnectionOperations: PrivateEndpointConnectionOperations;\n privateLinkResources: PrivateLinkResources;\n quotaUsages: QuotaUsages;\n replicas: Replicas;\n logFiles: LogFiles;\n serverThreatProtectionSettings: ServerThreatProtectionSettings;\n tuningOptions: TuningOptions;\n tuningIndex: TuningIndex;\n tuningConfiguration: TuningConfiguration;\n virtualEndpoints: VirtualEndpoints;\n virtualNetworkSubnetUsage: VirtualNetworkSubnetUsage;\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst checkMigrationNameAvailabilityOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{targetDbServerName}/checkMigrationNameAvailability\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.MigrationNameAvailabilityResource,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n requestBody: Parameters.parameters12,\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId1,\n Parameters.resourceGroupName1,\n Parameters.targetDbServerName,\n ],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\n"]}
|
|
1
|
+
{"version":3,"file":"postgreSQLManagementFlexibleServerClient.js","sourceRoot":"","sources":["../../src/postgreSQLManagementFlexibleServerClient.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAEH,uEAAiD;AACjD,oFAA8D;AAG9D,oDA4B+B;AA8B/B,2EAAqD;AACrD,qEAA+C;AAQ/C,MAAa,wCAAyC,SAAQ,UAAU,CAAC,aAAa;IACpF,KAAK,CAAS;IACd,cAAc,CAAU;IACxB,UAAU,CAAS;IAiBnB,YACE,WAAqC,EACrC,uBAAyF,EACzF,OAAgE;QAEhE,IAAI,WAAW,KAAK,SAAS,EAAE,CAAC;YAC9B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;QAClD,CAAC;QAED,IAAI,cAAkC,CAAC;QAEvC,IAAI,OAAO,uBAAuB,KAAK,QAAQ,EAAE,CAAC;YAChD,cAAc,GAAG,uBAAuB,CAAC;QAC3C,CAAC;aAAM,IAAI,OAAO,uBAAuB,KAAK,QAAQ,EAAE,CAAC;YACvD,OAAO,GAAG,uBAAuB,CAAC;QACpC,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD,MAAM,QAAQ,GAA2D;YACvE,kBAAkB,EAAE,iCAAiC;YACrD,UAAU,EAAE,WAAW;SACxB,CAAC;QAEF,MAAM,cAAc,GAAG,+CAA+C,CAAC;QACvE,MAAM,eAAe,GACnB,OAAO,CAAC,gBAAgB,IAAI,OAAO,CAAC,gBAAgB,CAAC,eAAe;YAClE,CAAC,CAAC,GAAG,OAAO,CAAC,gBAAgB,CAAC,eAAe,IAAI,cAAc,EAAE;YACjE,CAAC,CAAC,GAAG,cAAc,EAAE,CAAC;QAE1B,MAAM,mBAAmB,GAAG;YAC1B,GAAG,QAAQ;YACX,GAAG,OAAO;YACV,gBAAgB,EAAE;gBAChB,eAAe;a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mB;IACnC,yBAAyB,CAA4B;CACtD;AA9MD,4FA8MC;AACD,2BAA2B;AAC3B,MAAM,UAAU,GAAG,UAAU,CAAC,gBAAgB,CAAC,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,CAAC;AAE3E,MAAM,2CAA2C,GAA6B;IAC5E,IAAI,EAAE,4KAA4K;IAClL,UAAU,EAAE,MAAM;IAClB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,iCAAiC;SACtD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,aAAa;SAClC;KACF;IACD,WAAW,EAAE,UAAU,CAAC,YAAY;IACpC,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,eAAe;QAC1B,UAAU,CAAC,kBAAkB;QAC7B,UAAU,CAAC,kBAAkB;KAC9B;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,WAAW,EAAE,UAAU,CAAC,MAAM,CAAC;IAC7D,SAAS,EAAE,MAAM;IACjB,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport * as coreRestPipeline from \"@azure/core-rest-pipeline\";\nimport type { PipelineRequest, PipelineResponse, SendRequest } from \"@azure/core-rest-pipeline\";\nimport type * as coreAuth from \"@azure/core-auth\";\nimport {\n AdministratorsImpl,\n BackupsImpl,\n LocationBasedCapabilitiesImpl,\n ServerCapabilitiesImpl,\n CheckNameAvailabilityImpl,\n CheckNameAvailabilityWithLocationImpl,\n ConfigurationsImpl,\n DatabasesImpl,\n FirewallRulesImpl,\n ServersImpl,\n FlexibleServerImpl,\n LtrBackupOperationsImpl,\n MigrationsImpl,\n OperationsImpl,\n GetPrivateDnsZoneSuffixImpl,\n PrivateEndpointConnectionsImpl,\n PrivateEndpointConnectionOperationsImpl,\n PrivateLinkResourcesImpl,\n QuotaUsagesImpl,\n ReplicasImpl,\n LogFilesImpl,\n ServerThreatProtectionSettingsImpl,\n TuningOptionsImpl,\n TuningIndexImpl,\n TuningConfigurationImpl,\n VirtualEndpointsImpl,\n VirtualNetworkSubnetUsageImpl,\n} from \"./operations/index.js\";\nimport type {\n Administrators,\n Backups,\n LocationBasedCapabilities,\n ServerCapabilities,\n CheckNameAvailability,\n CheckNameAvailabilityWithLocation,\n Configurations,\n Databases,\n FirewallRules,\n Servers,\n FlexibleServer,\n LtrBackupOperations,\n Migrations,\n Operations,\n GetPrivateDnsZoneSuffix,\n PrivateEndpointConnections,\n PrivateEndpointConnectionOperations,\n PrivateLinkResources,\n QuotaUsages,\n Replicas,\n LogFiles,\n ServerThreatProtectionSettings,\n TuningOptions,\n TuningIndex,\n TuningConfiguration,\n VirtualEndpoints,\n VirtualNetworkSubnetUsage,\n} from \"./operationsInterfaces/index.js\";\nimport * as Parameters from \"./models/parameters.js\";\nimport * as Mappers from \"./models/mappers.js\";\nimport type {\n PostgreSQLManagementFlexibleServerClientOptionalParams,\n MigrationNameAvailabilityResource,\n CheckMigrationNameAvailabilityOptionalParams,\n CheckMigrationNameAvailabilityResponse,\n} from \"./models/index.js\";\n\nexport class PostgreSQLManagementFlexibleServerClient extends coreClient.ServiceClient {\n $host: string;\n subscriptionId?: string;\n apiVersion: string;\n\n /**\n * Initializes a new instance of the PostgreSQLManagementFlexibleServerClient class.\n * @param credentials Subscription credentials which uniquely identify client subscription.\n * @param subscriptionId The ID of the target subscription. The value must be an UUID.\n * @param options The parameter options\n */\n constructor(\n credentials: coreAuth.TokenCredential,\n subscriptionId: string,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n );\n constructor(\n credentials: coreAuth.TokenCredential,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n );\n constructor(\n credentials: coreAuth.TokenCredential,\n subscriptionIdOrOptions?: PostgreSQLManagementFlexibleServerClientOptionalParams | string,\n options?: PostgreSQLManagementFlexibleServerClientOptionalParams,\n ) {\n if (credentials === undefined) {\n throw new Error(\"'credentials' cannot be null\");\n }\n\n let subscriptionId: string | undefined;\n\n if (typeof subscriptionIdOrOptions === \"string\") {\n subscriptionId = subscriptionIdOrOptions;\n } else if (typeof subscriptionIdOrOptions === \"object\") {\n options = subscriptionIdOrOptions;\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: PostgreSQLManagementFlexibleServerClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n credential: credentials,\n };\n\n const packageDetails = `azsdk-js-arm-postgresql-flexible/8.1.0-beta.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix,\n },\n endpoint: options.endpoint ?? options.baseUri ?? \"https://management.azure.com\",\n };\n super(optionsWithDefaults);\n\n let bearerTokenAuthenticationPolicyFound: boolean = false;\n if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {\n const pipelinePolicies: coreRestPipeline.PipelinePolicy[] =\n options.pipeline.getOrderedPolicies();\n bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(\n (pipelinePolicy) =>\n pipelinePolicy.name === coreRestPipeline.bearerTokenAuthenticationPolicyName,\n );\n }\n if (\n !options ||\n !options.pipeline ||\n options.pipeline.getOrderedPolicies().length == 0 ||\n !bearerTokenAuthenticationPolicyFound\n ) {\n this.pipeline.removePolicy({\n name: coreRestPipeline.bearerTokenAuthenticationPolicyName,\n });\n this.pipeline.addPolicy(\n coreRestPipeline.bearerTokenAuthenticationPolicy({\n credential: credentials,\n scopes:\n optionsWithDefaults.credentialScopes ?? `${optionsWithDefaults.endpoint}/.default`,\n challengeCallbacks: {\n authorizeRequestOnChallenge: coreClient.authorizeRequestOnClaimChallenge,\n },\n }),\n );\n }\n // Parameter assignments\n this.subscriptionId = subscriptionId;\n\n // Assigning values to Constant parameters\n this.$host = options.$host || \"https://management.azure.com\";\n this.apiVersion = options.apiVersion || \"2025-01-01-preview\";\n this.administrators = new AdministratorsImpl(this);\n this.backups = new BackupsImpl(this);\n this.locationBasedCapabilities = new LocationBasedCapabilitiesImpl(this);\n this.serverCapabilities = new ServerCapabilitiesImpl(this);\n this.checkNameAvailability = new CheckNameAvailabilityImpl(this);\n this.checkNameAvailabilityWithLocation = new CheckNameAvailabilityWithLocationImpl(this);\n this.configurations = new ConfigurationsImpl(this);\n this.databases = new DatabasesImpl(this);\n this.firewallRules = new FirewallRulesImpl(this);\n this.servers = new ServersImpl(this);\n this.flexibleServer = new FlexibleServerImpl(this);\n this.ltrBackupOperations = new LtrBackupOperationsImpl(this);\n this.migrations = new MigrationsImpl(this);\n this.operations = new OperationsImpl(this);\n this.getPrivateDnsZoneSuffix = new GetPrivateDnsZoneSuffixImpl(this);\n this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this);\n this.privateEndpointConnectionOperations = new PrivateEndpointConnectionOperationsImpl(this);\n this.privateLinkResources = new PrivateLinkResourcesImpl(this);\n this.quotaUsages = new QuotaUsagesImpl(this);\n this.replicas = new ReplicasImpl(this);\n this.logFiles = new LogFilesImpl(this);\n this.serverThreatProtectionSettings = new ServerThreatProtectionSettingsImpl(this);\n this.tuningOptions = new TuningOptionsImpl(this);\n this.tuningIndex = new TuningIndexImpl(this);\n this.tuningConfiguration = new TuningConfigurationImpl(this);\n this.virtualEndpoints = new VirtualEndpointsImpl(this);\n this.virtualNetworkSubnetUsage = new VirtualNetworkSubnetUsageImpl(this);\n this.addCustomApiVersionPolicy(options.apiVersion);\n }\n\n /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */\n private addCustomApiVersionPolicy(apiVersion?: string) {\n if (!apiVersion) {\n return;\n }\n const apiVersionPolicy = {\n name: \"CustomApiVersionPolicy\",\n async sendRequest(request: PipelineRequest, next: SendRequest): Promise<PipelineResponse> {\n const param = request.url.split(\"?\");\n if (param.length > 1) {\n const newParams = param[1].split(\"&\").map((item) => {\n if (item.indexOf(\"api-version\") > -1) {\n return \"api-version=\" + apiVersion;\n } else {\n return item;\n }\n });\n request.url = param[0] + \"?\" + newParams.join(\"&\");\n }\n return next(request);\n },\n };\n this.pipeline.addPolicy(apiVersionPolicy);\n }\n\n /**\n * This method checks whether a proposed migration name is valid and available.\n * @param subscriptionId The subscription ID of the target database server.\n * @param resourceGroupName The resource group name of the target database server.\n * @param targetDbServerName The name of the target database server.\n * @param parameters The required parameters for checking if a migration name is available.\n * @param options The options parameters.\n */\n checkMigrationNameAvailability(\n subscriptionId: string,\n resourceGroupName: string,\n targetDbServerName: string,\n parameters: MigrationNameAvailabilityResource,\n options?: CheckMigrationNameAvailabilityOptionalParams,\n ): Promise<CheckMigrationNameAvailabilityResponse> {\n return this.sendOperationRequest(\n {\n subscriptionId,\n resourceGroupName,\n targetDbServerName,\n parameters,\n options,\n },\n checkMigrationNameAvailabilityOperationSpec,\n );\n }\n\n administrators: Administrators;\n backups: Backups;\n locationBasedCapabilities: LocationBasedCapabilities;\n serverCapabilities: ServerCapabilities;\n checkNameAvailability: CheckNameAvailability;\n checkNameAvailabilityWithLocation: CheckNameAvailabilityWithLocation;\n configurations: Configurations;\n databases: Databases;\n firewallRules: FirewallRules;\n servers: Servers;\n flexibleServer: FlexibleServer;\n ltrBackupOperations: LtrBackupOperations;\n migrations: Migrations;\n operations: Operations;\n getPrivateDnsZoneSuffix: GetPrivateDnsZoneSuffix;\n privateEndpointConnections: PrivateEndpointConnections;\n privateEndpointConnectionOperations: PrivateEndpointConnectionOperations;\n privateLinkResources: PrivateLinkResources;\n quotaUsages: QuotaUsages;\n replicas: Replicas;\n logFiles: LogFiles;\n serverThreatProtectionSettings: ServerThreatProtectionSettings;\n tuningOptions: TuningOptions;\n tuningIndex: TuningIndex;\n tuningConfiguration: TuningConfiguration;\n virtualEndpoints: VirtualEndpoints;\n virtualNetworkSubnetUsage: VirtualNetworkSubnetUsage;\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst checkMigrationNameAvailabilityOperationSpec: coreClient.OperationSpec = {\n path: \"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/flexibleServers/{targetDbServerName}/checkMigrationNameAvailability\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.MigrationNameAvailabilityResource,\n },\n default: {\n bodyMapper: Mappers.ErrorResponse,\n },\n },\n requestBody: Parameters.parameters12,\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId1,\n Parameters.resourceGroupName1,\n Parameters.targetDbServerName,\n ],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\n"]}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
// This file is read by tools that parse documentation comments conforming to the TSDoc standard.
|
|
2
|
-
// It should be published with your NPM package. It should not be tracked by Git.
|
|
3
|
-
{
|
|
4
|
-
"tsdocVersion": "0.12",
|
|
5
|
-
"toolPackages": [
|
|
6
|
-
{
|
|
7
|
-
"packageName": "@microsoft/api-extractor",
|
|
8
|
-
"packageVersion": "7.52.8"
|
|
9
|
-
}
|
|
10
|
-
]
|
|
11
|
-
}
|
|
1
|
+
// This file is read by tools that parse documentation comments conforming to the TSDoc standard.
|
|
2
|
+
// It should be published with your NPM package. It should not be tracked by Git.
|
|
3
|
+
{
|
|
4
|
+
"tsdocVersion": "0.12",
|
|
5
|
+
"toolPackages": [
|
|
6
|
+
{
|
|
7
|
+
"packageName": "@microsoft/api-extractor",
|
|
8
|
+
"packageVersion": "7.52.8"
|
|
9
|
+
}
|
|
10
|
+
]
|
|
11
|
+
}
|
package/dist/esm/lroImpl.js
CHANGED
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
|
-
import { __rest } from "tslib";
|
|
9
8
|
export function createLroSpec(inputs) {
|
|
10
9
|
const { args, spec, sendOperationFn } = inputs;
|
|
11
10
|
return {
|
|
@@ -13,8 +12,13 @@ export function createLroSpec(inputs) {
|
|
|
13
12
|
requestPath: spec.path,
|
|
14
13
|
sendInitialRequest: () => sendOperationFn(args, spec),
|
|
15
14
|
sendPollRequest: (path, options) => {
|
|
16
|
-
const { requestBody
|
|
17
|
-
return sendOperationFn(args,
|
|
15
|
+
const { requestBody, ...restSpec } = spec;
|
|
16
|
+
return sendOperationFn(args, {
|
|
17
|
+
...restSpec,
|
|
18
|
+
httpMethod: "GET",
|
|
19
|
+
path,
|
|
20
|
+
abortSignal: options?.abortSignal,
|
|
21
|
+
});
|
|
18
22
|
},
|
|
19
23
|
};
|
|
20
24
|
}
|
package/dist/esm/lroImpl.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lroImpl.js","sourceRoot":"","sources":["../../src/lroImpl.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG
|
|
1
|
+
{"version":3,"file":"lroImpl.js","sourceRoot":"","sources":["../../src/lroImpl.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,MAAM,UAAU,aAAa,CAAI,MAQhC;IACC,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,eAAe,EAAE,GAAG,MAAM,CAAC;IAC/C,OAAO;QACL,aAAa,EAAE,IAAI,CAAC,UAAU;QAC9B,WAAW,EAAE,IAAI,CAAC,IAAK;QACvB,kBAAkB,EAAE,GAAG,EAAE,CAAC,eAAe,CAAC,IAAI,EAAE,IAAI,CAAC;QACrD,eAAe,EAAE,CAAC,IAAY,EAAE,OAA2C,EAAE,EAAE;YAC7E,MAAM,EAAE,WAAW,EAAE,GAAG,QAAQ,EAAE,GAAG,IAAI,CAAC;YAC1C,OAAO,eAAe,CAAC,IAAI,EAAE;gBAC3B,GAAG,QAAQ;gBACX,UAAU,EAAE,KAAK;gBACjB,IAAI;gBACJ,WAAW,EAAE,OAAO,EAAE,WAAW;aAClC,CAAC,CAAC;QACL,CAAC;KACF,CAAC;AACJ,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport type { AbortSignalLike } from \"@azure/abort-controller\";\nimport type { LongRunningOperation, LroResponse } from \"@azure/core-lro\";\n\nexport function createLroSpec<T>(inputs: {\n sendOperationFn: (args: any, spec: any) => Promise<LroResponse<T>>;\n args: Record<string, unknown>;\n spec: {\n readonly requestBody?: unknown;\n readonly path?: string;\n readonly httpMethod: string;\n } & Record<string, any>;\n}): LongRunningOperation<T> {\n const { args, spec, sendOperationFn } = inputs;\n return {\n requestMethod: spec.httpMethod,\n requestPath: spec.path!,\n sendInitialRequest: () => sendOperationFn(args, spec),\n sendPollRequest: (path: string, options?: { abortSignal?: AbortSignalLike }) => {\n const { requestBody, ...restSpec } = spec;\n return sendOperationFn(args, {\n ...restSpec,\n httpMethod: \"GET\",\n path,\n abortSignal: options?.abortSignal,\n });\n },\n };\n}\n"]}
|