SlideShare a Scribd company logo
INPUT AND OUTPUT
FLOW: USING HTTP AND
JAVA COMPONENT
OPEN ANYPOINT STUDIO
CREATE A FILE  NEW  MULE PROJECT
CLICK «FINISH»
EXPAND THE «MYFIRSTPROJECT» ON PACKAGE EXPLORER
DOUBLE CLICK ON MYFIRSTPROJECT.XML
ONCE FILE IS OPEN, SHOW MESSAGE FLOW
FROM MULE PALETTE VIEW, SEARCH FOR ‘HTTP’ AND ‘JAVA’ AND SELECT THE FIRST ONE.
DRAG AND DROP HTTP THEN JAVA COMPONENT INTO MESSAGE FLOW VIEW.
NOW WE HAVE TO CONFIGURE LISTENER FOR OUR HTTP FLOW.
DOUBLE CLICK ON HTTP BLUE ELEMENT.
BELOW IT WILL APPEAR HTTP VIEW.
ON THE GENERAL SETTING LET’S CREATE AND CHOOSE AN HTTP LISTENER.
CLICK ON ADD(+) AND CONFIGURE:
HOST: DEFAULT (LOCALHOST)
PORT: 8081
ON BASIC SETTINGS DEFINE WEB SERVICE:
PATH: /FILETRANSFER
ALLOW.METHODS: GET
CLICK OK AND SAVE
NOW WE HAVE TO CONFIGURE THE JAVA LOGIC COMPONENT.
CREATE A PACKAGE AND A JAVA CLASS UNDER SRC/MAIN/JAVA FOLDER.
CREATE A LOCAL FOLDER TO SAVE THE FILE.
THE CLASS WILL CREATE A SIMPLE TEXT FILE AND WRITE TWO LINES.
LIBRARIES I USED:
JAVA.IO.FILE;
JAVA.IO.FILEWRITER;
CLICK ON SAVE AT TOP-LEFT OF SCREEN
CONFIGURE JAVA
COMPONENT.
TRANSFORMER CLASS: THE
CLASS THAT WILL DO THE
LOGIC TO CREATE A FILE IN A
LOCAL FOLDER.
CLICK ON SAVE.
NOW WE CAN START OUR MULE
SERVER
RIGHT CLICK ON PROJECT
RUN AS  MULE APPLICATION
ON THE CONSOLE VIEW BELOW
SERVER IS GOING TO START.
AT THE END YOU WILL SEE THE
STATUS DEPLOYED.
THIS MEANS THAT SERVER IS UP
AND RUNNING
OPEN YOUR BROWSER AND JOIN
THE HTTP PATH:
HTTP://LOCALHOST:8081/FILETRA
NSFER
NOW WE CAN SEE THE RESULT:
OPEN THE FOLDER WE CREATED
AND LOOK AT THE TXT FILE
GENERATED.
ENJOY
WITH

More Related Content

PPTX
Input and output flow using file and logger component
PPTX
Caching & validating
PPTX
Compress and decompress
PPTX
Encrypting/Decrypting mule
PPTX
Mule esb add logger to existing flow
ODP
Mule ESB SMTP Connector Integration
PPTX
Mulesoft Using Groovy Component
PPTX
Mule esb db_2
Input and output flow using file and logger component
Caching & validating
Compress and decompress
Encrypting/Decrypting mule
Mule esb add logger to existing flow
Mule ESB SMTP Connector Integration
Mulesoft Using Groovy Component
Mule esb db_2

What's hot (15)

PPTX
Mule esb db_1
PDF
MuleSoft ESB Message Enricher
PPTX
Mule Esb Data Weave
PPTX
Compressing & decompressing in mule
PPTX
Mule message enricher
PPTX
Using message enricher
PPTX
Groovy example in mule
PPTX
Initialize database in Mule part2
PPT
Simple Java component in Mule
PPTX
Configurare https mule
PPTX
Caching and invalidating with managed store
PPTX
Junit in mule demo
PPTX
Mule esb - How to use Idempotent Filters in 5 minutes
PPTX
Mule esb :Data Weave
PPTX
Splitting with mule part2
Mule esb db_1
MuleSoft ESB Message Enricher
Mule Esb Data Weave
Compressing & decompressing in mule
Mule message enricher
Using message enricher
Groovy example in mule
Initialize database in Mule part2
Simple Java component in Mule
Configurare https mule
Caching and invalidating with managed store
Junit in mule demo
Mule esb - How to use Idempotent Filters in 5 minutes
Mule esb :Data Weave
Splitting with mule part2
Ad

Viewers also liked (16)

PPTX
Database integrate with mule
PPTX
Sending mail in mule
PPTX
Input and output flow with logger component
PPTX
Stored procedure in mule
PPTX
Integrate to retrieve data microsoft azure
PDF
Java Week6(B) Notepad
PPTX
Java Components and their applicability in Mule Anypoint Studio
PPTX
Mule: Java Component
PPTX
Basic example using file connector in anypoint studio
PDF
Java Swing Custom GUI MVC Component Tutorial
PPTX
Chapter 1 swings
PPT
java swing programming
PPT
Swing and AWT in java
PPT
java swing
PPTX
JAVA AWT
PDF
H2O - the optimized HTTP server
Database integrate with mule
Sending mail in mule
Input and output flow with logger component
Stored procedure in mule
Integrate to retrieve data microsoft azure
Java Week6(B) Notepad
Java Components and their applicability in Mule Anypoint Studio
Mule: Java Component
Basic example using file connector in anypoint studio
Java Swing Custom GUI MVC Component Tutorial
Chapter 1 swings
java swing programming
Swing and AWT in java
java swing
JAVA AWT
H2O - the optimized HTTP server
Ad

Similar to Input and output flow using http and java component (20)

PPTX
Mule hppt java
PPTX
Esb first http flow
PPTX
My mule esb first http flow
PPTX
Simple interact between http and java components
PPTX
Mule esb httpflow
PPTX
Mule esb lesson 1
PPTX
Symple io flow
PPTX
First lesson
PPTX
Mule connectors-session1
PPTX
Mule esb first http connector
PPTX
Mule esb first http connector
PPTX
Mule connectors-part 1
PPTX
Mule esb
PDF
Mule esb and_relevant_components
PDF
Mule ESB Interview or Certification questions
PPTX
Mule ESB Components
PDF
Top 50 MuleSoft interview questions
PPTX
Muleesbcomponents1 160625154208
PPTX
Create web services jax - ws2
PPTX
Introduce anypoint studio
Mule hppt java
Esb first http flow
My mule esb first http flow
Simple interact between http and java components
Mule esb httpflow
Mule esb lesson 1
Symple io flow
First lesson
Mule connectors-session1
Mule esb first http connector
Mule esb first http connector
Mule connectors-part 1
Mule esb
Mule esb and_relevant_components
Mule ESB Interview or Certification questions
Mule ESB Components
Top 50 MuleSoft interview questions
Muleesbcomponents1 160625154208
Create web services jax - ws2
Introduce anypoint studio

More from Son Nguyen (20)

PPTX
Wsdl connector introduction
PPTX
Android intergrate with mule
PPTX
Mule flow overview
PPTX
Mule flow and filter
PPTX
Handle exceptions in mule
PPT
Spring security integrate with mule
PPTX
Message processor in mule
PPTX
Expression language in mule
PPTX
Mule with data weave
PPTX
Using spring scheduler mule
PPTX
Composite source in bound and out-bound
PPT
Batch job processing
PPT
Finance connectors with mule
PPT
Google drive connection
PPTX
Using properties in mule
PPT
Mule integrate with microsoft
PPTX
Jms queue
PPT
Anypoint connectors
PPTX
Mule esb basic introduction
PPTX
Runing batch job in mule
Wsdl connector introduction
Android intergrate with mule
Mule flow overview
Mule flow and filter
Handle exceptions in mule
Spring security integrate with mule
Message processor in mule
Expression language in mule
Mule with data weave
Using spring scheduler mule
Composite source in bound and out-bound
Batch job processing
Finance connectors with mule
Google drive connection
Using properties in mule
Mule integrate with microsoft
Jms queue
Anypoint connectors
Mule esb basic introduction
Runing batch job in mule

Recently uploaded (20)

PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Empathic Computing: Creating Shared Understanding
PPTX
sap open course for s4hana steps from ECC to s4
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPT
Teaching material agriculture food technology
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PPTX
Cloud computing and distributed systems.
PDF
Encapsulation theory and applications.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
KodekX | Application Modernization Development
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
Big Data Technologies - Introduction.pptx
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
20250228 LYD VKU AI Blended-Learning.pptx
Network Security Unit 5.pdf for BCA BBA.
Understanding_Digital_Forensics_Presentation.pptx
Empathic Computing: Creating Shared Understanding
sap open course for s4hana steps from ECC to s4
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Dropbox Q2 2025 Financial Results & Investor Presentation
Teaching material agriculture food technology
Reach Out and Touch Someone: Haptics and Empathic Computing
Cloud computing and distributed systems.
Encapsulation theory and applications.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
KodekX | Application Modernization Development
Programs and apps: productivity, graphics, security and other tools
Big Data Technologies - Introduction.pptx
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx

Input and output flow using http and java component

  • 1. INPUT AND OUTPUT FLOW: USING HTTP AND JAVA COMPONENT
  • 2. OPEN ANYPOINT STUDIO CREATE A FILE  NEW  MULE PROJECT CLICK «FINISH»
  • 3. EXPAND THE «MYFIRSTPROJECT» ON PACKAGE EXPLORER DOUBLE CLICK ON MYFIRSTPROJECT.XML ONCE FILE IS OPEN, SHOW MESSAGE FLOW FROM MULE PALETTE VIEW, SEARCH FOR ‘HTTP’ AND ‘JAVA’ AND SELECT THE FIRST ONE. DRAG AND DROP HTTP THEN JAVA COMPONENT INTO MESSAGE FLOW VIEW.
  • 4. NOW WE HAVE TO CONFIGURE LISTENER FOR OUR HTTP FLOW. DOUBLE CLICK ON HTTP BLUE ELEMENT. BELOW IT WILL APPEAR HTTP VIEW. ON THE GENERAL SETTING LET’S CREATE AND CHOOSE AN HTTP LISTENER. CLICK ON ADD(+) AND CONFIGURE: HOST: DEFAULT (LOCALHOST) PORT: 8081 ON BASIC SETTINGS DEFINE WEB SERVICE: PATH: /FILETRANSFER ALLOW.METHODS: GET CLICK OK AND SAVE
  • 5. NOW WE HAVE TO CONFIGURE THE JAVA LOGIC COMPONENT. CREATE A PACKAGE AND A JAVA CLASS UNDER SRC/MAIN/JAVA FOLDER. CREATE A LOCAL FOLDER TO SAVE THE FILE. THE CLASS WILL CREATE A SIMPLE TEXT FILE AND WRITE TWO LINES. LIBRARIES I USED: JAVA.IO.FILE; JAVA.IO.FILEWRITER; CLICK ON SAVE AT TOP-LEFT OF SCREEN
  • 6. CONFIGURE JAVA COMPONENT. TRANSFORMER CLASS: THE CLASS THAT WILL DO THE LOGIC TO CREATE A FILE IN A LOCAL FOLDER. CLICK ON SAVE.
  • 7. NOW WE CAN START OUR MULE SERVER RIGHT CLICK ON PROJECT RUN AS  MULE APPLICATION ON THE CONSOLE VIEW BELOW SERVER IS GOING TO START. AT THE END YOU WILL SEE THE STATUS DEPLOYED. THIS MEANS THAT SERVER IS UP AND RUNNING OPEN YOUR BROWSER AND JOIN THE HTTP PATH: HTTP://LOCALHOST:8081/FILETRA NSFER NOW WE CAN SEE THE RESULT: OPEN THE FOLDER WE CREATED AND LOOK AT THE TXT FILE GENERATED. ENJOY WITH