@azure/arm-hdinsight 0.22.0 → 1.1.0
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/CHANGELOG.md +5 -0
- package/{LICENSE.txt → LICENSE} +1 -1
- package/README.md +70 -74
- package/dist/index.js +7702 -0
- package/dist/index.js.map +1 -0
- package/dist/index.min.js +1 -0
- package/dist/index.min.js.map +1 -0
- package/dist-esm/src/hDInsightManagementClient.d.ts +29 -0
- package/dist-esm/src/hDInsightManagementClient.d.ts.map +1 -0
- package/dist-esm/src/hDInsightManagementClient.js +62 -0
- package/dist-esm/src/hDInsightManagementClient.js.map +1 -0
- package/dist-esm/src/index.d.ts +5 -0
- package/dist-esm/src/index.d.ts.map +1 -0
- package/{esm/models/configurationsMappers.js → dist-esm/src/index.js} +5 -2
- package/dist-esm/src/index.js.map +1 -0
- package/dist-esm/src/lroImpl.d.ts +16 -0
- package/dist-esm/src/lroImpl.d.ts.map +1 -0
- package/dist-esm/src/lroImpl.js +29 -0
- package/dist-esm/src/lroImpl.js.map +1 -0
- package/dist-esm/src/models/index.d.ts +1966 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +133 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +111 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/mappers.js +1813 -1305
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +37 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/dist-esm/src/models/parameters.js +280 -0
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/dist-esm/src/operations/applications.d.ts +90 -0
- package/dist-esm/src/operations/applications.d.ts.map +1 -0
- package/dist-esm/src/operations/applications.js +367 -0
- package/dist-esm/src/operations/applications.js.map +1 -0
- package/dist-esm/src/operations/clusters.d.ts +214 -0
- package/dist-esm/src/operations/clusters.d.ts.map +1 -0
- package/dist-esm/src/operations/clusters.js +979 -0
- package/dist-esm/src/operations/clusters.js.map +1 -0
- package/dist-esm/src/operations/configurations.d.ts +54 -0
- package/dist-esm/src/operations/configurations.d.ts.map +1 -0
- package/dist-esm/src/operations/configurations.js +178 -0
- package/dist-esm/src/operations/configurations.js.map +1 -0
- package/dist-esm/src/operations/extensions.d.ts +139 -0
- package/dist-esm/src/operations/extensions.d.ts.map +1 -0
- package/dist-esm/src/operations/extensions.js +602 -0
- package/dist-esm/src/operations/extensions.js.map +1 -0
- package/{esm → dist-esm/src}/operations/index.d.ts +2 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/dist-esm/src/operations/index.js +19 -0
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/locations.d.ts +52 -0
- package/dist-esm/src/operations/locations.d.ts.map +1 -0
- package/dist-esm/src/operations/locations.js +199 -0
- package/dist-esm/src/operations/locations.js.map +1 -0
- package/dist-esm/src/operations/operations.d.ts +32 -0
- package/dist-esm/src/operations/operations.d.ts.map +1 -0
- package/dist-esm/src/operations/operations.js +120 -0
- package/dist-esm/src/operations/operations.js.map +1 -0
- package/dist-esm/src/operations/privateEndpointConnections.d.ts +81 -0
- package/dist-esm/src/operations/privateEndpointConnections.d.ts.map +1 -0
- package/dist-esm/src/operations/privateEndpointConnections.js +349 -0
- package/dist-esm/src/operations/privateEndpointConnections.js.map +1 -0
- package/dist-esm/src/operations/privateLinkResources.d.ts +28 -0
- package/dist-esm/src/operations/privateLinkResources.d.ts.map +1 -0
- package/dist-esm/src/operations/privateLinkResources.js +85 -0
- package/dist-esm/src/operations/privateLinkResources.js.map +1 -0
- package/dist-esm/src/operations/scriptActions.d.ts +62 -0
- package/dist-esm/src/operations/scriptActions.d.ts.map +1 -0
- package/dist-esm/src/operations/scriptActions.js +232 -0
- package/dist-esm/src/operations/scriptActions.js.map +1 -0
- package/dist-esm/src/operations/scriptExecutionHistory.d.ts +46 -0
- package/dist-esm/src/operations/scriptExecutionHistory.d.ts.map +1 -0
- package/dist-esm/src/operations/scriptExecutionHistory.js +167 -0
- package/dist-esm/src/operations/scriptExecutionHistory.js.map +1 -0
- package/dist-esm/src/operations/virtualMachines.d.ts +45 -0
- package/dist-esm/src/operations/virtualMachines.d.ts.map +1 -0
- package/dist-esm/src/operations/virtualMachines.js +169 -0
- package/dist-esm/src/operations/virtualMachines.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/applications.d.ts +65 -0
- package/dist-esm/src/operationsInterfaces/applications.d.ts.map +1 -0
- package/{src/models/virtualMachinesMappers.ts → dist-esm/src/operationsInterfaces/applications.js} +2 -5
- package/dist-esm/src/operationsInterfaces/applications.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/clusters.d.ts +178 -0
- package/dist-esm/src/operationsInterfaces/clusters.d.ts.map +1 -0
- package/{esm/models/index.js → dist-esm/src/operationsInterfaces/clusters.js} +2 -1
- package/dist-esm/src/operationsInterfaces/clusters.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/configurations.d.ts +46 -0
- package/dist-esm/src/operationsInterfaces/configurations.d.ts.map +1 -0
- package/{src/models/configurationsMappers.ts → dist-esm/src/operationsInterfaces/configurations.js} +2 -5
- package/dist-esm/src/operationsInterfaces/configurations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/extensions.d.ts +131 -0
- package/dist-esm/src/operationsInterfaces/extensions.d.ts.map +1 -0
- package/{esm/models/virtualMachinesMappers.js → dist-esm/src/operationsInterfaces/extensions.js} +2 -2
- package/dist-esm/src/operationsInterfaces/extensions.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts +12 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +19 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/locations.d.ts +44 -0
- package/dist-esm/src/operationsInterfaces/locations.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/locations.js +9 -0
- package/dist-esm/src/operationsInterfaces/locations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.js +9 -0
- package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts +56 -0
- package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js +9 -0
- package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateLinkResources.d.ts +20 -0
- package/dist-esm/src/operationsInterfaces/privateLinkResources.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateLinkResources.js +9 -0
- package/dist-esm/src/operationsInterfaces/privateLinkResources.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/scriptActions.d.ts +37 -0
- package/dist-esm/src/operationsInterfaces/scriptActions.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/scriptActions.js +9 -0
- package/dist-esm/src/operationsInterfaces/scriptActions.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/scriptExecutionHistory.d.ts +21 -0
- package/dist-esm/src/operationsInterfaces/scriptExecutionHistory.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/scriptExecutionHistory.js +9 -0
- package/dist-esm/src/operationsInterfaces/scriptExecutionHistory.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.d.ts +37 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.js +9 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.js.map +1 -0
- package/dist-esm/test/sampleTest.d.ts +2 -0
- package/dist-esm/test/sampleTest.d.ts.map +1 -0
- package/dist-esm/test/sampleTest.js +40 -0
- package/dist-esm/test/sampleTest.js.map +1 -0
- package/package.json +65 -31
- package/review/arm-hdinsight.api.md +1678 -0
- package/rollup.config.js +181 -30
- package/src/hDInsightManagementClient.ts +106 -44
- package/src/{models/extensionsMappers.ts → index.ts} +4 -6
- package/src/lroImpl.ts +34 -0
- package/src/models/index.ts +1760 -2084
- package/src/models/mappers.ts +1840 -1291
- package/src/models/parameters.ts +236 -44
- package/src/operations/applications.ts +383 -187
- package/src/operations/clusters.ts +1051 -535
- package/src/operations/configurations.ts +162 -154
- package/src/operations/extensions.ts +693 -216
- package/src/operations/index.ts +3 -2
- package/src/operations/locations.ts +186 -99
- package/src/operations/operations.ts +85 -73
- package/src/operations/privateEndpointConnections.ts +495 -0
- package/src/operations/privateLinkResources.ts +116 -0
- package/src/operations/scriptActions.ts +215 -157
- package/src/operations/scriptExecutionHistory.ts +155 -123
- package/src/operations/virtualMachines.ts +166 -101
- package/src/operationsInterfaces/applications.ts +126 -0
- package/src/operationsInterfaces/clusters.ts +327 -0
- package/src/operationsInterfaces/configurations.ts +77 -0
- package/src/operationsInterfaces/extensions.ts +234 -0
- package/{esm/operations/index.js → src/operationsInterfaces/index.ts} +4 -3
- package/src/operationsInterfaces/locations.ts +88 -0
- package/src/operationsInterfaces/operations.ts +22 -0
- package/src/operationsInterfaces/privateEndpointConnections.ts +109 -0
- package/src/operationsInterfaces/privateLinkResources.ts +42 -0
- package/src/operationsInterfaces/scriptActions.ts +73 -0
- package/src/operationsInterfaces/scriptExecutionHistory.ts +43 -0
- package/src/operationsInterfaces/virtualMachines.ts +70 -0
- package/tsconfig.json +3 -3
- package/types/arm-hdinsight.d.ts +2866 -0
- package/types/tsdoc-metadata.json +11 -0
- package/dist/arm-hdinsight.js +0 -5759
- package/dist/arm-hdinsight.js.map +0 -1
- package/dist/arm-hdinsight.min.js +0 -1
- package/dist/arm-hdinsight.min.js.map +0 -1
- package/esm/hDInsightManagementClient.d.ts +0 -27
- package/esm/hDInsightManagementClient.d.ts.map +0 -1
- package/esm/hDInsightManagementClient.js +0 -41
- package/esm/hDInsightManagementClient.js.map +0 -1
- package/esm/hDInsightManagementClientContext.d.ts +0 -17
- package/esm/hDInsightManagementClientContext.d.ts.map +0 -1
- package/esm/hDInsightManagementClientContext.js +0 -56
- package/esm/hDInsightManagementClientContext.js.map +0 -1
- package/esm/models/applicationsMappers.d.ts +0 -2
- package/esm/models/applicationsMappers.d.ts.map +0 -1
- package/esm/models/applicationsMappers.js +0 -9
- package/esm/models/applicationsMappers.js.map +0 -1
- package/esm/models/clustersMappers.d.ts +0 -2
- package/esm/models/clustersMappers.d.ts.map +0 -1
- package/esm/models/clustersMappers.js +0 -9
- package/esm/models/clustersMappers.js.map +0 -1
- package/esm/models/configurationsMappers.d.ts +0 -2
- package/esm/models/configurationsMappers.d.ts.map +0 -1
- package/esm/models/configurationsMappers.js.map +0 -1
- package/esm/models/extensionsMappers.d.ts +0 -2
- package/esm/models/extensionsMappers.d.ts.map +0 -1
- package/esm/models/extensionsMappers.js +0 -9
- package/esm/models/extensionsMappers.js.map +0 -1
- package/esm/models/index.d.ts +0 -2397
- package/esm/models/index.d.ts.map +0 -1
- package/esm/models/index.js.map +0 -1
- package/esm/models/locationsMappers.d.ts +0 -2
- package/esm/models/locationsMappers.d.ts.map +0 -1
- package/esm/models/locationsMappers.js +0 -9
- package/esm/models/locationsMappers.js.map +0 -1
- package/esm/models/mappers.d.ts +0 -94
- package/esm/models/mappers.d.ts.map +0 -1
- package/esm/models/mappers.js.map +0 -1
- package/esm/models/operationsMappers.d.ts +0 -2
- package/esm/models/operationsMappers.d.ts.map +0 -1
- package/esm/models/operationsMappers.js +0 -9
- package/esm/models/operationsMappers.js.map +0 -1
- package/esm/models/parameters.d.ts +0 -15
- package/esm/models/parameters.d.ts.map +0 -1
- package/esm/models/parameters.js +0 -142
- package/esm/models/parameters.js.map +0 -1
- package/esm/models/scriptActionsMappers.d.ts +0 -2
- package/esm/models/scriptActionsMappers.d.ts.map +0 -1
- package/esm/models/scriptActionsMappers.js +0 -9
- package/esm/models/scriptActionsMappers.js.map +0 -1
- package/esm/models/scriptExecutionHistoryMappers.d.ts +0 -2
- package/esm/models/scriptExecutionHistoryMappers.d.ts.map +0 -1
- package/esm/models/scriptExecutionHistoryMappers.js +0 -9
- package/esm/models/scriptExecutionHistoryMappers.js.map +0 -1
- package/esm/models/virtualMachinesMappers.d.ts +0 -2
- package/esm/models/virtualMachinesMappers.d.ts.map +0 -1
- package/esm/models/virtualMachinesMappers.js.map +0 -1
- package/esm/operations/applications.d.ts +0 -115
- package/esm/operations/applications.d.ts.map +0 -1
- package/esm/operations/applications.js +0 -233
- package/esm/operations/applications.js.map +0 -1
- package/esm/operations/clusters.d.ts +0 -273
- package/esm/operations/clusters.d.ts.map +0 -1
- package/esm/operations/clusters.js +0 -621
- package/esm/operations/clusters.js.map +0 -1
- package/esm/operations/configurations.d.ts +0 -90
- package/esm/operations/configurations.d.ts.map +0 -1
- package/esm/operations/configurations.js +0 -173
- package/esm/operations/configurations.js.map +0 -1
- package/esm/operations/extensions.d.ts +0 -131
- package/esm/operations/extensions.d.ts.map +0 -1
- package/esm/operations/extensions.js +0 -307
- package/esm/operations/extensions.js.map +0 -1
- package/esm/operations/index.d.ts.map +0 -1
- package/esm/operations/index.js.map +0 -1
- package/esm/operations/locations.d.ts +0 -67
- package/esm/operations/locations.d.ts.map +0 -1
- package/esm/operations/locations.js +0 -113
- package/esm/operations/locations.js.map +0 -1
- package/esm/operations/operations.d.ts +0 -46
- package/esm/operations/operations.d.ts.map +0 -1
- package/esm/operations/operations.js +0 -79
- package/esm/operations/operations.js.map +0 -1
- package/esm/operations/scriptActions.d.ts +0 -100
- package/esm/operations/scriptActions.d.ts.map +0 -1
- package/esm/operations/scriptActions.js +0 -151
- package/esm/operations/scriptActions.js.map +0 -1
- package/esm/operations/scriptExecutionHistory.d.ts +0 -76
- package/esm/operations/scriptExecutionHistory.d.ts.map +0 -1
- package/esm/operations/scriptExecutionHistory.js +0 -117
- package/esm/operations/scriptExecutionHistory.js.map +0 -1
- package/esm/operations/virtualMachines.d.ts +0 -53
- package/esm/operations/virtualMachines.d.ts.map +0 -1
- package/esm/operations/virtualMachines.js +0 -134
- package/esm/operations/virtualMachines.js.map +0 -1
- package/src/hDInsightManagementClientContext.ts +0 -62
- package/src/models/applicationsMappers.ts +0 -56
- package/src/models/clustersMappers.ts +0 -65
- package/src/models/locationsMappers.ts +0 -28
- package/src/models/operationsMappers.ts +0 -18
- package/src/models/scriptActionsMappers.ts +0 -15
- package/src/models/scriptExecutionHistoryMappers.ts +0 -15
package/CHANGELOG.md
ADDED
package/{LICENSE.txt → LICENSE}
RENAMED
|
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
18
18
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
19
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
20
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,102 +1,98 @@
|
|
|
1
|
-
|
|
1
|
+
# Azure HDInsightManagement client library for JavaScript
|
|
2
2
|
|
|
3
|
-
This package contains an isomorphic SDK for
|
|
3
|
+
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure HDInsightManagement client.
|
|
4
|
+
|
|
5
|
+
HDInsight Management Client
|
|
6
|
+
|
|
7
|
+
[Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/hdinsight/arm-hdinsight) |
|
|
8
|
+
[Package (NPM)](https://www.npmjs.com/package/@azure/arm-hdinsight) |
|
|
9
|
+
[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-hdinsight) |
|
|
10
|
+
[Samples](https://github.com/Azure-Samples/azure-samples-js-management)
|
|
11
|
+
|
|
12
|
+
## Getting started
|
|
4
13
|
|
|
5
14
|
### Currently supported environments
|
|
6
15
|
|
|
7
|
-
- Node.js
|
|
8
|
-
-
|
|
16
|
+
- [LTS versions of Node.js](https://nodejs.org/about/releases/)
|
|
17
|
+
- Latest versions of Safari, Chrome, Edge and Firefox.
|
|
18
|
+
|
|
19
|
+
### Prerequisites
|
|
20
|
+
|
|
21
|
+
- An [Azure subscription][azure_sub].
|
|
22
|
+
|
|
23
|
+
### Install the `@azure/arm-hdinsight` package
|
|
9
24
|
|
|
10
|
-
|
|
25
|
+
Install the Azure HDInsightManagement client library for JavaScript with `npm`:
|
|
11
26
|
|
|
12
27
|
```bash
|
|
13
28
|
npm install @azure/arm-hdinsight
|
|
14
29
|
```
|
|
15
30
|
|
|
16
|
-
###
|
|
31
|
+
### Create and authenticate a `HDInsightManagementClient`
|
|
17
32
|
|
|
18
|
-
|
|
33
|
+
To create a client object to access the Azure HDInsightManagement API, you will need the `endpoint` of your Azure HDInsightManagement resource and a `credential`. The Azure HDInsightManagement client can use Azure Active Directory credentials to authenticate.
|
|
34
|
+
You can find the endpoint for your Azure HDInsightManagement resource in the [Azure Portal][azure_portal].
|
|
19
35
|
|
|
20
|
-
|
|
36
|
+
You can authenticate with Azure Active Directory using a credential from the [@azure/identity][azure_identity] library or [an existing AAD Token](https://github.com/Azure/azure-sdk-for-js/blob/master/sdk/identity/identity/samples/AzureIdentityExamples.md#authenticating-with-a-pre-fetched-access-token).
|
|
37
|
+
|
|
38
|
+
To use the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with the Azure SDK, please install the `@azure/identity` package:
|
|
21
39
|
|
|
22
|
-
- Please install minimum version of `"@azure/ms-rest-nodeauth": "^3.0.0"`.
|
|
23
40
|
```bash
|
|
24
|
-
npm install @azure/
|
|
41
|
+
npm install @azure/identity
|
|
25
42
|
```
|
|
26
43
|
|
|
27
|
-
|
|
44
|
+
You will also need to **register a new AAD application and grant access to Azure HDInsightManagement** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions).
|
|
45
|
+
Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`.
|
|
46
|
+
|
|
47
|
+
For more information about how to create an Azure AD Application check out [this guide](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal).
|
|
28
48
|
|
|
29
|
-
|
|
30
|
-
```typescript
|
|
31
|
-
const msRestNodeAuth = require("@azure/ms-rest-nodeauth");
|
|
49
|
+
```javascript
|
|
32
50
|
const { HDInsightManagementClient } = require("@azure/arm-hdinsight");
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
const client = new HDInsightManagementClient(creds, subscriptionId);
|
|
37
|
-
const resourceGroupName = "testresourceGroupName";
|
|
38
|
-
const clusterName = "testclusterName";
|
|
39
|
-
client.clusters.get(resourceGroupName, clusterName).then((result) => {
|
|
40
|
-
console.log("The result is:");
|
|
41
|
-
console.log(result);
|
|
42
|
-
});
|
|
43
|
-
}).catch((err) => {
|
|
44
|
-
console.error(err);
|
|
45
|
-
});
|
|
51
|
+
const { DefaultAzureCredential } = require("@azure/identity");
|
|
52
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
|
53
|
+
const client = new HDInsightManagementClient(new DefaultAzureCredential(), subscriptionId);
|
|
46
54
|
```
|
|
47
55
|
|
|
48
|
-
#### browser - Authentication, client creation and get clusters as an example written in JavaScript.
|
|
49
56
|
|
|
50
|
-
|
|
57
|
+
### JavaScript Bundle
|
|
58
|
+
To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling).
|
|
51
59
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
60
|
+
## Key concepts
|
|
61
|
+
|
|
62
|
+
### HDInsightManagementClient
|
|
55
63
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
<script src="node_modules/@azure/ms-rest-azure-js/dist/msRestAzure.js"></script>
|
|
68
|
-
<script src="node_modules/@azure/ms-rest-browserauth/dist/msAuth.js"></script>
|
|
69
|
-
<script src="node_modules/@azure/arm-hdinsight/dist/arm-hdinsight.js"></script>
|
|
70
|
-
<script type="text/javascript">
|
|
71
|
-
const subscriptionId = "<Subscription_Id>";
|
|
72
|
-
const authManager = new msAuth.AuthManager({
|
|
73
|
-
clientId: "<client id for your Azure AD app>",
|
|
74
|
-
tenant: "<optional tenant for your organization>"
|
|
75
|
-
});
|
|
76
|
-
authManager.finalizeLogin().then((res) => {
|
|
77
|
-
if (!res.isLoggedIn) {
|
|
78
|
-
// may cause redirects
|
|
79
|
-
authManager.login();
|
|
80
|
-
}
|
|
81
|
-
const client = new Azure.ArmHdinsight.HDInsightManagementClient(res.creds, subscriptionId);
|
|
82
|
-
const resourceGroupName = "testresourceGroupName";
|
|
83
|
-
const clusterName = "testclusterName";
|
|
84
|
-
client.clusters.get(resourceGroupName, clusterName).then((result) => {
|
|
85
|
-
console.log("The result is:");
|
|
86
|
-
console.log(result);
|
|
87
|
-
}).catch((err) => {
|
|
88
|
-
console.log("An error occurred:");
|
|
89
|
-
console.error(err);
|
|
90
|
-
});
|
|
91
|
-
});
|
|
92
|
-
</script>
|
|
93
|
-
</head>
|
|
94
|
-
<body></body>
|
|
95
|
-
</html>
|
|
64
|
+
`HDInsightManagementClient` is the primary interface for developers using the Azure HDInsightManagement client library. Explore the methods on this client object to understand the different features of the Azure HDInsightManagement service that you can access.
|
|
65
|
+
|
|
66
|
+
## Troubleshooting
|
|
67
|
+
|
|
68
|
+
### Logging
|
|
69
|
+
|
|
70
|
+
Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`:
|
|
71
|
+
|
|
72
|
+
```javascript
|
|
73
|
+
const { setLogLevel } = require("@azure/logger");
|
|
74
|
+
setLogLevel("info");
|
|
96
75
|
```
|
|
97
76
|
|
|
77
|
+
For more detailed instructions on how to enable logs, you can look at the [@azure/logger package docs](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/logger).
|
|
78
|
+
|
|
79
|
+
## Next steps
|
|
80
|
+
|
|
81
|
+
Please take a look at the [samples](https://github.com/Azure-Samples/azure-samples-js-management) directory for detailed examples on how to use this library.
|
|
82
|
+
|
|
83
|
+
## Contributing
|
|
84
|
+
|
|
85
|
+
If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/main/CONTRIBUTING.md) to learn more about how to build and test the code.
|
|
86
|
+
|
|
98
87
|
## Related projects
|
|
99
88
|
|
|
100
|
-
- [Microsoft Azure SDK for
|
|
89
|
+
- [Microsoft Azure SDK for JavaScript](https://github.com/Azure/azure-sdk-for-js)
|
|
90
|
+
|
|
91
|
+

|
|
101
92
|
|
|
102
|
-
|
|
93
|
+
[azure_cli]: https://docs.microsoft.com/cli/azure
|
|
94
|
+
[azure_sub]: https://azure.microsoft.com/free/
|
|
95
|
+
[azure_sub]: https://azure.microsoft.com/free/
|
|
96
|
+
[azure_portal]: https://portal.azure.com
|
|
97
|
+
[azure_identity]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity
|
|
98
|
+
[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity#defaultazurecredential
|