SlideShare a Scribd company logo
All contents © MuleSoft Inc.
Welcome To MuleSoftMeetup
1
All contents © MuleSoft Inc.
Welcome To MuleSoftMeetup
2
MuleSoft Meetup Virtual
17th SeP 2020
All contents © MuleSoft Inc.
Agenda
3
6:00 PM Welcome & Introductions
6:30 PM Dataweave2.0 by Avinash Vaddi
7:15 PM Queuing with Kafka by Tom Loughran, Apisero
8:00 PM Q/A, Trivia & Event Close
All contents © MuleSoft Inc.
Announcements
Hi everyone, Thanks for joining our first virtual meetup today.
Today we are going to have talks about Dataweave 2.0 and
Queueing with KAFKA.
At the end, we will have Trivia session, where we will ask some
random questions related to the topics which we discussed
today.
First 3 winners will get a free training and certification voucher
from MuleSoft. Do not miss the opportunity…!
Without further ado, let’s get started.
All contents © MuleSoft Inc.
DataWeave 2.0
All contents © MuleSoft Inc.
What is DataWeave?
• DataWeave is a programming language designed for transforming
data.
• It is MuleSoft’s primary language for data transformation, as well as
the expression language used to configure components and
connectors.
All contents © MuleSoft Inc.
• DataWeave files are categorized into two main sections:
1. Header -> Which defined directives
2. Body ----> Which describes output structure
7
When you include a header, the header appears above the body separated by a delimiter consisting of three dashes: ---.
Here is an example of a DataWeave file with an output directive declared in the header,
followed by a DataWeave expression to create a user object that contains two child key/value pairs:
Example:
Simple DataWeave Script
%dw 2.0
output application/xml
---
{
user:
{
firstName: payload.user_firstname,
lastName: payload.user_lastName
}
}
All contents © MuleSoft Inc.
• DataWeave supports DataSense i.e., metadata from connectors,
schemas, and sample documents is available to more easily design
transformations.
• It also provides content assist while you are coding and auto
generates lines of code from actions performed on UI.
8
e.g. If we drag and drop element from input section onto another element in output section, then corresponding code is automatically generated.
If you add the Transform Message component in your Mule flow, its Properties view looks like this:
All contents © MuleSoft Inc. 9
The Graphical UI
The Graphical UI exposes the known input and output structures. You can easily click and drag one field onto another to map these structures.
You can do following through the UI:
1.Drag an element from the input structure over to another on the output structure.
2.This casts a line that joins them and also generates necessary lines of DataWeave code that describes this mapping.
All contents © MuleSoft Inc.
Migrating from DataWeave version 1 to 2
DataWeave 1.0 DataWeave 2.0
%dw 1.0 %dw 2.0
%output output
%var var
%function fun
%namespace ns
DataWeave Header Content
Apart from syntax changes, there are many new features in
DataWeave 2.0.
• Language simplifications. Everything is now a function.
• DataWeave scripts can now be packaged and reused, via
the new imports and modules features.
• Support for multi-line comments.
• Support for calling static Java functions directly from
DataWeave.
All contents © MuleSoft Inc.
When Otherwise
The when otherwise statement is replaced by if else, for example:
Mule 3 Example: DataWeave 1
{ orderStatus: "complete" when flowVars.purchaseOrderStatus == "C" otherwise "incomplete" }
Mule 4 Example: DataWeave 2
{ orderStatus: if(vars.purchaseOrderStatus == "C") "complete" else "incomplete" }
Pattern Matcher:
For pattern matching now you can use case and else keyword instead of default.
Mule 3 Example: DataWeave 1'world' match { :string -> true, default -> false }
Mule 4 Example: DataWeave 2'world' match { case is String -> true else -> false }
All contents © MuleSoft Inc. 12
Removing Coercion:
DataWeave 2.0 has removed coercion and a new selector & is presented to select key-value pairs.
Mule 3 Example: DataWeave 1%var payload = {a: 1, b: 2} --- payload.a as: object
Mule 4 Example: DataWeave 2var payload = {a: 1, b:2} --- payload.&a}
Type References
The : was removed from the type references and are now all camel case, so :string is now String
All contents © MuleSoft Inc.
DataWeave 1.0 payload.foo as :string
DataWeave 2.0 payload.foo as String
Type Names
Operators Are Now Functions
DataWeave 1 sizeOf payload filter $.age > 30
DataWeave 2 - Function Syntax
sizeOf(filter(payload, (value) →
value.age > 30)))
DataWeave 2 - Shortcut Syntax sizeOf(payload filter $.age > 30)
All contents © MuleSoft Inc.
XML Format
The default for the reader property nullValueOn is empty for DataWeave 2.0.
For DataWeave 1.0 (which is compatible with Mule 3.x), the value is none, for example:
DataWeave Script
%dw 1.0 %output application/xml nullValueOn="none" --- payload
Input
<book>
<name></name>
</book>
Output
<book/>
All contents © MuleSoft Inc.
Scripting
15
Concatenate Two Strings into a Single String
Begin with a simple DataWeave script that
concatenates two strings ("hello" and "World")
together into a single string ("helloWorld").
All contents © MuleSoft Inc.
• Transform JSON Input to XML Output
16
Many integrations require transformations from one format to another. This procedure uses the output directive to produce XML output from JSON input.
All contents © MuleSoft Inc.
Defining and Using a DataWeave Variable as Input
%dw 2.0
var myJson = { "hello" : "world" }
output application/json
---
myJson
Output:
{
"hello": "world"
}
17
All contents © MuleSoft Inc. 18
Use a DataWeave Function in a DataWeave Variable
All contents © MuleSoft Inc.
• Map Elements from an Array into an Object
19
Output:
All contents © MuleSoft Inc.
Functions
In DataWeave 2.0, functions are categorized into different modules:
• Core (dw::Core)
• Arrays (dw::core::Arrays)
• Binaries (dw::core::Binaries)
• Encryption (dw::Crypto)
• Diff (dw::util::Diff)
• Objects (dw::core::Objects)
• Runtime (dw::Runtime)
• Strings (dw::core::Strings)
• System (dw::System)
• URL (dw::core::URL)
20
All contents © MuleSoft Inc.
Functions (Cont..)
21
Functions defined in Core (dw::Core) module are imported automatically into your DataWeave scripts.
To use other modules, we need to import them by adding the import directive to the head of
DataWeave script, for example:
import dw::core::Strings
import dasherize, underscore from dw::core::Strings
import * from dw::core::Strings
All contents © MuleSoft Inc.
Functions to work with Arrays
22
All contents © MuleSoft Inc.
DataWeave playground
• Use this address in browser to access the dataweave playground in
browser: 34.205.75.56:8081
• Using docker: https://www.prostdev.com/post/how-to-run-locally-
the-dataweave-playground-docker-
image?fbclid=IwAR2yOGsGLyATJIWxJvZfidHVs5rt1wLo8zN1_puAYwD
RoLnYohhTqFlU_xw
23
All contents © MuleSoft Inc.
All contents © MuleSoft Inc.
Q/A ?
25
All contents © MuleSoft Inc.
Trivia 1
When you flatten the payload it returns object in Dataweave 2.0?
a) True
b) False
26
All contents © MuleSoft Inc.
Trivia 2
What is the use of Map object in Dataweave 2.0 ?
a) Used to iterate over array.
b) Used to iterate over object and return object.
c) Turns nested into simple array.
d) None of the above.
27
All contents © MuleSoft Inc.
Trivia 3
Can we reuse Dataweave scripts, if so how to reuse them in in Dataweave 2.0?
a) Dataweave scripts can not be re used in dataweave 2.0.
b) It can be reused using lookup functions
c) It can be reused using imports and module features
d) None of the above
28
All contents © MuleSoft Inc.
Trivia 4
How to define a function in dataweave 2.0?
a) fun.
b) %function
c) %fun
d) None of the above
29
All contents © MuleSoft Inc.
Trivia 5
Why KAFKA is so fast? Please select the wrong answer from below options
a) Process the batch data in Chunks.
b) Zero Copy, calls the OS kernel direct
c) Supports Random Disk Access
d) Supports horizontal scaling
30
All contents © MuleSoft Inc.
Trivia 6
KAFKA brokers can maintain the cluster state
a) True.
b) False
31
All contents © MuleSoft Inc.
Trivia 7
As you know KAFKA is widely used in many social media websites. Please pick from below one, which is
not using KAFKA?
a) Tinder.
b) Twitter
c) TikTok
d) Facebook
32
All contents © MuleSoft Inc.
Trivia 8
What is the replacement of the when and otherwise in dataweave 2.0?
33
Explore our new version
MuleSoft Documentation
All contents © MuleSoft Inc.
Find the answers you need, fast.
35https://docs.mulesoft.com/
The best place to ask questions and help others.
MuleSoft Help Center
All contents © MuleSoft Inc.
15,000+ members ready to help.
37
https://help.mulesoft.com/
• Check out the “MuleSoft
Training” category for all
training and certification-
related questions
All contents © MuleSoft Inc.
Join Charlotte MuleSoft Discussion Group.
38
https://help.mulesoft.com/s/
group/0F92T0000004odaSAA
/charlotte-meetups
• Check out the “Charlotte
MuleSoft Discussion Group.”
category for all your
questions which you want
to discuss within the
Charlotte Group.
All contents © MuleSoft Inc.
Take a stand !
39
• Nominate yourself for the next meetup
speaker and suggest a topic as well.
All contents © MuleSoft Inc.
What’s next
40
• Feedback:
– Contact your organizer Subhash Patel, Aravind Ramadugu or Savannah
Williamson to suggest topics.
– Contact MuleSoft at meetup@mulesoft.com for ways to improve the program.
All contents © MuleSoft Inc.
Please Tweet
41
Nominate yourself for the next meetup speaker and suggest a topic as well.
Tweet your pictures with the hashtag #MuleSoftMeetup
Thank you

More Related Content

What's hot

MuleSoft Meetup Virtual_ 2_Charlotte
MuleSoft Meetup Virtual_ 2_CharlotteMuleSoft Meetup Virtual_ 2_Charlotte
MuleSoft Meetup Virtual_ 2_Charlotte
Subhash Patel
 
MuleSoft Meetup Mumbai Mule 4 Presentation Slide
MuleSoft Meetup Mumbai Mule 4 Presentation SlideMuleSoft Meetup Mumbai Mule 4 Presentation Slide
MuleSoft Meetup Mumbai Mule 4 Presentation Slide
Manish Kumar Yadav
 
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
Manish Kumar Yadav
 
Mule soft meetup_virtual_ 3_charlotte_07july_2021__final
Mule soft meetup_virtual_ 3_charlotte_07july_2021__finalMule soft meetup_virtual_ 3_charlotte_07july_2021__final
Mule soft meetup_virtual_ 3_charlotte_07july_2021__final
Subhash Patel
 
MuleSoft Clustring, Okta, CI/CD Integration with Jenkins
MuleSoft Clustring, Okta, CI/CD Integration with JenkinsMuleSoft Clustring, Okta, CI/CD Integration with Jenkins
MuleSoft Clustring, Okta, CI/CD Integration with Jenkins
Manish Kumar Yadav
 
Pune Mule Meetups July 2019
Pune Mule Meetups July 2019Pune Mule Meetups July 2019
Pune Mule Meetups July 2019
Santosh Ojha
 
A comprehensive guide to mule soft mule 4
A comprehensive guide to mule soft mule 4A comprehensive guide to mule soft mule 4
A comprehensive guide to mule soft mule 4
pruthviraj krishnam
 
Meet up slides_mumbai_21032020_final
Meet up slides_mumbai_21032020_finalMeet up slides_mumbai_21032020_final
Meet up slides_mumbai_21032020_final
Akshata Sawant
 
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load BalancerNashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
Jitendra Bafna
 
Virtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and LoggingVirtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and Logging
Jimmy Attia
 
Mulesoft meetup slides mumbai_20113019_exception_handling
Mulesoft meetup slides mumbai_20113019_exception_handlingMulesoft meetup slides mumbai_20113019_exception_handling
Mulesoft meetup slides mumbai_20113019_exception_handling
Manish Kumar Yadav
 
Mumbai MuleSoft Meetup 11
Mumbai MuleSoft Meetup 11Mumbai MuleSoft Meetup 11
Mumbai MuleSoft Meetup 11
Akshata Sawant
 
MuleSoft Manchester Meetup #2 slides 29th October 2019
MuleSoft Manchester Meetup #2 slides 29th October 2019MuleSoft Manchester Meetup #2 slides 29th October 2019
MuleSoft Manchester Meetup #2 slides 29th October 2019
Ieva Navickaite
 
Meetup hyderabad mule-4.x
Meetup hyderabad mule-4.xMeetup hyderabad mule-4.x
Meetup hyderabad mule-4.x
Santosh Ojha
 
MuleSoft meetup_sg_no2_may19
MuleSoft meetup_sg_no2_may19MuleSoft meetup_sg_no2_may19
MuleSoft meetup_sg_no2_may19
Julian Douch
 
Manila MuleSoft Meetup - September 2018
Manila MuleSoft Meetup - September 2018Manila MuleSoft Meetup - September 2018
Manila MuleSoft Meetup - September 2018
Ryan Anthony Andal
 
Warsaw MuleSoft Meetup - Runtime Fabric
Warsaw MuleSoft Meetup - Runtime FabricWarsaw MuleSoft Meetup - Runtime Fabric
Warsaw MuleSoft Meetup - Runtime Fabric
Patryk Bandurski
 
Manila MuleSoft Meetup - July 2019
Manila MuleSoft Meetup - July 2019Manila MuleSoft Meetup - July 2019
Manila MuleSoft Meetup - July 2019
Ryan Anthony Andal
 
Manchester Meetup #3
Manchester Meetup #3Manchester Meetup #3
Manchester Meetup #3
Francis Edwards
 
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
Angel Alberici
 

What's hot (20)

MuleSoft Meetup Virtual_ 2_Charlotte
MuleSoft Meetup Virtual_ 2_CharlotteMuleSoft Meetup Virtual_ 2_Charlotte
MuleSoft Meetup Virtual_ 2_Charlotte
 
MuleSoft Meetup Mumbai Mule 4 Presentation Slide
MuleSoft Meetup Mumbai Mule 4 Presentation SlideMuleSoft Meetup Mumbai Mule 4 Presentation Slide
MuleSoft Meetup Mumbai Mule 4 Presentation Slide
 
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
Clustering, Server setup and Hybrid deployment setup using Anypoint Runtime M...
 
Mule soft meetup_virtual_ 3_charlotte_07july_2021__final
Mule soft meetup_virtual_ 3_charlotte_07july_2021__finalMule soft meetup_virtual_ 3_charlotte_07july_2021__final
Mule soft meetup_virtual_ 3_charlotte_07july_2021__final
 
MuleSoft Clustring, Okta, CI/CD Integration with Jenkins
MuleSoft Clustring, Okta, CI/CD Integration with JenkinsMuleSoft Clustring, Okta, CI/CD Integration with Jenkins
MuleSoft Clustring, Okta, CI/CD Integration with Jenkins
 
Pune Mule Meetups July 2019
Pune Mule Meetups July 2019Pune Mule Meetups July 2019
Pune Mule Meetups July 2019
 
A comprehensive guide to mule soft mule 4
A comprehensive guide to mule soft mule 4A comprehensive guide to mule soft mule 4
A comprehensive guide to mule soft mule 4
 
Meet up slides_mumbai_21032020_final
Meet up slides_mumbai_21032020_finalMeet up slides_mumbai_21032020_final
Meet up slides_mumbai_21032020_final
 
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load BalancerNashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
Nashik MuleSoft Virtual Meetup#1 - Shared and Dedicated Load Balancer
 
Virtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and LoggingVirtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and Logging
 
Mulesoft meetup slides mumbai_20113019_exception_handling
Mulesoft meetup slides mumbai_20113019_exception_handlingMulesoft meetup slides mumbai_20113019_exception_handling
Mulesoft meetup slides mumbai_20113019_exception_handling
 
Mumbai MuleSoft Meetup 11
Mumbai MuleSoft Meetup 11Mumbai MuleSoft Meetup 11
Mumbai MuleSoft Meetup 11
 
MuleSoft Manchester Meetup #2 slides 29th October 2019
MuleSoft Manchester Meetup #2 slides 29th October 2019MuleSoft Manchester Meetup #2 slides 29th October 2019
MuleSoft Manchester Meetup #2 slides 29th October 2019
 
Meetup hyderabad mule-4.x
Meetup hyderabad mule-4.xMeetup hyderabad mule-4.x
Meetup hyderabad mule-4.x
 
MuleSoft meetup_sg_no2_may19
MuleSoft meetup_sg_no2_may19MuleSoft meetup_sg_no2_may19
MuleSoft meetup_sg_no2_may19
 
Manila MuleSoft Meetup - September 2018
Manila MuleSoft Meetup - September 2018Manila MuleSoft Meetup - September 2018
Manila MuleSoft Meetup - September 2018
 
Warsaw MuleSoft Meetup - Runtime Fabric
Warsaw MuleSoft Meetup - Runtime FabricWarsaw MuleSoft Meetup - Runtime Fabric
Warsaw MuleSoft Meetup - Runtime Fabric
 
Manila MuleSoft Meetup - July 2019
Manila MuleSoft Meetup - July 2019Manila MuleSoft Meetup - July 2019
Manila MuleSoft Meetup - July 2019
 
Manchester Meetup #3
Manchester Meetup #3Manchester Meetup #3
Manchester Meetup #3
 
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
Mule 4 migration + Common Integration Challenges : MuleSoft Virtual Muleys Me...
 

Similar to Mule soft meetup_virtual_ charlotte_2020_final1

20230721_OKC_Meetup_MuleSoft.pptx
20230721_OKC_Meetup_MuleSoft.pptx20230721_OKC_Meetup_MuleSoft.pptx
20230721_OKC_Meetup_MuleSoft.pptx
DianeKesler1
 
Using prime[31] to connect your unity game to azure mobile services
Using prime[31] to connect your unity game to azure mobile servicesUsing prime[31] to connect your unity game to azure mobile services
Using prime[31] to connect your unity game to azure mobile services
David Voyles
 
MuleSoft Meetup Warsaw Group #1
MuleSoft  Meetup Warsaw Group #1MuleSoft  Meetup Warsaw Group #1
MuleSoft Meetup Warsaw Group #1
Patryk Bandurski
 
MuleSoft Manchester Meetup #3 slides 31st March 2020
MuleSoft Manchester Meetup #3 slides 31st March 2020MuleSoft Manchester Meetup #3 slides 31st March 2020
MuleSoft Manchester Meetup #3 slides 31st March 2020
Ieva Navickaite
 
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
Jitendra Bafna
 
Data herding
Data herdingData herding
Data herding
unbracketed
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using Telegraf
InfluxData
 
Spring boot
Spring bootSpring boot
Spring boot
sdeeg
 
AngularJS for Web and Mobile
 AngularJS for Web and Mobile AngularJS for Web and Mobile
AngularJS for Web and Mobile
Rocket Software
 
Asp net interview_questions
Asp net interview_questionsAsp net interview_questions
Asp net interview_questions
Ghazi Anwar
 
Asp net interview_questions
Asp net interview_questionsAsp net interview_questions
Asp net interview_questionsBilam
 
Mulesoftmeetup4th july
Mulesoftmeetup4th julyMulesoftmeetup4th july
Mulesoftmeetup4th july
Anurag Dwivedi
 
Sql interview question part 10
Sql interview question part 10Sql interview question part 10
Sql interview question part 10
kaashiv1
 
Dataweave Libraries and ObjectStore
Dataweave Libraries and ObjectStoreDataweave Libraries and ObjectStore
Dataweave Libraries and ObjectStore
Vikalp Bhalia
 
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
Jitendra Bafna
 
An Introduction to Dashing and Smashing
An Introduction to Dashing and SmashingAn Introduction to Dashing and Smashing
An Introduction to Dashing and Smashing
Kunal Saha
 
How to Architect and Develop Cloud Native Applications
How to Architect and Develop Cloud Native ApplicationsHow to Architect and Develop Cloud Native Applications
How to Architect and Develop Cloud Native Applications
Sufyaan Kazi
 
Visual Basic.Net & Ado.Net
Visual Basic.Net & Ado.NetVisual Basic.Net & Ado.Net
Visual Basic.Net & Ado.Net
FaRid Adwa
 

Similar to Mule soft meetup_virtual_ charlotte_2020_final1 (20)

20230721_OKC_Meetup_MuleSoft.pptx
20230721_OKC_Meetup_MuleSoft.pptx20230721_OKC_Meetup_MuleSoft.pptx
20230721_OKC_Meetup_MuleSoft.pptx
 
Using prime[31] to connect your unity game to azure mobile services
Using prime[31] to connect your unity game to azure mobile servicesUsing prime[31] to connect your unity game to azure mobile services
Using prime[31] to connect your unity game to azure mobile services
 
MuleSoft Meetup Warsaw Group #1
MuleSoft  Meetup Warsaw Group #1MuleSoft  Meetup Warsaw Group #1
MuleSoft Meetup Warsaw Group #1
 
MuleSoft Manchester Meetup #3 slides 31st March 2020
MuleSoft Manchester Meetup #3 slides 31st March 2020MuleSoft Manchester Meetup #3 slides 31st March 2020
MuleSoft Manchester Meetup #3 slides 31st March 2020
 
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
 
Data herding
Data herdingData herding
Data herding
 
Data herding
Data herdingData herding
Data herding
 
Taming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using TelegrafTaming the Tiger: Tips and Tricks for Using Telegraf
Taming the Tiger: Tips and Tricks for Using Telegraf
 
Spring boot
Spring bootSpring boot
Spring boot
 
AngularJS for Web and Mobile
 AngularJS for Web and Mobile AngularJS for Web and Mobile
AngularJS for Web and Mobile
 
Asp net interview_questions
Asp net interview_questionsAsp net interview_questions
Asp net interview_questions
 
Asp net interview_questions
Asp net interview_questionsAsp net interview_questions
Asp net interview_questions
 
Mulesoftmeetup4th july
Mulesoftmeetup4th julyMulesoftmeetup4th july
Mulesoftmeetup4th july
 
Sql interview question part 10
Sql interview question part 10Sql interview question part 10
Sql interview question part 10
 
Ebook10
Ebook10Ebook10
Ebook10
 
Dataweave Libraries and ObjectStore
Dataweave Libraries and ObjectStoreDataweave Libraries and ObjectStore
Dataweave Libraries and ObjectStore
 
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
MuleSoft Surat Virtual Meetup#27 - MuleSoft Runtime 4.4, Transit Gateway and ...
 
An Introduction to Dashing and Smashing
An Introduction to Dashing and SmashingAn Introduction to Dashing and Smashing
An Introduction to Dashing and Smashing
 
How to Architect and Develop Cloud Native Applications
How to Architect and Develop Cloud Native ApplicationsHow to Architect and Develop Cloud Native Applications
How to Architect and Develop Cloud Native Applications
 
Visual Basic.Net & Ado.Net
Visual Basic.Net & Ado.NetVisual Basic.Net & Ado.Net
Visual Basic.Net & Ado.Net
 

Recently uploaded

Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Globus
 
First Steps with Globus Compute Multi-User Endpoints
First Steps with Globus Compute Multi-User EndpointsFirst Steps with Globus Compute Multi-User Endpoints
First Steps with Globus Compute Multi-User Endpoints
Globus
 
Enterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptxEnterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptx
QuickwayInfoSystems3
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Natan Silnitsky
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
rickgrimesss22
 
Pro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp BookPro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp Book
abdulrafaychaudhry
 
APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)
Boni García
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Shahin Sheidaei
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
e20449
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
Globus
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
Globus
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
Donna Lenk
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
AMB-Review
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Globus
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
Globus
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus
 
Introduction to Pygame (Lecture 7 Python Game Development)
Introduction to Pygame (Lecture 7 Python Game Development)Introduction to Pygame (Lecture 7 Python Game Development)
Introduction to Pygame (Lecture 7 Python Game Development)
abdulrafaychaudhry
 

Recently uploaded (20)

Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
 
First Steps with Globus Compute Multi-User Endpoints
First Steps with Globus Compute Multi-User EndpointsFirst Steps with Globus Compute Multi-User Endpoints
First Steps with Globus Compute Multi-User Endpoints
 
Enterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptxEnterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptx
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
 
Pro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp BookPro Unity Game Development with C-sharp Book
Pro Unity Game Development with C-sharp Book
 
APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
 
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdfDominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
Dominate Social Media with TubeTrivia AI’s Addictive Quiz Videos.pdf
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
 
Introduction to Pygame (Lecture 7 Python Game Development)
Introduction to Pygame (Lecture 7 Python Game Development)Introduction to Pygame (Lecture 7 Python Game Development)
Introduction to Pygame (Lecture 7 Python Game Development)
 

Mule soft meetup_virtual_ charlotte_2020_final1

  • 1. All contents © MuleSoft Inc. Welcome To MuleSoftMeetup 1
  • 2. All contents © MuleSoft Inc. Welcome To MuleSoftMeetup 2 MuleSoft Meetup Virtual 17th SeP 2020
  • 3. All contents © MuleSoft Inc. Agenda 3 6:00 PM Welcome & Introductions 6:30 PM Dataweave2.0 by Avinash Vaddi 7:15 PM Queuing with Kafka by Tom Loughran, Apisero 8:00 PM Q/A, Trivia & Event Close
  • 4. All contents © MuleSoft Inc. Announcements Hi everyone, Thanks for joining our first virtual meetup today. Today we are going to have talks about Dataweave 2.0 and Queueing with KAFKA. At the end, we will have Trivia session, where we will ask some random questions related to the topics which we discussed today. First 3 winners will get a free training and certification voucher from MuleSoft. Do not miss the opportunity…! Without further ado, let’s get started.
  • 5. All contents © MuleSoft Inc. DataWeave 2.0
  • 6. All contents © MuleSoft Inc. What is DataWeave? • DataWeave is a programming language designed for transforming data. • It is MuleSoft’s primary language for data transformation, as well as the expression language used to configure components and connectors.
  • 7. All contents © MuleSoft Inc. • DataWeave files are categorized into two main sections: 1. Header -> Which defined directives 2. Body ----> Which describes output structure 7 When you include a header, the header appears above the body separated by a delimiter consisting of three dashes: ---. Here is an example of a DataWeave file with an output directive declared in the header, followed by a DataWeave expression to create a user object that contains two child key/value pairs: Example: Simple DataWeave Script %dw 2.0 output application/xml --- { user: { firstName: payload.user_firstname, lastName: payload.user_lastName } }
  • 8. All contents © MuleSoft Inc. • DataWeave supports DataSense i.e., metadata from connectors, schemas, and sample documents is available to more easily design transformations. • It also provides content assist while you are coding and auto generates lines of code from actions performed on UI. 8 e.g. If we drag and drop element from input section onto another element in output section, then corresponding code is automatically generated. If you add the Transform Message component in your Mule flow, its Properties view looks like this:
  • 9. All contents © MuleSoft Inc. 9 The Graphical UI The Graphical UI exposes the known input and output structures. You can easily click and drag one field onto another to map these structures. You can do following through the UI: 1.Drag an element from the input structure over to another on the output structure. 2.This casts a line that joins them and also generates necessary lines of DataWeave code that describes this mapping.
  • 10. All contents © MuleSoft Inc. Migrating from DataWeave version 1 to 2 DataWeave 1.0 DataWeave 2.0 %dw 1.0 %dw 2.0 %output output %var var %function fun %namespace ns DataWeave Header Content Apart from syntax changes, there are many new features in DataWeave 2.0. • Language simplifications. Everything is now a function. • DataWeave scripts can now be packaged and reused, via the new imports and modules features. • Support for multi-line comments. • Support for calling static Java functions directly from DataWeave.
  • 11. All contents © MuleSoft Inc. When Otherwise The when otherwise statement is replaced by if else, for example: Mule 3 Example: DataWeave 1 { orderStatus: "complete" when flowVars.purchaseOrderStatus == "C" otherwise "incomplete" } Mule 4 Example: DataWeave 2 { orderStatus: if(vars.purchaseOrderStatus == "C") "complete" else "incomplete" } Pattern Matcher: For pattern matching now you can use case and else keyword instead of default. Mule 3 Example: DataWeave 1'world' match { :string -> true, default -> false } Mule 4 Example: DataWeave 2'world' match { case is String -> true else -> false }
  • 12. All contents © MuleSoft Inc. 12 Removing Coercion: DataWeave 2.0 has removed coercion and a new selector & is presented to select key-value pairs. Mule 3 Example: DataWeave 1%var payload = {a: 1, b: 2} --- payload.a as: object Mule 4 Example: DataWeave 2var payload = {a: 1, b:2} --- payload.&a} Type References The : was removed from the type references and are now all camel case, so :string is now String
  • 13. All contents © MuleSoft Inc. DataWeave 1.0 payload.foo as :string DataWeave 2.0 payload.foo as String Type Names Operators Are Now Functions DataWeave 1 sizeOf payload filter $.age > 30 DataWeave 2 - Function Syntax sizeOf(filter(payload, (value) → value.age > 30))) DataWeave 2 - Shortcut Syntax sizeOf(payload filter $.age > 30)
  • 14. All contents © MuleSoft Inc. XML Format The default for the reader property nullValueOn is empty for DataWeave 2.0. For DataWeave 1.0 (which is compatible with Mule 3.x), the value is none, for example: DataWeave Script %dw 1.0 %output application/xml nullValueOn="none" --- payload Input <book> <name></name> </book> Output <book/>
  • 15. All contents © MuleSoft Inc. Scripting 15 Concatenate Two Strings into a Single String Begin with a simple DataWeave script that concatenates two strings ("hello" and "World") together into a single string ("helloWorld").
  • 16. All contents © MuleSoft Inc. • Transform JSON Input to XML Output 16 Many integrations require transformations from one format to another. This procedure uses the output directive to produce XML output from JSON input.
  • 17. All contents © MuleSoft Inc. Defining and Using a DataWeave Variable as Input %dw 2.0 var myJson = { "hello" : "world" } output application/json --- myJson Output: { "hello": "world" } 17
  • 18. All contents © MuleSoft Inc. 18 Use a DataWeave Function in a DataWeave Variable
  • 19. All contents © MuleSoft Inc. • Map Elements from an Array into an Object 19 Output:
  • 20. All contents © MuleSoft Inc. Functions In DataWeave 2.0, functions are categorized into different modules: • Core (dw::Core) • Arrays (dw::core::Arrays) • Binaries (dw::core::Binaries) • Encryption (dw::Crypto) • Diff (dw::util::Diff) • Objects (dw::core::Objects) • Runtime (dw::Runtime) • Strings (dw::core::Strings) • System (dw::System) • URL (dw::core::URL) 20
  • 21. All contents © MuleSoft Inc. Functions (Cont..) 21 Functions defined in Core (dw::Core) module are imported automatically into your DataWeave scripts. To use other modules, we need to import them by adding the import directive to the head of DataWeave script, for example: import dw::core::Strings import dasherize, underscore from dw::core::Strings import * from dw::core::Strings
  • 22. All contents © MuleSoft Inc. Functions to work with Arrays 22
  • 23. All contents © MuleSoft Inc. DataWeave playground • Use this address in browser to access the dataweave playground in browser: 34.205.75.56:8081 • Using docker: https://www.prostdev.com/post/how-to-run-locally- the-dataweave-playground-docker- image?fbclid=IwAR2yOGsGLyATJIWxJvZfidHVs5rt1wLo8zN1_puAYwD RoLnYohhTqFlU_xw 23
  • 24. All contents © MuleSoft Inc.
  • 25. All contents © MuleSoft Inc. Q/A ? 25
  • 26. All contents © MuleSoft Inc. Trivia 1 When you flatten the payload it returns object in Dataweave 2.0? a) True b) False 26
  • 27. All contents © MuleSoft Inc. Trivia 2 What is the use of Map object in Dataweave 2.0 ? a) Used to iterate over array. b) Used to iterate over object and return object. c) Turns nested into simple array. d) None of the above. 27
  • 28. All contents © MuleSoft Inc. Trivia 3 Can we reuse Dataweave scripts, if so how to reuse them in in Dataweave 2.0? a) Dataweave scripts can not be re used in dataweave 2.0. b) It can be reused using lookup functions c) It can be reused using imports and module features d) None of the above 28
  • 29. All contents © MuleSoft Inc. Trivia 4 How to define a function in dataweave 2.0? a) fun. b) %function c) %fun d) None of the above 29
  • 30. All contents © MuleSoft Inc. Trivia 5 Why KAFKA is so fast? Please select the wrong answer from below options a) Process the batch data in Chunks. b) Zero Copy, calls the OS kernel direct c) Supports Random Disk Access d) Supports horizontal scaling 30
  • 31. All contents © MuleSoft Inc. Trivia 6 KAFKA brokers can maintain the cluster state a) True. b) False 31
  • 32. All contents © MuleSoft Inc. Trivia 7 As you know KAFKA is widely used in many social media websites. Please pick from below one, which is not using KAFKA? a) Tinder. b) Twitter c) TikTok d) Facebook 32
  • 33. All contents © MuleSoft Inc. Trivia 8 What is the replacement of the when and otherwise in dataweave 2.0? 33
  • 34. Explore our new version MuleSoft Documentation
  • 35. All contents © MuleSoft Inc. Find the answers you need, fast. 35https://docs.mulesoft.com/
  • 36. The best place to ask questions and help others. MuleSoft Help Center
  • 37. All contents © MuleSoft Inc. 15,000+ members ready to help. 37 https://help.mulesoft.com/ • Check out the “MuleSoft Training” category for all training and certification- related questions
  • 38. All contents © MuleSoft Inc. Join Charlotte MuleSoft Discussion Group. 38 https://help.mulesoft.com/s/ group/0F92T0000004odaSAA /charlotte-meetups • Check out the “Charlotte MuleSoft Discussion Group.” category for all your questions which you want to discuss within the Charlotte Group.
  • 39. All contents © MuleSoft Inc. Take a stand ! 39 • Nominate yourself for the next meetup speaker and suggest a topic as well.
  • 40. All contents © MuleSoft Inc. What’s next 40 • Feedback: – Contact your organizer Subhash Patel, Aravind Ramadugu or Savannah Williamson to suggest topics. – Contact MuleSoft at meetup@mulesoft.com for ways to improve the program.
  • 41. All contents © MuleSoft Inc. Please Tweet 41 Nominate yourself for the next meetup speaker and suggest a topic as well. Tweet your pictures with the hashtag #MuleSoftMeetup