SlideShare a Scribd company logo
Database Component In Mule
Demo
Abstract
• The main motto of this PPT is how to use
Database component in our applications.
Introduction
• The Database connector allows you to
connect with almost any Java Database
Connectivity (JDBC) relational database using
a single interface for every case. The Database
connector allows you to run diverse SQL
operations on your database, including Select,
Insert, Update, Delete, and even Stored
Procedures.
Example
• .mflow
• <?xml version="1.0" encoding="UTF-8"?>
• <mule xmlns:jdbc-ee="http://www.mulesoft.org/schema/mule/ee/jdbc" xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
• http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
• http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
• http://www.mulesoft.org/schema/mule/ee/jdbc http://www.mulesoft.org/schema/mule/ee/jdbc/current/mule-jdbc-ee.xsd">
• <jdbc-ee:mssql-data-source name="MS_SQL_Data_Source" user=“**" password=“****" url="jdbc:sqlserver://localhost;databaseName=test1"
transactionIsolation="UNSPECIFIED" doc:name="MS SQL Data Source"/>
• <jdbc-ee:connector name="Database" dataSource-ref="MS_SQL_Data_Source" validateConnections="true" queryTimeout="-1"
pollingFrequency="0" doc:name="Database"/>
• <flow name="Database_ComponentFlow1" doc:name="Database_ComponentFlow1">
• <http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8087" path="database" doc:name="HTTP"/>
• <logger message="--main flow--" level="INFO" doc:name="Logger"/>
• <jdbc-ee:outbound-endpoint exchange-pattern="request-response" queryKey="select" queryTimeout="-1" connector-ref="Database"
doc:name="Database">
• <jdbc-ee:query key="select" value="select * from mytable"/>
• </jdbc-ee:outbound-endpoint>
• <logger message="--Result is--#[payload]" level="INFO" doc:name="Logger"/>
• </flow>
• </mule>
• Output:
• INFO 2015-10-03 17:34:29,440 [[Database Component].config.change.2.thread.1] org.mule.DefaultMuleContext:
• **********************************************************************
• * Application: Database Component *
• * OS encoding: Cp1252, Mule encoding: UTF-8 *
• * *
• * Agents Running: *
• * Clustering Agent *
• * JMX Agent *
• **********************************************************************
• INFO 2015-10-03 17:34:29,441 [[Database Component].config.change.2.thread.1]
org.mule.module.launcher.MuleDeploymentService:
• ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
• + Started app 'Database Component' +
• ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
• INFO 2015-10-03 17:34:35,704 [[Database Component].connector.http.mule.default.receiver.02]
org.mule.api.processor.LoggerMessageProcessor: --main flow--
• INFO 2015-10-03 17:34:35,705 [[Database Component].connector.http.mule.default.receiver.02]
org.mule.lifecycle.AbstractLifecycleManager: Initialising: 'Database.dispatcher.1030403796'. Object is:
EEJdbcMessageDispatcher
• INFO 2015-10-03 17:34:35,705 [[Database Component].connector.http.mule.default.receiver.02]
org.mule.lifecycle.AbstractLifecycleManager: Starting: 'Database.dispatcher.1030403796'. Object is:
EEJdbcMessageDispatcher
• INFO 2015-10-03 17:34:35,815 [[Database Component].connector.http.mule.default.receiver.02]
org.mule.api.processor.LoggerMessageProcessor: --Result is--[{subj=Hindi, marks=55, name=Ramesh, id=1},
{subj=English, marks=65, name=Mahesh, id=2}, {subj=science, marks=75, name=Pavan, id=3}, {subj=social,
marks=45, name=Siva, id=4}]
• Flow of execution:
1. URL to trigger the service from browser
http://localhost:8087/database
2. Database component connects to the specific
database, executes the select query and prints
the result
References
• https://docs.mulesoft.com/mule-user-
guide/v/3.7/database-connector

More Related Content

PPTX
Until successful component in mule demo
PPTX
Mule Message Properties Component
PPTX
Choice component in mule
PPTX
Database component in mule demo
PPTX
Mule architecture
PPT
Anypoint data gateway
PPT
Mule and web services
PPTX
Database component in mule
Until successful component in mule demo
Mule Message Properties Component
Choice component in mule
Database component in mule demo
Mule architecture
Anypoint data gateway
Mule and web services
Database component in mule

What's hot (19)

PPT
Maven introduction in Mule
PPT
Anypoint data gateway
PDF
Mule Integration Simplified
PPTX
Webservice vm in mule
PPTX
Mule high availability (ha) cluster
PPTX
Send email attachment using smtp in mule esb
PPTX
Configuration patterns in mule
PPTX
Vm component in mule
PPTX
For each component in mule demo
PPTX
Mule quartz hari_gatadi
PPT
Mule anypoint data gateway
PPTX
Cloud hub and mule
PPTX
Mule esb
PPTX
Introduction to mule esb
PPT
Introduction to es bs mule
PPTX
Integration with Microsoft Azure using Mule ESB
PPTX
Expression filter in Mule
PPTX
MuleSoft ESB Composite Source
PPTX
Using mule with web services
Maven introduction in Mule
Anypoint data gateway
Mule Integration Simplified
Webservice vm in mule
Mule high availability (ha) cluster
Send email attachment using smtp in mule esb
Configuration patterns in mule
Vm component in mule
For each component in mule demo
Mule quartz hari_gatadi
Mule anypoint data gateway
Cloud hub and mule
Mule esb
Introduction to mule esb
Introduction to es bs mule
Integration with Microsoft Azure using Mule ESB
Expression filter in Mule
MuleSoft ESB Composite Source
Using mule with web services
Ad

Viewers also liked (20)

PPTX
Mule esb
PPTX
Why Integrate using an API? | MuleSoft
PPTX
Mule core concepts
PPTX
Mule File component
PPT
Anypoint connectorfor ibm as 400
PPTX
Github plugin setup in anypoint studio
PPTX
Mule for each scope headerc ollection
PPTX
Mule with rabbit mq
PPTX
Mule Jetty transport
PPTX
Shipping your logs to elk from mule app/cloudhub part 3
PPTX
Core concepts in mule
PPTX
Bindings of components in mule
PPTX
Mule esb for beginners
PPT
Mule introduction
PPT
Anypoint data gateway
PPTX
Error handling with respect to mule
PPT
Multi saas integrations
PPTX
Mule esb How to use Collection Splitter in 5 minutes
PPT
Dataweavewithflowreflookup
PPTX
Mule esb stripe
Mule esb
Why Integrate using an API? | MuleSoft
Mule core concepts
Mule File component
Anypoint connectorfor ibm as 400
Github plugin setup in anypoint studio
Mule for each scope headerc ollection
Mule with rabbit mq
Mule Jetty transport
Shipping your logs to elk from mule app/cloudhub part 3
Core concepts in mule
Bindings of components in mule
Mule esb for beginners
Mule introduction
Anypoint data gateway
Error handling with respect to mule
Multi saas integrations
Mule esb How to use Collection Splitter in 5 minutes
Dataweavewithflowreflookup
Mule esb stripe
Ad

Similar to Mule Database component (20)

PPTX
Database Component
PPTX
Basic example using database component
PPTX
How to use bean as datasource in database connector
PPTX
Bean as Datasource
PPTX
Mule new jdbc component
PPTX
Database Access in mule ESB
PPTX
Database integrate with mule
PPTX
Mule jdbc
PPT
Mule database connector
PPTX
PPTX
Integrate with database by groovy
PPTX
Mule ESB Components
PPTX
Muleesbcomponents1 160625154208
PPTX
Calling database with groovy in mule
PPTX
Mule esb – connecting to ms sql db
PPT
Mule database-connectors
PPT
MuleSoft Database Connector
PPT
Mule database-connectors
PPT
Mule database-connectors
PPT
Mule database-connectors
Database Component
Basic example using database component
How to use bean as datasource in database connector
Bean as Datasource
Mule new jdbc component
Database Access in mule ESB
Database integrate with mule
Mule jdbc
Mule database connector
Integrate with database by groovy
Mule ESB Components
Muleesbcomponents1 160625154208
Calling database with groovy in mule
Mule esb – connecting to ms sql db
Mule database-connectors
MuleSoft Database Connector
Mule database-connectors
Mule database-connectors
Mule database-connectors

More from AbdulImrankhan7 (20)

PPT
Web services Overview in depth
PPTX
Install sonarqube plugin
PPTX
Junit in mule
PPTX
commit a project in svn
PPTX
Github plugin setup in anypoint studio
PPTX
For each component
PPTX
Filter expression
PPTX
Mule Choice component
PPTX
Mule stored procedure
PPTX
Deploying and running in mule standalone
PPT
Mule real-world
PPT
Mule Overview
PPTX
Webservice with vm in mule
PPTX
Validating a soap request in mule
PPTX
Using xslt in mule
PPTX
Simple groovy example in mule
PPTX
Scatter gather flow control
PPTX
Mule with velocity
PPTX
Mule with rabbit mq
PPTX
Mule with quartz
Web services Overview in depth
Install sonarqube plugin
Junit in mule
commit a project in svn
Github plugin setup in anypoint studio
For each component
Filter expression
Mule Choice component
Mule stored procedure
Deploying and running in mule standalone
Mule real-world
Mule Overview
Webservice with vm in mule
Validating a soap request in mule
Using xslt in mule
Simple groovy example in mule
Scatter gather flow control
Mule with velocity
Mule with rabbit mq
Mule with quartz

Recently uploaded (20)

PDF
A comparative analysis of optical character recognition models for extracting...
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
Cloud computing and distributed systems.
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Approach and Philosophy of On baking technology
PDF
Empathic Computing: Creating Shared Understanding
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Electronic commerce courselecture one. Pdf
PDF
cuic standard and advanced reporting.pdf
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
A comparative analysis of optical character recognition models for extracting...
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
“AI and Expert System Decision Support & Business Intelligence Systems”
Review of recent advances in non-invasive hemoglobin estimation
Diabetes mellitus diagnosis method based random forest with bat algorithm
Per capita expenditure prediction using model stacking based on satellite ima...
Cloud computing and distributed systems.
NewMind AI Weekly Chronicles - August'25-Week II
Dropbox Q2 2025 Financial Results & Investor Presentation
20250228 LYD VKU AI Blended-Learning.pptx
Approach and Philosophy of On baking technology
Empathic Computing: Creating Shared Understanding
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Advanced methodologies resolving dimensionality complications for autism neur...
Chapter 3 Spatial Domain Image Processing.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Electronic commerce courselecture one. Pdf
cuic standard and advanced reporting.pdf
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows

Mule Database component

  • 2. Abstract • The main motto of this PPT is how to use Database component in our applications.
  • 3. Introduction • The Database connector allows you to connect with almost any Java Database Connectivity (JDBC) relational database using a single interface for every case. The Database connector allows you to run diverse SQL operations on your database, including Select, Insert, Update, Delete, and even Stored Procedures.
  • 5. • .mflow • <?xml version="1.0" encoding="UTF-8"?> • <mule xmlns:jdbc-ee="http://www.mulesoft.org/schema/mule/ee/jdbc" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd • http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd • http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd • http://www.mulesoft.org/schema/mule/ee/jdbc http://www.mulesoft.org/schema/mule/ee/jdbc/current/mule-jdbc-ee.xsd"> • <jdbc-ee:mssql-data-source name="MS_SQL_Data_Source" user=“**" password=“****" url="jdbc:sqlserver://localhost;databaseName=test1" transactionIsolation="UNSPECIFIED" doc:name="MS SQL Data Source"/> • <jdbc-ee:connector name="Database" dataSource-ref="MS_SQL_Data_Source" validateConnections="true" queryTimeout="-1" pollingFrequency="0" doc:name="Database"/> • <flow name="Database_ComponentFlow1" doc:name="Database_ComponentFlow1"> • <http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8087" path="database" doc:name="HTTP"/> • <logger message="--main flow--" level="INFO" doc:name="Logger"/> • <jdbc-ee:outbound-endpoint exchange-pattern="request-response" queryKey="select" queryTimeout="-1" connector-ref="Database" doc:name="Database"> • <jdbc-ee:query key="select" value="select * from mytable"/> • </jdbc-ee:outbound-endpoint> • <logger message="--Result is--#[payload]" level="INFO" doc:name="Logger"/> • </flow> • </mule>
  • 6. • Output: • INFO 2015-10-03 17:34:29,440 [[Database Component].config.change.2.thread.1] org.mule.DefaultMuleContext: • ********************************************************************** • * Application: Database Component * • * OS encoding: Cp1252, Mule encoding: UTF-8 * • * * • * Agents Running: * • * Clustering Agent * • * JMX Agent * • ********************************************************************** • INFO 2015-10-03 17:34:29,441 [[Database Component].config.change.2.thread.1] org.mule.module.launcher.MuleDeploymentService: • ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ • + Started app 'Database Component' + • ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ • INFO 2015-10-03 17:34:35,704 [[Database Component].connector.http.mule.default.receiver.02] org.mule.api.processor.LoggerMessageProcessor: --main flow-- • INFO 2015-10-03 17:34:35,705 [[Database Component].connector.http.mule.default.receiver.02] org.mule.lifecycle.AbstractLifecycleManager: Initialising: 'Database.dispatcher.1030403796'. Object is: EEJdbcMessageDispatcher • INFO 2015-10-03 17:34:35,705 [[Database Component].connector.http.mule.default.receiver.02] org.mule.lifecycle.AbstractLifecycleManager: Starting: 'Database.dispatcher.1030403796'. Object is: EEJdbcMessageDispatcher • INFO 2015-10-03 17:34:35,815 [[Database Component].connector.http.mule.default.receiver.02] org.mule.api.processor.LoggerMessageProcessor: --Result is--[{subj=Hindi, marks=55, name=Ramesh, id=1}, {subj=English, marks=65, name=Mahesh, id=2}, {subj=science, marks=75, name=Pavan, id=3}, {subj=social, marks=45, name=Siva, id=4}]
  • 7. • Flow of execution: 1. URL to trigger the service from browser http://localhost:8087/database 2. Database component connects to the specific database, executes the select query and prints the result