Skip to content

Commit 61e6c8c

Browse files
author
SDKAuto
committed
CodeGen from PR 15432 in Azure/azure-rest-api-specs
Merge 09aaa19d69803606784bbd0b630773800f7dcb6b into 1267076f6a49f9eea0860e70e79f523d1085ed14
1 parent 33602ff commit 61e6c8c

29 files changed

+4879
-1744
lines changed

sdk/machinelearningservices/arm-machinelearningservices/LICENSE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2020 Microsoft
3+
Copyright (c) 2021 Microsoft
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

sdk/machinelearningservices/arm-machinelearningservices/README.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
## Azure AzureMachineLearningWorkspaces SDK for JavaScript
22

3-
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for AzureMachineLearningWorkspaces.
3+
This package contains an isomorphic SDK (runs both in node.js and in browsers) for AzureMachineLearningWorkspaces.
44

55
### Currently supported environments
66

77
- [LTS versions of Node.js](https://nodejs.org/about/releases/)
8-
- Latest versions of Safari, Chrome, Edge, and Firefox.
8+
- Latest versions of Safari, Chrome, Edge and Firefox.
99

1010
### Prerequisites
1111

@@ -21,7 +21,6 @@ Install both packages using the below command:
2121
```bash
2222
npm install --save @azure/arm-machinelearningservices @azure/identity
2323
```
24-
2524
> **Note**: You may have used either `@azure/ms-rest-nodeauth` or `@azure/ms-rest-browserauth` in the past. These packages are in maintenance mode receiving critical bug fixes, but no new features.
2625
If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/), or are writing a client side browser application, we strongly encourage you to upgrade to `@azure/identity` which uses the latest versions of Azure Active Directory and MSAL APIs and provides more authentication options.
2726

@@ -37,7 +36,6 @@ If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/
3736

3837
In the below samples, we pass the credential and the Azure subscription id to instantiate the client.
3938
Once the client is created, explore the operations on it either in your favorite editor or in our [API reference documentation](https://docs.microsoft.com/javascript/api) to get started.
40-
4139
#### nodejs - Authentication, client creation, and list operations as an example written in JavaScript.
4240

4341
##### Sample code
@@ -51,7 +49,6 @@ const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];
5149
// Please note that you can also use credentials from the `@azure/ms-rest-nodeauth` package instead.
5250
const creds = new DefaultAzureCredential();
5351
const client = new AzureMachineLearningWorkspaces(creds, subscriptionId);
54-
5552
client.operations.list().then((result) => {
5653
console.log("The result is:");
5754
console.log(result);
@@ -86,7 +83,7 @@ In browser applications, we recommend using the `InteractiveBrowserCredential` t
8683
const credential = new InteractiveBrowserCredential(
8784
{
8885
clientId: "<client id for your Azure AD app>",
89-
tenantId: "<optional tenant for your organization>"
86+
tenant: "<optional tenant for your organization>"
9087
});
9188
const client = new Azure.ArmMachinelearningservices.AzureMachineLearningWorkspaces(creds, subscriptionId);
9289
client.operations.list().then((result) => {

sdk/machinelearningservices/arm-machinelearningservices/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"rollup-plugin-sourcemaps": "^0.4.2",
2828
"uglify-js": "^3.6.0"
2929
},
30-
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/machinelearningservices/arm-machinelearningservices",
30+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/machinelearningservices/arm-machinelearningservices",
3131
"repository": {
3232
"type": "git",
3333
"url": "https://github.com/Azure/azure-sdk-for-js.git"

sdk/machinelearningservices/arm-machinelearningservices/src/azureMachineLearningWorkspaces.ts

Lines changed: 9 additions & 109 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import * as msRest from "@azure/ms-rest-js";
1111
import { TokenCredential } from "@azure/core-auth";
1212
import * as Models from "./models";
1313
import * as Mappers from "./models/mappers";
14-
import * as Parameters from "./models/parameters";
1514
import * as operations from "./operations";
1615
import { AzureMachineLearningWorkspacesContext } from "./azureMachineLearningWorkspacesContext";
1716

@@ -20,15 +19,15 @@ class AzureMachineLearningWorkspaces extends AzureMachineLearningWorkspacesConte
2019
// Operation groups
2120
operations: operations.Operations;
2221
workspaces: operations.Workspaces;
23-
workspaceFeatures: operations.WorkspaceFeatures;
24-
notebooks: operations.Notebooks;
2522
usages: operations.Usages;
2623
virtualMachineSizes: operations.VirtualMachineSizes;
2724
quotas: operations.Quotas;
28-
workspaceConnections: operations.WorkspaceConnections;
29-
machineLearningCompute: operations.MachineLearningCompute;
25+
compute: operations.ComputeOperations;
3026
privateEndpointConnections: operations.PrivateEndpointConnections;
3127
privateLinkResources: operations.PrivateLinkResources;
28+
workspaceConnections: operations.WorkspaceConnections;
29+
workspaceFeatures: operations.WorkspaceFeatures;
30+
workspaceSkus: operations.WorkspaceSkus;
3231

3332
/**
3433
* Initializes a new instance of the AzureMachineLearningWorkspaces class.
@@ -38,125 +37,26 @@ class AzureMachineLearningWorkspaces extends AzureMachineLearningWorkspacesConte
3837
* {@link https://www.npmjs.com/package/@azure/identity}. Credentials implementing the
3938
* ServiceClientCredentials interface from the older packages @azure/ms-rest-nodeauth and
4039
* @azure/ms-rest-browserauth are also supported.
41-
* @param subscriptionId Azure subscription identifier.
40+
* @param subscriptionId The ID of the target subscription.
4241
* @param [options] The parameter options
4342
*/
4443
constructor(credentials: msRest.ServiceClientCredentials | TokenCredential, subscriptionId: string, options?: Models.AzureMachineLearningWorkspacesOptions) {
4544
super(credentials, subscriptionId, options);
4645
this.operations = new operations.Operations(this);
4746
this.workspaces = new operations.Workspaces(this);
48-
this.workspaceFeatures = new operations.WorkspaceFeatures(this);
49-
this.notebooks = new operations.Notebooks(this);
5047
this.usages = new operations.Usages(this);
5148
this.virtualMachineSizes = new operations.VirtualMachineSizes(this);
5249
this.quotas = new operations.Quotas(this);
53-
this.workspaceConnections = new operations.WorkspaceConnections(this);
54-
this.machineLearningCompute = new operations.MachineLearningCompute(this);
50+
this.compute = new operations.ComputeOperations(this);
5551
this.privateEndpointConnections = new operations.PrivateEndpointConnections(this);
5652
this.privateLinkResources = new operations.PrivateLinkResources(this);
57-
}
58-
59-
/**
60-
* Lists all skus with associated features
61-
* @param [options] The optional parameters
62-
* @returns Promise<Models.ListSkusResponse>
63-
*/
64-
listSkus(options?: msRest.RequestOptionsBase): Promise<Models.ListSkusResponse>;
65-
/**
66-
* @param callback The callback
67-
*/
68-
listSkus(callback: msRest.ServiceCallback<Models.SkuListResult>): void;
69-
/**
70-
* @param options The optional parameters
71-
* @param callback The callback
72-
*/
73-
listSkus(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
74-
listSkus(options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SkuListResult>, callback?: msRest.ServiceCallback<Models.SkuListResult>): Promise<Models.ListSkusResponse> {
75-
return this.sendOperationRequest(
76-
{
77-
options
78-
},
79-
listSkusOperationSpec,
80-
callback) as Promise<Models.ListSkusResponse>;
81-
}
82-
83-
/**
84-
* Lists all skus with associated features
85-
* @param nextPageLink The NextLink from the previous successful call to List operation.
86-
* @param [options] The optional parameters
87-
* @returns Promise<Models.ListSkusNextResponse>
88-
*/
89-
listSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.ListSkusNextResponse>;
90-
/**
91-
* @param nextPageLink The NextLink from the previous successful call to List operation.
92-
* @param callback The callback
93-
*/
94-
listSkusNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
95-
/**
96-
* @param nextPageLink The NextLink from the previous successful call to List operation.
97-
* @param options The optional parameters
98-
* @param callback The callback
99-
*/
100-
listSkusNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
101-
listSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SkuListResult>, callback?: msRest.ServiceCallback<Models.SkuListResult>): Promise<Models.ListSkusNextResponse> {
102-
return this.sendOperationRequest(
103-
{
104-
nextPageLink,
105-
options
106-
},
107-
listSkusNextOperationSpec,
108-
callback) as Promise<Models.ListSkusNextResponse>;
53+
this.workspaceConnections = new operations.WorkspaceConnections(this);
54+
this.workspaceFeatures = new operations.WorkspaceFeatures(this);
55+
this.workspaceSkus = new operations.WorkspaceSkus(this);
10956
}
11057
}
11158

11259
// Operation Specifications
113-
const serializer = new msRest.Serializer(Mappers);
114-
const listSkusOperationSpec: msRest.OperationSpec = {
115-
httpMethod: "GET",
116-
path: "subscriptions/{subscriptionId}/providers/Microsoft.MachineLearningServices/workspaces/skus",
117-
urlParameters: [
118-
Parameters.subscriptionId
119-
],
120-
queryParameters: [
121-
Parameters.apiVersion
122-
],
123-
headerParameters: [
124-
Parameters.acceptLanguage
125-
],
126-
responses: {
127-
200: {
128-
bodyMapper: Mappers.SkuListResult
129-
},
130-
default: {
131-
bodyMapper: Mappers.MachineLearningServiceError
132-
}
133-
},
134-
serializer
135-
};
136-
137-
const listSkusNextOperationSpec: msRest.OperationSpec = {
138-
httpMethod: "GET",
139-
baseUrl: "https://management.azure.com",
140-
path: "{nextLink}",
141-
urlParameters: [
142-
Parameters.nextPageLink
143-
],
144-
queryParameters: [
145-
Parameters.apiVersion
146-
],
147-
headerParameters: [
148-
Parameters.acceptLanguage
149-
],
150-
responses: {
151-
200: {
152-
bodyMapper: Mappers.SkuListResult
153-
},
154-
default: {
155-
bodyMapper: Mappers.MachineLearningServiceError
156-
}
157-
},
158-
serializer
159-
};
16060

16161
export {
16262
AzureMachineLearningWorkspaces,

sdk/machinelearningservices/arm-machinelearningservices/src/azureMachineLearningWorkspacesContext.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,16 @@
99

1010
import * as Models from "./models";
1111
import * as msRest from "@azure/ms-rest-js";
12-
import { TokenCredential } from "@azure/core-auth";
1312
import * as msRestAzure from "@azure/ms-rest-azure-js";
13+
import { TokenCredential } from "@azure/core-auth";
1414

1515
const packageName = "@azure/arm-machinelearningservices";
1616
const packageVersion = "4.1.0";
1717

1818
export class AzureMachineLearningWorkspacesContext extends msRestAzure.AzureServiceClient {
1919
credentials: msRest.ServiceClientCredentials | TokenCredential;
20-
subscriptionId: string;
2120
apiVersion?: string;
21+
subscriptionId: string;
2222

2323
/**
2424
* Initializes a new instance of the AzureMachineLearningWorkspaces class.
@@ -28,7 +28,7 @@ export class AzureMachineLearningWorkspacesContext extends msRestAzure.AzureServ
2828
* {@link https://www.npmjs.com/package/@azure/identity}. Credentials implementing the
2929
* ServiceClientCredentials interface from the older packages @azure/ms-rest-nodeauth and
3030
* @azure/ms-rest-browserauth are also supported.
31-
* @param subscriptionId Azure subscription identifier.
31+
* @param subscriptionId The ID of the target subscription.
3232
* @param [options] The parameter options
3333
*/
3434
constructor(credentials: msRest.ServiceClientCredentials | TokenCredential, subscriptionId: string, options?: Models.AzureMachineLearningWorkspacesOptions) {
@@ -42,25 +42,25 @@ export class AzureMachineLearningWorkspacesContext extends msRestAzure.AzureServ
4242
if (!options) {
4343
options = {};
4444
}
45-
if(!options.userAgent) {
45+
if (!options.userAgent) {
4646
const defaultUserAgent = msRestAzure.getDefaultUserAgentValue();
4747
options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
4848
}
4949

5050
super(credentials, options);
5151

52-
this.apiVersion = '2020-08-01';
52+
this.apiVersion = '2021-07-01';
5353
this.acceptLanguage = 'en-US';
5454
this.longRunningOperationRetryTimeout = 30;
5555
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
5656
this.requestContentType = "application/json; charset=utf-8";
5757
this.credentials = credentials;
5858
this.subscriptionId = subscriptionId;
5959

60-
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
60+
if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
6161
this.acceptLanguage = options.acceptLanguage;
6262
}
63-
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
63+
if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
6464
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout;
6565
}
6666
}
Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,60 +9,75 @@
99
export {
1010
discriminators,
1111
AKS,
12-
AksComputeSecrets,
1312
AksNetworkingConfiguration,
1413
AKSProperties,
1514
AmlCompute,
1615
AmlComputeNodeInformation,
1716
AmlComputeNodesInformation,
1817
AmlComputeProperties,
18+
AssignedUser,
19+
AutoPauseProperties,
20+
AutoScaleProperties,
21+
AzureEntityResource,
1922
BaseResource,
2023
ClusterUpdateParameters,
2124
Compute,
25+
ComputeCreateOrUpdateHeaders,
26+
ComputeDeleteHeaders,
2227
ComputeInstance,
2328
ComputeInstanceApplication,
2429
ComputeInstanceConnectivityEndpoints,
2530
ComputeInstanceCreatedBy,
2631
ComputeInstanceLastOperation,
2732
ComputeInstanceProperties,
2833
ComputeInstanceSshSettings,
29-
ComputeNodesInformation,
3034
ComputeResource,
3135
ComputeSecrets,
36+
CosmosDbSettings,
3237
Databricks,
33-
DatabricksComputeSecrets,
3438
DatabricksProperties,
3539
DataFactory,
3640
DataLakeAnalytics,
3741
DataLakeAnalyticsProperties,
3842
EncryptionProperty,
43+
ErrorAdditionalInfo,
3944
ErrorDetail,
4045
ErrorResponse,
4146
HDInsight,
4247
HDInsightProperties,
4348
Identity,
44-
IdentityUserAssignedIdentitiesValue,
49+
IdentityForCmk,
4550
KeyVaultProperties,
46-
MachineLearningComputeCreateOrUpdateHeaders,
47-
MachineLearningComputeDeleteHeaders,
48-
MachineLearningServiceError,
4951
NodeStateCounts,
5052
NotebookPreparationError,
5153
NotebookResourceInfo,
5254
PaginatedComputeResourcesList,
55+
PersonalComputeInstanceSettings,
5356
PrivateEndpoint,
5457
PrivateEndpointConnection,
5558
PrivateLinkResource,
5659
PrivateLinkServiceConnectionState,
60+
ProxyResource,
5761
Resource,
5862
ResourceId,
5963
ScaleSettings,
64+
ScaleSettingsInformation,
65+
ScriptReference,
66+
ScriptsToExecute,
67+
ServiceManagedResourcesSettings,
68+
SetupScripts,
6069
SharedPrivateLinkResource,
6170
Sku,
6271
SslConfiguration,
72+
SynapseSpark,
73+
SynapseSparkProperties,
74+
SystemData,
6375
SystemService,
76+
TrackedResource,
6477
UserAccountCredentials,
78+
UserAssignedIdentity,
6579
VirtualMachine,
80+
VirtualMachineImage,
6681
VirtualMachineProperties,
6782
VirtualMachineSecrets,
6883
VirtualMachineSshCredentials,

0 commit comments

Comments
 (0)