azure-eventhub

How to process eventhub stream with pyspark and custom python function

给你一囗甜甜゛ 提交于 2019-12-01 09:03:57
My current setup is: Spark 2.3.0 with pyspark 2.2.1 streaming service using Azure IOTHub/EventHub some custom python functions based on pandas, matplotlib, etc I'm using https://github.com/Azure/azure-event-hubs-spark/blob/master/docs/PySpark/structured-streaming-pyspark-jupyter.md as an example on how to read the data but: can't use foreach sink as that is not implemented in python when i try to call .rdd, .map or .flatMap i get an exception: "Queries with streaming sources must be executed with writeStream.start()" What is the correct way to get each element of the stream and pass it through

How to process eventhub stream with pyspark and custom python function

て烟熏妆下的殇ゞ 提交于 2019-12-01 06:15:08
问题 My current setup is: Spark 2.3.0 with pyspark 2.2.1 streaming service using Azure IOTHub/EventHub some custom python functions based on pandas, matplotlib, etc I'm using https://github.com/Azure/azure-event-hubs-spark/blob/master/docs/PySpark/structured-streaming-pyspark-jupyter.md as an example on how to read the data but: can't use foreach sink as that is not implemented in python when i try to call .rdd, .map or .flatMap i get an exception: "Queries with streaming sources must be executed

Azure IoT Hub, EventHub and Functions

橙三吉。 提交于 2019-12-01 04:15:31
I have an IoTHub with a route that points to an EventHub which triggers a Functions. I'm having problem getting the DeviceId and other IoT Hub properties from the event object without adding those explicitly to the payload. If I set the input type to a string (or a custom type): public static void Run(string iotMessage, TraceWriter log) { log.Info($"C# Event Hub trigger function processed a message: {iotMessage}"); } I only get the payload without any other IoT Hub properties like DeviceId , CorrelationId or MessageId . I tried to set the type to EventData instead: public static void Run

Should event hubs be split on message type?

此生再无相见时 提交于 2019-11-30 21:35:39
I am considering using Azure event Hub for a project I am currently working on. We are using Service Bus Queues for commands today and here we are using one queue per messagetype. Would it make sense to have several Event Hubs or is it better to use one hub for several message types? This is a question full of tradeoffs and exercising judgement about what systems you expect to build now and in the future and how they might use the different event types. Below is an excerpt from some of the guidance Jay Kreps has given for designing systems on top of Apache Kafka which applies well to Event

SignalR scaling out with Azure EventHub

大兔子大兔子 提交于 2019-11-30 19:27:14
I am looking high frequency scaling solution for SignalR. I am wondering if I can do it with Azure EventHub. If I use EventHub as my backplane for SignalR messages, will it become a bottleneck for me? I've checked this page but there is nothing about EventHub as it is fairly new. I can't speak to the precise specifics of SignalR; however, you could in principle use EventHubs for a backplane, but you need to be aware of the limitations. SignalR's backplane scaleout pattern assumes that all the servers will have access to all the messages and presumptively process them all. This provides a

Forcing EventProcessorHost to re-deliver failed Azure Event Hub eventData's to IEventProcessor.ProcessEvents method

≡放荡痞女 提交于 2019-11-30 10:48:17
The application uses .NET 4.6.1 and the Microsoft.Azure.ServiceBus.EventProcessorHost nuget package v2.0.2 , along with it's dependency WindowsAzure.ServiceBus package v3.0.1 to process Azure Event Hub messages. The application has an implementation of IEventProcessor . When an unhandled exception is thrown from the ProcessEventsAsync method the EventProcessorHost never re-sends those messages to the running instance of IEventProcessor . (Anecdotally, it will re-send if the hosting application is stopped and restarted or if the lease is lost and re-obtained.) Is there a way to force the event

Looking for clarity on Event Hubs vs Topics in Azure Service Bus

落爺英雄遲暮 提交于 2019-11-30 10:25:46
问题 I've been learning about Event Hubs and just want to get confirmation or correction on my perspective on Event Hubs? I’m used to leveraging retries, poison messages, at least once delivery and so on for normal enterprise messaging solutions, which Azure Service Bus Queues and Topics give me. It seems that Event Hubs is intended to provide a different tool for very high scale where you have to give up a little of the more “enterprise” features for much higher scale. Am I thinking about this

Should event hubs be split on message type?

那年仲夏 提交于 2019-11-30 05:43:32
问题 I am considering using Azure event Hub for a project I am currently working on. We are using Service Bus Queues for commands today and here we are using one queue per messagetype. Would it make sense to have several Event Hubs or is it better to use one hub for several message types? 回答1: This is a question full of tradeoffs and exercising judgement about what systems you expect to build now and in the future and how they might use the different event types. Below is an excerpt from some of

Azure DocumentDB Read Document Resource Not Found

我怕爱的太早我们不能终老 提交于 2019-11-30 01:51:36
问题 I'm building a .Net Console application to read information in a DocumentDB. The console app has data coming from an EventHub and inserts/updates recent data as it comes into the cloud. I am trying to read a singular document from DocumentDB and I can confirm that the Document Exists prior to requesting the Document. if (DocumentDBRepository<DocumentDBItem>.DoesItemExist(name)) { device = await DocumentDBRepository<DocumentDBItem>.GetItemAsync(name); } I used this tutorial from Microsoft

Azure IoT Hub AMQP Communication Multiplexing

百般思念 提交于 2019-11-29 21:43:03
问题 In some of the Microsoft documentation for working with Azure IoT hubs, it mentions that it is possible to multiplex the communication of multiple devices under a single TLS connection (using the AMQP protocol) for scenarios where multiple simple devices talk to a local hub device that is powerful enough to communicate with the IoT Hub. Are there any examples of how one would implement this multiplexing? The DeviceClient library does not appear to support this (although I could be wrong).