Mule:spring bean 中包含的映射的键,将在运行时通过连接 flowvar 和 MEL 中的 属性 来构建

Mule: Key of a map contained in a spring bean to be constructed at runtime by concatenating from flowvar and a property in MEL

在 spring bean(详细信息)中有一个 hashmap,其运行时的键将使用 flowVars (msVendorCode) 的串联和从 属性 读取的 属性 来构造文件(队列名称和 QUEUEROUTINGKEY)

 <amqp:outbound-endpoint exchangeName="${QUEUEEXCHANGE}" queueName="#{detail.vendor['#[flowVars.msVendorCode]' + '${QUEUENAME}']}" connector-ref="vendorConnector" routingKey="#{detail.vendor['#[flowVars.msVendorCode]' + '${QUEUEROUTINGKEY}']}" doc:name="AMQP" />

我如何在运行时通过连接流变量和 属性 为 spring bean 中的映射构造映射键。上面使用的表达式将 null 设置为路由键和队列名称。

试试:

queueName="#[app.registry.detail.vendor[flowVars.msVendorCode] + '${QUEUENAME}']"