![](/img/trans.png)
[英]java.lang.ClassNotFoundException: com.mulesoft.weave.module.writer.Writer
[英]Mulesoft Dataweave transformation into MongoDB - Failed to transform “com.mulesoft.weave.mule.WeaveMessageProcessor$WeaveOutputHandler”
我已成功從Alfresco ECM實例檢索記錄。 當我嘗試將它們推入MongoDb時,我得到以下信息:
無法從“ com.mulesoft.weave.mule.WeaveMessageProcessor $ WeaveOutputHandler”轉換為“ org.bson.Document”(org.mule.api.transformer.TransformerException)。 消息有效負載的類型為:WeaveMessageProcessor $ WeaveOutputHandler
我正在使用Dataweave將查詢記錄轉換為Json,但是我不確定為什么會這樣。
這是我的流程:
<flow name="mongotestFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/add" doc:name="HTTP"/>
<cmis:query config-ref="CMIS__Configuration" statement="SELECT cmis:objectId,cmis:name,cmis:contentStreamLength,cmis:creationDate,cmis:lastModifiedBy, cmis:lastModificationDate from cmis:document where cmis:createdBy <> 'System'" doc:name="CMIS"/>
<dw:transform-message doc:name="Transform Message">
<dw:set-payload><![CDATA[%dw 1.0
%output application/json
---
payload.properties map {
"size": $.values[2][0]
}
]]></dw:set-payload>
</dw:transform-message>
<mongo:insert-document config-ref="Mongo_DB__Configuration" collection="testCollection" doc:name="Mongo DB" document-ref="#[message.payload]"/>
</flow>
任何幫助將不勝感激。
-S
在插入到Mongo
之前,使用<mongo:json-to-dbobject doc:name="Mongo DB"/>
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.