mule

Large dataset processing using Mule ESB from database: how to update the processed records based on certain batch size?

为君一笑 提交于 2019-12-25 14:39:30
问题 I have a large set of records to be processed eg: 100,000 records. My use case has 4 steps: pick the records from database table using jdbc inbound adapter convert the record to xml format post the message to the queue then update the same record with some status flag as it has been processed so that it will not be picked again I don't want to pick all the records from table at one shot for processing: is there a way so that pick in some batches and don't want to update table for one record?

how to relate each execution step of my mule application to my web page

佐手、 提交于 2019-12-25 14:23:49
问题 In my mule project I added a web part. I just wanted to ask if there is a way to track every step of the execution process of my mule application via my web page. There is a screenshot of what i want to do. Those steps are related to my mule application. For example if the first step is executed I want to mark it in my web page. Any idea please?! I'm using Mule CE 3.5.0 回答1: You can use the AJAX Transport to push events from Mule to the browser displaying the execution steps. 回答2: for

how to relate each execution step of my mule application to my web page

断了今生、忘了曾经 提交于 2019-12-25 14:23:10
问题 In my mule project I added a web part. I just wanted to ask if there is a way to track every step of the execution process of my mule application via my web page. There is a screenshot of what i want to do. Those steps are related to my mule application. For example if the first step is executed I want to mark it in my web page. Any idea please?! I'm using Mule CE 3.5.0 回答1: You can use the AJAX Transport to push events from Mule to the browser displaying the execution steps. 回答2: for

how do i add a drop down list item in a mule connector?

♀尐吖头ヾ 提交于 2019-12-25 10:54:31
问题 I've made a mule connector, everything works great. I got 4 main properties for an HTTP outbound connection: url, port, path and method. I would like the method to be a drop down list with values: GET, POST. Do you guys know how to do it? what annotation needs to be used in case that's the way to solve it? Or is it recognized by Mule when adding a Map or Enum property? This is my current simple code /** * This file was automatically generated by the Mule Development Kit */ package com.web

Lookup list of Maps variable in data weave script

社会主义新天地 提交于 2019-12-25 09:15:31
问题 I have a list of maps (listOfMapsObject) like below [ { "Id" : "1234", "Value" : "Text1" }, { "Id" : "1235", "Value" : "Text2" } ] I would like access "Value" field for a given Id in dataweave script. For example: For Id = 1234, Text1 should be returned. %dw 1.0 %output application/json %var listOfMapsObject = flowVars.listOfMaps --- payload map { "key" : $.key, "data" : lookup Value field in listOfMapsObject by given key } 回答1: Approch suggested by @'sulthony h' is fine but it will end up in

Mule - how to parse the JSON response of REST webservice and update database

蹲街弑〆低调 提交于 2019-12-25 09:14:35
问题 I want to write a mule application which will read the database for unprocessed records, club them in JSON payload and then hit a REST webservice, REST webservice(Hosted on different server) will process the records and return the JSON output. Now I have to parse the JSON and update the database for the processed flag. I am able to get the response from the REST webservice, I have used Byte array to string transform to log in the logger. Do I need to write foreach component to process the

how to merge two Json based on key value in Mule

落爺英雄遲暮 提交于 2019-12-25 08:18:02
问题 Hi I have a 1 json as below "first": [ { "projectid": "15", "approval_status": "A" }, { "projectid": "24", "approval_status": "A" } ]} The next payload is stores in a flowVariable { "Second": [ { "projectid": "15", "total": "123", "updated": "yes" }, { "projectid": "24", "total": "123", "updated": "yes" }]} Am using datawevae to merge these payload but its not giving expected result my expected value is { "Result": [ { "projectid": "15", "total": "123", "approval_status": "A" }, { "projectid"

Merge two json payload with dataweave

喜你入骨 提交于 2019-12-25 08:06:32
问题 I have a Mule flow that calls two REST API's resulting in two json list payloads. I need to obtain a merged json list from these two payloads. I managed to achieve this with a scatter-gather flow with a custom aggregator strategy. However the code I had to write for this looks rather messy and it's slow. Is there any way to achieve this using dataweave?` input Json list 1: [{ "ID": "1", "firstName": "JANE""familyName": "DOE", "Entities": [{ "ID": "515785", "name": "UNKOWN UNITED", "callSign":

how to convert yyyymmdd into mm-dd-yyyy in dataweave

穿精又带淫゛_ 提交于 2019-12-25 07:59:12
问题 I have two string 1 represent date and 2nd time. have to convert same into date format in Mule-dataweave input :- s1= 20161228(yyyymmdd), s2= 1608(hhmm) output :- 12-28-2016 16:08:00(mm-dd-yyyy hh:mm:ss) in date format. Any Help? 回答1: This should work %dw 1.0 %output application/java %var s1= 20161228 // (yyyymmdd), %var s2= 1608 //(hhmm) --- output : (s1 ++ s2) as :localdatetime {format:"yyyyMMddHHmm"} as :string {format:"MM-dd-yyyy HH:mm:ss"} Hope this helps. 回答2: { "data":payload.date as

Getting functional unit tests to wait until devkit connector is connected

廉价感情. 提交于 2019-12-25 07:31:13
问题 I often have a requirement to wait some async process is finished in my devKit connector (which then causes isConnected to return true ) @ValidateConnection public boolean isConnected() { return isConnected; } How can I get my functional unit test to wait until this is completed. I would have thought the unit test would have waited until all the connectors in my flow were "connected". Atm I am using a sleep in the unit test to get round this in my FunctionalTestCase Thread.sleep(5000);