Skip to content

Commit

Permalink
Eventhubs blobstorage docs update (#7216)
Browse files Browse the repository at this point in the history
  • Loading branch information
YijunXieMS authored Sep 12, 2019
1 parent 483a334 commit c3fece1
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 9 deletions.
10 changes: 5 additions & 5 deletions sdk/eventhub/azure-eventhubs-checkpointstoreblob-aio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@
Azure EventHubs Checkpoint Store is used for storing checkpoints while processing events from Azure Event Hubs.
This Checkpoint Store package works as a plug-in package to `EventProcessor`. It uses Azure Storage Blob as the persistent store for maintaining checkpoints and partition ownership information.

[Source code](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/eventhub/azure-eventhubs-checkpointstoreblob-aio) | [Package (PyPi)](https://pypi.org/project/azure-eventhub-checkpointstoreblobaio/) | [API reference documentation](https://azure.github.io/azure-sdk-for-python/) | [Azure Eventhubs documentation](https://docs.microsoft.com/en-us/azure/event-hubs/) | [Azure Storage documentation](https://docs.microsoft.com/en-us/azure/storage/)
[Source code](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/eventhub/azure-eventhubs-checkpointstoreblob-aio) | [Package (PyPi)](https://pypi.org/project/azure-eventhub-checkpointstoreblob-aio/) | [API reference documentation](https://azure.github.io/azure-sdk-for-python/ref/azure.eventhub.extensions.html) | [Azure Eventhubs documentation](https://docs.microsoft.com/en-us/azure/event-hubs/) | [Azure Storage documentation](https://docs.microsoft.com/en-us/azure/storage/)

## Getting started

### Install the package

```
$ pip install --pre azure-eventhub-checkpointstoreblobaio
$ pip install --pre azure-eventhub-checkpointstoreblob-aio
```

**Prerequisites**

- Python 3.5.3 or later.
- **Microsoft Azure Subscription:** To use Azure services, including Azure Event Hubs, you'll need a subscription. If you do not have an existing Azure account, you may sign up for a free trial or use your MSDN subscriber benefits when you [create an account](https://account.windowsazure.com/Home/Index).
- **Microsoft Azure Subscription:** To use Azure services, including Azure Event Hubs, you'll need a subscription. If you do not have an existing Azure account, you may sign up for a free trial or use your MSDN subscriber benefits when you [create an account](https://azure.microsoft.com/en-us/).

- **Event Hubs namespace with an Event Hub:** To interact with Azure Event Hubs, you'll also need to have a namespace and Event Hub available. If you are not familiar with creating Azure resources, you may wish to follow the step-by-step guide for [creating an Event Hub using the Azure portal](https://docs.microsoft.com/en-us/azure/event-hubs/event-hubs-create). There, you can also find detailed instructions for using the Azure CLI, Azure PowerShell, or Azure Resource Manager (ARM) templates to create an Event Hub.

Expand Down Expand Up @@ -56,7 +56,7 @@ The easiest way to create a `ContainerClient` is to use a connection string.
from azure.storage.blob.aio import ContainerClient
container_client = ContainerClient.from_connection_string("my_storageacount_connection_string", container="mycontainer")
```
For other ways of creating a `ContainerClient`, go to [Blob Storage library](https://github.com/Azure/azure-sdk-for-python/tree/eventhubs_preview3/sdk/storage/azure-storage-blob) for more details.
For other ways of creating a `ContainerClient`, go to [Blob Storage library](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-blob) for more details.

### Create an `EventHubClient`
The easiest way to create a `EventHubClient` is to use a connection string.
Expand Down Expand Up @@ -114,7 +114,7 @@ Refer to [Logging](#logging) to enable loggers for related libraries.

### Documentation

Reference documentation is available at https://azure.github.io/azure-sdk-for-python/ref/azure.eventhub.
Reference documentation is available at https://azure.github.io/azure-sdk-for-python/ref/azure.eventhub.extensions.html.

### Logging

Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
../azure-eventhubs
../azure-eventhubs
pytest-asyncio>=0.8.0; python_version >= '3.5'
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
install_requires=[
'azure-storage-blob<12.0.0b4,>=12.0.0b2',
'azure-eventhub<6.0.0,>=5.0.0b3',
'aiohttp<4.0,>=3.0',
],
extras_require={

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ def get_live_storage_blob_client():
try:
storage_connection_str = os.environ['AZURE_STORAGE_CONN_STR']
except KeyError:
return None
return None, None
try:
from azure.storage.blob import BlobServiceClient
from azure.storage.blob.aio import ContainerClient
except ImportError or ModuleNotFoundError:
return None
return None, None

container_str = str(uuid.uuid4())
blob_service_client = BlobServiceClient.from_connection_string(storage_connection_str)
Expand Down
2 changes: 1 addition & 1 deletion sdk/eventhub/azure-eventhubs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ The Azure Event Hubs client library allows for publishing and consuming of Azure
- Observe interesting operations and interactions happening within your business or other ecosystem, allowing loosely coupled systems to interact without the need to bind them together.
- Receive events from one or more publishers, transform them to better meet the needs of your ecosystem, then publish the transformed events to a new stream for consumers to observe.

[Source code](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/eventhub/azure-eventhubs) | [Package (PyPi)](https://pypi.org/project/azure-eventhub/) | [API reference documentation](https://azure.github.io/azure-sdk-for-python/ref/azure.eventhub) | [Product documentation](https://docs.microsoft.com/en-us/azure/event-hubs/)
[Source code](https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/eventhub/azure-eventhubs) | [Package (PyPi)](https://pypi.org/project/azure-eventhub/5.0.0b3) | [API reference documentation](https://azure.github.io/azure-sdk-for-python/ref/azure.eventhub) | [Product documentation](https://docs.microsoft.com/en-us/azure/event-hubs/)

## Getting started

Expand Down
1 change: 1 addition & 0 deletions sdk/eventhub/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ jobs:
EnvVars:
AZURE_STORAGE_ACCOUNT: $(python-eh-livetest-event-hub-storage-account)
AZURE_STORAGE_ACCESS_KEY: $(python-eh-livetest-event-hub-storage-access-key)
AZURE_STORAGE_CONN_STR: $(python-eh-livetest-event-hub-storage-conn-str)
EVENT_HUB_HOSTNAME: $(python-eh-livetest-event-hub-hostname)
EVENT_HUB_NAME: $(python-eh-livetest-event-hub-name)
EVENT_HUB_SAS_POLICY: $(python-eh-livetest-event-hub-sas-policy)
Expand Down
1 change: 1 addition & 0 deletions shared_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,4 @@ six>=1.6
#override azure-storage-file azure-core<2.0.0,>=1.0.0b3
#override azure-cosmos azure-core<2.0.0,>=1.0.0b3
#override azure-eventhubs-checkpointstoreblob-aio azure-storage-blob<12.0.0b4,>=12.0.0b2
#override azure-eventhubs-checkpointstoreblob-aio aiohttp<4.0,>=3.0

0 comments on commit c3fece1

Please sign in to comment.