Azure Functions vs Azure Stream Analytics
Asked Answered
S

1

5

I noticed that both Azure Functions and Azure Stream Analytics can take an input, modify or transform that input, and put it into an output.

When would I use one versus the other? Are there any general rules I can use to decide?

I tried looking at the pricing of each to guide me, but I'm having trouble discerning how my logic would affect the compute time cost of Functions versus the App service plan cost of Functions versus the streaming unit cost of Stream Analytics.

Sula answered 2/3, 2018 at 20:12 Comment(0)
E
11

Azure Stream Analytics is a real time analytics service which can "run massively parallel real-time analytics on multiple IoT or non-IoT streams of data" whereas Azure Function is a (serverless) service to host functions (little pieces of code) that can be used for e.g. event-driven applications.

General rule is always difficult since everything depends on your requirement, but I would say if you have to analyze a data stream, you should take a look at Azure Stream Analytics and if you want to implement something like a serverless event-driven or timer-based application, you should check Azure Function or Logic Apps.

Endoscope answered 2/3, 2018 at 20:25 Comment(2)
Good answer. Another thing to add (and you alluded to it) is that with Stream Analytics, you can analyze a stream of data, so you can act on multiple messages with constructs such as windowing. There is some overlap of functionality between the two services if you're only acting on individual messages in isolation.Jarv
Piling on to the answers. If you need to call some other services, look up some other data, or implement any logic beyond the capabilities of ASA's query statements, then you'll need to use a Function.Sight

© 2022 - 2024 — McMap. All rights reserved.