SlideShare une entreprise Scribd logo
1  sur  24
Télécharger pour lire hors ligne
Patna MuleSoft Meetup Group (10th
Meetup)
DataWeave Extension Library
19th June 2022
Organizer
About:
● Working as Solution Architect at Apisero Inc.
● 11 + year of Total IT Experience. 5+ years in Mulesoft.
● Certified MuleSoft Developer and Architect.
● Mulesoft Leader and Mentor Amit Mohan
Safe Harbour Statement
● Both the speaker and the host are organizing this meet-up in individual capacity only. We are
not representing our companies here.
● This presentation is strictly for learning purposes only. Organizer/Presenter do not hold any
responsibility that same solution will work for your business requirements.
● This presentation is not meant for any promotional activities.
3
A recording of this meetup will be uploaded to events page within 24 hours.
Questions can be submitted/asked at any time in the Chat/Questions & Answers Tab.
Make it more Interactive!!!
Give us feedback! Rate this meetup session by filling feedback form at the end of the day.
We Love Feedbacks!!! Its Bread & Butter for Meetup.
Housekeeping
4
Speaker
Shyam Raj Prasad
Senior Principal Engineer
Tricon Infotech Private Limited
About:
● Working as Senior Principal Engineer at Tricon Infotech
Private Limited.
● 12+ years of Total Experience.
● 4+ years experience in Mulesoft.
● Certified MuleSoft Developer and Architect.
6
Agenda
● DataWeave
● DataWeave Library Extension
● Development of DataWeave library
● Features of Dataweave Library extension
● Packaging and deployment of DataWeave Library
● Demo
● DataWeave is the programming language designed by MuleSoft for data transformation.
● DataWeave enables you to build a simple solution for a common use case for integration developers:
read and parse data from one format, transform the data, and write it out as a different format.
● For example, a DataWeave script can receive a CSV file as input and transform it into an array of
complex JSON objects, or receive an XML input and write the data out to a flat file format.
DataWeave Language
The DataWeave extension to Visual Studio Code enhances productivity when you are building DataWeave
libraries. The extension provides the following capabilities:
● Ability to work on your DataWeave modules and mappings in a standalone manner, outside of a Mule
application.
● Instant execution of your DataWeave mappings, including live preview of data transformations.
● Language support, including autocompletion, navigation, refactoring, formatting, quick fixes, and syntax
highlighting.
● Debugging support for DataWeave mappings.
● Automatic generation of a documentation template that you can use to provide your own DataWeave
library documentation in Exchange.
● An embedded DataWeave Maven plugin with the following features:
○ Integration of packaging and deployment of your DataWeave libraries with your Maven lifecycle.
○ Integration with Exchange to share and consume DataWeave libraries.
● An embedded DataWeave testing framework that enables you to build automated unit and integration
tests easily.
DataWeave Library Extension
9
Requirements
● Java 8 or 11 provided
● Apache Maven (3.6.3 minimum)
● Microsoft Visual Studio Code for your specific operating system
● DataWeave 2.0 (BETA) library in VS code (Extensions tab)
10
Developing DataWeave Libraries
A DataWeave library is a reusable package of DataWeave module and mapping files, and
resource files, such as JSON, XML, and CSV. To develop DataWeave libraries, first create
a new DataWeave project in Visual Studio Code where you then create, preview, and test
custom mappings and modules.
If you want to try out your mapping without creating a DataWeave project, you can either
open your .dwl mapping file directly in Visual Studio Code or create a new one and use
sample data and scenarios.
DataWeave Modules and Mapping
● Dataweave modules can define functions, variables, types, and namespaces. You can import
these modules into a DataWeave script to use the features.
● Dataweave module cannot contain an output directive, body expression, or the separator (---)
between header and body sections.
● Dataweave mapping files are a type of module that contains a complete DataWeave script
that you can import and use in another DataWeave script or reference in a Mule component.
11
12
Understanding the DataWeave
Project Structure
DataWeave projects use Apache Maven to build and declare project dependencies. The following
diagram shows the DataWeave project structure:
13
DataWeave Library Extension
Features: Auto Completion
14
DataWeave Library Extension
Features: Live preview
15
DataWeave Library Extension
Features: Testing
16
DataWeave Library Extension
Features: Debugging
17
DataWeave Library Extension
Features
● Validation
● Hover
● Extract variable
● Goto definition
● Document symbols
● Formatting
● Find references
● Highlight
● Rename symbol
● Quick fixes
● Docs auto-generation
● Dependency management
18
Packaging and Deploying
DataWeave Libraries
Apache Maven plugin for DataWeave to integrate the packaging and deployment of your
DataWeave libraries with your Maven lifecycle. The plugin enables you to run six main
goals:
● compile Compiles the source code for your DataWeave library.
● test Tests the compiled source code using the DataWeave testing framework.
● data-weave:generate-docs Automatically generates the documentation for your
DataWeave library.
● package : Packages the compiled code in a .jar file.
● data-weave:deploy-docs :Uploads the auto-generated documentation for your
DataWeave library to Anypoint Exchange.
● deploy :Automatically uploads your DataWeave library to the deployment target and
uploads the auto-generated documentation to Exchange.
Demo
Q&A
Take a stand !
21
● Nominate yourself for the next meetup speaker and suggest a topic as well.
Get ready to WIN a Special Gift from MuleSoft Community
Quiz Time
23
● Share:
○ Tweet using the hashtag #MuleSoftMeetups
○ Invite your network to join: https://meetups.mulesoft.com/patna/
● Feedback:
○ Fill out the survey feedback and suggest topics for upcoming events
○ Contact MuleSoft at meetups@mulesoft.com for ways to improve the program
What’s next?
Thank you

Contenu connexe

Similaire à Dataweave_library_extension.pdf

Doing data visualizations with tableau
Doing data visualizations with tableauDoing data visualizations with tableau
Doing data visualizations with tableauRay Schwartz
 
Mule anypoint connector
Mule  anypoint connectorMule  anypoint connector
Mule anypoint connectorD.Rajesh Kumar
 
Mule anypoint connector dev kit
Mule  anypoint connector dev kitMule  anypoint connector dev kit
Mule anypoint connector dev kitD.Rajesh Kumar
 
Django app deployment in Azure By Saurabh Agarwal
Django app deployment in Azure By Saurabh AgarwalDjango app deployment in Azure By Saurabh Agarwal
Django app deployment in Azure By Saurabh Agarwalratneshsinghparihar
 
Anypoint connector dev kit
Anypoint connector dev kitAnypoint connector dev kit
Anypoint connector dev kitSon Nguyen
 
Asp Net Vs Vue JS Which One You Should Choose for Development.pdf
Asp Net Vs Vue JS Which One You Should Choose for Development.pdfAsp Net Vs Vue JS Which One You Should Choose for Development.pdf
Asp Net Vs Vue JS Which One You Should Choose for Development.pdfIntegrated IT Solutions
 
Experiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure teamExperiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure teamBrian Benz
 
Akshay_Paliwal_Lead_Developer
Akshay_Paliwal_Lead_DeveloperAkshay_Paliwal_Lead_Developer
Akshay_Paliwal_Lead_Developerakshaypaliwal23
 
Visual Studio 2008 Overview
Visual Studio 2008 OverviewVisual Studio 2008 Overview
Visual Studio 2008 OverviewRoman Okolovich
 
Database CI Demo Using Sql Server
Database CI  Demo Using Sql ServerDatabase CI  Demo Using Sql Server
Database CI Demo Using Sql ServerUmesh Kumar
 
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...Katy Slemon
 
13 - Panorama Necto 14 building models - visualization & data discovery solu...
13  - Panorama Necto 14 building models - visualization & data discovery solu...13  - Panorama Necto 14 building models - visualization & data discovery solu...
13 - Panorama Necto 14 building models - visualization & data discovery solu...Panorama Software
 
whats-new-netbeans-ide-7x.pptx
whats-new-netbeans-ide-7x.pptxwhats-new-netbeans-ide-7x.pptx
whats-new-netbeans-ide-7x.pptxGabrielSoche
 
005528214.pdf
005528214.pdf005528214.pdf
005528214.pdfEidTahir
 
1 - Introduction of Azure DevOps
1 - Introduction of Azure DevOps1 - Introduction of Azure DevOps
1 - Introduction of Azure DevOpsBhaumik Patel
 
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...WSPDC & FEDSPUG
 
235042632 super-shop-ee
235042632 super-shop-ee235042632 super-shop-ee
235042632 super-shop-eehomeworkping3
 
Installing Webpack with React JS from Scratch.pdf
Installing Webpack with React JS from Scratch.pdfInstalling Webpack with React JS from Scratch.pdf
Installing Webpack with React JS from Scratch.pdfSufalam Technologies
 

Similaire à Dataweave_library_extension.pdf (20)

Doing data visualizations with tableau
Doing data visualizations with tableauDoing data visualizations with tableau
Doing data visualizations with tableau
 
Mule tcat server
Mule  tcat serverMule  tcat server
Mule tcat server
 
Mule anypoint connector
Mule  anypoint connectorMule  anypoint connector
Mule anypoint connector
 
Mule anypoint connector dev kit
Mule  anypoint connector dev kitMule  anypoint connector dev kit
Mule anypoint connector dev kit
 
Django app deployment in Azure By Saurabh Agarwal
Django app deployment in Azure By Saurabh AgarwalDjango app deployment in Azure By Saurabh Agarwal
Django app deployment in Azure By Saurabh Agarwal
 
Anypoint connector dev kit
Anypoint connector dev kitAnypoint connector dev kit
Anypoint connector dev kit
 
Asp Net Vs Vue JS Which One You Should Choose for Development.pdf
Asp Net Vs Vue JS Which One You Should Choose for Development.pdfAsp Net Vs Vue JS Which One You Should Choose for Development.pdf
Asp Net Vs Vue JS Which One You Should Choose for Development.pdf
 
Experiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure teamExperiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure team
 
Akshay_Paliwal_Lead_Developer
Akshay_Paliwal_Lead_DeveloperAkshay_Paliwal_Lead_Developer
Akshay_Paliwal_Lead_Developer
 
Visual Studio 2008 Overview
Visual Studio 2008 OverviewVisual Studio 2008 Overview
Visual Studio 2008 Overview
 
Database CI Demo Using Sql Server
Database CI  Demo Using Sql ServerDatabase CI  Demo Using Sql Server
Database CI Demo Using Sql Server
 
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...
Top 12 Vue.js Developer Tools and Component Libraries (To Speed Up Vue.js Dev...
 
13 - Panorama Necto 14 building models - visualization & data discovery solu...
13  - Panorama Necto 14 building models - visualization & data discovery solu...13  - Panorama Necto 14 building models - visualization & data discovery solu...
13 - Panorama Necto 14 building models - visualization & data discovery solu...
 
whats-new-netbeans-ide-7x.pptx
whats-new-netbeans-ide-7x.pptxwhats-new-netbeans-ide-7x.pptx
whats-new-netbeans-ide-7x.pptx
 
005528214.pdf
005528214.pdf005528214.pdf
005528214.pdf
 
Asp.net Web Development.pdf
Asp.net Web Development.pdfAsp.net Web Development.pdf
Asp.net Web Development.pdf
 
1 - Introduction of Azure DevOps
1 - Introduction of Azure DevOps1 - Introduction of Azure DevOps
1 - Introduction of Azure DevOps
 
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...
FEDSPUG April 2014: Visual Studio 2013 for Application Lifecycle Management &...
 
235042632 super-shop-ee
235042632 super-shop-ee235042632 super-shop-ee
235042632 super-shop-ee
 
Installing Webpack with React JS from Scratch.pdf
Installing Webpack with React JS from Scratch.pdfInstalling Webpack with React JS from Scratch.pdf
Installing Webpack with React JS from Scratch.pdf
 

Dernier

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxRemote DBA Services
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistandanishmna97
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 

Dernier (20)

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 

Dataweave_library_extension.pdf

  • 1. Patna MuleSoft Meetup Group (10th Meetup) DataWeave Extension Library 19th June 2022
  • 2. Organizer About: ● Working as Solution Architect at Apisero Inc. ● 11 + year of Total IT Experience. 5+ years in Mulesoft. ● Certified MuleSoft Developer and Architect. ● Mulesoft Leader and Mentor Amit Mohan
  • 3. Safe Harbour Statement ● Both the speaker and the host are organizing this meet-up in individual capacity only. We are not representing our companies here. ● This presentation is strictly for learning purposes only. Organizer/Presenter do not hold any responsibility that same solution will work for your business requirements. ● This presentation is not meant for any promotional activities. 3
  • 4. A recording of this meetup will be uploaded to events page within 24 hours. Questions can be submitted/asked at any time in the Chat/Questions & Answers Tab. Make it more Interactive!!! Give us feedback! Rate this meetup session by filling feedback form at the end of the day. We Love Feedbacks!!! Its Bread & Butter for Meetup. Housekeeping 4
  • 5. Speaker Shyam Raj Prasad Senior Principal Engineer Tricon Infotech Private Limited About: ● Working as Senior Principal Engineer at Tricon Infotech Private Limited. ● 12+ years of Total Experience. ● 4+ years experience in Mulesoft. ● Certified MuleSoft Developer and Architect.
  • 6. 6 Agenda ● DataWeave ● DataWeave Library Extension ● Development of DataWeave library ● Features of Dataweave Library extension ● Packaging and deployment of DataWeave Library ● Demo
  • 7. ● DataWeave is the programming language designed by MuleSoft for data transformation. ● DataWeave enables you to build a simple solution for a common use case for integration developers: read and parse data from one format, transform the data, and write it out as a different format. ● For example, a DataWeave script can receive a CSV file as input and transform it into an array of complex JSON objects, or receive an XML input and write the data out to a flat file format. DataWeave Language
  • 8. The DataWeave extension to Visual Studio Code enhances productivity when you are building DataWeave libraries. The extension provides the following capabilities: ● Ability to work on your DataWeave modules and mappings in a standalone manner, outside of a Mule application. ● Instant execution of your DataWeave mappings, including live preview of data transformations. ● Language support, including autocompletion, navigation, refactoring, formatting, quick fixes, and syntax highlighting. ● Debugging support for DataWeave mappings. ● Automatic generation of a documentation template that you can use to provide your own DataWeave library documentation in Exchange. ● An embedded DataWeave Maven plugin with the following features: ○ Integration of packaging and deployment of your DataWeave libraries with your Maven lifecycle. ○ Integration with Exchange to share and consume DataWeave libraries. ● An embedded DataWeave testing framework that enables you to build automated unit and integration tests easily. DataWeave Library Extension
  • 9. 9 Requirements ● Java 8 or 11 provided ● Apache Maven (3.6.3 minimum) ● Microsoft Visual Studio Code for your specific operating system ● DataWeave 2.0 (BETA) library in VS code (Extensions tab)
  • 10. 10 Developing DataWeave Libraries A DataWeave library is a reusable package of DataWeave module and mapping files, and resource files, such as JSON, XML, and CSV. To develop DataWeave libraries, first create a new DataWeave project in Visual Studio Code where you then create, preview, and test custom mappings and modules. If you want to try out your mapping without creating a DataWeave project, you can either open your .dwl mapping file directly in Visual Studio Code or create a new one and use sample data and scenarios.
  • 11. DataWeave Modules and Mapping ● Dataweave modules can define functions, variables, types, and namespaces. You can import these modules into a DataWeave script to use the features. ● Dataweave module cannot contain an output directive, body expression, or the separator (---) between header and body sections. ● Dataweave mapping files are a type of module that contains a complete DataWeave script that you can import and use in another DataWeave script or reference in a Mule component. 11
  • 12. 12 Understanding the DataWeave Project Structure DataWeave projects use Apache Maven to build and declare project dependencies. The following diagram shows the DataWeave project structure:
  • 17. 17 DataWeave Library Extension Features ● Validation ● Hover ● Extract variable ● Goto definition ● Document symbols ● Formatting ● Find references ● Highlight ● Rename symbol ● Quick fixes ● Docs auto-generation ● Dependency management
  • 18. 18 Packaging and Deploying DataWeave Libraries Apache Maven plugin for DataWeave to integrate the packaging and deployment of your DataWeave libraries with your Maven lifecycle. The plugin enables you to run six main goals: ● compile Compiles the source code for your DataWeave library. ● test Tests the compiled source code using the DataWeave testing framework. ● data-weave:generate-docs Automatically generates the documentation for your DataWeave library. ● package : Packages the compiled code in a .jar file. ● data-weave:deploy-docs :Uploads the auto-generated documentation for your DataWeave library to Anypoint Exchange. ● deploy :Automatically uploads your DataWeave library to the deployment target and uploads the auto-generated documentation to Exchange.
  • 19. Demo
  • 20. Q&A
  • 21. Take a stand ! 21 ● Nominate yourself for the next meetup speaker and suggest a topic as well.
  • 22. Get ready to WIN a Special Gift from MuleSoft Community Quiz Time
  • 23. 23 ● Share: ○ Tweet using the hashtag #MuleSoftMeetups ○ Invite your network to join: https://meetups.mulesoft.com/patna/ ● Feedback: ○ Fill out the survey feedback and suggest topics for upcoming events ○ Contact MuleSoft at meetups@mulesoft.com for ways to improve the program What’s next?