Azure Stream Analytics 如何处理超过 5 个查询?

Azure Stream Analytics How to handle more than 5 query?

我创建了一个 ASA 作业,还创建了一个输入(eventhub)和 6 个输出(2 个 cosmos 和 4 个服务总线队列) 查询如下所示。 SA 允许编写超过 5 个查询,但在 activity logs.Because 中给出错误,其中我也得到水印延迟。

1: Select
             *
          INTO
             CosmosOutput
          FROM
             eventhubinput ;
2:       Select
             id,long,lat,timestamp
          INTO
             CosmosOutput1
          FROM
             eventhubinput ;
3:       Select
             *
          INTO
             SB1
          FROM
             eventhubinput 
           Where <condition>;

4:          Select
             *
          INTO
             SB2
          FROM
             eventhubinput 
           Where <condition>;
5:          Select
             *
          INTO
             SB3
          FROM
             eventhubinput 
           Where <condition1>;
6:          Select
             *
          INTO
             SB4
          FROM
             eventhubinput 
           Where <condition1>;

问题:

如何高效地编写 5 个以上的查询?提前致谢!

由于您有多个查询,您可以尝试分配 Stream Units Settings

流单元 (SU) 表示为执行流分析作业而分配的计算资源。 SU 的数量越多,为您的作业分配的 CPU 和内存资源就越多。为特定作业选择所需 SU 的数量取决于输入的分区配置和作业中定义的查询。

当然,SU 会产生更多 cost.Another 解决方法,您可以设置 azure function output to replace some queries.For example, I notice you need to push data into different Service Bus Output with totally same conditions. You could sum them into one query and push same data into Azure function as parameters. Inside Azure function, configure multiple output bindings of service bus