Questions tagged [mule4]

Version 4 of Mule, a lightweight enterprise service bus (ESB) and integration framework provided by MuleSoft

Mule is a lightweight enterprise service bus (ESB) and integration framework provided by MuleSoft. According to the documentation, Version 4 aims at simplifying the expression language and reducing management complexity. This way, it shall be possible to deliver applications faster than in earlier versions of the product.

1166 questions
2
votes
1 answer

JSON array to Table structure formatting while sending email via Mule 4

I have a requirement to send the error report as a tabular format, which needs to be sent as a email body. I am constructing error report as a JSON array and I would need to do the HTML transformation to structure that as table format. Below is the…
Deeps
  • 47
  • 9
2
votes
1 answer

Element 'springService' is not defined in the Mule Registry [Mule 4]

I have a problem with beans in mule 4. There is an error when trying to invoke java: Element 'springService' is not defined in the Mule Registry Error occures in run time. I have created configuration.xml and declared spring config:
Mateusz
  • 61
  • 5
2
votes
3 answers

how to check if any one element of a variable length String array is present in another variable length string array

inputArray = ["cat", "bat", "mat"] configuredArray = ["dog", "elephant", "fox", "cat"] inputArray and configuredArray are variable length String arrays. If any one element of the inputArray is present in the configuredArray I would like to set a…
jpass abba
  • 21
  • 2
2
votes
4 answers

MuleSoft Dataweave reduce

I try to get my head around the reduce function in Mulesoft Dataweave 2.0. expected outcome: { "dev": "1", "test": "2", "uat": "3", "prod": "4" } my dataweave code: %dw 2.0 var invar = [ {"id": "1", "name": "dev"}, {"id": "2", "name":…
Ben
  • 594
  • 1
  • 9
  • 24
2
votes
3 answers

MULE-4 : SFTP Connection is not re-establishing after connection failure

We are reading new or updated files for every 1 minute on SFTP server using SFTP
Prudhvi B
  • 144
  • 2
  • 13
2
votes
1 answer

Mule 4 : Dataweave 2.0 : is there any alternative of Java 8 Streams anyMatch() method in Dataweave 2.0?

Scenario : Given an array consisting of objects representing a students marks and role in various subjects, I want to filter and see if there are any subjects where a particular student failed. var sampleArray = [ { "studentName" :…
Bibek Kr. Bazaz
  • 505
  • 10
  • 34
2
votes
3 answers

Using p() function in Transform Message in Mule Plugin

I have a mule plugin added as a dependency in my Project-A, In the mule-plugin I have defined a Transform Message where I am referring the values from the properties file defined in the plugin using p('property_name'). But it is throwing an error.…
Sufi
  • 186
  • 1
  • 2
  • 12
2
votes
2 answers

Zip key and value arrays into one object with Dataweave

I need to generate a single object starting from two arrays, one with the key names and the other with the values. I was able to get it using the following code: var keys = ["fieldA","fieldB","fieldC"] var values = [45,"data", {some:…
Jorge Garcia
  • 1,313
  • 8
  • 14
2
votes
1 answer

Is it posible to use Dataweave mask or update functions with conditions that depend on dynamic data?

I need to mask some fields which are dynamic. This is what I'm using now: var data = { a: 1, b: 2, c: 3, d: 4, e: 5 } var mask = { a: " ", d: "0"} --- data mapObject ((value, key, index) -> (key): mask[key] default value ) And I'm getting the…
Jorge Garcia
  • 1,313
  • 8
  • 14
2
votes
1 answer

Polymorphism in DW 2.0

I recently became aware of a generics-like notation to denote polymorphic types in DW 2.0. The example below %dw 2.0 output application/dw fun id1(a) = a fun id2(a: Any) = a fun id3(a: T) = a var id4 = (a: T) -> a --- { "d1": id1, …
George
  • 2,758
  • 12
  • 16
2
votes
3 answers

JSON object Ignore null

Im kinda new to MuleSoft and DataWeave and im trying to make a JSON Object with only not null values from another JSON object. Let's say this is my JSON array : { str1 : "String 1", str2 : "String 2", str3 : null, str4 : "String…
Fragan
  • 792
  • 10
  • 29
2
votes
1 answer

How to resolve Mule SFTP Kerberos username and password prompt in Mule 4 Version: Mule 4.3

I am facing SFTP Kerberos username and prompt for first time run of service. The subsequent run of service is running fine. Kerberos is not prompt when the SFTP location is within a network. If it is a different network it asks for Kerberos username…
naren
  • 105
  • 2
  • 13
2
votes
1 answer

Cannot coerce Array error while using map operator with XML data in mule 4?

I am getting the following error while using the map operator: org.mule.runtime.core.internal.message.ErrorBuilder$ErrorImplementation { description="Cannot coerce Array (org.mule.weave.v2.model.values.ArrayValue$IteratorArrayValue@22af825a) to…
HMT
  • 2,093
  • 1
  • 19
  • 51
2
votes
1 answer

Insert dynamic data based on array size in json mule 4

Existing JSON: { "name":"abc", "place": "äbc" } I have a separte array as below: [documentDetails:{ "name" : "doc1", "size" : "5" }, documentDetails:{ "name" : "doc1", "size" : "5" } ] Final JSON REQUIRED: { …
HMT
  • 2,093
  • 1
  • 19
  • 51
2
votes
1 answer

is it possible to Extract file name from octet stream?

I have to send an octet stream fetched from S3 through an api. I need to change the name of the file received. Does octet stream contain the name of the file ? if yes ,How can I extract the file name from the octet stream ? if no, is there any other…
HMT
  • 2,093
  • 1
  • 19
  • 51
1 2
3
77 78