Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.

Commit

Permalink
Generate azure-arm-hanaonazure package (#5071)
Browse files Browse the repository at this point in the history
* Generate azure-arm-hanaonazure package

* Bump the version
  • Loading branch information
kpajdzik committed Apr 18, 2019
1 parent d427e98 commit a5c7558
Show file tree
Hide file tree
Showing 22 changed files with 2,020 additions and 475 deletions.
41 changes: 41 additions & 0 deletions lib/services/hanaonazureManagement/.scripts/postinstall.js
@@ -0,0 +1,41 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.

const resetColor = "\x1b[0m";
const brightColor = "\x1b[1m";
const highlightColor = "\x1b[31m";

try {
const invisibleCharactersLength = resetColor.length + brightColor.length + highlightColor.length;

const firstLine = `Active development of this SDK has been moved to ${highlightColor}@azure/arm-hanaonazure${resetColor}${brightColor} package.`;
const secondLine = "This package is in maintenance mode and will be deprecated in July 2019.";
const thirdLine = "Visit https://aka.ms/azure-sdk-for-js-migration for more information.";

const framePadding = 4;
const adjustedFirstLineLength = firstLine.length - invisibleCharactersLength;
const width = Math.max(adjustedFirstLineLength, secondLine.length, thirdLine.length) + framePadding;
const getPaddingLength = (strLength) => width - strLength - framePadding;

const firstLinePaddingLength = getPaddingLength(adjustedFirstLineLength);
const secondLinePaddingLength = getPaddingLength(secondLine.length);
const thirdLinePaddingLength = getPaddingLength(thirdLine.length);
const line = "#".repeat(width);

const formatTextLine = (text, padding) => `#${" ".repeat(Math.floor(padding / 2))} ${text} ${" ".repeat(Math.ceil(padding / 2))}#`;

console.log(brightColor);
console.log("\n" + line);
console.log(formatTextLine(firstLine, firstLinePaddingLength));
console.log(formatTextLine(secondLine, secondLinePaddingLength));
console.log(formatTextLine(thirdLine, thirdLinePaddingLength));
console.log(line + "\n");
console.log(resetColor);
} catch (err) {
// ignore
}
42 changes: 21 additions & 21 deletions lib/services/hanaonazureManagement/LICENSE.txt
@@ -1,21 +1,21 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
The MIT License (MIT)
Copyright (c) 2019 Microsoft
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
87 changes: 44 additions & 43 deletions lib/services/hanaonazureManagement/README.md
@@ -1,43 +1,44 @@
---
uid: azure-arm-hanaonazure
summary: *content

---
# Microsoft Azure SDK for Node.js - HanaManagementClient
This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**

## Features


## How to Install

```bash
npm install azure-arm-hanaonazure
```

## How to use

### Authentication, client creation and list operations as an example.

```javascript
const msRestAzure = require("ms-rest-azure");
const HanaManagementClient = require("azure-arm-hanaonazure");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new HanaManagementClient(creds, subscriptionId);
return client.operations.list().then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error occurred:');
console.dir(err, {depth: null, colors: true});
});

## Related projects

- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)


![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-node%2Flib%2Fservices%2FhanaonazureManagement%2FREADME.png)
---
uid: azure-arm-hanaonazure
summary: *content

---
**This SDK will be deprecated next year and will be replaced by a new TypeScript-based isomorphic SDK (found at https://www.npmjs.com/package/@azure/arm-hanaonazure) which works on Node.js and browsers.**
**See https://aka.ms/azure-sdk-for-js-migration to learn more.**
## Microsoft Azure SDK for Node.js - HanaManagementClient

This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**

### Features


### How to Install

```bash
npm install azure-arm-hanaonazure
```

### How to use

#### Authentication, client creation, and list operations as an example.

```javascript
const msRestAzure = require("ms-rest-azure");
const HanaManagementClient = require("azure-arm-hanaonazure");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new HanaManagementClient(creds, subscriptionId);

return client.operations.list().then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error occurred:');
console.dir(err, {depth: null, colors: true});
});
```
### Related projects

- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)
12 changes: 6 additions & 6 deletions lib/services/hanaonazureManagement/lib/models/disk.js
Expand Up @@ -17,12 +17,12 @@
class Disk {
/**
* Create a Disk.
* @member {string} [name] The disk name.
* @member {number} [diskSizeGB] Specifies the size of an empty data disk in
* gigabytes.
* @member {number} [lun] Specifies the logical unit number of the data disk.
* This value is used to identify data disks within the VM and therefore must
* be unique for each data disk attached to a VM.
* @property {string} [name] The disk name.
* @property {number} [diskSizeGB] Specifies the size of an empty data disk
* in gigabytes.
* @property {number} [lun] Specifies the logical unit number of the data
* disk. This value is used to identify data disks within the VM and
* therefore must be unique for each data disk attached to a VM.
*/
constructor() {
}
Expand Down
24 changes: 12 additions & 12 deletions lib/services/hanaonazureManagement/lib/models/display.js
Expand Up @@ -17,24 +17,24 @@
class Display {
/**
* Create a Display.
* @member {string} [provider] The localized friendly form of the resource
* @property {string} [provider] The localized friendly form of the resource
* provider name. This form is also expected to include the publisher/company
* responsible. Use Title Casing. Begin with "Microsoft" for 1st party
* services.
* @member {string} [resource] The localized friendly form of the resource
* @property {string} [resource] The localized friendly form of the resource
* type related to this action/operation. This form should match the public
* documentation for the resource provider. Use Title Casing. For examples,
* refer to the “name” section.
* @member {string} [operation] The localized friendly name for the operation
* as shown to the user. This name should be concise (to fit in drop downs),
* but clear (self-documenting). Use Title Casing and include the
* entity/resource to which it applies.
* @member {string} [description] The localized friendly description for the
* operation as shown to the user. This description should be thorough, yet
* concise. It will be used in tool-tips and detailed views.
* @member {string} [origin] The intended executor of the operation; governs
* the display of the operation in the RBAC UX and the audit logs UX. Default
* value is 'user,system'
* @property {string} [operation] The localized friendly name for the
* operation as shown to the user. This name should be concise (to fit in
* drop downs), but clear (self-documenting). Use Title Casing and include
* the entity/resource to which it applies.
* @property {string} [description] The localized friendly description for
* the operation as shown to the user. This description should be thorough,
* yet concise. It will be used in tool-tips and detailed views.
* @property {string} [origin] The intended executor of the operation;
* governs the display of the operation in the RBAC UX and the audit logs UX.
* Default value is 'user,system'
*/
constructor() {
}
Expand Down
Expand Up @@ -17,8 +17,8 @@
class ErrorResponse {
/**
* Create a ErrorResponse.
* @member {string} [code] Error code
* @member {string} [message] Error message indicating why the operation
* @property {string} [code] Error code
* @property {string} [message] Error message indicating why the operation
* failed.
*/
constructor() {
Expand Down
59 changes: 39 additions & 20 deletions lib/services/hanaonazureManagement/lib/models/hanaInstance.js
Expand Up @@ -20,39 +20,42 @@ const models = require('./index');
class HanaInstance extends models['Resource'] {
/**
* Create a HanaInstance.
* @member {object} [hardwareProfile] Specifies the hardware settings for the
* HANA instance.
* @member {string} [hardwareProfile.hardwareType] Name of the hardware type
* (vendor and/or their product name). Possible values include: 'Cisco_UCS',
* 'HPE'
* @member {string} [hardwareProfile.hanaInstanceSize] Specifies the HANA
* @property {object} [hardwareProfile] Specifies the hardware settings for
* the HANA instance.
* @property {string} [hardwareProfile.hardwareType] Name of the hardware
* type (vendor and/or their product name). Possible values include:
* 'Cisco_UCS', 'HPE'
* @property {string} [hardwareProfile.hanaInstanceSize] Specifies the HANA
* instance SKU. Possible values include: 'S72m', 'S144m', 'S72', 'S144',
* 'S192', 'S192m', 'S192xm', 'S384', 'S384m', 'S384xm', 'S384xxm', 'S576m',
* 'S576xm', 'S768', 'S768m', 'S768xm', 'S960m'
* @member {object} [storageProfile] Specifies the storage settings for the
* 'S192', 'S192m', 'S192xm', 'S96', 'S384', 'S384m', 'S384xm', 'S384xxm',
* 'S576m', 'S576xm', 'S768', 'S768m', 'S768xm', 'S960m'
* @property {object} [storageProfile] Specifies the storage settings for the
* HANA instance disks.
* @member {string} [storageProfile.nfsIpAddress] IP Address to connect to
* @property {string} [storageProfile.nfsIpAddress] IP Address to connect to
* storage.
* @member {array} [storageProfile.osDisks] Specifies information about the
* @property {array} [storageProfile.osDisks] Specifies information about the
* operating system disk used by the hana instance.
* @member {object} [osProfile] Specifies the operating system settings for
* @property {object} [osProfile] Specifies the operating system settings for
* the HANA instance.
* @member {string} [osProfile.computerName] Specifies the host OS name of
* @property {string} [osProfile.computerName] Specifies the host OS name of
* the HANA instance.
* @member {string} [osProfile.osType] This property allows you to specify
* @property {string} [osProfile.osType] This property allows you to specify
* the type of the OS.
* @member {string} [osProfile.version] Specifies version of operating
* @property {string} [osProfile.version] Specifies version of operating
* system.
* @member {object} [networkProfile] Specifies the network settings for the
* @property {object} [networkProfile] Specifies the network settings for the
* HANA instance.
* @member {array} [networkProfile.networkInterfaces] Specifies the network
* @property {array} [networkProfile.networkInterfaces] Specifies the network
* interfaces for the HANA instance.
* @member {string} [networkProfile.circuitId] Specifies the circuit id for
* @property {string} [networkProfile.circuitId] Specifies the circuit id for
* connecting to express route.
* @member {string} [hanaInstanceId] Specifies the HANA instance unique ID.
* @member {string} [powerState] Resource power state. Possible values
* @property {string} [hanaInstanceId] Specifies the HANA instance unique ID.
* @property {string} [powerState] Resource power state. Possible values
* include: 'starting', 'started', 'stopping', 'stopped', 'restarting',
* 'unknown'
* @property {string} [proximityPlacementGroup] Resource proximity placement
* group
* @property {string} [hwRevision] Hardware revision of a HANA instance
*/
constructor() {
super();
Expand Down Expand Up @@ -166,6 +169,22 @@ class HanaInstance extends models['Resource'] {
type: {
name: 'String'
}
},
proximityPlacementGroup: {
required: false,
readOnly: true,
serializedName: 'properties.proximityPlacementGroup',
type: {
name: 'String'
}
},
hwRevision: {
required: false,
readOnly: true,
serializedName: 'properties.hwRevision',
type: {
name: 'String'
}
}
}
}
Expand Down
Expand Up @@ -16,7 +16,8 @@
class HanaInstancesListResult extends Array {
/**
* Create a HanaInstancesListResult.
* @member {string} [nextLink] The URL to get the next set of HANA instances.
* @property {string} [nextLink] The URL to get the next set of HANA
* instances.
*/
constructor() {
super();
Expand Down
Expand Up @@ -17,12 +17,12 @@
class HardwareProfile {
/**
* Create a HardwareProfile.
* @member {string} [hardwareType] Name of the hardware type (vendor and/or
* @property {string} [hardwareType] Name of the hardware type (vendor and/or
* their product name). Possible values include: 'Cisco_UCS', 'HPE'
* @member {string} [hanaInstanceSize] Specifies the HANA instance SKU.
* @property {string} [hanaInstanceSize] Specifies the HANA instance SKU.
* Possible values include: 'S72m', 'S144m', 'S72', 'S144', 'S192', 'S192m',
* 'S192xm', 'S384', 'S384m', 'S384xm', 'S384xxm', 'S576m', 'S576xm', 'S768',
* 'S768m', 'S768xm', 'S960m'
* 'S192xm', 'S96', 'S384', 'S384m', 'S384xm', 'S384xxm', 'S576m', 'S576xm',
* 'S768', 'S768m', 'S768xm', 'S960m'
*/
constructor() {
}
Expand Down

0 comments on commit a5c7558

Please sign in to comment.