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

[AutoPR eventhub/resource-manager] MultiApi EventHub for Python #4825

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/services/eventHubManagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft
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
Expand Down
32 changes: 16 additions & 16 deletions lib/services/eventHubManagement/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,41 +3,41 @@ uid: azure-arm-eventhub
summary: *content

---
# Microsoft Azure SDK for Node.js - EventHubManagementClient
**This SDK will be deprecated next year and will be replaced by a new TypeScript-based isomorphic SDK (found at https://github.com/Azure/azure-sdk-for-js) which works on Node.js and browsers.**
## Microsoft Azure SDK for Node.js - EventHubManagementClient

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

## Features
### Features


## How to Install
### How to Install

```bash
npm install azure-arm-eventhub
```

## How to use
### How to use

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

```javascript
const msRestAzure = require("ms-rest-azure");
const EventHubManagementClient = require("azure-arm-eventhub");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new EventHubManagementClient(creds, subscriptionId);
return client.operations.list().then((result) => {
console.log("The result is:");
console.log(result);
});
const subscriptionId = "<Subscription_Id>";
const client = new EventHubManagementClient(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
```
### 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%2FeventHubManagement%2FREADME.png)
17 changes: 9 additions & 8 deletions lib/services/eventHubManagement/lib/models/accessKeys.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,20 @@
class AccessKeys {
/**
* Create a AccessKeys.
* @member {string} [primaryConnectionString] Primary connection string of
* @property {string} [primaryConnectionString] Primary connection string of
* the created namespace AuthorizationRule.
* @member {string} [secondaryConnectionString] Secondary connection string
* @property {string} [secondaryConnectionString] Secondary connection string
* of the created namespace AuthorizationRule.
* @member {string} [aliasPrimaryConnectionString] Primary connection string
* of the alias if GEO DR is enabled
* @member {string} [aliasSecondaryConnectionString] Secondary connection
* @property {string} [aliasPrimaryConnectionString] Primary connection
* string of the alias if GEO DR is enabled
* @member {string} [primaryKey] A base64-encoded 256-bit primary key for
* @property {string} [aliasSecondaryConnectionString] Secondary connection
* string of the alias if GEO DR is enabled
* @property {string} [primaryKey] A base64-encoded 256-bit primary key for
* signing and validating the SAS token.
* @member {string} [secondaryKey] A base64-encoded 256-bit primary key for
* @property {string} [secondaryKey] A base64-encoded 256-bit primary key for
* signing and validating the SAS token.
* @member {string} [keyName] A string that describes the AuthorizationRule.
* @property {string} [keyName] A string that describes the
* AuthorizationRule.
*/
constructor() {
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,18 @@ const models = require('./index');
class ArmDisasterRecovery extends models['Resource'] {
/**
* Create a ArmDisasterRecovery.
* @member {string} [provisioningState] Provisioning state of the
* @property {string} [provisioningState] Provisioning state of the
* Alias(Disaster Recovery configuration) - possible values 'Accepted' or
* 'Succeeded' or 'Failed'. Possible values include: 'Accepted', 'Succeeded',
* 'Failed'
* @member {string} [partnerNamespace] ARM Id of the Primary/Secondary
* eventhub namespace name, which is part of GEO DR pairning
* @member {string} [alternateName] Alternate name specified when alias and
* @property {string} [partnerNamespace] ARM Id of the Primary/Secondary
* eventhub namespace name, which is part of GEO DR pairing
* @property {string} [alternateName] Alternate name specified when alias and
* namespace names are same.
* @member {string} [role] role of namespace in GEO DR - possible values
* @property {string} [role] role of namespace in GEO DR - possible values
* 'Primary' or 'PrimaryNotReplicating' or 'Secondary'. Possible values
* include: 'Primary', 'PrimaryNotReplicating', 'Secondary'
* @member {number} [pendingReplicationOperationsCount] Number of entities
* @property {number} [pendingReplicationOperationsCount] Number of entities
* pending to be replicated.
*/
constructor() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@
class ArmDisasterRecoveryListResult extends Array {
/**
* Create a ArmDisasterRecoveryListResult.
* @member {string} [nextLink] Link to the next set of results. Not empty if
* Value contains incomplete list of Alias(Disaster Recovery configuration)
* @property {string} [nextLink] Link to the next set of results. Not empty
* if Value contains incomplete list of Alias(Disaster Recovery
* configuration)
*/
constructor() {
super();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const models = require('./index');
class AuthorizationRule extends models['Resource'] {
/**
* Create a AuthorizationRule.
* @member {array} rights The rights associated with the rule.
* @property {array} rights The rights associated with the rule.
*/
constructor() {
super();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
class AuthorizationRuleListResult extends Array {
/**
* Create a AuthorizationRuleListResult.
* @member {string} [nextLink] Link to the next set of results. Not empty if
* Value contains an incomplete list of Authorization Rules
* @property {string} [nextLink] Link to the next set of results. Not empty
* if Value contains an incomplete list of Authorization Rules
*/
constructor() {
super();
Expand Down
37 changes: 23 additions & 14 deletions lib/services/eventHubManagement/lib/models/captureDescription.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,29 +17,31 @@
class CaptureDescription {
/**
* Create a CaptureDescription.
* @member {boolean} [enabled] A value that indicates whether capture
* @property {boolean} [enabled] A value that indicates whether capture
* description is enabled.
* @member {string} [encoding] Enumerates the possible values for the
* @property {string} [encoding] Enumerates the possible values for the
* encoding format of capture description. Note: 'AvroDeflate' will be
* deprecated in New API Version. Possible values include: 'Avro',
* 'AvroDeflate'
* @member {number} [intervalInSeconds] The time window allows you to set the
* frequency with which the capture to Azure Blobs will happen, value should
* between 60 to 900 seconds
* @member {number} [sizeLimitInBytes] The size window defines the amount of
* data built up in your Event Hub before an capture operation, value should
* be between 10485760 to 524288000 bytes
* @member {object} [destination] Properties of Destination where capture
* @property {number} [intervalInSeconds] The time window allows you to set
* the frequency with which the capture to Azure Blobs will happen, value
* should between 60 to 900 seconds
* @property {number} [sizeLimitInBytes] The size window defines the amount
* of data built up in your Event Hub before an capture operation, value
* should be between 10485760 to 524288000 bytes
* @property {object} [destination] Properties of Destination where capture
* will be stored. (Storage Account, Blob Names)
* @member {string} [destination.name] Name for capture destination
* @member {string} [destination.storageAccountResourceId] Resource id of the
* storage account to be used to create the blobs
* @member {string} [destination.blobContainer] Blob container Name
* @member {string} [destination.archiveNameFormat] Blob naming convention
* @property {string} [destination.name] Name for capture destination
* @property {string} [destination.storageAccountResourceId] Resource id of
* the storage account to be used to create the blobs
* @property {string} [destination.blobContainer] Blob container Name
* @property {string} [destination.archiveNameFormat] Blob naming convention
* for archive, e.g.
* {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}.
* Here all the parameters (Namespace,EventHub .. etc) are mandatory
* irrespective of order
* @property {boolean} [skipEmptyArchives] A value that indicates whether to
* Skip Empty Archives
*/
constructor() {
}
Expand Down Expand Up @@ -102,6 +104,13 @@ class CaptureDescription {
name: 'Composite',
className: 'Destination'
}
},
skipEmptyArchives: {
required: false,
serializedName: 'skipEmptyArchives',
type: {
name: 'Boolean'
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
class CheckNameAvailabilityParameter {
/**
* Create a CheckNameAvailabilityParameter.
* @member {string} name Name to check the namespace name availability
* @property {string} name Name to check the namespace name availability
*/
constructor() {
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
class CheckNameAvailabilityResult {
/**
* Create a CheckNameAvailabilityResult.
* @member {string} [message] The detailed info regarding the reason
* @property {string} [message] The detailed info regarding the reason
* associated with the Namespace.
* @member {boolean} [nameAvailable] Value indicating Namespace is
* @property {boolean} [nameAvailable] Value indicating Namespace is
* availability, true if the Namespace is available; otherwise, false.
* @member {string} [reason] The reason for unavailability of a Namespace.
* @property {string} [reason] The reason for unavailability of a Namespace.
* Possible values include: 'None', 'InvalidName', 'SubscriptionIsDisabled',
* 'NameInUse', 'NameInLockdown', 'TooManyNamespaceInCurrentSubscription'
*/
Expand Down
6 changes: 3 additions & 3 deletions lib/services/eventHubManagement/lib/models/consumerGroup.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ const models = require('./index');
class ConsumerGroup extends models['Resource'] {
/**
* Create a ConsumerGroup.
* @member {date} [createdAt] Exact time the message was created.
* @member {date} [updatedAt] The exact time the message was updated.
* @member {string} [userMetadata] Usermetadata is a placeholder to store
* @property {date} [createdAt] Exact time the message was created.
* @property {date} [updatedAt] The exact time the message was updated.
* @property {string} [userMetadata] User Metadata is a placeholder to store
* user-defined string data with maximum length 1024. e.g. it can be used to
* store descriptive data, such as list of teams and their contact
* information also user-defined configuration settings can be stored.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
class ConsumerGroupListResult extends Array {
/**
* Create a ConsumerGroupListResult.
* @member {string} [nextLink] Link to the next set of results. Not empty if
* Value contains incomplete list of Consumer Group
* @property {string} [nextLink] Link to the next set of results. Not empty
* if Value contains incomplete list of Consumer Group
*/
constructor() {
super();
Expand Down
8 changes: 4 additions & 4 deletions lib/services/eventHubManagement/lib/models/destination.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@
class Destination {
/**
* Create a Destination.
* @member {string} [name] Name for capture destination
* @member {string} [storageAccountResourceId] Resource id of the storage
* @property {string} [name] Name for capture destination
* @property {string} [storageAccountResourceId] Resource id of the storage
* account to be used to create the blobs
* @member {string} [blobContainer] Blob container Name
* @member {string} [archiveNameFormat] Blob naming convention for archive,
* @property {string} [blobContainer] Blob container Name
* @property {string} [archiveNameFormat] Blob naming convention for archive,
* e.g.
* {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}.
* Here all the parameters (Namespace,EventHub .. etc) are mandatory
Expand Down
29 changes: 15 additions & 14 deletions lib/services/eventHubManagement/lib/models/eHNamespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,26 @@ const models = require('./index');
class EHNamespace extends models['TrackedResource'] {
/**
* Create a EHNamespace.
* @member {object} [sku] Properties of sku resource
* @member {string} [sku.name] Name of this SKU. Possible values include:
* @property {object} [sku] Properties of sku resource
* @property {string} [sku.name] Name of this SKU. Possible values include:
* 'Basic', 'Standard'
* @member {string} [sku.tier] The billing tier of this particular SKU.
* @property {string} [sku.tier] The billing tier of this particular SKU.
* Possible values include: 'Basic', 'Standard'
* @member {number} [sku.capacity] The Event Hubs throughput units, vaule
* @property {number} [sku.capacity] The Event Hubs throughput units, value
* should be 0 to 20 throughput units.
* @member {string} [provisioningState] Provisioning state of the Namespace.
* @member {date} [createdAt] The time the Namespace was created.
* @member {date} [updatedAt] The time the Namespace was updated.
* @member {string} [serviceBusEndpoint] Endpoint you can use to perform
* @property {string} [provisioningState] Provisioning state of the
* Namespace.
* @property {date} [createdAt] The time the Namespace was created.
* @property {date} [updatedAt] The time the Namespace was updated.
* @property {string} [serviceBusEndpoint] Endpoint you can use to perform
* Service Bus operations.
* @member {string} [metricId] Identifier for Azure Insights metrics.
* @member {boolean} [isAutoInflateEnabled] Value that indicates whether
* @property {string} [metricId] Identifier for Azure Insights metrics.
* @property {boolean} [isAutoInflateEnabled] Value that indicates whether
* AutoInflate is enabled for eventhub namespace.
* @member {number} [maximumThroughputUnits] Upper limit of throughput units
* when AutoInflate is enabled, vaule should be within 0 to 20 throughput
* units. ( '0' if AutoInflateEnabled = true)
* @member {boolean} [kafkaEnabled] Value that indicates whether Kafka is
* @property {number} [maximumThroughputUnits] Upper limit of throughput
* units when AutoInflate is enabled, value should be within 0 to 20
* throughput units. ( '0' if AutoInflateEnabled = true)
* @property {boolean} [kafkaEnabled] Value that indicates whether Kafka is
* enabled for eventhub namespace.
*/
constructor() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
class EHNamespaceListResult extends Array {
/**
* Create a EHNamespaceListResult.
* @member {string} [nextLink] Link to the next set of results. Not empty if
* Value contains incomplete list of namespaces.
* @property {string} [nextLink] Link to the next set of results. Not empty
* if Value contains incomplete list of namespaces.
*/
constructor() {
super();
Expand Down
8 changes: 4 additions & 4 deletions lib/services/eventHubManagement/lib/models/errorResponse.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@
'use strict';

/**
* Error reponse indicates EventHub service is not able to process the incoming
* request. The reason is provided in the error message.
* Error response indicates EventHub service is not able to process the
* incoming request. The reason is provided in the error message.
*
*/
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
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
class EventHubListResult extends Array {
/**
* Create a EventHubListResult.
* @member {string} [nextLink] Link to the next set of results. Not empty if
* Value contains incomplete list of EventHubs.
* @property {string} [nextLink] Link to the next set of results. Not empty
* if Value contains incomplete list of EventHubs.
*/
constructor() {
super();
Expand Down
Loading